


Login Issues
Forgot password?Activate Issues
Account activation email not received? Wrong account activation email used?Other Problems?
Contact Support - Help Center Get help on the UGX Discord. Join it now!
![]() | |
![]() | |
![]() | Has the ability to issue warnings to users, edit and remove posts from the forum and to move topics to other boards. Upholds the rules of the forum. Moderates Chat Rooms. |
isTouching() only works with triggers. Haven't read the rest of this but I assume you are using isTouching on something that doesn't support it. Just use distance checks.
Main()
{
Place1 = GetEnt( "place1", "targetname" );
place1 thread function( "m9" );
}
function( Weap )
{
ice_model = GetEnt( "ice_model", "targetname" );
level.KillCount = 0;//Maybe throw in while loop if it keeps running over and over otherwise here will be fine
while( IsDefined( self ) )
{
ice_model hide();
self waittill( "trigger", Player );
CurrWeap = Player GetCurrentWeapon();
if( CurrWeap == Weap )
{
self trigger_off();
Player takeweapon( CurrWeap );
ice_model show();
Zombs = GetAISpeciesArray( "axis", "all" );
for(;;)
{
for( i = 0; i < Zombs.size; i++ )
{
if( Zombs[i] IsTouching( ice_radius ) )
Zombs[i] thread KillWatch();
if( level.KillCount >= 3 )
break;
}
if( level. KillCount >= 3 )
break;
wait .05;
}
self trigger_on();
ice_model SetModel( "zombie_3rd_perk_bottle_doubletap" );
self waittill( "trigger", Player );
Player GiveWeapon( CurrWeap + "_upgraded" );
Player SwitchToWeapon( CurrWeap + "_upgraded" );
ice_model hide();
}
//If you only want to run this once add the if( level.KillCount == 3 ) break;
wait .05;
}
}
KillWatch()
{
self notify( "DontRegister" );
self endon( "DontRegister" );
self waittill( "death" );
level.KillCount += 1;
}