Hi. I need you to write me an interesting and creative script using MoonScript triggers.…
- User
Hi. I need you to write me an interesting and creative script using MoonScript triggers. Here's an overview of the language, a list of the triggers, and some example scripts to help you with writing your own.
The language is based on a series of causes and effects. When you put a cause and an effect together, you've made what we call a trigger. You can have as many different triggers as you want it just depends how many things you want to have happening on your map. The simplest kind of trigger has just one cause and one effect. The causes are the lines where the first number in the parenthesis is 0. Effects always have a 5 at the beginning.
Here is a list of triggers.
; MS Trigger Configuration File ;0 - Simplest - no strings, no andcause, area, filter, coords. - training wheels ;1 - Add in areas, strings, coords - can now do a fair amount of useful & cool stuff ;2 - Add in andcauses - can do a very significant portion of what most actions ;3 - Add in filters, time functions ;4 - More advanced stuff - everything but variables now ;5 - Add variables - you're a smart person, arencha? ;6 - Add in addons - these triggers require a client with LunaAddons [CAUSES] 3 0:0 "When everything is starting up," 2 0:1 "Whenever someone moves," ; 0:2 "When someone moves into floor #," ; 0:3 "When someone moves into object #," ; 0:4 "When someone moves into item #," 2 0:10 "When someone turns," ; 0:11 "When someone moves into position (#,#)," "Position X" "Position Y" ; 0:12 "When someone drops any item," 2 0:13 "When someone arrives in any map," 2 0:14 "When someone leaves any map," 2 0:16 "When someone attacks," 2 0:17 "When someone stands up," 2 0:18 "When someone sits down," 2 0:20 "When someone uses any emote," 0 0:21 "When someone uses emote #," "Emote Type" ; 0:22 "When someone uses any item," ; 0:23 "When someone picks up any item," ; 0:23 "When someone picks up item #," "Item Type" ; 0:24 "When someone drops item #," "Item Type" ; 0:25 "When someone uses item #," "Item Type" 2 0:30 "When someone says anything," 0 0:31 "When someone says {...}," 0 0:32 "When someone says something with {...} in it," 2 0:60 "When someone moves northeast," 2 0:61 "When someone moves southeast," 2 0:62 "When someone moves southwest," 2 0:63 "When someone moves northwest," 2 0:100 "When someone tries to drop any item," 0 0:101 "When someone tries to drop # of item #," "Item Amount" "Item Type" 0 0:102 "When someone tries to drop between # and # of item #," "Item Amount" "Item Amount" "Item Type" 2 0:103 "When someone tries to pick up any item," 0 0:104 "When someone tries to pick up # of item #," "Item Amount" "Item Type" 0 0:105 "When someone tries to pick up between # and # of item #," "Item Amount" "Item Amount" "Item Type" 2 0:150 "When someone tries to open any door," 0 0:151 "When someone tries to open a door at (#,#)," "Position X" "Position Y" 3 0:250 "When # seconds have passed, offset by #," "Seconds Delay" "Seconds Offset" [ADDITIONAL CONDITIONS] 2 1:0 "and they are on map #," "Map ID" 2 1:1 "and they are male," 2 1:2 "and they are female," 2 1:3 "and they are not male," 2 1:4 "and they are not female," 2 1:5 "and their name is {...}," 2 1:6 "and there's a player at (#,#)," "Position X" "Position Y" 2 1:7 "and there's no player at (#,#)," "Position X" "Position Y" 2 1:8 "and there's an NPC at (#,#)," "Position X" "Position Y" 2 1:9 "and there's no NPC at (#,#)," "Position X" "Position Y" 2 1:10 "and they have at least # of # in their inventory," "Item Amount" "Item Type" 2 1:11 "and they have more than # of # in their inventory," "Item Amount" "Item Type" 2 1:12 "and they have fewer than # of # in their inventory," "Item Amount" "Item Type" 2 1:13 "and the item # at (#,#) belongs to them," "Item Type" "Position X" "Position Y" 2 1:14 "and the item # at (#,#) belongs to the player named {...}," "Item Type" "Position X" "Position Y" "Character Name" 2 1:15 "and the item # at (#,#) on map # belongs to them," "Item Type" "Map ID" "Position X" "Position Y" "Character Name" 2 1:16 "and the item # at (#,#) on map # belongs to the player named {...}," "Item Type" "Map ID" "Position X" "Position Y" "Character Name" 2 1:35 "and they move into position (#,#)," "Position X" "Position Y" 2 1:50 "and their title is {...}," 2 1:51 "and their home is {...}," 2 1:52 "and their fiance is {...}," 2 1:53 "and their partner is {...}," 2 1:54 "and their class is #," "Class Type" 2 1:55 "and their skin is #," "Skin Type" 2 1:56 "and their hair style is #," 2 1:57 "and their hair color is #," 2 1:58 "and they are facing direction #," "Direction Type" 2 1:59 "and their level is higher than #," 2 1:60 "and their health is higher than #," 2 1:61 "and their maximum health is higher than #," 2 1:62 "and their mana is higher than #," 2 1:63 "and their maximum mana is higher than #," 2 1:64 "and their maximum stamina is higher than #," 2 1:65 "and their EXP is higher than #," 2 1:66 "and they are sitting on the ground," 2 1:67 "and they are not sitting on the ground," 2 1:68 "and they are sitting on a chair," 2 1:69 "and they are not sitting on a chair," 2 1:70 "and they are standing," 2 1:71 "and they are not standing," 2 1:72 "and they have at least # stat points remaining," 2 1:72 "and they have at least # skill points remaining," 2 1:80 "and they can see position (#,#)," "Position X" "Position Y" 5 1:200 "and variable # is equal to #," "Variable" "Number" 5 1:201 "and variable # is more than #," "Variable" "Number" 5 1:202 "and variable # is less than #," "Variable" "Number" 5 1:203 "and variable # is not equal to #," "Variable" "Number" 5 1:208 "and the X,Y position in variable # is the same as the position in variable #," "Variable" "Variable" 5 1:209 "and the X,Y position in variable # is not the same as the position in variable #," "Variable" "Variable" [AREAS] 1 3:1 "everywhere on the whole map," 1 3:2 "at position (#,#) on the map," "Position X" "Position Y" ; 0 3:3 "within the diamond (#,#) - (#,#)," "Top" "Left" "Bottom" "Right" ; 0 3:4 "within the rectangle (#,#) - (#,#)," "Top" "Left" "Bottom" "Right" 1 3:5 "where the triggering player is at, not moving," ; 0 3:5 "where the triggering player moved from," ; 0 3:6 "where the triggering player moved into," ; 0 3:7 "whereever the triggering player was at when the trigger activated," 1 3:8 "everyplace the triggering player can see," ; 3:9 "everyplace that can be seen from (#,#)," "Position X" "Position Y" 1 3:10 "in the space right in front of the triggering player," 1 3:11 "# step(s) in front of the triggering player," "Steps" 1 3:12 "in the space right behind the triggering player," 1 3:13 "# step(s) behind the triggering player," "Steps" ; 0 3:14 "in a line starting at (#,#) and going # more spaces northeast." "Position X" "Position Y" "Distance" ; 0 3:15 "in a line starting at (#,#) and going # more spaces southeast." "Position X" "Position Y" "Distance" ; 0 3:16 "in a line starting at (#,#) and going # more spaces southwest." "Position X" "Position Y" "Distance" ; 0 3:17 "in a line starting at (#,#) and going # more spaces northwest." "Position X" "Position Y" "Distance" 1 3:20 "at the location where the triggering player (currently is/previously was) attempting to drop an item," [FILTERS] ; 3 4:0 "clear all filtering," 3 4:9 "only in places where someone can walk," 3 4:10 "only in places that can't be walked into," 3 4:12 "only in places the triggering player can see," 3 4:13 "only in places the triggering player cannot see," ; 3 4:14 "only in places that can be seen from (#,#)," "Position X" "Position Y" ; 3 4:15 "only in places that can not be seen from (#,#)," "Position X" "Position Y" 3 4:20 "only in places where there is an NPC," 3 4:21 "only in places where there are no NPCs," [EFFECTS] 0 5:14 "move the triggering player to (#,#) if there's nobody already there." "Position X" "Position Y" 0 5:15 "move the triggering player to (#,#)." "Position X" "Position Y" 0 5:16 "move any player present to (#,#) if there's nobody already there." "Position X" "Position Y" 0 5:17 "move any player present to (#,#)." "Position X" "Position Y" 0 5:18 "move the triggering player to (#,#,#) if there's nobody already there." "Position X" "Position Y" "Map ID" 0 5:19 "move the triggering player to (#,#,#)." "Position X" "Position Y" "Map ID" 0 5:20 "move any player present to (#,#,#) if there's nobody already there." "Position X" "Position Y" "Map ID" 0 5:21 "move any player present to (#,#,#)." "Position X" "Position Y" "Map ID" 4 5:31 "make any player standing at (#,#) become the new triggering player." "Position X" "Position Y" 4 5:32 "make any player standing at (#,#,#) become the new triggering player." "Position X" "Position Y" "Map ID" 4 5:48 "make the player named {...} the new triggering player, if they're on the map right now." 4 5:49 "make the player named {...} the new triggering player, if they're in the world right now." 0 5:50 "emit message {...} to the triggering player." 0 5:51 "emit message {...} to any player present." 0 5:52 "emit message {...} to every player who can see (#,#)." "Message" "Position X" "Position Y" 0 5:53 "emit message {...} to every player who can see the triggering player." 0 5:54 "emit message {...} to everyone on the map." 0 5:55 "emit message {...} to the player named {...} if they're on the map." 0 5:56 "emit message {...} to everyone in the world." 0 5:68 "remove # of item # on the map." "Item Amount" "Item Type" 0 5:69 "remove # of item # at (#,#) on the map." "Item Amount" "Item Type" "Position X" "Position Y" 0 5:70 "place # of item # on the map." "Item Amount" "Item Type" 0 5:71 "place # of item # at (#,#) on the map." "Item Amount" "Item Type" "Position X" "Position Y" 0 5:75 "place # of item # in the triggering player's inventory." "Item Amount" "Item Type" 0 5:76 "remove # of item # from the triggering player's inventory." "Item Amount" "Item Type" 0 5:100 "disconnect the triggering player." 0 5:150 "make the triggering player use emote #." "Emote Type" 0 5:151 "make any player present use emote #." "Emote Type" 0 5:152 "make any player standing at (#,#) use emote #." "Position X" "Position Y" "Emote Type" 0 5:200 "open the door at (#,#) on the map." "Position X" "Position Y" 0 5:201 "open the door at (#,#,#)." "Position X" "Position Y" 0 5:220 "spawn a new NPC # at (#,#) on the map." "NPC Type" "Position X" "Position Y" 0 5:221 "spawn a new NPC # on the map." "NPC Type" 0 5:222 "kill the NPC # at (#,#) on the map." "NPC Index" "Position X" "Position Y" 0 5:223 "kill any NPC located at (#,#) on the map." "Position X" "Position Y" 0 5:224 "kill any NPC # on the map." "NPC Type" 0 5:225 "kill any NPC on the map." 0 5:226 "inflict # damage upon any NPC on the map." "Damage" 0 5:227 "inflict # damage upon NPC # on the map." "Damage" "NPC Index" 0 5:230 "make NPC # walk # steps in the direction #." "NPC Index" "Steps" "Direction" 5 5:300 "set variable # to the value #." "Variable" "Number" 5 5:301 "copy the value of variable # into variable #." "Variable" "Variable" 5 5:302 "take variable # and add # to it." "Variable" "Number" 5 5:303 "take variable # and add variable # to it." "Variable" "Variable" 5 5:304 "take variable # and subtract # from it." "Variable" "Number" 5 5:305 "take variable # and subtract variable # from it." "Variable" "Variable" 5 5:318 "set variable # to the number of players on the map." "Variable" 5 5:319 "set variable # to the number of players in the server." "Variable" 5 5:320 "set variable # to the X,Y position the triggering player is standing at." "Variable" 5 5:321 "set variable # to the current day of the month." "Variable" 5 5:322 "set variable # to the current hour UTC (Universal Standard Time in twenty-four hour format)." "Variable" 5 5:323 "set variable # to the current minute FST (Furcadia Standard Time)." "Variable" 5 5:324 "set variable # to the current month of the year." "Variable" 5 5:325 "set variable # to the current second FST (Furcadia Standard Time)." "Variable" 5 5:326 "set variable # to the current year." "Variable" 5 5:347 "set variable # to the ID of the item the triggering player tried to drop." "Variable" 5 5:348 "set variable # to the amount of the item the triggering player tried to drop." "Variable" 5 5:349 "set variable # to the X,Y position of the item the triggering player tried to drop." "Variable" 5 5:350 "set variable # to the ID of the item the triggering player tried to pick up." "Variable" 5 5:351 "set variable # to the amount of the item the triggering player tried to pick up." "Variable" 5 5:352 "set variable # to the X,Y position of the item the triggering player tried to pick up." "Variable" 5 5:384 "set variable # to the X,Y position (#,#)." "Variable" "X Position" "Y Position" 5 5:385 "set variable # to the X,Y position of the NPC." "Variable" "X Position" "Y Position" 5 5:386 "set variable # to the index of the NPC." "Variable" 5 5:387 "set variable # to the type of the NPC." "Variable" 5 5:390 "set variable # to the last emote the triggering player used." "Variable" 5 5:391 "set variable # to the index of the last NPC the triggering player attacked." "Variable" 5 5:392 "set variable # to the type of the last NPC the triggering player attacked." "Variable" 5 5:393 "set variable # to the current health of the last NPC the triggering player attacked." "Variable" 5 5:394 "set variable # to the total health of the last NPC the triggering player attacked." "Variable" 5 5:395 "set variable # to the X,Y position of the last NPC the triggering player attacked." "Variable" 5 5:399 "clear all variables to zero." 4 5:404 "set message ~ to {...}." 4 5:405 "set message ~ to what the triggering player last said." 4 5:406 "set message ~ to the triggering players's name." 6 5:800 "set the floor to #." "Floor type" ; 6 5:801 "change floor # to floor #." "First Floor Type" "Second Floor Type" ; 6 5:802 "swap floor types # and #." "First Floor Type" "Second Floor Type" 6 5:803 "set the object to #." "Object Type" ; 6 5:804 "change object # to object #." "First Object Type" "Second Object Type" ; 6 5:805 "swap object types # and #." "First Object Type" "Second Object Type" 6 5:806 "set the overlay_a to #." "Overlay Type" ; 6 5:807 "change the overlay_a # to #." "First Overlay Type" "Second Overlay Type" ; 6 5:808 "swap overlay_a types # and #." "First Overlay Type" "Second Overlay Type" 6 5:809 "set the overlay_b to #." "Overlay Type" ; 6 5:810 "change the overlay_b # to #." "First Overlay Type" "Second Overlay Type" ; 6 5:811 "swap overlay_b types # and #." "First Overlay Type" "Second Overlay Type" 6 5:812 "set the down wall to #." "Wall Type" ; 6 5:813 "change the down wall # to #." "First Wall Type" "Second Wall Type" ; 6 5:814 "swap down wall types # and #." "First Wall Type" "Second Wall Type" 6 5:815 "set the right wall to #." "Wall Type" ; 6 5:816 "change the right wall # to #." "First Wall Type" "Second Wall Type" ; 6 5:817 "swap right wall types # and #." "First Wall Type" "Second Wall Type" 6 5:818 "set the roof to #." "Roof Type" ; 6 5:819 "change the roof # to #." "First Roof Type" "Second Roof Type" ; 6 5:820 "swap roof types # and #." "First Roof Type" "Second Roof Type" 6 5:821 "set the top to #." "Top Type" ; 6 5:822 "change the top # to #." "First Top Type" "Second Top Type" ; 6 5:823 "swap top types # and #." "First Top Type" "Second Top Type" 6 5:824 "set the shadow to #." "Shadow Type" ; 6 5:825 "change the shadow # to #." "First Shadow Type" "Second Shadow Type" ; 6 5:826 "swap shadow types # and #." "First Shadow Type" "Second Shadow Type" 6 5:827 "set the special tile to #." "Special Type" ; 6 5:828 "change the special tile # to #." "First Special Type" "Second Special Type" ; 6 5:829 "swap special types # and #." "First Special Type" "Second Special Type" 6 5:835 "make the triggering player stand up." 6 5:836 "make the triggering player sit down." ; 6 5:840 "turn the triggering player counterclockwise." ; 6 5:841 "turn the triggering player to face northeast." ; 6 5:842 "turn the triggering player to face southeast." ; 6 5:843 "turn the triggering player to face southwest." ; 6 6:844 "turn the triggering player to face northwest." 0 5:850 "make the triggering player attack in direction #." "Direction" 0 5:860 "play jukebox song # to the triggering player." "Song number" 1 5:861 "play jukebox song # to any player present." "Song number" 2 5:862 "play jukebox song # to every player who can see (#,#)." "Song number" "X Position" "Y Position" ; 0 5:863 "play jukebox song # to every player who can see the triggering player." "Song number" (https://github.com/lunaeo/LunaAddons/issues/5) 0 5:864 "play jukebox song # to everyone on the map." "Song number" 0 5:1000 "emit message {...} to the server console." - Assistant