tec icon indicating copy to clipboard operation
tec copied to clipboard

Expose certain APIs to Lua

Open dimaguy opened this issue 4 years ago • 4 comments

I'd like these events to be exposed to lua:

  • [X] Commands/Chat (with name of player or other identifier)
  • [x] Player Join (with IP and identifier)
  • [ ] Player Interaction with objects like computers (with identifier and entity id + type of interaction)
  • [ ] Player Movement (with identifier and data useful to movement)
  • [x] Player Leaving (with identifier)

I'd like events 1 to 4 to be cancellable.

I'd like these calls to be exposed to lua:

  • [ ] Teleport
  • [ ] Kick
  • [x] PlayerInfo(which provides a table with any Info of the requested player)
  • [x] List of Players
  • [ ] Entity Spawning

dimaguy avatar Feb 09 '21 21:02 dimaguy

Added 0.2 milestone as there is some underlying architecture needed for a few of these. Some might might be able to be done sooner.

adam4813 avatar Feb 09 '21 22:02 adam4813

onChatCommand has been added see api docs

adam4813 avatar Mar 14 '21 22:03 adam4813

Player info and player list are exposed via User and UserList. Currently the only data is the user's Id and their username. If you can expand on what data you'd like for a user please note it somewhere.

adam4813 avatar Mar 24 '21 04:03 adam4813

Lua API

adam4813 avatar Jun 03 '21 01:06 adam4813