| Blockland Forums > Modification Help |
| Getting the vehicle from it's spawn |
| << < (2/3) > >> |
| MegaScientifical:
Sorry, I'll stop posting. Everyone is being loud and annoying and stuff around me. I can't concentrate, but this shouldn't be a problem, so I don't get how you're making it one. |
| Snaily:
--- Quote from: Space Guy on August 02, 2010, 10:53:32 AM ---Setting %brick in the console will most likely have its value erased if you try "%brick = 27801;" "echo(%brick.vehicle);". --- End quote --- I didn't type %brick in the console. I listed serverConnection objects, found the spawn brick's id, and used that as a reference. Something like this: --- Code: ---echo(27801.vehicle); --- End code --- |
| MegaScientifical:
--- Quote from: Snaily on August 02, 2010, 10:58:31 AM ---I didn't type %brick in the console. I listed serverConnection objects, found the spawn brick's id, and used that as a reference. Something like this: --- Code: ---echo(27801.vehicle); --- End code --- --- End quote --- That's your problem. The ServerConnection doesn't take the variables, the server does. ServerConnection is your connection to the server. As host, you are just directly perceiving your server. |
| ZSNO:
Also to get the ID of almost anything you can look at it and do "/getid" and it will return the id of the object :s |
| Snaily:
--- Quote from: ZSNO on August 02, 2010, 11:04:36 AM ---Also to get the ID of almost anything you can look at it and do "/getid" and it will return the id of the object :s --- End quote --- Ooh, forgot about that :P Ok, thanks people, I think I found the problem: %brick didn't equal the vehicle spawn brick id. Now, I'm not sure why, but I can probably figure it out. If not, I'll post all the code up. Thanks everyone. |
| Navigation |
| Message Index |
| Next page |
| Previous page |