Home   Help Search Login Register  

Author Topic: Trying to create a zombie script  (Read 6318 times)

0 Members and 1 Guest are viewing this topic.

Offline mathias_eichinger

  • Missions Depot
  • Administrator
  • *****
  • I'm a llama!
Trying to create a zombie script
« on: 05 Feb 2010, 22:56:04 »
Hey guys, I am trying to create a mission that feels like the film "I am Legend" with Will Smith.

For this, I need to create a script that lets civilians close in at the player. But when they encounter a searchlight, they should back away and run to the woods.

This is what I have:

Quote
#loop
~0.5
zombie domove getpos me
If(zombie distance light < 50)Then{zombie domove getpos home} 
goto "loop";

....Where zombie is a single civilian named zombie
...light is a searchlight
...home is a game logic somewhere in the woods

What this script does now is to let a single civilian follow me around the map until I am close to the light and he is at 50 m distance. There he would twitch back and forth because he is trapped between the 2 commands.

My questions:
1) How do I apply the script to all civilians in a given trigger, not just one man?
2) How can I override the "getpos me" with that "getpos home" order once the unit is close to the light, e.g. blinded by it?

I sure have to implement things like evil screams and melee animations as well, but that would be for later....
Help on my questions would be most appreciated.

Cheers

Mathias

Offline ZapBrannigan

  • Members
  • *
Re: Trying to create a zombie script
« Reply #1 on: 06 Feb 2010, 15:17:51 »
#loop
~0.5
zombie domove getpos me
If(zombie distance light < 50)Then{zombie domove getpos home}
@zombie distance light > 100
goto "loop";


how about that?

Offline mathias_eichinger

  • Missions Depot
  • Administrator
  • *****
  • I'm a llama!
Re: Trying to create a zombie script
« Reply #2 on: 06 Feb 2010, 17:53:34 »
Hey Zap, thanks for your efforts.

Your proposal leads to the zombie just stopping at the given distance from the light, and not moving about. It would not follow me again if I would put the required distance between me and the light.  :scratch:

EDIT:

Quote
#loop
~0.5
zombie domove getpos me
? zombie distance light < 20 : goto "Home"
goto "loop";

#Home
zombie domove getpos home
~30
goto "loop";

This script leads one zombie to close in on me until he is closer than 20 m to the searchlight. Then he runs for his home in the woods only to return and charge again, be driven off, etc. etc.

Next question remains: How can I do it for all units of a side in a trigger, or probably more practically just for a whole group of zombies?
« Last Edit: 06 Feb 2010, 18:49:33 by mathias_eichinger »

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: Trying to create a zombie script
« Reply #3 on: 07 Feb 2010, 03:48:23 »
okay,I made a mission for you

Download that mission and put it in the editor...
Preview and you'll find how it work.

Actually,I finished that mission yesterday,but I was unable to post due to connections here. (the backbone dropped a few days ago and its now OK)

Regards,
Haroon1992

EDIT : Oops!
I thought it was ARMA,anyway, I know you have ARMA (right?)
The script is the same,whether its ARMA or ARMA 2..
You have to copy/paste it in your ARMA 2 Zombie mission...

(Sorry for my mistake)

