The object has no owner...
var sm = World.GetWorld().CreateSM(player, player.Location.x, player.Location.y, player.Location.z);
var ent = new Entity(World.GetWorld().Spawn(";struct_metal_wall", player.Location.x, player.Location.y, player.Location.z));
if...
"StructureMaster.AddStructureComponent(StructureComponent)" is deprecated: ""NOT OBSOLETE BUT.. This should only be called from datablocks or otherwise immediately after the component is instantiated - and only once""
I'm just trying to do as it is here - unity installed and are available in all structures from rust , to open them in unity : walls,roof,Foundation and so on
why I can not set the player as owner of the buildings?
Type test = Util.GetUtil().TryFindReturnType("StructureComponent");
var spawnPos = Util.GetUtil().CreateVector(Convert.ToSingle(player.PlayerClient.lastKnownPosition.x)...
how to get gameobject entity?
Fougerite.Entity go1 = (Fougerite.Entity)World.GetWorld().Spawn(";deploy_wood_storage_large", sPos.x, sPos.y, sPos.z, sRot);
sm.AddStructureComponent(go1.Object.gameObject.GetComponent[test]());
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.