gldfunc_dunsw.txt 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. //===== eAthena Script =======================================
  2. //= War of Emperium Guild Dungeon Switch Function
  3. //===== By: ==================================================
  4. //= jAthena - kalen (1.0)
  5. //= 1.1 by Akaru, ho|yAnge|X, and Valaris
  6. //===== Current Version: =====================================
  7. //= 1.3
  8. //===== Compatible With: =====================================
  9. //= eAthena 0.1+; RO Episode 4+
  10. //===== Description: =========================================
  11. //= Switch that warps guild members to guild dungeon.
  12. //==========================================
  13. //= Break down of arguments used in the function:
  14. //= arg(0): name of guild castle.
  15. //= arg(1): guild dungeon level.
  16. //= arg(2): x1 coordinate for warp
  17. //= arg(3): y1 coordinate for warp
  18. //===== Additional Comments: =================================
  19. //= 1.2: All guild Dungeon Switch npcs use this function.[kobra_k88]
  20. //= 1.3 Reverted back. Don't listen to ... people at forums
  21. and check all bugs yourself!
  22. Some not competent people try to change gld_dun -> gld_dun0
  23. IT is wrong, because we already supple "02","03",etc as suffix.
  24. [Lupus]
  25. //============================================================
  26. //==================================================
  27. function script F_GldDunSw {
  28. mes "[ Mysterious Voice ]";
  29. mes " ' Only brave warriors may lead the guild base.. '";
  30. next;
  31. mes "(There is little switch over here....... Would you like to pull the switch?)";
  32. next;
  33. menu "Yes",-,"No",M_No;
  34. set @GID, GetCastleData(getarg(0)+".gat",1);
  35. if (getcharid(2) != @GID) goto L_NotGLead;
  36. warp "gld_dun"+getarg(1)+".gat",getarg(2),getarg(3);
  37. end;
  38. L_NotGLead:
  39. mes "[ Mysterious Voice ]";
  40. mes " ' ..... it seems that you are not brave enough...... ' ";
  41. M_No:
  42. return;
  43. }