[DiscordArchive] why is that?
[DiscordArchive] why is that?
Archived author: Honey • Posted: 2022-12-25T21:03:07.612000+00:00
Original source
`(event, player, command, chatHandler)` these are arguments the core passes on to your script.
`command` is what the user typed, minus the .
so if you want the script to do something when the user types ` .test`, use `if command == 'test' then`
Archived author: adm • Posted: 2022-12-25T21:09:16.136000+00:00
Original source
Right, this works, thanks!
Now just have to figure how to cast a buff on the player on use
Archived author: Honey • Posted: 2022-12-25T21:16:33.888000+00:00
Original source
CastSpell with player as caster and target can do that
Archived author: adm • Posted: 2022-12-25T21:18:18.572000+00:00
Original source
or maybe player:AddAura too?
Archived author: Honey • Posted: 2022-12-25T21:18:21.731000+00:00
Original source
add a nil check for player at the start of the function, cause if the command is used from the worldserver, player is nil
Archived author: Honey • Posted: 2022-12-25T21:18:41.221000+00:00
Original source
depends if you cast a spell or add an aura
Archived author: adm • Posted: 2022-12-25T21:18:51.529000+00:00
Original source
i prefer a spell