Jump to content
Sign in to follow this  
norrin

SQF revive script

Recommended Posts

AI_enabled revive script update(130807)

The new version is available here

Changes

* The mission maker can now specify if he only wants to give medics the capability to revive in the init.sqf.

* The revive timer option has been enabled. This gives mission makers the option to set an amount of time. If that time elapses before a unit is revived it will respawn at base_1 (preferably at the mission start point). Therefore a mission start marker must be defined as Base_1 in the respawn points for this to work. NB: this works slightly differently to the AI_disabled revive timer.

* Hopefully fixed the occasional dialog bug identified by HulkingUnicorn in the previous post.

Additional implementation notes

* If the mission_end function is being used then it will create a trigger of the type “END6†on the map which may conflict with an “END6†trigger placed in the mission editor.

* If you wish to use custom sounds in your mission a config file, config.cpp, for custom sounds is located in the dialogs subfolder of the revive_sqf folder and this will need to be changed.

* If you do not want to use the sound option and want to reduce the size of your mission then set call_out_function = 0, delete the sound folder and also delete this line from the description.ext file

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">#include "revive_sqf\dialogs\config.cpp"

Recommended usage of options

If the revive timer option is utilised it is probably best to disable the revive/respawn at base dialogs in the init.sqf.

Bugs

* Occassionally a unit’s body will disappear if the revive timer is exceeded.

* Occasionally when using this revive with other scripts, such as Kiljoy’s weather script, you will need to put the init.sqf code for the other scripts before the init.sqf code for the revive.

Share this post


Link to post
Share on other sites

Norrin,

i would like to ask you what shall i put or what would you like to put as information refering the revive script in the briefing.html

if you could add it in the 1st post for all to use it, would be very apreciated.

Share this post


Link to post
Share on other sites
Norrin,

i would like to ask you what shall i put or what would you like to put as information refering the revive script in the briefing.html

if you could add it in the 1st post for all to use it, would be very apreciated.

To be honest bravo I've never thought about it. I'll look through some missions/scripts and see if I can come up with something. If any one has any suggestions that would be great. smile_o.gif

Share this post


Link to post
Share on other sites

Hey norrin -

What's the main difference between the disabledAI and the enabledAI versions? I'm trying to implement your new version in Black Sword, but the mission is meant to have the AI disabled, and <s>so we experience weird problems such as  players dying for no reason (joined in progress or not), no revive action when close to the bodies, body disappearing, etc.</s>

Just point me out in the right direction, cheers!

Igor.

[edit]

Disregard, it may be caused by the revive_timer option... I'll report later.

Share this post


Link to post
Share on other sites

Afaik Igor when i use AI_Disabled (which is all i use)when i start a clan coop, the spaces not filled by clan members are automatically disabled!

Share this post


Link to post
Share on other sites

Well I meant other than the descritption.ext actually smile_o.gif

Disregard my previous post, all errors seem to have been caused by me badly configuring the revive_timer variable smile_o.gif.

Share this post


Link to post
Share on other sites

Norrin,

Have you tried to implement this into kiljoy's Evo MP mission?

I've tried to include it into the mission as I only plan lan with 4 others but come up with errors that stay throughout the match. It all seems to work with no problems but cannot figure how to eliminate the error message. My scripting knowledge is limited and any help would be greatly appreciated.

The error is as follows:

'say_scalar [#]bool array string 0xe0ffffef = false'

error missing ;

And then is quickly followed by;

'say_scalar [#]bool array string 0xe0ffffef '

error missing ;

Which stays throughout the game. Its late and I've tried some things that don't work.

thanks and great scripting, this really adds alot to arma

rod

Share this post


Link to post
Share on other sites
Norrin,

Have you tried to implement this into kiljoy's Evo MP mission?

I've tried to include it into the mission as I only plan lan with 4 others but come up with errors that stay throughout the match. It all seems to work with no problems but cannot figure how to eliminate the error message. My scripting knowledge is limited and any help would be greatly appreciated.

