Jump to content
🛡️FORUMS ARE IN READ-ONLY MODE Read more... ×
Sign in to follow this  
zootso

I want to keep on playing, not die!

Recommended Posts

Hey all,

*Before I ask this, let me assure you that I have searched the forums for the answer to this, and cannot come up with it smile_o.gif*

Anyways, here is the deal: My brother and I are creating a small multi-player/2 player vs. map. In it, player 1 gets to command one squad of soldiers (AI) against player 2.

What we want to do, is allow the player, once they get killed, to switch over and be able to take command and play as one of his AI troops. Is this possible? We played one of the small multi-player maps that came with the original OFP, and in it you could do this.

Thanks!

Share this post


Link to post
Share on other sites

You could fake it by deleting the unit you want to switch to and then creating on in it's place:

_pos = getPos _unitName

_dir = getDir _unitName

_type = typeOf _unitName

_grp = group _unitName

deleteVehicle _unitName

_newGuy = _type createUnit [_pos, _grp, "", 0.6, "corporal"]

_newGuy setDir _dir

_newGuy setPos _pos

Now I'm not sure about how well this would function in mp, so somebody else would have to optimise it for mp use, and oit would be a gopod idea to add the same weapons and mags... but it's 3:30am and I need some sleep so....

Also.. Armed Assault will do this as standard.

Share this post


Link to post
Share on other sites

there is a default multiplayer mission that already does this, I think it is just called coop and I think it is for malden. When you die in that mission it zooms out from your body and the camera goes to another AI on your team and you keep playing.

Share this post


Link to post
Share on other sites

In your mission directory , if you have a description.ext , edit it (that's a simple text file, so notepad/wordpad can do)

If you don't have a description.ext file , create one

Inside of the description.ext , put

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">respawn=X;

X is a number between 0 and 5 , the number is a respawn method :

0 -> no respawn

1 -> respawn as a seagull

2 -> respawn exactly where you died

3 -> respawn at a base (the base must be a marker named exactly respawn_west or respawn_east or respawn_guer or respawn_civilian according to the side of the unit that will respawn )

4 -> respawn into a remaining unit of your group (if there are no more units in your group, you respawn as a seagull)

5 -> respawn into a remaining unit of your side (if there are no more units in your side, you respawn as a seagull)

Only units that are set to "Playable" are capable of respawning, the other may not.

So in your case, it is

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">respawn=4;

That you must add into the description.ext

Share this post


Link to post
Share on other sites

Thanks all! I'm trying it out right now!

Thanks again! smile_o.gif

Share this post


Link to post
Share on other sites

After four years of MP-gaming I feel a little bit silly asking this question: Does Respawn 5 (side respawn) really work? I've never seen it, as far as I can remember.

Share this post


Link to post
Share on other sites

No it does not. I have also asked this question. It is the same as group.

--Ben

Share this post


Link to post
Share on other sites
In your mission directory , if you have a description.ext , edit it (that's a simple text file, so notepad/wordpad can do)

If you don't have a description.ext file , create one

Inside of the description.ext , put

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">respawn=X;

X is a number between 0 and 5 , the number is a respawn method :

0 -> no respawn

1 -> respawn as a seagull

2 -> respawn exactly where you died

3 -> respawn at a base (the base must be a marker named exactly respawn_west or respawn_east or respawn_guer or respawn_civilian according to the side of the unit that will respawn )

4 -> respawn into a remaining unit of your group (if there are no more units in your group, you respawn as a seagull)

5 -> respawn into a remaining unit of your side (if there are no more units in your side, you respawn as a seagull)

Only units that are set to "Playable" are capable of respawning, the other may not.

So in your case, it is

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">respawn=4;

That you must add into the description.ext

Hey again,

I've attempted to do this, but it's not working (I just get spawned back to a seagull).

Am I doing it incorrectly? I go into the Codemasters folder, then the MPlayer folder, then the folder for the mission I created. In this folder, I've put a simple test document, named 'description.ext', with just 'respawn=4;'

Am I missing something here? Sorry, I'm a bit confused.

Thanks!

Share this post


Link to post
Share on other sites

You've probably got a description.ext file that's not working properly.

Share this post


Link to post
Share on other sites

It sounds like your comp is set to 'Hide extensions for known file types'.

When you create a new text document is it called Untitled or Untitled.txt? If it's just Untitled -

1) From the 'Tools' menu (In any folder.) click 'Folder Options...'

2) Click the 'View' tab and in the Advanced Settings look for 'Hide extensions for known file types' and make sure it's not selected.

I'm not 100% sure if that's your problem but I had trouble with this when I started scripting.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×