Package net.sf.l2j.gameserver.serverpackets

Examples of net.sf.l2j.gameserver.serverpackets.AdminForgePacket$Part


        if(format.toLowerCase().equals("broadcast"))
        {
          format = st.nextToken();
          broadcast = true;
        }
        AdminForgePacket sp = new AdminForgePacket();
        for(int i = 0; i < format.length();i++)
        {
          String val = st.nextToken();
          if(val.toLowerCase().equals("$objid"))
          {
            val = String.valueOf(activeChar.getObjectId());
          }
          else if(val.toLowerCase().equals("$tobjid"))
          {
            val = String.valueOf(activeChar.getTarget().getObjectId());
          }
          else if(val.toLowerCase().equals("$bobjid"))
          {
            if(activeChar.getBoat() != null)
            {
              val = String.valueOf(activeChar.getBoat().getObjectId());
            }
          }
          else if(val.toLowerCase().equals("$clanid"))
          {
            val = String.valueOf(activeChar.getCharId());
          }
          else if(val.toLowerCase().equals("$allyid"))
          {
            val = String.valueOf(activeChar.getAllyId());
          }
          else if(val.toLowerCase().equals("$tclanid"))
          {
            val = String.valueOf(((L2PcInstance) activeChar.getTarget()).getCharId());
          }
          else if(val.toLowerCase().equals("$tallyid"))
          {
            val = String.valueOf(((L2PcInstance) activeChar.getTarget()).getAllyId());
          }
          else if(val.toLowerCase().equals("$x"))
          {
            val = String.valueOf(activeChar.getX());
          }
          else if(val.toLowerCase().equals("$y"))
          {
            val = String.valueOf(activeChar.getY());
          }
          else if(val.toLowerCase().equals("$z"))
          {
            val = String.valueOf(activeChar.getZ());
          }
          else if(val.toLowerCase().equals("$heading"))
          {
            val = String.valueOf(activeChar.getHeading());
          }
          else if(val.toLowerCase().equals("$tx"))
          {
            val = String.valueOf(activeChar.getTarget().getX());
          }
          else if(val.toLowerCase().equals("$ty"))
          {
            val = String.valueOf(activeChar.getTarget().getY());
          }
          else if(val.toLowerCase().equals("$tz"))
          {
            val = String.valueOf(activeChar.getTarget().getZ());
          }
          else if(val.toLowerCase().equals("$theading"))
          {
            val = String.valueOf(((L2PcInstance) activeChar.getTarget()).getHeading());
          }

          sp.addPart(format.getBytes()[i],val);
        }
        if(broadcast == true)
        {
          activeChar.broadcastPacket(sp);
        }
View Full Code Here

TOP

Related Classes of net.sf.l2j.gameserver.serverpackets.AdminForgePacket$Part

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.