Modding Help Working with wires

Discussion in 'Starbound Modding' started by Hiran, May 28, 2017.

  1. Hiran

    Hiran Subatomic Cosmonaut

    Is there any function that is called when object gets its wire "node" connected to/disconnected from something? I would like to add a bit of logic that only re-scans necessary parts when player disconnects things.
     
  2. Cyel

    Cyel Scruffy Nerf-Herder

    Code:
    onNodeConnectionChange(args)
    I don't know what args is made of.
    While it might not be fully complete, we try to list those kind of callbacks here: http://starbounder.org/Modding:Lua/Hooks/Object
    You can also look in /objects/wired's .lua files, for example the door and light's scripts do use that.
     

Share This Page