fix note bubbles for dance (both for starting and stopping)

This commit is contained in:
darkk1138
2013-12-09 10:36:21 +01:00
parent 51207c5803
commit 93ba62cd4f
3 changed files with 7 additions and 3 deletions
+4 -2
View File
@@ -69,7 +69,7 @@ def startDance(core, actor, danceName, visual):
actor.sendSystemMessage('@performance:dance_lack_skill_self',0)
return
if actor.getPerformanceId() > 0:
if actor.getPosture() == 0x09:
actor.sendSystemMessage('@performance:already_performing_self',0)
return
@@ -89,8 +89,10 @@ def startDance(core, actor, danceName, visual):
dance = entSvc.getDance(visual)
# performanceId > 0 seems to trigger the note bubble stuff, so use 0 here
# instead of dance.getLineNumber()
# send CREO6 here
# second param is some sort of counter or start tick
actor.startPerformance(dance.getLineNumber(), -842249156 , danceVisual, 1)
actor.startPerformance(0, -842249156 , danceVisual, 1)
return
+1 -1
View File
@@ -6,7 +6,7 @@ def setup():
def run(core, actor, target, commandString):
entSvc = core.entertainmentService
if (actor.getPerformanceId() <= 0):
if actor.getPosture() != 0x09 or actor.getPerformanceId() > 0:
actor.sendSystemMessage('@performance:dance_not_performing', 0)
return
@@ -1428,6 +1428,8 @@ public class CreatureObject extends TangibleObject implements IPersistent {
sendSystemMessage("@performance:" + type + "_stop_self",(byte)0);
notifyAudience("@performance:" + type + "_stop_other");
getClient().getSession().write(messageBuilder.buildPerformanceId(performanceId));
getClient().getSession().write(messageBuilder.buildPerformanceCounter(performanceCounter));
getClient().getSession().write(messageBuilder.buildStartPerformance(false));
}