OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: eversman on 04 Jun 2003, 21:47:59
-
I have one question. I try make a mission that player is blachhawk pilot and he hust stop a group of cars. I have a convoy of three Uaz and i want stop them but i dont want to kill soliders in second and third car. I put a triger on the map, that if first Uaz in convoy will dead the others should stop (stop true command), but even if first car is out of action the rest didnt stop.
What should i do????
-
Try defining the drivers as the units to be stopped:
driver UAZ2 stop true ; driver UAZ3 stop true
GrEEtz! :)
-
condition : not alive uaz
OnActiv : [Truck1, Truck2] setfuel 0
Put that in your trig, should work
-
Insead of setfuel=0
Try setvelocity [0,0,0]
Then also use the stop true command.
-
but its so much simpler to sue setfuel, plus theres less lag than using velocity.
Just addfuel again and it will set off again as well.
-
dont use da stop command as it proved lil buggy latly :-X - i t bugged 1 of ma misions 2 death :(
da setfuel command dont work like ace said (@ ace watch ur syntax ;))
unitname setfuel 0
not array ;)
LCD OUT
-
Hey, eversman ;) and welcome aboard the lovejeep! :-* 8)
A trigger could do the job :thumbsup:
condition:
Behaviour Jeep1D == "Combat" || Behaviour Jeep1D == "Stealth"
OnActivation:
"[_x] orderGetin false" foreach units GroupName
som'n like that. This will kick them outta the jeeps, if thats what ya want
-
Thanks guys it now works fine :thumbsup:
But i have only one question:
As you knew in my mission i have a convoy and i want that sometimes at intersection cars turn at diffrent directions(south and north).
Just like witch objects that sometimes they are in difrent places.
Can i do this or this is unreal :hmm:
Please :help:
-
First off, your first problem was probably that with your three Urals, the first one was the leader. Now when he dies, then #2 takes over, and that command to stop is lifted when he takes command If the leader is in the second ural, and #2 is in the lead ural, then a trigger saying when #2 dies to stop, should work( I did this in one of my first missions).
Second, your new request of a convoy randomly shooseing what direction to go at an intersection...
AI is stupid. All computers and technology is stupid. A dog is much smarter. If your computer could, and you told it to go fetch the paper, it would walk outside, pick it up, and stay there holding the paper, waiting for a command to come back inside iwth the paper. If you told your dog to do the same thing, he would go outside, get the paper, and walk back inside to you, with the paper.
Anyways, you need to first decide a way tha the convoy is going to know which way to go. Makeign the AI randomly choose is more difficult than makeign a trigger to say... detect where the helicopter is, so the convoy goes the route leading away from the helicopter.
However you conclude to do this, it will be best to do it with a script, being that alot of triggers, waypoints, and so forth on the map, may cause lag.
-
AI is stupid. All computers and technology is stupid.
somtime AI is lots smarter dan som humans i know
If your computer could, and you told it to go fetch the paper, it would walk outside, pick it up, and stay there holding the paper, waiting for a command to come back inside iwth the paper.
dats not AI - dats regular comp ;) :P - AI has somin 2 do w/ intelegence - if u made ur comp a AI - he wud fetch da paper back (or wil go n read it ::)) - wich is da reason dat u can call da AI in OFP (nd most oder games) half AI - so it cud obey da wishes of da mission maker nd not alwayz do wat is best ::)
If you told your dog to do the same thing, he would go outside, get the paper, and walk back inside to you, with the paper.
i gott a dog - wen i tel him 2 do somin - he just stands lookin @ me ::) ;D - dogs r not smarter dan AIs - AIs r as smart as da designer made em
bout how 2 do it - v. simple :P
make some GLs on d aplaces it can go nd use da random command like dat
_num = random 2
? _num < 1 : goto "gonorth"
LeadTruckName move getpos NameOfSouthernGL
exit
#gonorth
LeadTruckName move getpos NameOfNorthernGL
exit
wont lag at all :P
do u think dat after dat - if da Matrix is real - da AIs wil luv me more ? mebe lots of money on da way 2 me ? ::)
LCD OUT
-
Well your leaving out one flaw in your statement LCD. AI (Like OFP's) is a series of commands programmed by a human being, that if translated into plain english would sound like "What to do after..." or "What if...".
So to make this brief, If the programmer didn't program all the following into that AI: "Whatot do after get paper? Go back inside. What to do after I get inside? Go to master. What to do after I go to master? Do hand paper to master, EXIT. What if master is not there? Go to table. What to do after at table? Do place paper on table. EXIT".
So once again, any AI or computer is only as smart as the person who made it.
Heck, my dog is slower than any computer mentaly, but all I need ot do is show it once what to do, and give it a treat after it does it, and I dont have to do crap after that. What if I moved? I would have to reprogram the AI to where everything is. What if the robot got the paper, and then someone tried to kick it? MY dog would bite that persons nutz off, the robot would have to stop and analize the situation and then respond, pending the programer made a operation for "Condition: Getting my @$$ wooped".
-
getin into AI buisness here ;D huh ?
Well your leaving out one flaw in your statement LCD. AI (Like OFP's) is a series of commands programmed by a human being, that if translated into plain english would sound like "What to do after..." or "What if...".
So to make this brief, If the programmer didn't program all the following into that AI: "Whatot do after get paper? Go back inside. What to do after I get inside? Go to master. What to do after I go to master? Do hand paper to master, EXIT. What if master is not there? Go to table. What to do after at table? Do place paper on table. EXIT".
did i say oder thin ?
wich is da reason dat u can call da AI in OFP (nd most oder games) half AI - so it cud obey da wishes of da mission maker nd not alwayz do wat is best
exactly wat i say ;)
dis is half-AI cuz it depends on wat da man told it 2 do ;D
Heck, my dog is slower than any computer mentaly, but all I need ot do is show it once what to do, and give it a treat after it does it, and I dont have to do crap after that.
nd its even less on comp ;) - tell (not show) it 1 time wat do nd den run da program again n again nd itll do watever u want - u c ? not doin crap after da 1st time + not needin 2 give example + not givin it treat
What if the robot got the paper, and then someone tried to kick it? MY dog would bite that persons nutz off, the robot would have to stop and analize the situation and then respond, pending the programer made a operation for "Condition: Getting my @$$ wooped".
depends on wat type of dog u have ::) - he can run away ;) - dats inpredictble nd ur dog can alwayz not come back 1 day cuz he tried 2 bit som1s nutz >:(
da robot - wont try 2 analyze cuz no1 told him ::) - it wil just continue bringin da paper home - not reactin 2 da man who kicks @ all
btw i know da if i showed ma dog how 2 brin paper hell prooly have fun seein me doin it ::) nd wont move a bone later - but den ma dogs is master of lazines (k - mebe after me)
LCD OUT
-
Dinger (or Terox) has posted about this sort of 'random' pathing in the past, under advanced scripting from memory.
Its possible to do, but definitely not easy (scripts, tables, etc).
Check out posts in the Advanced Scripting area, it will be there somewhere.
:)
-
notices that the 'retired' part of Granpa noony's title has been removed... oooooh yay :D
-
YO noon grandpa wuzup ? ur back (not dat u ever realy left ::))? kool 8)
LCD OUT
-
::) so, noonsy, I figure it didn't take ya more than 6 months to get yer divorce back home! 8) ;D
*hint-hint: RECRUITMENT DEPOT* :o ;D ;D ;D
ROFLMAO