Guest User

Untitled

a guest
May 24th, 2018
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 2.31 KB | None | 0 0
  1. /*=====================*\
  2. |* DiasEx  Dialogdatei *|
  3. |* 15.01.2012 19:43:45 *|
  4. \*=====================*/
  5.  
  6. //--------------------------
  7. // Variablen
  8. //--------------------------
  9. var int Namespace2_var;
  10.  
  11. //--------------------------
  12. // TestDialoge_DIA1
  13. //--------------------------
  14. instance TestDialoge_DIA1(C_Info) {
  15.     npc = PAL_100_Friend;
  16.     info = TestDialoge_DIA1_Info;
  17.     condition = TestDialoge_DIA1_Condition;
  18.     description = "Hi, Arto!";
  19. };
  20.  
  21. func int TestDialoge_DIA1_Condition() {
  22.     return !Npc_KnowsInfo(hero, TestDialoge_DIA1);
  23. };
  24.  
  25. func int TestDialoge_DIA1_Blubber_Condition() {
  26.     return Namespace2.var;
  27. };
  28.  
  29. func int TestDialoge_DIA1_Blobber_Condition() {
  30.     return Npc_KnowsInfo(hero, TestDialoge_DIA2);
  31. };
  32.  
  33. func void TestDialoge_DIA1_Info() {
  34.     AI_Output(other, self, "DIA_TestDialoge_DIA1_hero_00");//Hi, Arto!
  35.     AI_Output(self, other, "DIA_TestDialoge_DIA1_Arto_01");//Hallo, Held.
  36.     if(TestDialoge_DIA1_Blubber_Condition()) {
  37.         Info_AddChoice(TestDialoge_DIA1, "Okay, ich geh dann wieder.", TestDialoge_DIA1_Blubber);
  38.     };
  39.     if(TestDialoge_DIA1_Blobber_Condition()) {
  40.         Info_AddChoice(TestDialoge_DIA1, "Wir haben schon gehandelt, ne?", TestDialoge_DIA1_Blobber);
  41.     };
  42. };
  43.  
  44. func void TestDialoge_DIA1_Blubber() {
  45.     AI_Output(other, self, "DIA_TestDialoge_DIA1_Blubber_hero_00");//Okay, ich geh dann wieder.
  46.     AI_Output(self, other, "DIA_TestDialoge_DIA1_Blubber_Arto_01");//Fein.
  47. };
  48.  
  49. func void TestDialoge_DIA1_Blobber() {
  50.     AI_Output(other, self, "DIA_TestDialoge_DIA1_Blobber_hero_00");//Wir haben schon gehandelt, ne?
  51.     AI_Output(self, other, "DIA_TestDialoge_DIA1_Blobber_Arto_01");//Jup.
  52.     Info_ClearChoices(TestDialoge_DIA1);
  53. };
  54.  
  55. //--------------------------
  56. // TestDialoge_DIA2
  57. //--------------------------
  58. instance TestDialoge_DIA2(C_Info) {
  59.     npc = PAL_100_Friend;
  60.     info = TestDialoge_DIA2_Info;
  61.     condition = TestDialoge_DIA2_Condition;
  62.     permanent = true;
  63.     trade = true;
  64.     description = "Ich möchte mit dir tauschen.";
  65. };
  66.  
  67. func int TestDialoge_DIA2_Condition() {
  68.     return Arto.attribute[ATR_HITPOINTS];
  69. };
  70.  
  71. func void TestDialoge_DIA2_Info() {
  72.     AI_Output(other, self, "DIA_TestDialoge_DIA2_hero_00");//Ich möchte mit dir tauschen.
  73.     AI_Output(self, other, "DIA_TestDialoge_DIA2_Arto_01");//Nur zu:
  74. };
Add Comment
Please, Sign In to add comment