Posts
12
Respect
Forum Rank
Legless Crawler
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!#include maps\_music;
#include common_scripts\utility;
#include maps\_zombiemode_utility;
#include maps\_utility;
main()
{
thread auto_door();
}
auto_door()
{
auto = GetEnt( "auto_door", "targetname" );
auto1 = GetEnt( "auto_door1", "targetname" );
auto_trigger = GetEnt( "auto_trig", "targetname");
auto_trigger waittill ("trigger", user);
auto movex(-50, 6);
auto1 movex(50, 6);
wait 3;
auto movex(25, 6);
auto1 movex(-25, 6);
wait 3;
thread auto_door();
}
waittill ("trigger", user);
![]() | |
![]() | 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. |
![]() BO3 Modtools Alpha | This user has access to the Black Ops 3 Modtools Alpha |
Make it a while or a for loop (while( true ) preferably) and check if the door is moving if it is pull it back again so player doesn't have to wait (unless you want to). Currently you're only making it only run once.
i wanted to have the doors open without having to use F key to open it maybe use a trigger_radius would that do that?
#include maps\_music;
#include common_scripts\utility;
#include maps\_zombiemode_utility;
#include maps\_utility;
main()
{
Auto = GetEntArray( "auto_door", "targetname" );
Auto1 = GetEntArray( "auto_door1", "targetname" );// Also wanna know what this is for it would let me know if this is needed or not. Put it here since you had but might not be needed.
for( i = 0; i < Auto.size; i++ )
Auto[i] thread auto_door( -50, 25 );
for( i = 0; i < Auto1.size; i++ )
Auto1[i] thread auto_door( 50, -25 );
}
auto_door( Num, Num2 )
{
NotAlreadyIn = undefined;
Play = GetPlayers();
for( i = 0; i < Play.size; i++ )
{
if( distance( Play[i].origin, self.origin ) < 300 && !IsDefined( NotAlreadyIn ) ) // Maybe bigger/smaller depending on distance you want
{
NotAlreadyIn = true;
self MoveX( Num, 6 );
wait 3;
self MoveX( Num2, 6 );
wait 3;
}
}
self thread auto_door();
}
i was thinking about a way to do that but i guess i might have to just give them a path around the doors through barriers or something but quick question how would i make the doors open faster then the slow opening of the doors?
The second argument defines the speed. See Zeroys script reference for function arguments http://www.zeroy.com/script/motion/movex.htm
why not tell him how to use "moveto" that way he han move the doors to structs and made prefabs instead of having to make 1 script for every door lol