Jump to content
KC Grimes

Grimes Simple Revive Script

Recommended Posts

Hey Grimes,

I wanted to just post and say that this script is awesome! I will keep an eye on the upcoming versions.

Keep up the good work man.

Thank you so much for the kind words, I really appreciate it. Really hoping we can get this script bug-free so we can start having some fun!

@W1CK3D, and any other testers - In G_Revive\G_Unconscious.sqf, change the beginning of the script to look like the following, where the Red is the new line:

private ["_itemsArray","_replaceArray","_reviveTimer"];

_unit = _this select 0;

[color="#FF0000"]if (!local _unit) exitWith {};
[/color]
if (_unit getVariable "G_Unconscious") exitWith {};
_unit setVariable ["G_Unconscious",true,true];

That should fix the titleText stuff popping up universally.

About the ragdoll issue, I can't quite visualize what you're describing. I can say that at this point Ragdoll has been replaced by a simple fall to DeadState animation, where they lay on the ground. This can be seen in the video in the OP. If it doesn't look like that, or some obviously wrong stuff is happening, let me know. I have an idea of how to "get" ragdoll, but I want to have the script completely functional and bug-free first.

Share this post


Link to post
Share on other sites

Thanks for the quick response! Your hard work is appreciated. I will be testing and will provide feedback!

Share this post


Link to post
Share on other sites

Tested with my guys and we had an issue involving duplicated actions for the enemy (which, really, isn't a big deal, but I'll fix it when I get the chance), as well as the unit tags not working for JIP.

Share this post


Link to post
Share on other sites

Tested the script for my mission and everything turned out great, I spawned in the moving chopper. The only issue I came across was when I set the value to -1 for infinite respawns. I respawned and went directly to the spectator camera, I changed the value from -1 to 999 and everything worked properly.

Share this post


Link to post
Share on other sites
Tested the script for my mission and everything turned out great, I spawned in the moving chopper. The only issue I came across was when I set the value to -1 for infinite respawns. I respawned and went directly to the spectator camera, I changed the value from -1 to 999 and everything worked properly.

Will take a look. 999 will work for you, but it's not "perfect". Must've messed it up in fixing this other stuff. Thanks for letting me know, glad its working.

Edit: I tested this and it is working fine on my end. Be sure G_Init_Start = 0.

Edit: Fixed the duplicate actions, I believe.

Right now I believe the only resting problem is JIP-only. Working on that tonight.

Edited by Grimes [3rd ID]

Share this post


Link to post
Share on other sites
Tested the script for my mission and everything turned out great, I spawned in the moving chopper. The only issue I came across was when I set the value to -1 for infinite respawns. I respawned and went directly to the spectator camera, I changed the value from -1 to 999 and everything worked properly.

Can confirm G_Init_Start = -1 does not work for infinite respawns.

Testing In G_Revive\G_Unconscious.sqf fix in about 30 minutes with same group of mates. I will try and get them to take pictures of the ragdoll error they were seeing if it replicates itself again.

EDIT: The G_Revive\G_Unconscious.sqf fixed the universal titleText and we can't seem to replicate the ragdoll error again.

Edited by W1CK3D

Share this post


Link to post
Share on other sites
Can confirm G_Init_Start = -1 does not work for infinite respawns.

Testing In G_Revive\G_Unconscious.sqf fix in about 30 minutes with same group of mates. I will try and get them to take pictures of the ragdoll error they were seeing if it replicates itself again.

EDIT: The G_Revive\G_Unconscious.sqf fixed the universal titleText and we can't seem to replicate the ragdoll error again.

I'll look again here in a bit with a fresh mind. Thanks for confirming all of the above! Really appreciate the help.

Edit:

Fixed the error in the unlimited respawns, had an and where an or was needed. Will be posting an update later.

Edited by Grimes [3rd ID]

Share this post


Link to post
Share on other sites

Been cracking on this all day yesterday and for a little while today and just finished my MP hosted testing. After lunch I will be testing my few latest things on a DS, then will hopefully (again, hopefully) release a completely working tonight or tomorrow. I say this because last night I got together with my guys and said "Break my script" and they were only able to do 2 things, which I've fixed. Check out my issue tracker to see what all is fixed and added for v0.6. Ready to get this thing outta there!

Edit: Did some more extensive (and really more "what-if" style testing) and found 2 issues, the first of which I have fixed by reworking the MRV system to be not only completely functional but much more efficient to the clients and server. The final issue involves JIP with the Unit Tag system. If a player JIPs into a Dead or Unconscious unit, the system will not initiate for them. This kind of sparked my idea to add further support for JIPing into already-active units. I've written down my thoughts and will hopefully accomplish this tomorrow night. My work week begins tomorrow, so the timing gets limited. I'm pushing for perfection with this.

