Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsCog Forum → ennemie inocent
ennemie inocent
2000-10-15, 11:55 PM #1
hi, can someone tell me how i can make that the ennemies don't open the fire only if I shoot the first?

------------------
May The Force Be With You

[url="mailto:jedi_nizar@yahoo.com"]mailto:jedi_nizar@yahoo.com[/url]jedi_nizar@yahoo.com</A>

Home Page: The Art of a Jedi
Wie vielen Leben setztet ihr ein Ende.
Und wie vielen Leben habt ihr bewahrt.
Glänzt noch einmal im Licht, meine Klingen,
und leuchtet für meine letzte Fahrt.
2000-10-17, 5:57 AM #2
I have an idea.. but not sure exactly how to script it...


alright.. set a civilian, with the desired 3do/pup/snd all that stuff... then you make a second guy same 3do/pup/snd that is armed and ready to kill.. now you set the cog on the civilian.. so if he is damaged, then he will be deleted and turned into the bad guy...


any scripters wanan tell him how to do that? i am not very good with cogs myself..

------------------
SDÅ_Lªkútí
SDÅ_Lªkútí
2000-10-17, 8:31 AM #3
Erm, no. If it's JK, open the enemy's AI file and set the alignment (in the header section) to 0. Then take the original ai and rename it to something else. Next open his cog, add a damaged: message, and an ai to the symbols section, and insert the line of code: AiSetClass(thing, newai) in the damaged message. You could add some validity checks to make sure the player was the aggressor.

Here's what I mean:
Code:
symbols
ai       enemyai=whatever.ai   //the original AI file (unmodified)
thing    enemy
thing    player
message damaged
//add the above to the symbols section
//of the thing's template cog
...
end

code
damaged:
AiSetClass(enemy, enemyai);
...
Return;
...
end
Dreams of a dreamer from afar to a fardreamer.

↑ Up to the top!