Blockland Forums > Modification Help
Another beginner's help post [FIXED]
KuriousGeorge:
Excuse me for asking such a beginner question. I just got into to TS, and have barely scratched the surface of any programming. I have a quick question.
So I'm trying to make a function where somebody types /gotostore and the player will go to the store.
The floor of the store is called "store1", how can I call that to use getTransform()?
So here's the rundown so far.
--- Code: --- function serverCmdGoToStore(%client)
{%client.player.setTransform(store1.getTransform());
}
--- End code ---
I tried PMing and looking through everything, I hate to embarrass myself on a post. But I want to get this by tonight. How do I get store1?
Thanks for reading.
Headcrab Zombie:
Do you have an object named store1?
I think if you're trying to go to a brick named store1 then the object is named _store1?
KuriousGeorge:
Right, so how do I use that?
KuriousGeorge:
would it be like findObjectByName(_store1).getTransform();
?
Headcrab Zombie:
Just _store1.getTransorm()