Edited by Grimes [3rd ID]

Share this post


Link to post
Share on other sites

Thanks for your hard work. I've been doing some testing and as the others above indicated, the fixes seem to be working for the most part. We will do a full test Saturday night. I'll follow up with the results.

Share this post


Link to post
Share on other sites
Thanks for your hard work. I've been doing some testing and as the others above indicated, the fixes seem to be working for the most part. We will do a full test Saturday night. I'll follow up with the results.

I have been running into some time issues and have yet to fix the unit tags JIP issues. If I don't have it fixed tonight, I'll go ahead and upload what I have for y'all to test. Thank you so much for once again volunteering.

Edit:

Unfortunately, I wasn't able to get to it tonight. I work 7 AM to 7 PM, so my "free time" is fairly limited, especially when things come up during that free time. However, tomorrow is my last work day for a few days, so I'll be able to give it a good go. Below is the download for the latest unofficial version. Once again, this version is not official and is not meant for distribution. Please feel free to provide any support or feedback. The only known issue I have for this one is that Unit Tags struggle a bit with JIP, specifically on a DS. Everything else, including MRVs, should be good to go, even on a DS.

[REDACTED - See next post]

Edited by Grimes [3rd ID]

Share this post


Link to post
Share on other sites

My friends I am excited to announce that after many hours of strenuous testing and alterations of the original script I have finally made Grimes' Simple Revive Script truly and completely Dedicated Server and JIP compatible. At this point I have fixed all reported bugs that either I have found or that you guys have found, in addition to editing some small features that were suggested. Thank you all so much for your support in helping me get this script on BOTH feet for everyone to enjoy. Without further delay, please see the original post of this thread for v0.6 of Grimes' Simple Revive Script, containing a sample mission that allows you to employ all aspects of the script, in addition to a detailed readMe file. As well, I've updated COOP 5 First Light so that you can jump right into the action with friends or AI and see how this script works first-hand!

To those of you who assisted in reporting, suggesting, and testing, thank you so much. I could not have done this without your help and creativity!

Enjoy!

Edited by Grimes [3rd ID]

Share this post


Link to post
Share on other sites
Guest

Thanks for informing us about the updated release :cool:

New version frontpaged on the Armaholic homepage.

================================================

We have also "connected" these pages to your account on Armaholic.

This means in the future you will be able to maintain these pages yourself if you wish to do so. Once this new feature is ready we will contact you about it and explain how things work and what options you have.

When you have any questions already feel free to PM or email me!

Share this post


Link to post
Share on other sites

Grimes [3rd ID] - I really like the look of this script, very well done and great news about the DS and JIP.

Just a question. I usually make coop missions for my group, but we're just trying out some PvP, just for a change and for something different, etc.

Briefly the scenario is that there are up to 4 players (blufor) behind enemy lines and they have to make it to one of four escape points to "win". The other players (opfor) are in heli's etc and have to hunt them down.

