MightyPirates / OpenComputers

Home of the OpenComputers mod for Minecraft.
https://oc.cil.li
Other
1.59k stars 430 forks source link

can't recognize inventory #2816

Closed thestronger8 closed 6 years ago

thestronger8 commented 6 years ago

I have a robot with inventory controller upgrade,I place it near a chest.In lua mode, enter the following code:

cp=require "component" iv=cp.inventory_controller iv.getInventorySize(3)

in single player mode,can return the correct result, but in server mode, return nil "no inventory"

What should I do?

MC version: 1.7.10 OC version: 1.7.2.1166-universal & 1.7.1.1137-universal

xarses commented 6 years ago

Are you using sponge or something similar with player claims? If so you need to find a setting for allowing fake players. See if #2730, #2706

payonel commented 6 years ago

cannot repro, working well for me make sure to use sides relative to the face of the robot test all sides, you might not be oriented like you think also, leverage the sides library in openos, it can be helpful