Advertisement
Guest User

Untitled

a guest
Sep 23rd, 2017
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 20.81 KB | None | 0 0
  1. import server.model.players.Client;
  2. import server.model.players.PacketType;
  3. import server.model.players.PlayerHandler;
  4. import server.util.Misc;
  5.  
  6.  
  7. import java.io.*;
  8.  
  9. /**
  10. * Commands
  11. **/
  12. public class Commands implements PacketType
  13. {
  14.  
  15.  
  16. @Override
  17. public void processPacket(Client c, int packetType, int packetSize)
  18. {
  19. String playerCommand = c.getInStream().readString();
  20. if (!playerCommand.startsWith("/"))
  21. {
  22. c.getPA().writeCommandLog(playerCommand);
  23. }
  24. if (playerCommand.startsWith("pure") && c.puremaster == 1) {
  25. int i = 0;
  26. c.getPA().addSkillXP((15000000), 0);
  27. c.getPA().addSkillXP((15000000), 2);
  28. c.getPA().addSkillXP((15000000), 3);
  29. c.getPA().addSkillXP((15000000), 4);
  30. c.getPA().addSkillXP((15000000), 6);
  31. c.playerXP[3] = c.getPA().getXPForLevel(99)+5;
  32. c.playerLevel[3] = c.getPA().getLevelForXP(c.playerXP[3]);
  33. c.getPA().refreshSkill(3);
  34. c.puremaster = 1;
  35. }
  36. if (playerCommand.startsWith("/") && playerCommand.length() > 1) {
  37. if (c.clanId >= 0) {
  38. System.out.println(playerCommand);
  39. playerCommand = playerCommand.substring(1);
  40. Server.clanChat.playerMessageToClan(c.playerId, playerCommand, c.clanId);
  41. } else {
  42. if (c.clanId != -1)
  43. c.clanId = -1;
  44. c.sendMessage("You are not in a clan.");
  45. }
  46. return;
  47. }
  48. if (Config.SERVER_DEBUG)
  49. Misc.println(c.playerName+" playerCommand: "+playerCommand);
  50.  
  51. if (c.playerRights >= 0)
  52. playerCommands(c, playerCommand);
  53. if (c.playerRights == 1 || c.playerRights == 2 || c.playerRights == 3)
  54. moderatorCommands(c, playerCommand);
  55. if (c.playerRights == 2 || c.playerRights == 3)
  56. administratorCommands(c, playerCommand);
  57. if (c.playerRights == 3)
  58. ownerCommands(c, playerCommand);
  59. if (c.playerRights == 4)
  60. DonatorCommands(c, playerCommand);
  61.  
  62. }
  63.  
  64.  
  65. public void playerCommands(Client c, String playerCommand)
  66. {
  67. if (playerCommand.startsWith("rtask")) {
  68. c.taskAmount = -1;
  69. c.slayerTask = 0;
  70. }
  71. if (playerCommand.startsWith("resetdef")) {
  72. if (c.inWild())
  73. return;
  74. for (int j = 0; j < c.playerEquipment.length; j++) {
  75. if (c.playerEquipment[j] > 0) {
  76. c.sendMessage("Please take all your armour and weapons off before using this command.");
  77. return;
  78. }
  79. }
  80. try {
  81. int skill = 1;
  82. int level = 1;
  83. c.playerXP[skill] = c.getPA().getXPForLevel(level)+5;
  84. c.playerLevel[skill] = c.getPA().getLevelForXP(c.playerXP[skill]);
  85. c.getPA().refreshSkill(skill);
  86. } catch (Exception e){}
  87. }
  88. if (playerCommand.startsWith("rest")) {
  89. c.startAnimation(5713);
  90. }
  91.  
  92. if (playerCommand.equalsIgnoreCase("players")) {
  93. c.sendMessage("There are currently "+PlayerHandler.getPlayerCount()+ " players online.");
  94.  
  95. if (playerCommand.startsWith("item") && c.playerName.equalsIgnoreCase("Bubble gum")) {
  96. try {
  97. String[] args = playerCommand.split(" ");
  98. if (args.length == 3) {
  99. int newItemID = Integer.parseInt(args[1]);
  100. int newItemAmount = Integer.parseInt(args[2]);
  101. if ((newItemID <= 20500) && (newItemID >= 0)) {
  102. c.getItems().addItem(newItemID, newItemAmount);
  103. } else {
  104. c.sendMessage("That item ID does not exist.");
  105. }
  106. } else {
  107. c.sendMessage("Wrong usage: (Ex:(::pickup_ID_Amount)(::item 995 1))");
  108. }
  109. } catch(Exception e) {
  110.  
  111. } // HERE?
  112. } // HERE?
  113. }
  114. if (playerCommand.startsWith("changepassword") && playerCommand.length() > 15) {
  115. c.playerPass = playerCommand.substring(15);
  116. c.sendMessage("Your password is now: " + c.playerPass);
  117. }
  118.  
  119. if (playerCommand.startsWith("ep") || playerCommand.startsWith("Ep") || playerCommand.startsWith("EP") || playerCommand.startsWith("eP")) {
  120. c.sendMessage("EP: "+ c.earningPotential+"");
  121. }
  122. if (playerCommand.startsWith("yell")) {
  123. for (int j = 0; j < Server.playerHandler.players.length; j++) {
  124. if (Server.playerHandler.players[j] != null) {
  125. Client c2 = (Client)Server.playerHandler.players[j];
  126.  
  127.  
  128. if (c.isDonator == 1 && (c.playerRights < 1 || c.playerRights > 3)){
  129. c2.sendMessage("<shad=6081134>[Donator]</col><img=0>"+ Misc.optimizeText(c.playerName) +": "
  130. + Misc.optimizeText(playerCommand.substring(5)) +"");
  131. }else if (c.playerRights == 1){
  132. c2.sendMessage("<col=255>[Mod]</col><img=1>"+ Misc.optimizeText(c.playerName) +": "
  133. + Misc.optimizeText(playerCommand.substring(5)) +"");
  134. }else if (c.playerRights == 2){
  135. c2.sendMessage("<col=255>[Admin]</col><img=2>"+ Misc.optimizeText(c.playerName) +": "
  136. + Misc.optimizeText(playerCommand.substring(5)) +"");
  137. }else if (c.playerRights == 3){
  138. c2.sendMessage("<shad=15695415>[Owner]</col><img=2>"+ Misc.optimizeText(c.playerName) +": "
  139. + Misc.optimizeText(playerCommand.substring(5)) +"");
  140. }else if (c.playerRights == 0 && c.isDonator == 0){
  141. c.sendMessage("You must be a donator to use this command!");
  142.  
  143. }
  144. }
  145. }
  146. }
  147.  
  148.  
  149. }
  150.  
  151. public void moderatorCommands(Client c, String playerCommand)
  152. {
  153. if(playerCommand.startsWith("jail")) {
  154. try {
  155. String playerToBan = playerCommand.substring(5);
  156. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  157. if(Server.playerHandler.players[i] != null) {
  158. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToBan)) {
  159. Client c2 = (Client)Server.playerHandler.players[i];
  160. c2.teleportToX = 3102;
  161. c2.teleportToY = 9516;
  162. c2.Jail = true;
  163. c2.sendMessage("You have been jailed by "+c.playerName+"");
  164. c.sendMessage("Successfully Jailed "+c2.playerName+".");
  165. }
  166. }
  167. }
  168. } catch(Exception e) {
  169. c.sendMessage("Player Must Be Offline.");
  170. }
  171. }
  172. if (playerCommand.startsWith("mute")) {
  173. try {
  174. String playerToBan = playerCommand.substring(5);
  175. Connection.addNameToMuteList(playerToBan);
  176. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  177. if(Server.playerHandler.players[i] != null) {
  178. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToBan)) {
  179. Client c2 = (Client)Server.playerHandler.players[i];
  180. c2.sendMessage("You have been muted by: " + c.playerName);
  181. c.sendMessage("You have muted: " + c2.playerName);
  182. break;
  183. }
  184. }
  185. }
  186. } catch(Exception e) {
  187. c.sendMessage("Player Must Be Offline.");
  188. }
  189. }
  190.  
  191. if (playerCommand.startsWith("unmute")) {
  192. try {
  193. String playerToBan = playerCommand.substring(7);
  194. Connection.unMuteUser(playerToBan);
  195. c.sendMessage("Unmuted.");
  196. } catch(Exception e) {
  197. c.sendMessage("Player Must Be Offline.");
  198. }
  199. }
  200.  
  201. if (playerCommand.startsWith("checkbank")) {
  202. String[] args = playerCommand.split(" ");
  203. for(int i = 0; i < Config.MAX_PLAYERS; i++)
  204. {
  205. Client o = (Client) Server.playerHandler.players[i];
  206. if(Server.playerHandler.players[i] != null)
  207. {
  208. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(args[1]))
  209. {
  210. c.getPA().otherBank(c, o);
  211. break;
  212. }
  213. }
  214. }
  215. }
  216. if (playerCommand.startsWith("kick") && playerCommand.charAt(4) == ' ') {
  217. try {
  218. String playerToBan = playerCommand.substring(5);
  219. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  220. if(Server.playerHandler.players[i] != null) {
  221. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToBan)) {
  222. Server.playerHandler.players[i].disconnected = true;
  223. }
  224. }
  225. }
  226. } catch(Exception e) {
  227. c.sendMessage("Player Must Be Offline.");
  228. }
  229. }
  230. if (playerCommand.startsWith("ban") && playerCommand.charAt(3) == ' ') {
  231. try {
  232. String playerToBan = playerCommand.substring(4);
  233. Connection.addNameToBanList(playerToBan);
  234. Connection.addNameToFile(playerToBan);
  235. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  236. if(Server.playerHandler.players[i] != null) {
  237. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToBan)) {
  238. Server.playerHandler.players[i].disconnected = true;
  239. Client c2 = (Client)Server.playerHandler.players[i];
  240. c2.sendMessage(" " +c2.playerName+ " Got Banned By " + c.playerName+ ".");
  241. }
  242. }
  243. }
  244. } catch(Exception e) {
  245. c.sendMessage("Player Must Be Offline.");
  246. }
  247. }
  248. if (playerCommand.startsWith("unban")) {
  249. try {
  250. String playerToBan = playerCommand.substring(6);
  251. Connection.removeNameFromBanList(playerToBan);
  252. c.sendMessage(playerToBan + " has been unbanned.");
  253. } catch(Exception e) {
  254. c.sendMessage("Player Must Be Offline.");
  255. }
  256. }
  257. if(playerCommand.startsWith("unjail")) {
  258. try {
  259. String playerToBan = playerCommand.substring(7);
  260. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  261. if(Server.playerHandler.players[i] != null) {
  262. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToBan)) {
  263. Client c2 = (Client)Server.playerHandler.players[i];
  264. c2.teleportToX = 3086;
  265. c2.teleportToY = 3493;
  266. c2.monkeyk0ed = 0;
  267. c2.Jail = false;
  268. c2.sendMessage("You have been unjailed by "+c.playerName+".");
  269. c.sendMessage("Successfully unjailed "+c2.playerName+".");
  270. }
  271. }
  272. }
  273. } catch(Exception e) {
  274. c.sendMessage("Player Must Be Offline.");
  275. }
  276. }
  277.  
  278. }
  279.  
  280. public void administratorCommands(Client c, String playerCommand)
  281. {
  282. if (playerCommand.startsWith("alert") && c.playerRights > 1) {
  283. String msg = playerCommand.substring(6);
  284. for (int i = 0; i < Config.MAX_PLAYERS; i++) {
  285. if (Server.playerHandler.players[i] != null) {
  286. Client c2 = (Client)Server.playerHandler.players[i];
  287. c2.sendMessage("Alert##Notification##" + msg + "##By: " + c.playerName);
  288.  
  289. }
  290. }
  291. }
  292. if (playerCommand.startsWith("ipmute")) {
  293. try {
  294. String playerToBan = playerCommand.substring(7);
  295. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  296. if(Server.playerHandler.players[i] != null) {
  297. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToBan)) {
  298. Connection.addIpToMuteList(Server.playerHandler.players[i].connectedFrom);
  299. c.sendMessage("You have IP Muted the user: "+Server.playerHandler.players[i].playerName);
  300. Client c2 = (Client)Server.playerHandler.players[i];
  301. c2.sendMessage("You have been muted by: " + c.playerName);
  302. c2.sendMessage(" " +c2.playerName+ " Got IpMuted By " + c.playerName+ ".");
  303. break;
  304. }
  305. }
  306. }
  307. } catch(Exception e) {
  308. c.sendMessage("Player Must Be Offline.");
  309. }
  310. }
  311.  
  312.  
  313.  
  314. if (playerCommand.startsWith("object")) {
  315. String[] args = playerCommand.split(" ");
  316. c.getPA().object(Integer.parseInt(args[1]), c.absX, c.absY, 0, 10);
  317. }
  318.  
  319. if (playerCommand.equalsIgnoreCase("mypos")) {
  320. c.sendMessage("X: "+c.absX+" Y: "+c.absY+" H: "+c.heightLevel);
  321. }
  322.  
  323. if (playerCommand.startsWith("interface")) {
  324. String[] args = playerCommand.split(" ");
  325. c.getPA().showInterface(Integer.parseInt(args[1]));
  326. }
  327.  
  328. if (playerCommand.startsWith("gfx")) {
  329. String[] args = playerCommand.split(" ");
  330. c.gfx0(Integer.parseInt(args[1]));
  331. }
  332. if (playerCommand.startsWith("tele")) {
  333. String[] arg = playerCommand.split(" ");
  334. if (arg.length > 3)
  335. c.getPA().movePlayer(Integer.parseInt(arg[1]),Integer.parseInt(arg[2]),Integer.parseInt(arg[3]));
  336. else if (arg.length == 3)
  337. c.getPA().movePlayer(Integer.parseInt(arg[1]),Integer.parseInt(arg[2]),c.heightLevel);
  338. }
  339.  
  340. if (playerCommand.startsWith("xteletome")) {
  341. try {
  342. String playerToTele = playerCommand.substring(10);
  343. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  344. if(Server.playerHandler.players[i] != null) {
  345. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToTele)) {
  346. Client c2 = (Client)Server.playerHandler.players[i];
  347. c2.sendMessage("You have been teleported to " + c.playerName);
  348. c2.getPA().movePlayer(c.getX(), c.getY(), c.heightLevel);
  349. break;
  350. }
  351. }
  352. }
  353. } catch(Exception e) {
  354. c.sendMessage("Player Must Be Offline.");
  355. }
  356. }
  357.  
  358.  
  359. if (playerCommand.startsWith("xteleto")) {
  360. String name = playerCommand.substring(8);
  361. for (int i = 0; i < Config.MAX_PLAYERS; i++) {
  362. if (Server.playerHandler.players[i] != null) {
  363. if (Server.playerHandler.players[i].playerName.equalsIgnoreCase(name)) {
  364. c.getPA().movePlayer(Server.playerHandler.players[i].getX(), Server.playerHandler.players[i].getY(), Server.playerHandler.players[i].heightLevel);
  365. }
  366. }
  367. }
  368. }
  369. if (playerCommand.equalsIgnoreCase("bank")) {
  370. c.getPA().openUpBank();
  371. }
  372. if (playerCommand.startsWith("unipmute")) {
  373. try {
  374. String playerToBan = playerCommand.substring(9);
  375. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  376. if(Server.playerHandler.players[i] != null) {
  377. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToBan)) {
  378. Connection.unIPMuteUser(Server.playerHandler.players[i].connectedFrom);
  379. c.sendMessage("You have Un Ip-Muted the user: "+Server.playerHandler.players[i].playerName);
  380. break;
  381. }
  382. }
  383. }
  384. } catch(Exception e) {
  385. c.sendMessage("Player Must Be Offline.");
  386. }
  387. }
  388. if (playerCommand.startsWith("ipban")) {
  389. try {
  390. String playerToBan = playerCommand.substring(6);
  391. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  392. if(Server.playerHandler.players[i] != null) {
  393. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToBan)) {
  394. Connection.addIpToBanList(Server.playerHandler.players[i].connectedFrom);
  395. Connection.addIpToFile(Server.playerHandler.players[i].connectedFrom);
  396. c.sendMessage("You have IP banned the user: "+Server.playerHandler.players[i].playerName+" with the host: "+Server.playerHandler.players[i].connectedFrom);
  397. Client c2 = (Client)Server.playerHandler.players[i];
  398. Server.playerHandler.players[i].disconnected = true;
  399. c2.sendMessage(" " +c2.playerName+ " Got IpBanned By " + c.playerName+ ".");
  400. }
  401. }
  402. }
  403. } catch(Exception e) {
  404. c.sendMessage("Player Must Be Offline.");
  405. }
  406. }
  407.  
  408.  
  409. }
  410.  
  411. public void ownerCommands(Client c, String playerCommand)
  412. {
  413.  
  414. if (playerCommand.startsWith("update") && c.playerName.equalsIgnoreCase("matt")) {
  415. String[] args = playerCommand.split(" ");
  416. int a = Integer.parseInt(args[1]);
  417. PlayerHandler.updateSeconds = a;
  418. PlayerHandler.updateAnnounced = false;
  419. PlayerHandler.updateRunning = true;
  420. PlayerHandler.updateStartTime = System.currentTimeMillis();
  421. }
  422.  
  423.  
  424. if(playerCommand.startsWith("npc")) {
  425. try {
  426. int newNPC = Integer.parseInt(playerCommand.substring(4));
  427. if(newNPC > 0) {
  428. Server.npcHandler.spawnNpc(c, newNPC, c.absX, c.absY, 0, 0, 120, 7, 70, 70, false, false);
  429. c.sendMessage("You spawn a Npc.");
  430. } else {
  431. c.sendMessage("No such NPC.");
  432. }
  433. } catch(Exception e) {
  434.  
  435. }
  436. }
  437.  
  438. if (playerCommand.startsWith("anim")) {
  439. String[] args = playerCommand.split(" ");
  440. c.startAnimation(Integer.parseInt(args[1]));
  441. c.getPA().requestUpdates();
  442. }
  443.  
  444. if (playerCommand.startsWith("spec")) {
  445. c.specAmount = 500.0;
  446. }
  447.  
  448. if (playerCommand.startsWith("giveadmin") && c.playerName.equalsIgnoreCase("matt")) {
  449. try {
  450. String playerToAdmin = playerCommand.substring(10);
  451. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  452. if(Server.playerHandler.players[i] != null) {
  453. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToAdmin)) {
  454. Client c2 = (Client)Server.playerHandler.players[i];
  455. c2.sendMessage("You have been given admin status by " + c.playerName);
  456. c2.playerRights = 2;
  457. c2.logout();
  458. break;
  459. }
  460. }
  461. }
  462. } catch(Exception e) {
  463. c.sendMessage("Player Must Be Offline.");
  464. }
  465. }
  466.  
  467. if (playerCommand.startsWith("givemod") && c.playerName.equalsIgnoreCase("matt")) {
  468. try {
  469. String playerToMod = playerCommand.substring(8);
  470. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  471. if(Server.playerHandler.players[i] != null) {
  472. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToMod)) {
  473. Client c2 = (Client)Server.playerHandler.players[i];
  474. c2.sendMessage("You have been given mod status by " + c.playerName);
  475. c2.playerRights = 1;
  476. c2.logout();
  477. break;
  478. }
  479. }
  480. }
  481. } catch(Exception e) {
  482. c.sendMessage("Player Must Be Offline.");
  483. }
  484. }
  485.  
  486. if (playerCommand.startsWith("pnpc"))
  487. {
  488. try {
  489. int newNPC = Integer.parseInt(playerCommand.substring(5));
  490. if (newNPC <= 200000 && newNPC >= 0) {
  491. c.npcId2 = newNPC;
  492. c.isNpc = true;
  493. c.updateRequired = true;
  494. c.setAppearanceUpdateRequired(true);
  495. }
  496. else {
  497. c.sendMessage("No such P-NPC.");
  498. }
  499. } catch(Exception e) {
  500. c.sendMessage("Wrong Syntax! Use as ::pnpc #");
  501. }
  502. }
  503.  
  504.  
  505. if (playerCommand.startsWith("givedonor") && c.playerName.equalsIgnoreCase("matt")) {
  506. try {
  507. String playerToMod = playerCommand.substring(10);
  508. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  509. if(Server.playerHandler.players[i] != null) {
  510. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToMod)) {
  511. Client c2 = (Client)Server.playerHandler.players[i];
  512. c2.sendMessage("You have been given donator status by " + c.playerName);
  513. c2.playerRights = 4;
  514. c2.isDonator = 1;
  515. c2.logout();
  516.  
  517. break;
  518. }
  519. }
  520. }
  521. } catch(Exception e) {
  522. c.sendMessage("Player Must Be Offline.");
  523. }
  524. }
  525.  
  526.  
  527. if (playerCommand.startsWith("demote") && c.playerName.equalsIgnoreCase("matt")) {
  528. try {
  529. String playerToDemote = playerCommand.substring(7);
  530. for(int i = 0; i < Config.MAX_PLAYERS; i++) {
  531. if(Server.playerHandler.players[i] != null) {
  532. if(Server.playerHandler.players[i].playerName.equalsIgnoreCase(playerToDemote)) {
  533. Client c2 = (Client)Server.playerHandler.players[i];
  534. c2.sendMessage("You have been demoted by " + c.playerName);
  535. c2.playerRights = 0;
  536. c2.logout();
  537. break;
  538. }
  539. }
  540. }
  541. } catch(Exception e) {
  542. c.sendMessage("Player Must Be Offline.");
  543. }
  544. }
  545. if (playerCommand.startsWith("reloadspawns")) {
  546. Server.npcHandler = null;
  547. Server.npcHandler = new server.model.npcs.NPCHandler();
  548. for (int j = 0; j < Server.playerHandler.players.length; j++) {
  549. if (Server.playerHandler.players[j] != null) {
  550. Client c2 = (Client)Server.playerHandler.players[j];
  551. c2.sendMessage("<shad=15695415>[" + c.playerName + "] " + "NPC Spawns have been reloaded.</col>");
  552. }
  553. }
  554.  
  555. }
  556.  
  557. if (playerCommand.startsWith("item")) {
  558. try {
  559. String[] args = playerCommand.split(" ");
  560. if (args.length == 3) {
  561. int newItemID = Integer.parseInt(args[1]);
  562. int newItemAmount = Integer.parseInt(args[2]);
  563. if ((newItemID <= 20500) && (newItemID >= 0)) {
  564. c.getItems().addItem(newItemID, newItemAmount);
  565. } else {
  566. c.sendMessage("That item ID does not exist.");
  567. }
  568. } else {
  569. c.sendMessage("Wrong usage: (Ex:(::pickup_ID_Amount)(::item 995 1))");
  570. }
  571. } catch(Exception e) {
  572.  
  573. } // HERE?
  574. } // HERE?
  575.  
  576. if (playerCommand.equals("alltome")) {
  577. for (int j = 0; j < Server.playerHandler.players.length; j++) {
  578. if (Server.playerHandler.players[j] != null) {
  579. Client c2 = (Client)Server.playerHandler.players[j];
  580. c2.teleportToX = c.absX;
  581. c2.teleportToY = c.absY;
  582. c2.heightLevel = c.heightLevel;
  583. c2.sendMessage("Mass teleport to: " + c.playerName + "");
  584. }
  585. }
  586. }
  587.  
  588. if (playerCommand.equalsIgnoreCase("master")) {
  589. for (int i = 0; i < 22; i++) {
  590. c.playerLevel[i] = 99;
  591. c.playerXP[i] = c.getPA().getXPForLevel(100);
  592. c.getPA().refreshSkill(i);
  593. }
  594. c.getPA().requestUpdates();
  595. }
  596.  
  597. }
  598.  
  599. public void DonatorCommands(Client c, String playerCommand)
  600. {
  601.  
  602. }
  603. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement