Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

computer interface - this shouldn't return true #46

Open
Nex4rius opened this issue Aug 21, 2017 · 1 comment
Open

computer interface - this shouldn't return true #46

Nex4rius opened this issue Aug 21, 2017 · 1 comment

Comments

@Nex4rius
Copy link

Nex4rius commented Aug 21, 2017

Workaround:
if component.isAvailable("stargate") then
sg = component.getPrimary("stargate")
if sg.energyToDial(sg.localAddress()) then
return true
end
end

@Nex4rius Nex4rius changed the title this shouldn't return true computer interface - this shouldn't return true Aug 21, 2017
@gcewing
Copy link
Owner

gcewing commented Aug 21, 2017

I don't think this is incorrect; component.isAvailable is just testing whether there is an SG interface unit attached. Whether there is a stargate attached to the interface is another matter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants