Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help 2 function Run
#1
Hi

Is possible i need some help a bout this code :

I have 2 function
Code:
Function1()
        {
               }

Function2()
         {
                 }
so
Code:
if(Function1 is run)
  {
    Don not do Function2;
       }
    else
  {
        Do function1;
          }
is not understandable so i can give completed cod.

thanks
Reply

#2
I didnt understand:

Code:
function1()
{
    self.isrunningthefunction1 = true;
}

function2()
{

}


if( self.isrunningthefunction1 )
    whatever

Undecided
Reply

#3
Thanks man Wink
sorry i explain bad

so
I have this:

Code:
doPickLocation()
{
        self endon ( "disconnect" );
        self endon ( "death" );
        self notifyOnPlayerCommand( "town", "centerview" );

        for(;;)
        {
        self waittill("town");      
        self beginLocationselection( "map_artillery_selector", true, ( level.mapSize / 15 ) );
             self.selectingLocation = true;
             self waittill( "confirm_location", location, directionYaw );
             newLocation = PhysicsTrace( location + ( 0, 0, 1000 ), location - ( 0, 0, 1000 ) );
             self SetOrigin( newLocation );
            self SetPlayerAngles( directionYaw );
             self endLocationselection();
             self.selectingLocation = undefined;
    }
}

doGhost()
{
self endon ( "disconnect" );
self endon ( "death" );
self notifyOnPlayerCommand( "ghost", "+actionslot 1" );
        maps\mp\gametypes\_spectating::setSpectatePermissions();
        for(;;)
        {
            self waittill("ghost");      
            self allowSpectateTeam( "freelook", true );
            self.sessionstate = "spectator";
            self setContents( 0 );
            self waittill("ghost");
            self.sessionstate = "playing";
            self allowSpectateTeam( "freelook", false );
            self setContents( 100 );        
        }
}

so when doGhost() is running, with out closing doGhost() i run doPickLocation() and the game screen locked so i cant do any thing

so I want when the doGhost() is active the doPickLocation() not allowed to run ! :|
Reply

#4
@Yamato
if you have free time plz see my problem. thank you
Reply

#5
(02-23-2012, 09:37)raminr63 Wrote: @Yamato
if you have free time plz see my problem. thank you

I dont understand this part of what you said, Confused :

Code:
so when doGhost() is running, with out closing doGhost() i run doPickLocation() and the game screen locked so i cant do any thing

so I want when the doGhost() is active the doPickLocation() not allowed to run ! :|
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Help Help Function Fire dargula 1 2,160 10-31-2013, 23:03
Last Post: Nekochan
  Black Ops II IWI block decompression/decryption function kokole 7 5,457 12-07-2012, 22:53
Last Post: master131
  Help [C#] Function pointer? Pozzuh 3 3,864 03-31-2012, 22:26
Last Post: crAyon
  [Tutorial] Custom Kill/Point Streak Function Tomsen1410 9 5,863 12-01-2011, 00:15
Last Post: JariZ
  Help Random Function isn't working. - SOLVED gumpo03 1 1,885 11-09-2011, 21:46
Last Post: Phl3x_
  random function ?!? - SOLVED gumpo03 8 4,128 11-04-2011, 14:45
Last Post: Yamato
  [Release] Spawn fort function tonymamoni1 13 7,956 10-08-2011, 18:04
Last Post: tonymamoni1
  Help Server compile error unknown function megaovi 10 6,824 09-09-2011, 06:08
Last Post: megaovi
  [Release] Function List & Description site Hixos 7 4,535 08-15-2011, 11:28
Last Post: AZUMIKKEL
  [Release] Gate building function in Radiation (Confirmed) alistair3149 20 10,060 03-02-2011, 20:59
Last Post: Nekochan

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.