EDIT 2 :
The script in the mission is here (i think its more convenient to show it here

zombiescript.sqs
Code: [Select]
_zombieman=_this select 0;
_tobefollowed=_this select 1;
_lightobject=_this select 2;
_homey=_this select 3;

;syntax = [man name,player name or the person's name,name of light,name of zombie hide-out] exec ;"zombies.sqs"

_zombieman setbehaviour "CARELESS";
_zombieman setspeedmode "LIMITED";

#zombieloop

? _zombieman distance _lightobject > 20 : _zombieman domove getpos _tobefollowed
?_zombieman distance _lightobject  < 20 : _zombieman domove getpos _homey
?_zombieman distance _tobefollowed < 2 : goto "zombiebite"
~0.1
goto "zombieloop"
;=========================================================================
#zombiebite

_randanim=ceil random 2
?_randanim<1.5 : _animname="AwopPercMstpSgthWpstDnon_Part3"
?_randanim > 1.5 : _animname="AwopPercMstpSgthWpstDnon_Part4"

;-------------------------------------
;checks to make sure player is still around zombie
;-------------------------------------

?_zombieman distance _tobefollowed < 3 : _zombieman setdir getdir _tobefollowed* (-1);_zombieman dowatch _tobefollowed;_zombieman switchmove _animname
~1

;--------------------------------------------------
;the animation used here is for ARMA and is a Grenade Throwing animation,which looked like a scratching zombie
;checks again to ensure that player is still near zombie to avoid being scratched even when he's away from zombie
;--------------------------------------------------------
? _zombieman distance _tobefollowed < 3 : _tobefollowed setdammage getdammage _tobefollowed + 0.3

~2

hint format ["%1",getdammage _tobefollowed]
;damages the player if he catches the scratch,the damage value is 0.3,so four scratches and the player is dead
goto "zombieloop"

As you can see now,there's local variables so you can use this same script for all of the civilians you want to be zombies.
Just put the described syntax with your desired options in the INIT of the civilian.
To make a whole group zombie,put the following in the INIT of leader :
Code: [Select]
{[_x,player,light1,zombiesweethome] exec "zombiescript.sqs"} foreach units group this
I am *this* clumsy that I have to edit my post twice  :D
« Last Edit: 07 Feb 2010, 03:56:23 by haroon1992 »
Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(

Offline mathias_eichinger

  • Missions Depot
  • Administrator
  • *****
  • I'm a llama!
Re: Trying to create a zombie script
« Reply #4 on: 07 Feb 2010, 21:28:53 »
Wow, haroon that looks like a mighty complete package!

I need to try that out once I find the time, I guess I owe you several virtual beers.  :D
Many thanks for your effort!

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: Trying to create a zombie script
« Reply #5 on: 08 Feb 2010, 03:42:55 »
The script isn't that complete.
You will need to alter some of it to suit your need.
And the script is in .sqs format (to which people said 'old')

Also,keep in mind that the zombie may not follow you if you get inside buildings (Just thinking)
Sometimes,they don't follow you if you are in shallow water,too.

I recommend you ask someone to convert it to .sqf format as this one may cause lag if you used this for more than 100 zombies.(not sure whether it will cause lag with your machine though,I have got a low-end CPU,maybe that's the cause of it)

GLuck,
Haroon1992

EDIT : 
Sorry,mathias...
That script I gave you is still not working with the light
Here is the fix.......
(You know,I kept creating and tweaking that example mission,I even added sound!!!!!
It's gonna like a real mission rather than an example mission....
The mission is still unfinished,I'll attach it this evening)
Here is the scipt (seems complicated,but its me who sloppily commented that the script looks like a mess)
Code: [Select]
_zombieman=_this select 0;
_tobefollowed=_this select 1;
_lightobject=_this select 2;
_homey=_this select 3;
_fleetimelimit=_this select 4
_feardis=_this select 5;
_additionalcondition=_this select 6;
_fleetime=0
;syntax = [_zombieman,_tobefollowed,_lightobject,_homey,fleetimelimit,_feardis] exec "zombies.sqs"
;syntax explanations

;_zombieman -    name of zombie

;_tobefollowed -   player name or the person's name(victim)

;_lightobject   -   the name of the object that the zombies afraid of,you can set anything here,like
; a chopper or a truck,which the zombies will become afraid of and run away from that thing

;_homey     -   place to where zombies will flee,when they encounter "object" OR "thing"
;this can be anything from a graveyard to forests.

;_fleetimelimit  -   the time in seconds,which starts when the zombie encounter _lightobject,
;after the desired time,the zombie will return back to player.
;should be more than 10 seconds,use the RANDOM command here to make it more dynamic
;the zombie will fight back the player when returning home,if he gets too close to the zombie

;_feardis   -    the distance between ZOMBIE and _lightobject,at which the ZOMBIE will become afraid of _lightobject
;and return back to _homey,use min value + random value here to make it dynamic.

;_additionalcondition    -    an additional condition for the zombie to flee,for example,the zombie only flees when
;the searchlight is manned / turned on


;EG SYNTAX
;[zombienimble1,player,searchlight1,home1,15+random 10,50,!(isNil gunner searchlight1)] exec "haroonzombiescript.sqs"

;exp > zombienimble1 chases player until it saw searchlight1 (GAMELOGIC'ED OR MANNED) from 50m distance,zombienimble then fleed away
;to his grave,home1,on the way to home, after a min of 15 seconds,zombienimble changed his mind and return back to
;player instead of going to home1


; HAVE A GOOD TIME WITH THIS SCRIPT



#zombieloop

? not (ALIVE _zombieman) : exit
? not (ALIVE _tobefollowed) : goto "deadplayer"
_zombieman setbehaviour "CARELESS";
_zombieman setspeedmode "LIMITED";
? _zombieman distance _lightobject > _feardis : _zombieman domove getpos _tobefollowed
?_zombieman distance _lightobject  < _feardis AND _additionalcondition : goto "goawayzombies"
?_zombieman distance _tobefollowed < 2 : goto "zombiebite"
~0.5

goto "zombieloop"
;======================================================================
#zombiebite
_randanim=round random 2
?_randanim<1.5 : _animname="AwopPercMstpSgthWpstDnon_Part3"
?_randanim > 1.5 : _animname="AmovPercMrunSnonWnonDf_AmovPercMstpSnonWnonDnon_gthStart"

;checks to make sure player is still around zombie
?_zombieman distance _tobefollowed < 3 : _zombieman dowatch _tobefollowed;_zombieman switchmove _animname
~1

;the animation used here is for ARMA and is a Grenade Throwing animation,which looked like a scratching zombie
;checks again to ensure that player is still near zombie to avoid being scratched even when he's away from zombie

? _zombieman distance _tobefollowed < 3 : _tobefollowed setdammage getdammage _tobefollowed + 0.3

~2
hint format ["%1",getdammage _tobefollowed]
;damages the player if he catches the scratch,the damage value is 0.3,so four scratches and the player is dead
goto "zombieloop"
;=====================================================================
#deadplayer
_zombieman domove getpos _tobefollowed
;zombie moves to victim when its dead
;--------------------------------------------------
@_zombieman distance _tobefollowed < 4
;waituntil zombie gets to 4m distance from victim
;--------------------------------------------------
_zombieman setpos [(getpos _tobefollowed select 0)+(random 2+random -2),(getpos _tobefollowed select 1)+(random 2+random -2),0]
~1.5
_zombieman switchmove "AinvPknlMstpSlayWrflDnon_healed2"
~3
_zombieman switchmove "AinvPknlMstpSlayWrflDnon_healed2"
~4

_zombieman action ["HIDEBODY",_tobefollowed]

;position zombie randomly around player and then perform an eating animation
;ONCE THE ZOMBIE FINISHES EATING THE DEAD,THE BODY WILL SINK INTO THE GROUND
;If you don't want that,just remove this line
;_zombieman action ["HIDEBODY",_tobefollowed]

;haroon : SOUND is added in the EXAPLE MISSION (which will be posted this evening)
;sounds are to be added via description.ext
;=========================================================================
EXIT
;GO AWAY ZOMBIES

#goawayzombies
_zombieman setspeedmode "NORMAL"
?_fleetime==_fleetimelimit : goto "zombieloop"
_fleetime=_fleetime + 0.5
_zombieman domove getpos _homey
~2
;CHECKs

? NOT (ALIVE _zombieman) : exit
? _tobefollowed distance _zombieman < 3 : goto "zombiebite"
? _tobefollowed distance _zombieman < 5 AND _zombieman distance _lightobject > _feardis : goto "zombieloop"
;exp of above line :

;if VICTIM is within 5M from ZOMBIE and ZOMBIE is farer to the FEARSOME OBJECT (> _FEARDIS),THEN goto to ZOMBIELOOP
;which will make the ZOMBIE turn back from going to HOME and chase the VICTIM again


goto "goawayzombies"



:CREDITS
:Haroon1992 (me,beginner scriptor who writes crappy scripts :D)
;mathias_eichinger (for his idea about zombie script)


EXIT



« Last Edit: 09 Feb 2010, 03:13:44 by haroon1992 »
Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(

Offline mathias_eichinger

  • Missions Depot
  • Administrator
  • *****
  • I'm a llama!
Re: Trying to create a zombie script
« Reply #6 on: 10 Feb 2010, 19:36:43 »
Hi haroon,

First of all, I cannot use your example mission because I am on ArmA2 not ArmA1.

I do have problems with both scripts. The first simpler one, the zombie would follow me and scratch, yet when it comes to the fear distance specified in the script it only stands there because it is in conflict between running home when closer than 20 m to the light and running towards me when further away than 20 m from the light.

The second script: I get the message that isNil expects a string and not an object (or the other way round?).
If I omit additional_condition from the syntax, I get the error message of an undefined value and nothing happens.
Could you help me with these problems?

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: Trying to create a zombie script
« Reply #7 on: 11 Feb 2010, 11:06:29 »
I have been heavily working on this script (this whole day!!)
Now I got it working...
But I need to fix some other things and prepare the script...

EDIT :
This is version 1.08 and the download for this version has been removed.
Please go to my last post for the latest version.


« Last Edit: 15 Feb 2010, 15:16:41 by haroon1992 »
Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(

Offline mathias_eichinger

  • Missions Depot
  • Administrator
  • *****
  • I'm a llama!
Re: Trying to create a zombie script
« Reply #8 on: 12 Feb 2010, 21:32:49 »
Hi haroon, just wanted to try out your script, but before opening my example mission, ArmA2 crashed with:

C:\Users\Mathias\Documents\ArmA2\missions\mymission.utes\description.ext, line 71: /CfgSounds/: Missing '}'

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: Trying to create a zombie script
« Reply #9 on: 14 Feb 2010, 16:47:36 »
Sorry,real life work has kept me away from OFPEC for two days.....
But in that two days,I was working intensively on this script...

(I was ashamed because I have said 'this script is perfectly working' in the previous post)
The error you encountered was due to the missed } at the end of the description.ext
Okay,leave that thing.

Now I present you all the Haroon Zombie Script ( note : haroon is not a zombie,i just worried something might happen if  i put a " ' " behind haroon  :D )
Brief Description about current script

-Version 1.0

-Tested more than 5 times in ArmA 2 (no bugs/errors found,except the zombies/civilians go prone when they heard gun-fire,but they do stand up after the gun-fire.)

-Tested more than 25 times in ArmA (no bugs/errors found)

-Added two new options for the User
One - You can now set the zombies to only turn back after they reached home and waited there for 5-15 secs.
Two - An option to reduce the sound when the zombies are eating the victim(I think it becomes too loud if there are more than 15 zombies eating the body)

Current features of this script :

o Hunt victims one by one (if array is Enabled and more than one unit presents in the array)
o Scratch victims,then eat the victim, and the dead victim's body will sink into the ground (HIDEBODY action)
o Sounds on Scratching,Eating,Being Hit,Dying
o Victims also moan when Scratched,Dying
o A Specific Object to which zombies afraid can be added.
o Works with lots of Distance checks so that the zombies will :
- Run home if they encounter that Specific Object from a Defined Distance
- Come back from running home if victim gets within 40-90 meters from the Zombie
o Victim is not damaged by the scratch if he quickly run away as soon as the Zombie scratches.
(The damage amount can also be changed,though not in-game)
o Some other features that I am currently unable to remember....

With Best Wishes,
Haroon1992




 
Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(

Offline mathias_eichinger

  • Missions Depot
  • Administrator
  • *****
  • I'm a llama!
Re: Trying to create a zombie script
« Reply #10 on: 14 Feb 2010, 17:30:30 »
Hi haroon, these are the bugs/errors I found on the first try:

Quote
An unknown error in expression for the nombieshout02.ogg

Quote
_homey is an undefined variable, hence the zombie would not run away from the light, but rather close in to me

Note that I just only tried your quick start method.

Thank you for the script and example missions, I hope you can iron out the errors...are there any specifics I should look for during testing?

Oh, one thing: Is it possible to toggle the speed mode, e.g. make fast running zombies?

EDIT: Just tried your daytime example mission, where the same error occurs for

Quote
man domove getpost har_zombie_home. har_zombie_home is an unknown variable
« Last Edit: 14 Feb 2010, 17:57:49 by mathias_eichinger »

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: Trying to create a zombie script
« Reply #11 on: 15 Feb 2010, 15:14:11 »
I think you have not read how to put the description.ext in your missions.
Also keep in mind that you have to SAVE the mission each time you have modified the description.ext.

I've checked the sound files and the description.ext but I found no errors.
Oh by the way,I am using
ArmA Version 1.18 and
ArmA 2 Version 1.05 (both are latest patches)

I think I missed to put an object which will be set as the home.
(Please wait as I am working on these two missions now)

The readme may be confusing for some people,as its too long.
That's why I put a quick start section.

NOTE : Mathias,please use the scripts in the main folder.(I forgot to update those scripts in the missions,my bad)

Well,did you mean the characteristic of a zombie?
Or how will they act?
(oh...I forgot to add Zombie Features in the readme!!!)
The features list will be added in the next release (which will be uploaded tomorrow)

Toggling speed modes will be added in the next release (this will be the eleventh argument in the array :D)

As this script is highly intended for you (mathias_eichinger),please ask me anything you want to add in this script.
Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(

Offline mathias_eichinger

  • Missions Depot
  • Administrator
  • *****
  • I'm a llama!
Re: Trying to create a zombie script
« Reply #12 on: 15 Feb 2010, 21:45:10 »
Ok, I tried your scripts and missions on ArmA2, Patch 1.05.

I did not have a description.ext there before, as I deleted the one from your version 0.8 and never created one of my own for this mission beforehand. So what I did was just to copy the contents of the Necessary Files folder into my mission and then added the haroon scripts folder. But maybe I have to re-check the readme as it contains a mountain of information.

Now what I intend with that zombie script are not classic zombies but infected people. It is my fault to have put that simplistic description in the post.
What I intend to is to have fast running, carnivorous individuals, not walking dead in different stages of decay.
If you have seen films like "28 days later" or "I am Legend", you know what I mean. I think you can just search for snippets of both films on youtube.

Looking forward to the next edition of the script and I hope I will not miss anything this time!
« Last Edit: 15 Feb 2010, 21:55:29 by mathias_eichinger »

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: Trying to create a zombie script
« Reply #13 on: 16 Feb 2010, 16:39:25 »
Edit :

Okay,here is the new version of my script..
It includes many fixes and more functions....
In addition, I've took two hours to comment out all the statements in the script...which will be a great help to both beginners and people who wants to modify my script them-self.

I cannot write much right now,please just download the pack,it includes all the necessary documentations..
Be sure you take a look at my main script (har_zombies.sqs)...
which contains many many more information about it-self.


Latest Version : v1.2
Availability : Yes
Download Place : This Thread

Thank You Very Much Mathias....
for your Idea about this script and for you putting me on a big job  :D

Regards,
Haroon1992

ChangeLog
Code: [Select]
v0.5
Initial Zombie Script

v0.7
-Added some animations
-Some more variables

v0.8

-Added sound
-Zombies now cannot harm the player when he's inside a vehicle
-Zombies can now hunt down multiple units(who are defined in an array)
-Zombies shout when hit and when they dies.
-Player moans when scratched
-Other sides other than Civilians can now be zombies(note : script removes all ammunitions from the zombie)

v1.0
-Fixed : Zombies not really running away.
-Fixed   : Zombies sometimes stuck because of two conflicting commands.
-New : Users can now define whether the zombies will run to their home and wait there before they turn back and hunt again OR the zombies will turn back to hunt after
           a desired amount of time (FleeTime_Limit)
-Added two array ,one with positive values ("ON","ENABLE" etc) and the other with negative values ("OFF","DISABLE",etc)
(please see readme for more info)

v1.1 (not released to the community)
-Added : new argument,users can now define the speedmodes of zombies
-Fixed : Several issues in the script.
- The script is now splitted,one for ArmA and one for ArmA 2
(due to the command "hintSilent" which can only be used in ArmA 2)
Code: [Select]
v1.2 (This Version)
-Commented every line in the script. (Allowing beginners to learn new stuffs from my script)
-Fixed a Critical Error : Zombies having problem with Victim Array
-Changed : hint to hintSilent in the ArmA 2 version.
-Added : Mission Maker can now defined the amount of damage caused by the zombies(via the mission editor)
-Many other arrangements to make the script look clearer.(Though not that clean as its sqs : D )
Time Taken to Update to Version 1.2 : +5 Hours (due to testing and tweaking in the mission editor)
-Fixed : The variable _aninname is UnKnown as its undefined at the start of script.

EDIT 1 : Oh oh! I found a critical bug in this version too...but its fixed now.
Bug : The zombies are not performing the animations.(Just not doing any animations,all other things are fine)
Reason : the variable _animname was not defined at the start of the script.
(But the animation did worked in previous versions without being defined at the start of the script!!!
I don't know why it become necessary to define it!!!!)
« Last Edit: 19 Feb 2010, 12:41:07 by haroon1992 »
Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(

Offline mathias_eichinger

  • Missions Depot
  • Administrator
  • *****
  • I'm a llama!
Re: Trying to create a zombie script
« Reply #14 on: 20 Feb 2010, 16:55:54 »
Hi haroon, what follows is my next bug report.

Steps before playing

1) Deleting my small zombie test mission.
2) Opening the folder of my planned zombie mission. Note that there is not description.ext beforehand.
3) Copying the sound folder and description.ext into my mission folder.
4) Copying the haroon_zombie_scripts out of their ArmA2 folder into my mission folder.
5) Adding a barrel named home1 to the mission (well within sight of me)
6) Checking if one of the 4 searchlights I am using is still called light1 - positive.
7) Adding a civilian to the mission.
8 ) Coyping the line from the top of your readme into his init line.
9) Saving the mission.

What happened while previewing the mission

1) Error message:
har_victim_damage this select 11
Error zero divisor

2)Error message:
har_zombie_speedmode
Undefined variable

