Lost - Accessing client's Ghosted terrain
by Davis Ray Sickmon, Jr · in Torque Game Engine · 06/20/2002 (11:49 am) · 0 replies
Ok, I'm a bit lost now. I've been having fun with writing a new terrain deformation routine (basically, on the server, the terrain datablock now has a console method of Terrain.setTerrainHeight) All is well with the server side of things - playin' around, I now do all sorts of mean and nasty things to the terrain.
So, to set up for this to work for networked gaming, I set up a deal where it tracked all the deformations that occured, and set up a client-side command where the server informs the client what needs to be done to the local copy of the terrain. All in script (where I'm most proficent) of course.
And of course it doesn't work. Why? Well... in scripts, you can't call terrain.(anything) since terrain doesn't exist there! However, a ghosted copy exists, which is what I started looking around at.
But now I'm lost - how in the heck do you get ahold of the ghosted copy of a terrain so I can use my cool little command to screw with the terrain?
Any good ideas on how I SHOULD be doing it?
So, to set up for this to work for networked gaming, I set up a deal where it tracked all the deformations that occured, and set up a client-side command where the server informs the client what needs to be done to the local copy of the terrain. All in script (where I'm most proficent) of course.
And of course it doesn't work. Why? Well... in scripts, you can't call terrain.(anything) since terrain doesn't exist there! However, a ghosted copy exists, which is what I started looking around at.
But now I'm lost - how in the heck do you get ahold of the ghosted copy of a terrain so I can use my cool little command to screw with the terrain?
Any good ideas on how I SHOULD be doing it?
About the author