Oops... looks like the spiders padded through here
Add products to your cart and remove them from here Lets buyOn this page, you will find how to make an NPC do something when a player clicks it.
The actions are saved in the NPC's own file in the npcs folder.
Every NPC has three lists of actions:
| List | Runs on |
|---|---|
| Left Click Actions | A left click, or a hit. |
| Right Click Actions | A right click. |
| Any Click Actions | Every click, after the left or right click actions. |
The editor adds actions through the action builder, which asks for each field of the type you pick. Clicks with the off hand are ignored.
A [PERMISSION] or [CONDITION] action stops the rest of its own list for players who fail it. The other list still runs.
/pnpc action <id> <click> <add|remove|clear|list> [action] does the same as the editor. <click> is left, right, any or proximity, the last one for proximity actions.
| Command | Does |
|---|---|
/pnpc action guide right add MESSAGE Hello %player% |
Adds [MESSAGE] Hello %player% to the end of the list. |
/pnpc action guide right remove 2 |
Removes the second action. |
/pnpc action guide right list |
Lists the actions with their numbers. |
/pnpc action guide right clear |
Empties the list. |
Oops... looks like the spiders padded through here
Add products to your cart and remove them from here Lets buy