|
Hi guys,
Getting back into coding after an extremely long time out of the game - hence the noob code below.
Just wanted to know - how do I make it so that the animation complete before the XP is given? so that it looks like once the player finishes the fletching emote it grants the xp because he has actually finished fletching rather than as soon as the player starts the emote xp is granted?
I'm still unsure of how to use action timers and that so if someone could give me a simple fix that'd be great
RegardsCode:if ((itemUsed == 1507) && (useWith == 5605)) { setAnimation(1248); actionTimer = 4; addSkillXP(185, 17); AnimationReset = true; updateRequired = true; appearanceUpdateRequired = true; }
Viper
Thanks for the reply mate.
Don't have that anim only setAnimation.
But basically I want it to complete the animation before the xp goes through :\
I have no clue what sheepmonger is talking about
actual answer: use task/events
example:
Code:// do the animation player.animation(new Animation(...)); // wait 1.2 seconds then add the exp GameServer.getWorld().submit(new Worker(2, false) { @Override public void fire() { player.getSkills[...].addExperience(...); this.cancel(); } });
« Previous Thread | Next Thread » |
Thread Information |
Users Browsing this ThreadThere are currently 1 users browsing this thread. (0 members and 1 guests) |