3)Error message:
har_victim damage
Undefined variable

The effect was that the zombie followed me around and was scared away by the light. But since har_victim damage did not work, I was able to receive an unlimited amount of scratches, even if my character was complaining about his head.

Hm, adding several fear objects would be beneficial since I have a bunker compound with 4 lights and a ring of fire. What I would like to achieve is that zombies are scared away by the lights first, then there is a power outtage, and they come close, only to be scared away by the fire. They could then retreat back to a "home2" that is just a few meters out of the shine of fire.

But I don't want to overload you with work, I should be content if you only fix the errors, since you are doing so much already.
« Last Edit: 20 Feb 2010, 17:11:12 by mathias_eichinger »

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: Trying to create a zombie script
« Reply #15 on: 21 Feb 2010, 15:49:51 »
Well,I forgot to update the execution line in  ReadMe.txt ...
(hey you know,the answer is right behind that text you've copied!!
Next time,you should check the Syntax (The Syntax Header in ReadMe)
Sorry for my fault.
Okay here is the correct one :

[this,player,light1,home1,20,20,"OFF","NONE","TRUE",0.8,"FULL",0.3] exec "haroon_zombie_scripts\har_zombies.sqs"

0.3 is the value of damage caused by the zombie,change it to whatever you want.
(only set a value between 0 and 1,setting it 1 will make player dies by one scratch)
0.1=ten scratches
0.3=four/sometimes three
0.5=two
0.9=two/sometimes one
1=one

"FULL" - Zombie's Speedmode ("FULL" is running,they'll run straight towards you so be Careful :D)
(possible values = "LIMITED","NORMAL")

Quote
But I don't want to overload you with work, I should be content if you only fix the errors, since you are doing so much already.

Don't worry,I won't give up until this script is perfectly working (as you wish).

Quote
Hm, adding several fear objects would be beneficial since I have a bunker compound with 4 lights and a ring of fire. What I would like to achieve is that zombies are scared away by the lights first, then there is a power outtage, and they come close, only to be scared away by the fire. They could then retreat back to a "home2" that is just a few meters out of the shine of fire.
That was another great idea!
And it's not difficult to make it.I'll include it in the next release.
My idea is to make the zombies hunt the nearest victim (defined in the Victim Array)

I am working one this,so please wait
(The readme in the next version will be completely rewritten)

Version 1.4 (coming soon!)
--------------------------
Done
------
- shortened variable names to make the script look clear.
- Changed the way of animations and sound.
Mission Make can now define what animation the zombies will do, and what sound they will shout.
There will be three new options-
Zombie Scratch Animation Array
Mission Maker can put his own array of animations in this argument.
(if no array presents,then default animations will be used)


Zombie Eating Sound Array

Array of custom sounds,defined by mission maker.
(if no array presents,then default sounds will be used)
Zombie Scratching Sound Array
(if no array presents,then default sounds will be used)
Array of custom sounds,defined by mission maker.

Doing Now
----------
Zombies hunting the victim nearest to them.(< 30 meters)
Zombies will flee away from the objects defined in an array by the mission maker.
Zombies will have several hide-outs,the nearest hide-out is selected for fleeing.

Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(

Offline Wiggum

  • Members
  • *
Re: Trying to create a zombie script
« Reply #16 on: 07 Apr 2010, 14:13:21 »
Hi,

how is the work going on with you zombie scripts ?

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: Trying to create a zombie script
« Reply #17 on: 09 Apr 2010, 09:31:55 »
Yeah,its pretty done.....
(I am making sure that no problems occur with my script)

Though I am having trouble testing whether this script is multiplayer compatible.......as I have only one PC (the laptop is not good for ArmA 2)

Now Doing :
Conversion to .SQF about 80 % finished (it took me lots of time to convert it!)
Finding and fixing errors......
(I am also planning to add some setvelocity thing to victims,simulating that zombies throw victims)
Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(