Maris Posted December 19, 2014 Share Posted December 19, 2014 AddPrefabPostInit("wilson",function(inst) local x,y,z = inst.Transform:GetWorldPosition() print(x..", "..y..", "..z)end)Result: 0,0,0 Link to comment Share on other sites More sharing options...
rezecib Posted December 19, 2014 Share Posted December 19, 2014 (edited) @Maris, Try wrapping it in a DoTaskInTime:AddPrefabPostInit("wilson",function(inst) inst:DoTaskInTime(0, function() local x,y,z = inst.Transform:GetWorldPosition() print(x..", "..y..", "..z) end)end)Edit: Although you can also get the position with a simple inst:GetPosition():Get() call. Edited December 19, 2014 by rezecib Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now