Posts
78
Respect
16Add +1
Forum Rank
Rotting Walker
Primary Group
Member
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!
![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
![]() | Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community. |



..../// other code ////
disableWeapons(); // hide weapons
freezecontrols_all( true ); // Locking movement for Player
wait 5;
freezecontrols_all( false ); //Movement for Player
enableWeapons(); // show weapons
..../// next other code ////
disableWeapons();
// and
enableWeapons();
but others map is working. Why?


![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
![]() | Has shown excellence and experience in the area of custom scripting in the UGX-Mods community. |
![]() Oil Rig Beta Access |
self disableWeapons();
player disableWeapons();
players = get_players();
for( i=0 ; i<players.size ; i++ )
{
players[i] disableweapons();
}

freezecontrols_all(true );
and
freezecontrols_all( false );
![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
![]() | Has shown excellence and experience in the area of custom scripting in the UGX-Mods community. |
![]() Oil Rig Beta Access |
player freezecontrols( true );
#include maps\NAME_OF_THE_GSC;
main()
{
thread hide();
timelock();
}
////////////////////////////////// start ////////////////////////////
timelock()
{
wait( 9 );
thread show();
}
hide()
{
setdvar( "hud_showStance", "0" );
setdvar( "compass", "0" );
setdvar( "ammoCounterHide", "1" );
setdvar("miniscoreboardhide","1");
players = get_players();
for( i=0 ; i<players.size ; i++ )
{
players[i] freezecontrols_all( true );
players[i] disableweapons();
}
}
show()
{
setdvar( "hud_showStance", "1" );
setdvar( "compass", "1" );
setdvar( "ammoCounterHide", "0" );
setdvar("miniscoreboardhide","0");
players = get_players();
for( i=0 ; i<players.size ; i++ )
{
players[i] freezecontrols_all( false );
players[i] EnableWeapons();
}
}

but now, this code no show any errors )


![]() | Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum. |
![]() | Has shown excellence and experience in the area of custom scripting in the UGX-Mods community. |
![]() Oil Rig Beta Access |
hide()
{
flag_wait( "all_players_connected" );
setdvar( "hud_showStance", "0" );
setdvar( "compass", "0" );
setdvar( "ammoCounterHide", "1" );
setdvar("miniscoreboardhide","1");
players = get_players();
for( i=0 ; i<players.size ; i++ )
{
players[i] freezecontrols_all( true );
players[i] disableweapons();
}
}

main()
{
//// other parts codes /////
// only after maps\_load::main(); //
maps\_load::main();
thread hide_hud();
custom_introscreen();
set_loadout();
}
custom_introscreen()
{
wait( 9 );
thread show_hud();
}
hide_hud()
{
flag_wait( "all_players_connected" );
setdvar( "hud_showStance", "0" );
setdvar( "compass", "0" );
setdvar( "ammoCounterHide", "1" );
setdvar("miniscoreboardhide","1");
players = get_players();
for( i=0 ; i<players.size ; i++ )
{
players[i] freezecontrols_all( true );
players[i] disableweapons();
}
}
show_hud()
{
setdvar( "hud_showStance", "1" );
setdvar( "compass", "1" );
setdvar( "ammoCounterHide", "0" );
setdvar("miniscoreboardhide","0");
players = get_players();
for( i=0 ; i<players.size ; i++ )
{
players[i] freezecontrols_all( false );
players[i] enableWeapons();
}
}
//// other parts codes /////
set_loadout()
{
maps\_loadout::add_weapon( "colt");
maps\_loadout::add_weapon( "thompson" );
maps\_loadout::add_weapon( "m1carbine" );
maps\_loadout::add_weapon( "fraggrenade" );
maps\_loadout::set_secondary_offhand( "smoke" );
maps\_loadout::set_laststand_pistol( "colt" );
game["allies"] = "marines";
game["axis"] = "japanese";
game["attackers"] = "allies";
game["defenders"] = "axis";
game["allies_soldiertype"] = "pacific";
game["axis_soldiertype"] = "pacific";
maps\_loadout::set_player_viewmodel( "viewmodel_usa_marine_arms");
maps\_loadout::set_player_interactive_hands( "viewmodel_usa_marine_player" );
maps\_loadout::set_switch_weapon( "m1garand_bayonet" );
level.campaign = "american";
mptype\player_usa_marine::precache();
players = get_players();
for( i = 0; i < players.size; i++ )
{
player = players[i];
players[i] TakeWeapon( "springfield" );
}
}
//// other parts codes /////