Jump to content
Sign in to follow this  
xhdx

MP respawn script

Recommended Posts

Hi,

I have created a simple training map with various vehicles. These are too be used for training/testing etc. I need to find out two things.

  • How to allow the player to respawn within an area on the map
  • How to enable the vehicles to respawn around 3 seconds after it has been destroyed

I added a Description.ext file in the mission folder at C:\Users\Username\Documents\Arma 3\missions\Multiplayer%20mission.Stratis

There are 2 files. The Description file and a Missions.sqm file.

Within the Description file, I have this code:

respawn = base;

respawndelay = 5;

But it doesn't seem to work.

Thanks for reading :)

Share this post


Link to post
Share on other sites

For your first issue, the respawn type your using spawns you on a specific point (a marker to be exact), so you would need to script in a radius of an area to then choose a random point.

For the second, there is the vanilla vehicle respawn module that would make life easy :).

Share this post


Link to post
Share on other sites

Edit:

I created the respawn area, and my character does spawn in that area at random coordinates. However, when I die, it doesn't exactly respawn.

It fails the mission which then takes me back to the role selection screen.

If I die, the role and character is deleted until I restart the server, so it's not really respawning. Plus the server restarts after I die and I get a "Mission Failed" pop which triggers this.

Is there any way to make the players fully respawn without deleting the roles, and not restarting the server mission with the "Mission Failed" pop-up?

Sry, I am a newb at this, and I don't know how to script either.

Edited by xHDx

Share this post


Link to post
Share on other sites
Maybe you forgot the quote signs in the description.ext ?

respawn = "BASE";

And don't forget to name your respawn marker "respawn_west", if you are BLUFOR.

https://community.bistudio.com/wiki/Arma_3_Respawn

I did forget the quotation marks, but I added them in and it made no difference.

I already have the marker set as "respawn_west". I have a respawn position, but it has it's default name. Would I need this to be "respawn_west" as well?

Share this post


Link to post
Share on other sites

Yes the marker placed in the editor needs to be named "Respawn_West".

When you say

I already have the marker set as "respawn_west".
Is this a marker or the module?

Share this post


Link to post
Share on other sites
Yes the marker placed in the editor needs to be named "Respawn_West".

When you say Is this a marker or the module?

I placed both. It was first a Marker only, then I added a module, but I'm not sure which I'm supposed to have. Another source said a Marker, so I had that first, then I added a module with the same name. However, I have no idea what I'm supposed to have.

Both are now named "Respawn_West" with the Quotation marks.

It still doesn't work either. The respawn button is there, but it keeps giving me the "mission failed" text.

Edited by xHDx

Share this post


Link to post
Share on other sites

Is this in the preview for the mission?

Share this post


Link to post
Share on other sites
Is this in the preview for the mission?

No, It's when I host the server.

Share this post


Link to post
Share on other sites

If you name something in the editor, you don't have to put quotation marks around it.

Share this post


Link to post
Share on other sites

No quotes on respawn_west

also make sure if your using respawn_west that you are also blufor not opfor.

respawn = "base";

respawndelay = 10;

and marker is

respawn_west

Be sure to check the extension on the Description to make sure it dont say Description.ext.txt if you made the Description with notepad.

Share this post


Link to post
Share on other sites
If you name something in the editor, you don't have to put quotation marks around it.

I haven't. The name in the file has the quotation marks, not the name in the Editor.

---------- Post added at 14:30 ---------- Previous post was at 14:20 ----------

Maybe you forgot the quote signs in the description.ext ?

respawn = "BASE";

And don't forget to name your respawn marker "respawn_west", if you are BLUFOR.

https://community.bistudio.com/wiki/Arma_3_Respawn

No quotes on respawn_west

also make sure if your using respawn_west that you are also blufor not opfor.

respawn = "base";

respawndelay = 10;

and marker is

respawn_west

Be sure to check the extension on the Description to make sure it dont say Description.ext.txt if you made the Description with notepad.

Ok, this is just confusing. One of you are saying one thing and the other, saying the opposite.

In my EXT file, I have this text;

respawn = "Respawn_West";

respawndelay = 5;

Does the "Respawn_West"; part need or not need the quotation marks?

And yes, the marker and module in the game DONT have the quotation marks but are named Respawn_West.

Share this post


Link to post
Share on other sites

In the description file it needs to be: "BASE"

And the marker name, in the editor, should be: respawn_west

Share this post


Link to post
Share on other sites

In the editor you need to place a marker and name it respawn_west and change in your description.ext "respawn_west" back to "base" :)

Share this post


Link to post
Share on other sites

Ok, changed it, but it still won't allow me to respawn. Getting "Missions Failed" when I die.

After this, it puts be into the selection screen to pick a new role, instead of spawning me in the spawn area :(

Share this post


Link to post
Share on other sites
Is this multiplayer or singleplayer?

Multiplayer. I host the server and I have port forwarded too.

Share this post


Link to post
Share on other sites

Hmm weird, could you just provide a zip of the mission folder?

Share this post


Link to post
Share on other sites
Hmm weird, could you just provide a zip of the mission folder?

Sure :)

I'll edit this with the link when i upload it.

Here is the file.

Edited by xHDx

Share this post


Link to post
Share on other sites

Tested it on Dedicated Server, it does work for me. If I shoot the other AI, it get's respawned after 5 seconds and so do I, if I crash with a helicopter.

The respawn does not work in the editor preview!

Share this post


Link to post
Share on other sites
Tested it on Dedicated Server, it does work for me. If I shoot the other AI, it get's respawned after 5 seconds and so do I, if I crash with a helicopter.

The respawn does not work in the editor preview!

Rather strange because I have around 4 copies of the same mission in diff Arma 3 directories.

You can try and join my server and you'll see it won't work.

IP: 82.17.123.70

Address: TST[Respawn]

Pass: TST[Respawn]

Other than that, I have no idea. It's obviously not the mission which is the problem. It'l be the way the files are placed.

However, I can't change the directories creates files, so I can't have done something wrong... there's nothing I can find which would cause this.

---------- Post added at 17:07 ---------- Previous post was at 16:45 ----------

Ok, I have managed to get it working. It look like I have a bug.

I loaded it up in the editor to add a few more vehicles, and click Save. I then loaded the mission up in the server, and the vehicles were missing (didn't save).

So I then went back and clicked Save As instead, and it worked. Strange, strange game.

Edited by xHDx

Share this post


Link to post
Share on other sites

I personally always do Save As and overwrite the files to ensure that the description.ext gets updated properly with all the necessary changes, why it doesn't work with a simple Save, I'm not sure, but I've always done Save As.

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  

×