Advertisement
KingRecycle

Aion - Butler Greeting Script

Apr 15th, 2012
2,939
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 4.10 KB | None | 0 0
  1. -- You can customize the butler's greeting to match every visitor.
  2. -- Enter the character name in the table below, along with the greeting for the character's visit.
  3.  
  4. helloTable = {
  5.                 --"NotOnList" is used for the default response when entering player is not on list. Do not change unless you know what you are doing.
  6.  
  7.                    ["NotOnList"] = {"Not on list.",    H.Percussion.fx4, H.Emotion.ready },
  8.                    ["Elliya"] = {"Let's do our mating call from our native land. BIDOOOOOFF!",    H.Percussion.fx4, H.Emotion.ready },
  9.                    ["Lecernawx"] = {"Oh hey, it's Mr. Programmer guy! How much for teach?",    H.Percussion.fx11 },
  10.                    ["Thorr"] = {"It's the guy that posts all that GW2 stuff!",  H.Percussion.fx3 },
  11.                    ["Zefrine"] = {"",  H.Percussion.fx5 },
  12.                    ["Kalumus"] = {"Oh it's you...dirty mouth guy!",  H.Percussion.fx6 },
  13.                    ["Whambulance"] = {"Hey girl, wanna DEEEEPEEEEE?",  H.Percussion.fx7 },
  14.                    ["Kayari"] = {"It's my southern girl! HOWDY!",  H.Percussion.fx8 },
  15.                    ["Catchy"] = {"Woah..watch where you swing that penis.",  H.Percussion.fx9 },
  16.                    ["Katie"] = {"No Asians, get out.",  H.Percussion.fx10 },
  17.                    ["Alatreon"] = {"Hot naked guys in this room. You like?",  H.Percussion.fx12 },
  18.                    ["Oshamd"] = {"Oh great leader...welcome!",  H.Percussion.fx13 },
  19.                    ["Oshaguy"] = {"The legion name should of been 'Recycle and Friends'.",  H.Percussion.fx14 },
  20.                    ["Recycle"] = {"The Great King has arrived!",  H.Percussion.snare, H.Emotion.boo },
  21.                  };
  22.  
  23.                  
  24. function GetHelloString(desc)
  25.     if (helloTable[desc] == nil) then
  26.         return helloTable["NotOnList"][1];
  27.     end
  28.         return helloTable[desc][1];
  29. end
  30.  
  31. function GetHelloSound(desc)
  32.     if (helloTable[desc] == nil) then
  33.         return helloTable["NotOnList"][2];
  34.     end
  35.         return helloTable[desc][2];
  36. end
  37.  
  38. function GetHelloAnim(desc)
  39.     if (helloTable[desc] == nil) then
  40.         return helloTable["NotOnList"][3];
  41.     end
  42.         return helloTable[desc][3];
  43. end
  44.  
  45. -- It will be called when the script becomes initialized.
  46. function OnInit()
  47.  
  48.     -- With the SetSensor command, you can customize the distance the butler recognizes a user.
  49.     -- When a user enters in the first variable, the butler recognizes him/her.
  50.     -- When a user steps out of the second variable, the butler does not respond.
  51.     -- Do as follows and the butler recognizes a user when he/she is within a 3m radius.
  52.     -- Again, the butler does not respond when a user steps past a 30m radius.
  53.     H.SetSensor(3, 30);
  54.  
  55. end
  56.  
  57. -- Called when a user enters a distance range that the butler can recognize.
  58. function OnUserEntered(desc)
  59.  
  60.     -- With the PlaySound command, options for music play or label can be set.
  61.     -- The first variable is to set channels and the second one for music score.
  62.     -- Do as follows and 2 labels will be set for channel no. 0.
  63.     H.PlaySound(0, "r[1]r[2]");
  64.  
  65.     -- Plays the effect sound for the respective visitors.
  66.     if (GetHelloSound(desc) ~= nil) then
  67.         -- The SetPercussion command is for customizing sounds.
  68.         H.SetPercussion(1, GetHelloSound(desc));
  69.         -- "x" refers to SetPercussion, enabling the preset sound.
  70.         H.PlaySound(1, "x");
  71.     end
  72.  
  73.     -- The butler starts an animation.
  74.     -- The first variable "0" refers to the butler.
  75.     -- The second variable "1" refers to the label no. [1] in the PlaySound command.
  76.     -- The third variable is an emote gotten from the table.
  77.     H.StartAnimation(0, 1, GetHelloAnim(desc));
  78.  
  79.     -- The butler speaks through a speech bubble.
  80.     -- The first variable 2 refers to the label no. [2] in the PlaySound command.
  81.     -- Enter the dialog message of the butler in the second variable.
  82.     H.Say(2 , GetHelloString(desc));
  83. end
  84.  
  85. -- Available Motions for Setup:
  86. --    point, sleep, angry, blush, dance, clap, comfort, drink, eat, laugh, kneel, no,
  87. --    otl, pat, plead, ready, sad, slap, surprise, taunt, thanks, thunder,
  88. --    useup, victory, yes, wave, boo, charge, dislike, panic, salute, smile,
  89. --    sorry, think, blueflag, twoflag, whiteflag, sing, jump
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement