Jump to content

Question

2 answers to this question

Recommended Posts

  • 0
Posted (edited)

Exemple with scheme posted for aCis..

 

java/net/sf/l2j/gameserver/model/actor/instance/SchemeBuffer

 

For all buffs animation:

  1.  public void onBypassFeedback(Player player, String command)
  2.  {
  3.  StringTokenizer st = new StringTokenizer(command, " ");
  4.  String currentCommand = st.nextToken();
  5. +
  6.  if (currentCommand.startsWith("menu"))
  7.  {
  8.  NpcHtmlMessage html = new NpcHtmlMessage(1);
  9.  html.setFile(getHtmlPath(getNpcId(), 0));
  10.  html.replace("%objectId%", getObjectId());
  11.  player.sendPacket(html);
  12.  }
  13.  else if (currentCommand.equalsIgnoreCase("getbuff"))
  14.  {
  15.  int buffid = 0;
  16.  int bufflevel = 1;
  17.  String nextWindow = null;
  18.  
  19.  if (st.countTokens() == 3)
  20.  {
  21.  buffid = Integer.valueOf(st.nextToken());
  22.  bufflevel = Integer.valueOf(st.nextToken());
  23.  nextWindow = st.nextToken();
  24.  }
  25.  else if (st.countTokens() == 1)
  26.  buffid = Integer.valueOf(st.nextToken());
  27.  
  28.  if (buffid != 0)
  29.  {
  30. + player.broadcastPacket(new MagicSkillUse(this, player, buffid, bufflevel, 200, 0));
  31.  
  32.  player.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.YOU_FEEL_S1_EFFECT).addSkillName(buffid, bufflevel));
  33.  SkillTable.getInstance().getInfo(buffid, bufflevel).getEffects(this, player);
  34.  showSubBufferWindow(player);
  35.  showChatWindow(player, nextWindow);
  36.  }
  37.  }
 
  1. For Cancel Animation:
 
  1.  else if (currentCommand.startsWith("cleanup"))
  2.  {
  3.  +player.broadcastPacket(new MagicSkillUse(this, player, 1056, 12, 200, 0));
  4.  player.stopAllEffectsExceptThoseThatLastThroughDeath();
  5.  
  6.  final Summon summon = player.getSummon();
  7.  if (summon != null)
  8.  summon.stopAllEffectsExceptThoseThatLastThroughDeath();
  9.  
  10.  NpcHtmlMessage html = new NpcHtmlMessage(1);
  11.  html.setFile(getHtmlPath(getNpcId(), 0));
  12.  html.replace("%objectId%", getObjectId());
  13.  player.sendPacket(html);
  14.  }
 
Player use animation of buff on get buffs
player.sendPacket(new MagicSkillUse(player, player, buffid, bufflevel, 1000, 0));
 
NPC use SocialAction
player.sendPacket(new SocialAction(this.getObjectId(), 1));
Edited by Orochy

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...