mirror of
https://github.com/ProjectSWGCore/NGECore2.git
synced 2026-08-04 05:16:21 -04:00
Added posture checks, radial script for player objects, bug fixes
(Bug Fix) Must now wait before performing multiple flourishes (Bug Fix) Can no longer propose to yourself (aka your hand) (Bug Fix) Fixed some strings that didn't have variables (Added) Posture checks before Skill Animating (Added) Additional radial options show on players
This commit is contained in:
@@ -429,8 +429,7 @@ public class EntertainmentService implements INetworkDispatch {
|
||||
public void run() {
|
||||
if (spectator.getPosition().getDistance2D(performer.getWorldPosition()) > (float) 70) {
|
||||
|
||||
String pType = (performer.getPerformanceType()) ? "dance" : "music";
|
||||
if(pType.equals("dance")) {
|
||||
if(((performer.getPerformanceType()) ? "dance" : "music").equals("dance")) {
|
||||
spectator.setPerformanceWatchee(null);
|
||||
spectator.sendSystemMessage("You stop watching " + performer.getCustomName() + " because " + performer.getCustomName()
|
||||
+ " is out of range.", (byte) 0);
|
||||
@@ -452,6 +451,36 @@ public class EntertainmentService implements INetworkDispatch {
|
||||
spectator.setSpectatorTask(spectatorTask);
|
||||
}
|
||||
|
||||
public void performFlourish(final CreatureObject performer, int flourish) {
|
||||
|
||||
if (performer.getFlourishCount() > 0) {
|
||||
performer.sendSystemMessage("@performance:wait_flourish_self", (byte) 0);
|
||||
return;
|
||||
}
|
||||
Performance performance = getPerformanceByIndex(performer.getPerformanceId());
|
||||
|
||||
if(performance == null)
|
||||
return;
|
||||
|
||||
String anmFlo = "skill_action_" + flourish;
|
||||
|
||||
if (flourish == 9)
|
||||
anmFlo = "mistake";
|
||||
|
||||
performer.setFlourishCount(1);
|
||||
performer.sendSystemMessage("@performance:flourish_perform", (byte) 0);
|
||||
performer.doSkillAnimation(anmFlo);
|
||||
|
||||
scheduler.schedule(new Runnable() {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
performer.setFlourishCount(0);
|
||||
}
|
||||
|
||||
}, (long) performance.getLoopDuration(), TimeUnit.SECONDS);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void shutdown() {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user