AI's in maps....

Post your scripting questions / solutions here

Moderator: Moderators

Post Reply
7th Es Cyborg
First Lieutenant
Posts: 189
Joined: Fri Dec 13, 2002 5:00 pm
Location: PA
Contact:

AI's in maps....

Post by 7th Es Cyborg »

is there a way to remove AI's that don't have a target name?

I've already changed the bsp to .map to get the names, and for good measure did a remove on all the generic target names that are listed in the ai.scr but I still have around 15 germans on the converted map that I can't get rid of......
User avatar
Alcoholic
General
Posts: 1470
Joined: Sat May 17, 2003 5:57 am
Location: California
Contact:

Post by Alcoholic »

if they dont have a targetname, you cant really do anything to them.
User avatar
Gold
First Lieutenant
Posts: 176
Joined: Sun Sep 28, 2003 8:10 pm

AI's in maps

Post by Gold »

if theres no way to do it then how did wartech do it????
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Re: AI's in maps

Post by jv_map »

Gold wrote:if theres no way to do it then how did wartech do it????
Did he? :?
Image
7th Es Cyborg
First Lieutenant
Posts: 189
Joined: Fri Dec 13, 2002 5:00 pm
Location: PA
Contact:

Post by 7th Es Cyborg »

this is an old thread, but I did eventualy find out how to do it.

Open the maps BSP in notepad, scroll to where it has the AI spawn information like such:

{
"classname" "ai_german_wehrmact_soldier"
"scale" "1.0"
"model" "human//german_wehrmact_soldier.tik"

you need to edit the model name, like in the example change

"human//german_wehrmact_soldier.tik"

to

"human//german_wehrmact_foldier.tik"

when the map loads it will try to spawn the edited model, which of course does not exist, so it will create a one line error and not spawn it.

Make sure you change just one letter, do not remove or add things to the bsp file or it will not load the map!!!

This also works for removing static models.
User avatar
Gold
First Lieutenant
Posts: 176
Joined: Sun Sep 28, 2003 8:10 pm

Ai

Post by Gold »

"human//german_wehrmact_soldier.tik"
to
"human//german_wehrmact_foldier.tik"

would ya change that throughout the whole bsp ,,and what would ya change this to?? "model" "human//german_winter_type1.tik" or this
"model" "human//german_wehrmact_grenadier.tik"?? and would ya only change tik lines only or also the accompanied lines such as
"classname" "ai_german_wehrmact_grenadier"
I tryed the above method
"human//german_wehrmact_soldier.tik"
to
"human//german_wehrmact_foldier.tik"
in just one line and map would not load:(

what am i doin wrong?? lol
7th Es Cyborg
First Lieutenant
Posts: 189
Joined: Fri Dec 13, 2002 5:00 pm
Location: PA
Contact:

Post by 7th Es Cyborg »

ok this is straight out of one of my map that works:

Code: Select all

{
"enemysharerange" "0"
"hearing" "512"
"classname" "ai_german_afrikacorps_soldier"
"scale" "1.0"
"model" "suman//german_afrika_private.tik"
"testanim" "idle"
"origin" "-5436.00 -5092.00 716.00"
"angle" "270"
"type_idle" "idle"
"type_attack" "cover"
"type_disguise" "salute"
"type_grenade" "grenade"
"sound_awareness" "20"
"noticescale" "70"
"fixedleash" "0"
"waittrigger" "0"
"accuracy" "20"
"ammo_grenade" "0"
"disguise_range" "256"
"disguise_period" "15"
"disguise_level" "1"
"gren_awareness" "10"
"leash" "256"
}
the original tik was:

"model" "human//german_afrika_private.tik"

Changed to:

"model" "suman//german_afrika_private.tik"

you have to make sure you don't add any extra letters or take away any extra letters - the number of letters total in the file must remain the same or it won't work.

bodybagger may be able to add more to this than I did as far as an explanation - he's the one who showed me this trick...
7th Es Cyborg
First Lieutenant
Posts: 189
Joined: Fri Dec 13, 2002 5:00 pm
Location: PA
Contact:

Post by 7th Es Cyborg »

doh - just thought about something, I'm doing my editing in red hat (linux) so windows notepad might be saving it wrong. Try using a hex editor or another text editor with a clean (unaltered) bsp file each time and see what happens - post which works right for you so others working in windows can use that.
nuggets
General
Posts: 1006
Joined: Fri Feb 28, 2003 2:57 am
Location: U-england-K (england in the UK) :P
Contact:

Post by nuggets »

good thinking that man :D

editing the .bsp will work as long as characters are only changed and not added, there is a character count in the .bsp so if this doesn't match, YOUR SCREWED!!! :P
hope this helps, prob not cos it's all foreign 2 me :-/
User avatar
Gold
First Lieutenant
Posts: 176
Joined: Sun Sep 28, 2003 8:10 pm

AI's in maps....

Post by Gold »

Cyborg i checked out what ya were sayin and it was %100 per cent accurate:) Also nuggets the idea is to change one letter in each line so the ai soldiers dont load,,,a friend of mine knew how to hex so i sent him the bsp and told him what to do,,he did so and sent it back,,took him like 4 minutes to change human to suman and theres was over 20 ai soldiers in that paticular map. Then i in turn i just set up the script so the map runs in tdm mode etc,,,flawlessly if i might add.Only took like 2 minutes after he sent me the editor to teach me how to do it lol
nuggets
General
Posts: 1006
Joined: Fri Feb 28, 2003 2:57 am
Location: U-england-K (england in the UK) :P
Contact:

Post by nuggets »

i know...

i was making sure that was all people were doing...
hope this helps, prob not cos it's all foreign 2 me :-/
User avatar
Gold
First Lieutenant
Posts: 176
Joined: Sun Sep 28, 2003 8:10 pm

AI's in maps....

Post by Gold »

ok another question,,i removed some static barbwire using the above decribed method. Now the problem is i still cant walk thru were the barbwire was. Is there any solution to this ? Any info would be appreciated:)
7th Es Cyborg
First Lieutenant
Posts: 189
Joined: Fri Dec 13, 2002 5:00 pm
Location: PA
Contact:

Post by 7th Es Cyborg »

there is probably a clip brush there
Post Reply