Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public String parseToGM()
- {
- StringBuilder str = new StringBuilder();
- if(_fight == null)// Hors combat
- {
- str.append(_curCell.getID()).append(";").append(_orientation).append(";");
- str.append("0").append(";");//ActorId: Défini le type d'acteur e.g: player, offlinePlayer, mobs, prisme, perco, etc
- str.append(_GUID).append(";").append(_name).append(";").append(_classe);
- str.append((this.get_title()>0?(","+this.get_title()+";"):(";")));
- str.append(_gfxID).append("^").append(_size).append(";");//gfxID^size
- str.append(_sexe).append(";").append(_align).append(",");//1,0,0,4055064
- str.append(_align).append(",");//FIXED FakeAlign je crois
- str.append((_showWings?getGrade():"0")).append(",");
- str.append(_lvl+_GUID).append(";");//FIXED ça c'est pour voir les ailes grisé/lumineuse des autres joueurs
- str.append((_color1==-1?"-1":Integer.toHexString(_color1))).append(";");
- str.append((_color2==-1?"-1":Integer.toHexString(_color2))).append(";");
- str.append((_color3==-1?"-1":Integer.toHexString(_color3))).append(";");
- str.append(getGMStuffString()).append(";");
- if(Ancestra.AURA_SYSTEM)
- {
- str.append((_lvl>99?(_lvl>199?(2):(1)):(0))).append(";");
- }else
- {
- str.append("0;");
- }
- str.append(_emoteActive).append(";");//Emote
- str.append(_emoteTime).append(";");//Emote timer
- if(this._guildMember!=null && this._guildMember.getGuild().getMembers().size()>9)
- {
- str.append(this._guildMember.getGuild().get_name()).append(";").append(this._guildMember.getGuild().get_emblem()).append(";");
- }
- else str.append(";;");
- str.append(get_Speed()).append(";");//TODO: Make Restriction
- str.append((_onMount&&_mount!=null?_mount.get_color():"")).append(";");
- str.append(";");
- }
- return str.toString();
- }
- //On crée deux champs:
- private int _emoteTime = 360000;
- private Timer emoteTimer = new Timer(1000, null);
- //Remplacer set_emoteActive ou setEmoteActive (enfin je sais pas moi je lai renommé en setEmoteActive()...) par:
- public void setEmoteActive(int emoteActive)
- {
- this._emoteActive = emoteActive;
- if(emoteTimer.isRunning())
- {
- _emoteTime = 360000;
- emoteTimer.restart();
- } else
- {
- emoteTimer.addActionListener(new ActionListener()
- {
- @Override
- public void actionPerformed(ActionEvent arg0) {
- if(_emoteTime > 0) {
- _emoteTime = _emoteTime - 1000;
- }
- if(_emoteTime <= 0) {
- _emoteTime = 360000;
- _emoteActive = 0;
- emoteTimer.stop();
- }
- }
- });
- emoteTimer.start();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment