Spawn Point Selection?
by Steven Peterson · in Torque Game Engine · 10/17/2005 (1:13 pm) · 3 replies
Another, vastly different question.
My game is comprised of an overworld map with numerous underworld "labryinths". I was originally going to make each labryinth it's own mission, and then use some kind of "event trigger" to switch the player back and forth between different worlds.
Having seen the LightingPack demo, it seems feasible to put the labryinths (essentialy buildings from Quark or similar) under the main map - allowing for seemless transtion between over and underworld. This would be cool.
The Catch:
- If you die on the overworld you always respwan at the orgin.
- If you die in a labryinth you always respawn at the beginning of that labryinth.
This would require somehow detecting where the player is when they die, and then picking the appropriet spawn point I suppose.
The Question:
- Does this sound possible/feasible in torque?
- Suggested approaches?
- problems to look out for?
thanks,
Raven
My game is comprised of an overworld map with numerous underworld "labryinths". I was originally going to make each labryinth it's own mission, and then use some kind of "event trigger" to switch the player back and forth between different worlds.
Having seen the LightingPack demo, it seems feasible to put the labryinths (essentialy buildings from Quark or similar) under the main map - allowing for seemless transtion between over and underworld. This would be cool.
The Catch:
- If you die on the overworld you always respwan at the orgin.
- If you die in a labryinth you always respawn at the beginning of that labryinth.
This would require somehow detecting where the player is when they die, and then picking the appropriet spawn point I suppose.
The Question:
- Does this sound possible/feasible in torque?
- Suggested approaches?
- problems to look out for?
thanks,
Raven
#2
You can also try it with a single trigger that simply "toggles" the value in the variable from the "overworld" variable to the one that designates that labrynth. Everytime the trigger is hit, it switches it. Unfortunately, I see this leading to problems, which is why I suggested two triggers, but you can probably find a way to make this work too.
Edit: Doh! Matt beat me to it!
10/17/2005 (1:23 pm)
What you might want to do is set up two triggers at the entrances of each labrynth. The first trigger sets a variable for the player to a designation stating he's now in the "overworld". The second trigger sets that variable to whatever designation you have for that specific labrynth. That way, when the player dies, the value of that variable can be looked at and then the correct spawn point chosen.You can also try it with a single trigger that simply "toggles" the value in the variable from the "overworld" variable to the one that designates that labrynth. Everytime the trigger is hit, it switches it. Unfortunately, I see this leading to problems, which is why I suggested two triggers, but you can probably find a way to make this work too.
Edit: Doh! Matt beat me to it!
#3
Much thanks to both of you! :-)
raven
10/17/2005 (3:17 pm)
Awesom - I hadn't thought of that, but it makes perfect sense! This will probably be the route I take.Much thanks to both of you! :-)
raven
Torque 3D Owner Matthew Langley
Torque