SetTimerEx problem
#7

Код:
ShowXomnia( playerid ) { 
	
	PlayerInfo[ playerid ][ xTutStep ] = 0;
	UpdatePlayer( playerid );
	
	TextDrawSetString( IntroTxt[ playerid ][ 5 ], TutorialTitles[ PlayerInfo[ playerid ][ xTutStep ] ] );
	TextDrawSetString( IntroTxt[ playerid ][ 6 ], TutorialStrings[ PlayerInfo[ playerid ][ xTutStep ] ] );
	
	for( new i = 0; i < 7; i++ ) {
		
		TextDrawShowForPlayer( playerid, IntroTxt[ playerid ][ i ] );
	}
	
	SetPlayerPos( playerid, ServerInfo[ MainSpawnX ], ServerInfo[ MainSpawnY ], ServerInfo[ MainSpawnZ ] );
	SetPlayerFacingAngle( playerid, ServerInfo[ MainSpawnA ] );
	SetPlayerInterior( playerid, ServerInfo[ MainSpawnInterior ] );
	SetPlayerVirtualWorld( playerid, ServerInfo[ MainSpawnVirtualWorld ] );
	
	SetPlayerCameraPos( playerid, ServerInfo[ MainSpawnX ] - TUTORIAL_CAMERA_OFFSET_X, ServerInfo[ MainSpawnY ] - TUTORIAL_CAMERA_OFFSET_Y, ServerInfo[ MainSpawnZ ] + TUTORIAL_CAMERA_OFFSET_Z );
	SetPlayerCameraLookAt( playerid, ServerInfo[ MainSpawnX ], ServerInfo[ MainSpawnY ], ServerInfo[ MainSpawnZ ] );

	TogglePlayerControllable( playerid, 0 );

	Timer_xMoving[ playerid ] = SetTimerEx( "MovingCamera", MOVING_CAMERA_FPS, true, "i", playerid );
	return true;
}
Код:
function FirstTutorial( playerid ) {

	if( PlayerInfo[ playerid ][ xTutStep ] < 6 ) {
	
		TogglePlayerControllable( playerid, 0 );
		
		PlayerInfo[ playerid ][ xTutStep ]++;
		OnPlayerUpdateEx( playerid );
		
		TextDrawSetString( IntroTxt[ playerid ][ 5 ], TutorialTitles[ PlayerInfo[ playerid ][ xTutStep ] ] );
		TextDrawSetString( IntroTxt[ playerid ][ 6 ], TutorialStrings[ PlayerInfo[ playerid ][ xTutStep ] ] );
		
		return true;

	}
	else {
	
		for( new i = 0; i < 7; i++ ) TextDrawHideForPlayer( playerid, IntroTxt[ playerid ][ i ] );

		PlayerInfo[ playerid ][ xTutStep ] = 255;
		UpdatePlayer( playerid );

		KillTimer( Timer_xMoving[ playerid ] );

		SetSpawnForPlayer( playerid );
		SetCameraBehindPlayer( playerid );
	
	}
	
	return true;

}
Reply


Messages In This Thread
SetTimerEx problem - by FTLOG - 28.12.2011, 17:39
Re: SetTimerEx problem - by coole210 - 28.12.2011, 18:41
Re: SetTimerEx problem - by FTLOG - 28.12.2011, 18:46
Re: SetTimerEx problem - by coole210 - 28.12.2011, 23:10
Re: SetTimerEx problem - by FTLOG - 29.12.2011, 11:42
Re: SetTimerEx problem - by MadeMan - 29.12.2011, 11:45
Re: SetTimerEx problem - by FTLOG - 29.12.2011, 12:39

Forum Jump:


Users browsing this thread: 1 Guest(s)