Advertisement
Guest User

Untitled

a guest
May 28th, 2017
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.95 KB | None | 0 0
  1. var status = 0;
  2.  
  3. function start() {
  4. status = -1;
  5. action(1, 0, 0);
  6. }
  7.  
  8. function action(mode, type, selection) {
  9.  
  10. if (mode == -1) {
  11. cm.dispose();
  12. }
  13. else {
  14. if (status >= 2 && mode == 0) {
  15. cm.sendOk("Goodbye");
  16. cm.dispose();
  17. return;
  18. }
  19.  
  20. if (mode == 1) {
  21. status++;
  22. }
  23. else {
  24. status--;
  25. }
  26.  
  27. if (status == 0) {
  28. cm.sendNext("Hi, I'm the MapleReflex Mercenary");
  29. }
  30. else if (status == 1) {
  31. if(cm.haveItem(4001129)) {
  32. cm.sendSimple("You have #v4001129#!\r\nI would trade my services for it.\r\n#L0#Kill my enemy#l\r\n#L1#I have no enemies#l");
  33. }
  34. else {
  35. cm.sendOk("You dont have any #v4001129#, you get them alongside with event prizes(which means you have to win an event) ");
  36. cm.dispose();
  37. }
  38. }
  39. else if (status == 2) {
  40. if (selection == 0) {
  41. cm.sendGetText("Enter His IGN.");
  42. }
  43. else if (selection == 1) {
  44. cm.sendOk("I'll be your first enemy then.");
  45. cm.getplayer().setHp(0);
  46. cm.dispose();
  47. }
  48. }
  49. else if (status == 3) {
  50. if (cm.getCharByName(target).getMap() == 910000000) {
  51. var target = cm.getText();
  52. cm.getCharByName(target).setHp(0);
  53. cm.gainItem(4001129, -1);
  54. cm.sendOk("The deed has been done");
  55. cm.dispose();
  56. }
  57. else {
  58. cm.sendOk("Please make sure that the target is in the Free Market Entrance");
  59. cm.dispose();
  60. }
  61.  
  62. }
  63. }
  64. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement