Home   Help Search Login Register  

Author Topic: Plzzzzzzzzz help with creating limited groups!!  (Read 3163 times)

0 Members and 2 Guests are viewing this topic.

CptBravo

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #15 on: 15 Jan 2003, 11:29:32 »
Hi,

The question I had was how to set the initial skill of the unit in the first place? What line do I need to add to the script to change the skill level?

Thanks


chills

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #16 on: 15 Jan 2003, 12:46:04 »
How can you make it to make the group respawn after the group is eliminated?
Ottie change the number from 1 in the script to .1 . That makes them less experienced.
« Last Edit: 15 Jan 2003, 12:48:39 by chills »

Offline Ottie

  • Members
  • *
  • And you think this is personal
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #17 on: 15 Jan 2003, 13:46:32 »
CptBravo, and Chills

I don't know which script you are using but  I changed the following script;

It has lesser skills and respawn when al units have died

_pos = _this select 0
_grp = _this select 1

#Begin
"OfficerE" createunit [getpos _pos,_grp,"",0.5,"LIEUTENANT"]
"SoldierEMG" createunit [getpos _pos,_grp,"",0.5,"SERGEANT"]
"SoldierEG" createunit [getpos _pos,_grp,"",0.5,"CORPORAL"]
"SoldierEB" createunit [getpos _pos,_grp,"",0.5,"CORPORAL"]
"SoldierEB" createunit [getpos _pos,_grp,"",0.5,"PRIVATE"]
"SoldierEMedic" createunit [getpos _pos,_grp,"",0.5,"PRIVATE"]
~1
_units = units _grp
_grp setformation "LINE"
"_x allowfleeing 0" foreach _units

#loop
?(("Alive _x" count _units) == 0): "deletevehicle _x" foreach _units; goto "Begin"
~random(10) + 10
goto "loop"
If you can't beat them, buy them

Offline uiox

  • Contributing Member
  • **
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #18 on: 15 Jan 2003, 15:51:21 »
Quote
How can you make it to make the group respawn after the group is eliminated?

If you respawning units of a group and avoid complete destruction use Ottie's scripts before the complete destruction.




CptBravo

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #19 on: 15 Jan 2003, 22:27:32 »
Thanks Ottie! That is exactly what I was looking for. I always wonderd what that '1" stood for!! :)

Hey Chills, I'm using CrashnBurn respawn script.Great script for keeping the enemy coming for more!! :)

You can download it from this site. If you can't find it let me know and I'll attach it.

Thanks  

chills

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #20 on: 15 Jan 2003, 23:46:30 »
I cant seem to find it. Do you get the lag when they respawn? And did you notice in multiplayer that after a while it stops respawning?

CptBravo

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #21 on: 16 Jan 2003, 00:07:58 »
here you go, the CrashnBurn script to respawn AI and delete them after death.

I have not had any lag with this script and I respawned over 400 enemy units in my mission! And that was a MP mission and it seemed to work as it is supposed to.

Thanks

chills

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #22 on: 16 Jan 2003, 00:46:15 »
Thank you! This is great! Is there a script like this for Vehicles? I need it for my Dynamic Battles!

CptBravo

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #23 on: 16 Jan 2003, 03:26:18 »
I think you can use the same script for vehicles. Just change the soldiers with whatever unit you need. I have not tried it but I think it would work.

CrashnBurn

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #24 on: 16 Jan 2003, 04:49:26 »
You can call the scripts without using gamelogics as a spawn position if you want. Just use the trigger that you are calling the script with by giving it a name in its name box, and use that as the position for spawning the units. Remember the centermost point of the trigger is where the units will spawn so place the trigger carefully. It just lets you skip having to place gamelogics around the map. The less things you place in the editor, the quicker the mission loads. example-

[triggername, groupname] exec "create.sqs"

You can use a script like this for vehicles and create new ones when they can no longer fire or move depending on what kind of vehicle it is.

example- assumes group name is east1, and triggername is used as spawn location.

[trigger1, east1] exec "createvehicle.sqs"

;-----------------------------------------------------------------------
#start

_pos = _this select 0
_grp = _this select 1

_crew = units _grp
"_x allowfleeing 0" foreach _crew

#loop

?(("Alive _x" count _crew) < 3): goto "create"
? NOT(canfire _tank): goto "create"
? NOT(canmove _tank): goto "create"
~random(5)
goto "loop"

#create

? NOT(alive player): exit
_tank setdammage 1
~1
"deletevehicle _x" foreach _crew
;wait 75 seconds for smoke to stop
~75
deletevehicle  _tank
~random(10)
_tank = "T80" createvehicle getpos _pos
~1
"SoldierECrew" createunit [getpos _pos, _grp, "c1 = this", 1, "SERGEANT"]
"SoldierECrew" createunit [getpos _pos, _grp, "c2 = this", 1, "CORPORAL"]
"SoldierECrew" createunit [getpos _pos, _grp, "c3 = this", 1, "PRIVATE"]
~1
c1 moveincommander _tank
c2 moveingunner _tank
c3 moveindriver _tank
goto "start"

;-----------------------------------------------------------------------

chills

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #25 on: 16 Jan 2003, 09:27:26 »
Thank you! Im off to try it!

chills

  • Guest
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #26 on: 17 Jan 2003, 07:24:55 »
It works! Great one!
« Last Edit: 17 Jan 2003, 07:34:05 by chills »

Offline uiox

  • Contributing Member
  • **
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #27 on: 17 Jan 2003, 14:07:03 »
A tip for really creates new groupS.

If a group is destroy you need a predefined group for creates it.
Something like that :

"logic" createUnit [ PosUwant ,PreCreateGroup ,"NewUnit = this"]

After U join NewUnit to a group null

[NewUnit] join grpNull

And create a new group

_NewGroup = group NewUnit

After You can do that for build the new group

"logic" createUnit [ PosUwant ,_NewGroup  ,"NewUnit = this"]


Note: I'm working on scripts for "restart" system:
Part 1 : infantry
Transition : delete infantry, create armored
Part 2 : armored

With this I can design a mini campaign in a mission.
« Last Edit: 17 Jan 2003, 14:16:29 by uiox »

Offline Ottie

  • Members
  • *
  • And you think this is personal
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #28 on: 17 Jan 2003, 14:21:56 »
uiox,

maybe this is a better solution, (I haven't tried it)

"logic" createUnit [ PosUwant , grpNull ,"NewUnit = this"]
If you can't beat them, buy them

Offline uiox

  • Contributing Member
  • **
Re:Plzzzzzzzzz help with creating limited groups!!
« Reply #29 on: 17 Jan 2003, 17:57:16 »
Not work, I have test different solutions during 4 hours. It's one of the first I have try.
But sometime you don't do the good sequence.
It's hard to test cause OFP when you are wrong it does nothing (no error ans no unit creates).
Maybe a solution with grpnull...
« Last Edit: 17 Jan 2003, 18:02:43 by uiox »