

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!
switch( self.entity_num)
{
case 0:
character\char_zomb_player_0::main();
break;
case 1:
character\char_zomb_player_1::main();
break;
case 2:
character\char_zomb_player_2::main();
break;
case 3:
character\char_zomb_player_3::main();
break;
}players = get_players();
if(players.size > 1)
{
switch( self.entity_num)
{
case 0:
character\char_zomb_player_0::main();
break;
case 1:
character\char_zomb_player_1::main();
break;
case 2:
character\char_zomb_player_2::main();
break;
case 3:
character\char_zomb_player_3::main();
break;
}
}
else
{
self.body_select = randomint(4);
if(self.body_select == 0)
{
character\char_zomb_player_0::main();
self.entity_num_randomized = 0;
}
if(self.body_select == 1)
{
character\char_zomb_player_1::main();
self.entity_num_randomized = 1;
}
if(self.body_select == 2)
{
character\char_zomb_player_2::main();
self.entity_num_randomized = 2;
}
if(self.body_select == 3)
{
character\char_zomb_player_3::main();
self.entity_num_randomized = 3;
}
}get_player_index(player)
{
assert( IsPlayer( player ) );
assert( IsDefined( player.entity_num ) );
return player.entity_num;
}get_player_index(player)
{
assert( IsPlayer( player ) );
assert( IsDefined( player.entity_num ) );
players = get_players();
if(players.size == 1)
return player.entity_num_randomized;
else
return player.entity_num;
}
spawn_vo()players = getplayers();players = get_players();![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |



[/url]![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
![]() | Has released one or more maps to the UGX-Mods community. |
![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
the getplayers() change at the end of the tutorial is what fixed that for me
wait 0.5;get_player_index(player)
{
assert( IsPlayer( player ) );
assert( IsDefined( player.entity_num ) );
players = get_players();
if(players.size == 1)
return player.entity_num_randomized;
else
return player.entity_num;
}![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
awesome you got it to work.. I get tired of only hearing Dempey's voice, hope people start using this tut
I also put the players = get_players(); back to players = getplayers(); in spawn_vo() and still didnt freeze, so maybe that wasn't the source of the issue? 
![]() | Has released one or more maps to the UGX-Mods community. |

You should seriously talk with @daedra descent He's been trying to get a random weapon spawn and cabinet working for ages and he'd probably appreciate your help.
![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
Exactly, how do you fix the infinite loop? I don't know where to put the: wait: 05
get_player_index(player)wait .05;get_player_index(player)
{
wait .05;
assert( IsPlayer( player ) );
assert( IsDefined( player.entity_num ) );
players = get_players();
if(players.size == 1)
return player.entity_num_randomized;
else
return player.entity_num;
}You probably made a mistake when copying it and deleted a bracket or something.
- Phil.