TargetSelected.java 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. /*
  2. * This program is free software: you can redistribute it and/or modify it under
  3. * the terms of the GNU General Public License as published by the Free Software
  4. * Foundation, either version 3 of the License, or (at your option) any later
  5. * version.
  6. *
  7. * This program is distributed in the hope that it will be useful, but WITHOUT
  8. * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  9. * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
  10. * details.
  11. *
  12. * You should have received a copy of the GNU General Public License along with
  13. * this program. If not, see <http://www.gnu.org/licenses/>.
  14. */
  15. package com.l2jserver.gameserver.network.serverpackets;
  16. /**
  17. * format ddddd
  18. *
  19. * sample
  20. * 0000: 39 0b 07 10 48 3e 31 10 48 3a f6 00 00 91 5b 00 9...H>1.H:....[.
  21. * 0010: 00 4c f1 ff ff .L...
  22. *
  23. * @version $Revision: 1.3.2.1.2.3 $ $Date: 2005/03/27 15:29:39 $
  24. */
  25. public final class TargetSelected extends L2GameServerPacket
  26. {
  27. private static final String _S__39_TARGETSELECTED = "[S] 23 TargetSelected";
  28. private int _objectId;
  29. private int _targetObjId;
  30. private int _x;
  31. private int _y;
  32. private int _z;
  33. /**
  34. * @param _characters
  35. */
  36. public TargetSelected(int objectId, int targetId, int x, int y, int z)
  37. {
  38. _objectId = objectId;
  39. _targetObjId = targetId;
  40. _x = x;
  41. _y = y;
  42. _z = z;
  43. }
  44. @Override
  45. protected final void writeImpl()
  46. {
  47. writeC(0x23);
  48. writeD(_objectId);
  49. writeD(_targetObjId);
  50. writeD(_x);
  51. writeD(_y);
  52. writeD(_z);
  53. writeD(0x00);
  54. }
  55. /* (non-Javadoc)
  56. * @see com.l2jserver.gameserver.serverpackets.ServerBasePacket#getType()
  57. */
  58. @Override
  59. public String getType()
  60. {
  61. return _S__39_TARGETSELECTED;
  62. }
  63. }