hello folks!
i want to remove everything a player could pick up, like health, ammo and weapons etc.
i basically took this code from the instagib mutator, and it effectively removes all this stuff. however, when i join a dedicated server, the weapon and health spawns are still here (but no weapons or health).
when i try it locally, the level is cleaned just fine, so i assume it's some kind of replication problem....
it's purely cosmetic, but i'd appreciate it if anyone can shed some light on this!
(this is called in my GameInfo's PostbeginPlay, ut2004 tc-mod)
i want to remove everything a player could pick up, like health, ammo and weapons etc.
i basically took this code from the instagib mutator, and it effectively removes all this stuff. however, when i join a dedicated server, the weapon and health spawns are still here (but no weapons or health).
when i try it locally, the level is cleaned just fine, so i assume it's some kind of replication problem....
it's purely cosmetic, but i'd appreciate it if anyone can shed some light on this!
(this is called in my GameInfo's PostbeginPlay, ut2004 tc-mod)
Code:
function CleanupLevel() { local xPickupBase P; local Pickup L; foreach AllActors(class'xPickupBase', P) { P.bHidden = true; if (P.myEmitter != None) P.myEmitter.Destroy(); P.Destroy(); } foreach AllActors(class'Pickup', L) { if ( L.IsA('WeaponLocker') ) L.GotoState('Disabled'); L.Destroy(); } log("level cleaned"); }
Comment