I have no knowledge of Lua, so I have no clue how feasible this would be, but if you already defined a wirelink in the @inputs, would there be anyway to create an E2 function to wire it to an entity?
Say if you had '@inputs Pod:wirelink' at the start of your code, could you have something like:
Pod:wirelink(E) or Pod:connect(E), where E is the entity of your Advanced Pod Controller, or even Pod=E:wirelink().
From what I know, I see no reason against it, as if you have already defined the wirelink then it will get recognised by the compiler. It would just be useful for when you need to switch between seats for an entity, or screens for an output. Say, for example:
Code:
@inputs Pod:wirelink
@persist LastSaid:string
if(first()|duped()){
runOnChat(1)
}
if(chatClk(owner())){
LastSaid=owner():lastSaid()
if(LastSaid=="~pod"){
Pod:wirelink(owner():aimEntity())
}
}
Bookmarks