OK, ive read every tutorial and every thread involving MG42's, but I cannot get them to work. The nazis walk up and man them, but dont turn or fire them. There are two gunner/mg sets, names MG42_gunner/MG42 and MG42Gunner_2/MG42_2. There are lines between the gunners and MGs, and I have the AI settings correct. Here is the .scr file:
exec global/loadout.scr maps/test.scr
exec global/ai.scr
main:
level waittill spawn
$mg42 thread global/mg42_active.scr::mg42
$mg42_2 thread global/mg42_active.scr::mg42_2
end
What am I doing wrong?
MG42s... Yes, I already read all the other threads
Moderator: Moderators
-
Personator
- Private
- Posts: 5
- Joined: Fri Mar 21, 2003 11:42 pm
I have the same problem with the gunners not shooting. One thing that might be wrong with your script, though is this line:
$mg42_2 thread global/mg42_active.scr::mg42_2
The last part, after global/mg42_active.scr:: is a thread in the script mg42_active.scr. This shouldn't be changed to the name of your gun. It needs to stay mg42 because that's the name of thread in the script.
I hope this helps a little and I hope someone can tell us why our gunners aren't shooting.
$mg42_2 thread global/mg42_active.scr::mg42_2
The last part, after global/mg42_active.scr:: is a thread in the script mg42_active.scr. This shouldn't be changed to the name of your gun. It needs to stay mg42 because that's the name of thread in the script.
I hope this helps a little and I hope someone can tell us why our gunners aren't shooting.
-
MC Disgruntled Goat
- Lance Corporal
- Posts: 22
- Joined: Mon Sep 02, 2002 9:58 pm
-
Personator
- Private
- Posts: 5
- Joined: Fri Mar 21, 2003 11:42 pm
well I think that I got my mg42 to work for spearhead by useing the global/turret.scr in that script all mg42's have the same targetname $mg42
if ($mg42)
for (local.i=1;local.i<$mg42.size+1;local.i++)
$mg42[local.i] thread mg42_start
mg42_start local.type:
level waittill spawn
if !(self.set)
self.set = -1
if (self.target)
{
local.man = $(self.target)
local.man.mg = self
.local.man thread gunner_think
}
the gunner is the $mg42's target . Also I think you can do it without any script you just have to make sure you press I to bring up ai's property box and set the "turret" to the targetname of your gun but don't ! set the ai's target to be the gun . the gun's target can be the man not vise versa .I had a friend that deleted the target for the ai and got his gun to work .gunner_think:
self.mg targettype "auto"
self type_idle "machinegunner"
self type_attack "machinegunner"
self type_disguise "machinegunner"
self type_grenade "machinegunner"
self gun "MG42"
self turret self.mg
-
Personator
- Private
- Posts: 5
- Joined: Fri Mar 21, 2003 11:42 pm