Anyhow, I want a random spawn start and I have something working very well (for replay ability and no doubt teams will swap around, etc and don't want to give the "hunterforce" a heads up on where blufor will be at the start, etc)- BUT I seem to be having issues with other revive systems to make this work (or just work in PvP in general- but that could be just me!).

Then I came across your revive script and it looks great (I will use it for coop's in the future regardless). What really pleased me is that you have a random start build in already- perfect! I have only tested it with myself and 3 blufor ai on client mp- but it seems the ai spawn in on one marker and I on another? Does the random spawn work that all your group (players) will spawn in on the same marker ? If not, is there a work around for this (apart from "dying" and respawning on squad leader -which is an option and worst case scenario, but rather avoid that if poss) ? Sorry I obviously need to test this with human players, but most of my group are away until tomorrow and just want a heads up so I can figure it out.

Your help would be appreciated (I really like this so far- great job!).

P.S. I saw a post on page 4 that brought this up regarding default gear and respawn ? just want to check, is there an an option yet for not having default gear on respawn? Thanks.

Edited by pathfinder2-1

Share this post


Link to post
Share on other sites
Grimes [3rd ID] - I really like the look of this script, very well done and great news about the DS and JIP.

Just a question. I usually make coop missions for my group, but we're just trying out some PvP, just for a change and for something different, etc.

Briefly the scenario is that there are up to 4 players (blufor) behind enemy lines and they have to make it to one of four escape points to "win". The other players (opfor) are in heli's etc and have to hunt them down.

Anyhow, I want a random spawn start and I have something working very well (for replay ability and no doubt teams will swap around, etc and don't want to give the "hunterforce" a heads up on where blufor will be at the start, etc)- BUT I seem to be having issues with other revive systems to make this work (or just work in PvP in general- but that could be just me!).

Then I came across your revive script and it looks great (I will use it for coop's in the future regardless). What really pleased me is that you have a random start build in already- perfect! I have only tested it with myself and 3 blufor ai on client mp- but it seems the ai spawn in on one marker and I on another? Does the random spawn work that all your group (players) will spawn in on the same marker ? If not, is there a work around for this (apart from "dying" and respawning on squad leader -which is an option and worst case scenario, but rather avoid that if poss) ? Sorry I obviously need to test this with human players, but most of my group are away until tomorrow and just want a heads up so I can figure it out.

Your help would be appreciated (I really like this so far- great job!).

P.S. I saw a post on page 4 that brought this up regarding default gear and respawn ? just want to check, is there an an option yet for not having default gear on respawn? Thanks.

Thank you for the kind words, I'm glad you enjoy the script!

The random respawn featured in this script is random on an individual basis. Unless you want your squad to start out separated, it is not the way to go. If you still want to do random start, I suggest you set G_Init/JIP_Start to 0, and in a different script (or in the editor) do some randoming. An easy example:

In the editor:

Create markers - random1, random2, random3

Place units wherever you'd like, they're going to be moved.

For the following, you may try putting it in the squad leader's init field in the editor, or just name the squad leader something (in this case bobby) and put it in init.sqf. (If you put it in editor, change "bobby" to "this")

_markers = ["random1", "random2", "random3"];
_randomspawn = _markers call BIS_fnc_selectRandom; 
_randompos = getMarkerPos _randomspawn; 
{
_x setPos _randompos;
} forEach units group bobby; 

That should do you.

About the gear persistence, I have not gotten to this yet. Sorry! I'll bump it up on my list however, as it seems this is a popular feature.

Share this post


Link to post
Share on other sites
;2698106']Thank you for the kind words' date=' I'm glad you enjoy the script!

The random respawn featured in this script is random on an individual basis. Unless you want your squad to start out separated, it is not the way to go. If you still want to do random start, I suggest you set G_Init/JIP_Start to 0, and in a different script (or in the editor) do some randoming. An easy example:

In the editor:

Create markers - random1, random2, random3

Place units wherever you'd like, they're going to be moved.

For the following, you may try putting it in the squad leader's init field in the editor, or just name the squad leader something (in this case bobby) and put it in init.sqf. (If you put it in editor, change "bobby" to "this")

_markers = ["random1", "random2", "random3"];
_randomspawn = _markers call BIS_fnc_selectRandom; 
_randompos = getMarkerPos _randomspawn; 
{
_x setPos _randompos;
} forEach units group bobby; 

That should do you.

About the gear persistence, I have not gotten to this yet. Sorry! I'll bump it up on my list however, as it seems this is a popular feature.[/quote']

Thanks, that works great now, really appreciated. Ref: gear persistence, sure when you get time, it would be a great addition as a feature. As you say, for a number of reasons it is a popular option people like.

Thanks again.

Share this post


Link to post
Share on other sites

Grimes, this revive script is truly awesome. I am definetely a buyer. Thanks for putting this together.

I wanted to drop a line about gear persistence. You don't have to use it. The original credit goes to aeroson. I have his two function files in my missions folder and then:

in my initPlayerLocal.sqf, I have the following lines:

getLoadout = compile preprocessFileLineNumbers 'get_loadout.sqf';
setLoadout = compile preprocessFileLineNumbers 'set_loadout.sqf';
loadout = [player] call getLoadout;
player addMPEventHandler ["MPKilled", {loadout = [player] call getLoadout;}];
player addMPEventHandler ["MPRespawn", {[player,loadout] call setLoadout;}];

This works fairly well and saves gear upon true death and reloads gear upon respawn. I have a mission that uses it with stock BIS respawn dialog. I am hoping it would work with yours too.

Anyway, to reiterate, this revive system is a great one and thank you very much for your work.

Share this post


Link to post
Share on other sites
Grimes, this revive script is truly awesome. I am definetely a buyer. Thanks for putting this together.

I wanted to drop a line about gear persistence. You don't have to use it. The original credit goes to aeroson. I have his two function files in my missions folder and then:

in my initPlayerLocal.sqf, I have the following lines:

getLoadout = compile preprocessFileLineNumbers 'get_loadout.sqf';
setLoadout = compile preprocessFileLineNumbers 'set_loadout.sqf';
loadout = [player] call getLoadout;
player addMPEventHandler ["MPKilled", {loadout = [player] call getLoadout;}];
player addMPEventHandler ["MPRespawn", {[player,loadout] call setLoadout;}];

This works fairly well and saves gear upon true death and reloads gear upon respawn. I have a mission that uses it with stock BIS respawn dialog. I am hoping it would work with yours too.

Anyway, to reiterate, this revive system is a great one and thank you very much for your work.

Thank you very much for this reference. If it works with the BIS spawn, it'll work with my system. This script is very stock, which makes everything a whole lot easier. I'll give it a look tonight or tomorrow. Thanks!

Share this post


Link to post
Share on other sites

Hey Grimes,

just want to report something OR it could be how I have my set up?

After more testing with some of my group- one major issue has been discovered. When flying in a helicopter and getting shot down and "dying" the message "you are unconscious, etc" comes up for a few seconds and it appears that you are dead( but only for a few seconds), but then we become automatically fully revived and not actually dying? We can walk away out of a burning helicopter absolutely fine and not only that we become invulnerable ? We used two full mags on one another and not a scratch.

What's odd when we're on the ground and dying as infantry it seems to be working fine? Not sure if its something I've done or a conflict with some mods, or...?

Some help/suggestions please. Thanks.

P.S. This happens on both client and server mp.

Edited by pathfinder2-1

Share this post


Link to post
Share on other sites
Hey Grimes,

just want to report something OR it could be how I have my set up?

After more testing with some of my group- one major issue has been discovered. When flying in a helicopter and getting shot down and "dying" the message "you are unconscious, etc" comes up for a few seconds and it appears that you are dead( but only for a few seconds), but then we become automatically fully revived and not actually dying? We can walk away out of a burning helicopter absolutely fine and not only that we become invulnerable ? We used two full mags on one another and not a scratch.

What's odd when we're on the ground and dying as infantry it seems to be working fine? Not sure if its something I've done or a conflict with some mods, or...?

Some help/suggestions please. Thanks.

P.S. This happens on both client and server mp.

I never even considered the event of dying while airborne. I am at work now, but can get started on it tonight. There are a few vehicle related things that need doing, but moreso for quality. What you are reporting certainly is an issue. Thank you for bringing it to my attention. Glad to hear all works well otherwise though.

Share this post


Link to post
Share on other sites

The automedic is needed more than ever mate. Is there a timescale for this? Just ask if you need a tester (I have dedi too)

Also found a bug in your mission that uses the script, where I died close to a building wall and the AI could not reach me to revive.

Share this post


Link to post
Share on other sites

[*]For SP' date=' simply run your SP mission as an MP Host. This allows for the use of parameters anyway, allowing you to make your mission more diverse!

[/quote']

Hey Grimes, this script really looks promising!

Is there a way to use it in "pure" SP? I mean, without needing to run the mission as MP host?

Share this post


Link to post
Share on other sites
The automedic is needed more than ever mate. Is there a timescale for this? Just ask if you need a tester (I have dedi too)

Also found a bug in your mission that uses the script, where I died close to a building wall and the AI could not reach me to revive.

Just to clarify, at this point the AI do not do anything automatic related to this script. They will not revive you. That said, as mentioned before, this is something I want to implement. Time frame? If I had to throw a number, lets say 2 or 3 weeks. I have a few other things to take care of first.

Hey Grimes, this script really looks promising!

Is there a way to use it in "pure" SP? I mean, without needing to run the mission as MP host?

At this moment, I am going to be safe and say No to this. That said, I have been thinking of ways to allow this, so expect it in the future. I know there are folks who play Scenarios in SP, so I want to be able to accommodate them as well.

I realize a lot of my posts include "stay tuned"-type messages. I do this because all of the ideas y'all are putting forward truly are good ones, but they vary on my priorities list. I assure you, whenever I get some free time, I work on the script and new features. That said, stay tuned! :P Thanks guys.

Share this post


Link to post
Share on other sites

Sure, I'll stay tuned then. :) :D

Take your time, your work is much appreciated! *thumbsup*

Share this post


Link to post
Share on other sites

Grimes, sorry to bother you. I can appreciate that you need to look at your script/code relating to the matter I brought up. But we were hoping to play that mission this w/e. Is there a short work around for those issues? For e.g. as a one off I could just set my mission as respawn only, the key thing is the invulnerability thing- is there a way around that, or is it more complex to fix?

Thanks, I appreciate your work.

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

×