The error is as follows:

   'say_scalar [#]bool array string 0xe0ffffef = false'

     error missing ;

And then is quickly followed by;

    'say_scalar [#]bool array string 0xe0ffffef '

     error missing ;

Which stays throughout the game. Its late and I've tried some things that don't work.

thanks and great scripting, this really adds alot to arma

rod

To be honest I've only ever played Evolution for a short time and never tried to make the conversion.  It sounds to me like the sounds from the revive are conflicting with the sounds in Evo though.  This will happen as both of the description.ext files of Evo and the revive script are trying to define a list of sounds when only one can be defined.  There's a couple of ways of fixing this error:

1. Don't use the sounds in the revive script delete the sound folder from the revive script and remove the <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">#include "revive_sqf\dialogs\config.cpp" line form the revive description.ext file and make sure the call_out_function = 0; in the revive init.sqf code.

2. If you are handy with scripting you could cut and paste the sound config code from the evo description.ext file to the revive config.cpp file (where the revive sounds are defined) which you can find in the dialog sub-folder in the revive_sqf folder and make any necesary changes to the code.

Hope this helps.

norrin

Share this post


Link to post
Share on other sites
Norrin,

i would like to ask you what shall i put or what would you like to put as information refering the revive script in the briefing.html

if you could add it in the 1st post for all to use it, would be very apreciated.

To be honest bravo I've never thought about it. I'll look through some missions/scripts and see if I can come up with something. If any one has any suggestions that would be great. smile_o.gif

iv'e come on with this "crappy version" for the Briefing:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">Revive Script v1.0 Written by norris

The Revive Script allows you to bring back your unconscient friend to game using a menu.

AI will be able to bring you back when ordered by leader.

While players are unconscient they are able to spectate other players.

When all players are unconscient the mission ends.

On version 1.08 on both dedicated and local servers. Works with JIP.

would be nice if someone improves it smile_o.gif

ps- norrin is there any improvements on the revive script about the prone anim getting revive?

Share this post


Link to post
Share on other sites

Hi, great script; couple of things:

It would be really helpful if there was more information on the unit types that can revive. It looks like only soldiers (not teamleaders or squadleaders?) can revive at present but I don't really understand it. All I want is to have all units on my side able to be revived, and to know how to have only medics able to revive or all units able to revive.

There isn't much on how to change the sides, either.

Share this post


Link to post
Share on other sites

Everything which you have asked about can be changed in the init.sqf. Have a nose around there, and change what you need to, its very self explanatory.

Share this post


Link to post
Share on other sites

In the last version i changed the hard coded 100 Meters to a init.sqf variable :

follow_cam_distance = 250;

So i can change the params for the follow cam quickly.

If the mission is palced in an town 100 meters is ok ... in wide aeras 250 meters would be better...

Share this post


Link to post
Share on other sites
Hi, great script; couple of things:

It would be really helpful if there was more information on the unit types that can revive.  It looks like only soldiers (not teamleaders or squadleaders?)  can revive at present but I don't really understand it.  All I want is to have all units on my side able to be revived, and to know how to have only medics able to revive or all units able to revive.

There isn't much on how to change the sides, either.

Hi Gisen,

The soldier classes are organised like a logical tree.  With the classes further up the tree being a more generic type.  Check out the soldier class tree available on this page: http://www.ofpec.com/COMREF/armavehicles.php

As you can see the generic west (soldierWB) class includes all the subclasses of western soldiers eg: from SoldierWG to SoldierWCrew.

Therefore to get west medics to heal any type of west unit also using the revive script use the following options in the init.sqf:

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

can_revive_2 = "";

can_be_revived = "soldierWB";

can_be_revived_2 = "";

@bravo - Thanks smile_o.gif I'll use what you've got as a template and get something posted hopefully later today.

@MCPXXL - Consider it done m8 smile_o.gif  Just making some slight changes to simplify/optimise the code as well as fixing an annoying bug found by bravo 6 related to the way healing players detect unconscious players in my code.  Once they're done and properly tested I'll get the revised versions posted either tonight or tomorrow night Melbourne time.

