Home   Help Search Login Register  

Author Topic: Not your average respawn thread.  (Read 1922 times)

0 Members and 1 Guest are viewing this topic.

Offline unleashed2k

  • Members
  • *
Not your average respawn thread.
« on: 13 May 2007, 21:18:35 »
First off I am copy and pasting two of my post I made on another forum...

Quote
::retyped::
::edited 3 times::

This is what I need:
This is after your first death (does not apply to JIP players)

When you die, you can select any three spawns on a dialog. Spawn 1, Spawn 2, or Spawn 3.

How would you do this?

Quote
Anyone? I have looked at post on various forums including this one and havn't found a script or a tutorial that I need..

I have three markers set.
Respawn_West
Respawn_West1
Respawn_West2

Right now it's at random.

After players death, I want them to have the choice to select either west, west1, or west 2.

If no one can help me on this part, what about something like KP CTI where you have a transportation menu? There any tutorials on this?

I just need ways to get people to get to west1 and west2, but not randomly. West is the main base.

IF ANYONE can help me figure a way out to get them to west1 and west2, but not randomly i'd love to hear it.

The two ways I would like, any of these ways but not both:
1. After first death, player gets choice to spawn at west,west1 or west2.
or
2. Player can go to building, select a spot where he/she wants to be transported to and will teleport there.

Thankyou for your help if you can!

^^

Offline JasonO

  • OFPEC Patron
  • ****
  • Oh no...
    • The New Life RPG
Re: Not your average respawn thread.
« Reply #1 on: 13 May 2007, 22:32:52 »
I wouldn't know how to make the dialog but the scripting side could go something like this.

1) Place 3 game logics named westrespawn1, westrespawn2 and westrespawn3 in the respawn positions you want.
2) Put respawn_west at the default location you want units to spawn at one of the game logics.
3) In a init.sqs file type the following:
Quote
respawnpoint = west1
[] exec "respawn.sqs"
exit
    (change west1 to the default one you want to spawn at)
4) A dialog would need to define the variable for each button. respawnpoint = west1, respawnpoint = west2, respawnpoint = west3
5) A script named respawn.sqs should be placed in the mission folder. This is what it should contain:
Quote
#start
?!(alive player) : goto "spawn"
~1
goto "start
exit

#spawn
?(respawnpoint == west1) : "Respawn_west" setMarkerPos getPos westrespawn1
?(respawnpoint == west2) : "Respawn_west" setMarkerPos getPos westrespawn2
?(respawnpoint == west3) : "Respawn_west" setMarkerPos getPos westrespawn3

#alive
?(alive player) : goto "start"
~1
goto "alive"

exit

I havn't checked it, but if theres any problems you can't fix yourself then post them and myself or others could try and help you.

If someone else can suggest a better way then please do.

Offline unleashed2k

  • Members
  • *
Re: Not your average respawn thread.
« Reply #2 on: 13 May 2007, 23:03:36 »
Thankyou, I am currently messing with this and I am currently investigating dialogs (http://community.bistudio.com/wiki/User:Manny/Dialogs_%28Work_in_progress%29#Introduction)