Need help in order to script some civilians......
Moderator: Moderators
Need help in order to script some civilians......
What is the best way for me to make some civilians to inhabit some of my multiplayer/ bot maps?
Can I just spawn some unarmed bots, and make run from everybody?
Can I just spawn some unarmed bots, and make run from everybody?
Well, I don't know about making them run away. Standard AI won't run in terror if they get shot at.
I'm sure there's some sort of script (or maybe you could make your own?) where they'll try to stay a certain distance from players, or you could make it so that, when a player moves into a specified area, the AI will run to specified points in another area.
As for the best way to make them just be civilians... Spawning unarmed bots will make them stare at players. You could disable their AI, which should stop them from staring at players. Of course, in a warzone, they might look a bit more realistic if they're in their alert, AI-enabled state, looking at players constantly.
I'm assuming you'll want the AI to be invincible, so just slap some nodamage on them. If you don't make them invincible, they'll all be dead in the first two minutes, because lots of players get their sick kicks by killing teammates or anyone who's unarmed in video games. Ever played Half-Life? Many a Barney and a Scientist have been crowbarred to death in Black Mesa by the oh-so-terrible Gordon Freeman.
If you'd like the civilians to be killable by all players, you'll have to set them to a team other than Allies and Axis. Americans and Germans are the usual AI teams, though I'm not sure if that would be any different. I think Spectator is a team, too. No idea.
I found this in m1l2a.scr. It was never used, so I'm not sure if it will do anything, but it seems to imply some sort of team-changing.
I'm sure there's some sort of script (or maybe you could make your own?) where they'll try to stay a certain distance from players, or you could make it so that, when a player moves into a specified area, the AI will run to specified points in another area.
As for the best way to make them just be civilians... Spawning unarmed bots will make them stare at players. You could disable their AI, which should stop them from staring at players. Of course, in a warzone, they might look a bit more realistic if they're in their alert, AI-enabled state, looking at players constantly.
I'm assuming you'll want the AI to be invincible, so just slap some nodamage on them. If you don't make them invincible, they'll all be dead in the first two minutes, because lots of players get their sick kicks by killing teammates or anyone who's unarmed in video games. Ever played Half-Life? Many a Barney and a Scientist have been crowbarred to death in Black Mesa by the oh-so-terrible Gordon Freeman.
If you'd like the civilians to be killable by all players, you'll have to set them to a team other than Allies and Axis. Americans and Germans are the usual AI teams, though I'm not sure if that would be any different. I think Spectator is a team, too. No idea.
I found this in m1l2a.scr. It was never used, so I'm not sure if it will do anything, but it seems to imply some sort of team-changing.
level.friendly3 german

there are only two (known) sides to MOH, american and german. however jv just found a third difficulty so i wouldn't put it past them to have another faction.
and they're commands,
$guy american
$guy german
side note: you can make the player german too.
and they're commands,
$guy american
$guy german
side note: you can make the player german too.
Moderator
۞
Abyssus pro sapientia
Olympus pro Ignarus
۞
AND STUFF™ © 2006
۞
Abyssus pro sapientia
Olympus pro Ignarus
۞
AND STUFF™ © 2006
Thank you for your input.....
I have only just started to learn MOH.
I have learned scripting in LUA from modding the game Blitzkrieg, I have learned to script for Vice City.
What I am after is civilians for some crowded street scenes.
I once mistakingly put a custom skinned bot into the game with a messed-up tiki. I assume he had standard AI, for he would attack all players reguardlees of the team that they were on.
If I could do that again but, instead of attacking players, running a certain( random) distance away.
Still thinking..................
I have only just started to learn MOH.
I have learned scripting in LUA from modding the game Blitzkrieg, I have learned to script for Vice City.
What I am after is civilians for some crowded street scenes.
I once mistakingly put a custom skinned bot into the game with a messed-up tiki. I assume he had standard AI, for he would attack all players reguardlees of the team that they were on.
If I could do that again but, instead of attacking players, running a certain( random) distance away.
Still thinking..................
Hmmm.....What about making regular bot civilians to walk around the map? Possibly hide from the nazi's when they see then coming?
AI then........hmm....too much processor use ,and not enough animations.i dont recall seeing any "scared" and "fleeing" animations .
maybe for single player ,but then again why use bots? while the AI can do it for less processor usage
Still stumped for now....
Let me keep reading all the tut's and forum's....
Useing
$ai_targetname exec global/disable_ai.scr
will make the ai ignore enemies and anything else but bots will still shoot at them . There is a command
$ai_targetname threatbias 0
that should make them be ignored by the bots in theory . You would still need a script that determines where they run to and when .
$ai_targetname exec global/disable_ai.scr
will make the ai ignore enemies and anything else but bots will still shoot at them . There is a command
$ai_targetname threatbias 0
that should make them be ignored by the bots in theory . You would still need a script that determines where they run to and when .
Actually, Spectator is a team, in multiplayer at least. I've got a script for driveable tanks that ensures that the Spectator team won't be able to drive the tanks.
When I said disable_ai, I just meant that so the AI wouldn't try to fight their enemies, or look like they wanted to.
Also, threatbias 0 is the standard threatbias. AI with threatbias 0 or even threatbias -999999 will still be attacked. Threatbias ignoreme is what will stop AI from being targeted as enemies.
When I said disable_ai, I just meant that so the AI wouldn't try to fight their enemies, or look like they wanted to.
Also, threatbias 0 is the standard threatbias. AI with threatbias 0 or even threatbias -999999 will still be attacked. Threatbias ignoreme is what will stop AI from being targeted as enemies.

Notice there is a distinction between team and dmteam.
team
Property of: Sentient (Actor or Player)
Values:
Property of: Player
Values:
models/player/base/include.txt specifies the player as an american (even when using a german skin).
team
Property of: Sentient (Actor or Player)
Values:
- american
- german
Property of: Player
Values:
- allies
- axis
- spectator
models/player/base/include.txt specifies the player as an american (even when using a german skin).
//
// include the base player model definition
//
}
$include models/player/base/include.tx
$include models/human/multiplayer_generic_human.tik
$include models/human/animation/dialogue/generic_dialogue_german.tik
/*QUAKED ai_multiplayer_german_axis_chav (1.0 0.5 0.0) (-16 -16 0) (16 16 92)
*/
So this "bot" will be regarded as an American, even though it's tik. is named
"multiplayer_german_chav"?
// include the base player model definition
//
}
$include models/player/base/include.tx
$include models/human/multiplayer_generic_human.tik
$include models/human/animation/dialogue/generic_dialogue_german.tik
/*QUAKED ai_multiplayer_german_axis_chav (1.0 0.5 0.0) (-16 -16 0) (16 16 92)
*/
So this "bot" will be regarded as an American, even though it's tik. is named
"multiplayer_german_chav"?
I learned to just paste something like this:
YA, ya ,ya "paste"= "script kiddie" but, I have to reverse engineer and disassemble your tech. to be able to learn for myself without anyone sitting here to guide me.
, to the end of a normal "player" tik. , then I add "multiplayer" to the tik.'s name. Then I add the new tik. to your Models/Human folder in the BotsPAK to have a new custom skinned bot for my game.$include models/human/multiplayer_generic_human.tik
$include models/human/animation/dialogue/generic_dialogue_german.tik
/*QUAKED ai_multiplayer_german_axis_chav (1.0 0.5 0.0) (-16 -16 0) (16 16 92)
*/
YA, ya ,ya "paste"= "script kiddie" but, I have to reverse engineer and disassemble your tech. to be able to learn for myself without anyone sitting here to guide me.