Share this post


Link to post
Share on other sites
Hi norrin smile_o.gif Did you get my e-mail? In the attachement there is the problem I have mentioned.

I sent you a reply to your email a couple of days ago and then re-sent it again this morning as I've been having some probs with my ISP and had a major lock up while down loading my emails and may have lost some both going out and being received.

Check your email again m8 as I would of sent it about an hour ago - if its not there I'll resend it.  If you sent me a second mission for editing then you better re-send it cause it got lost in the lock-up.  Sorry m8.

@Gisen, if you are looking for an answer to your question about soldier classes its answered on the previous page smile_o.gif

Share this post


Link to post
Share on other sites

Oh my god, I've checked my e-mail spam filter a few moments ago and recognized 3 mails of you wow_o.gif I've set your e-mail address to friendly smile_o.gif

Were there any attachements? The filter doesn't show them anymore once an e-mail is marked as hostile. Can you send it again please? The mail filter should be ignoring you now biggrin_o.gif

Quote[/b] ]

Just one other thing I forgot you'll still need to make the group leader in

your Sabotage mission a higher rank than the other team members otherwise

you'll pass the leadership onto an AI unit when you die/revive.

Ah that's very good! I was getting crazy about this. I thought it was a bug of ArmA tounge2.gif I'm glad to hear how I can fix this.

Share this post


Link to post
Share on other sites

Hi Norrin,

Have you ran into crashing into the Water in an Air Vehicle and screen goes BLACK. I can hear the pilot swimming but no video, just black. If i crash same Air Vehicle on Land no problem? Strange? help.gif

Share this post


Link to post
Share on other sites
Hi Norrin,

Have you ran into crashing into the Water in an Air Vehicle and screen goes BLACK.  I can hear the pilot swimming but no video, just black.  If i crash same Air Vehicle on Land no problem?  Strange?  help.gif

What version of the code are you using m8 ai_enabled or disabled?  Anyway I'll look into it.

@legislator - resent smile_o.gif

EDIT: Its OK vengence I've found it AI_disabled script some problem with the anti-water code - I'll start working on a fix.

Share this post


Link to post
Share on other sites

Updates for AI_enabled and AI_disabled Revive Scripts (20th August 2007)

Get the revised AI_enabled script here

Get the revised AI_disabled script here

Fixes:

* No longer will the revive action appear when the player is next to a conscious prone unit that is not carrying weapons (more relevant for the AI_enabled script).  Thanks to bravo 6 for finding this bug

* Fixed the anti-water script bug identified by vengeance1 in the AI_disabled script - I highly recommend everyone to down load the latest version for this fix. Note there is no anti-water script in the AI_enabled version so please let me know if you feel you'd like this feature implemented.

New Features

* added the follow_cam_distance variable in the init.sqf so that the mission designer can specify up to what distance the unconcious follow camera will follow friendly units as suggested by MCPXXL.

* simplified/optimised the code in the revive_player.sqf

* also changes to the camera_follow.sqs, init.sqf and improved the information in the 2 note/implementation files.

Share this post


Link to post
Share on other sites

Thanks Norrin, I will give it a try right away, bye the way got it working with Airlift, very nice combo of scripts.

notworthy.gif

Share this post


Link to post
Share on other sites

It's working very good now, norrin wink_o.gif Thanks!

May I ask a wish for future updates? biggrin_o.gif I'd like to have a First-Person-View in the spectating view just like in Kegetys's spectating script. It's always useful to observate the own team mates while you're waiting for rescue.

What about filters to disable the AI within the spectating script? I know these aren't the core functions of your script but from my point of view your script has become more important to my missions than the other spectating script. inlove.gif

Share this post


Link to post
Share on other sites

Thank you for the answer Uzi and Norrin, maybe you could put a link to that page in the readme in the next version so noone has this question again?

Cheers

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  

×