move garage code to module
This commit is contained in:
parent
a6a7f00c52
commit
039452310d
@ -53,6 +53,18 @@ new
|
|||||||
;
|
;
|
||||||
|
|
||||||
/* ** Hooks ** */
|
/* ** Hooks ** */
|
||||||
|
hook OnScriptInit( )
|
||||||
|
{
|
||||||
|
// format garage interior list
|
||||||
|
for( new i = 0; i < sizeof( g_garageInteriorData ); i++ ) {
|
||||||
|
format( szg_garageInteriors, sizeof( szg_garageInteriors ), "%s"COL_GREY"%d Vehicle Slots"COL_WHITE"\t%s\n", szg_garageInteriors, g_garageInteriorData[ i ] [ E_VEHICLE_CAPACITY ], g_garageInteriorData[ i ] [ E_NAME ] );
|
||||||
|
}
|
||||||
|
|
||||||
|
// load all garages
|
||||||
|
mysql_function_query( dbHandle, "SELECT * FROM `GARAGES`", true, "OnGaragesLoad", "" );
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
hook OnDialogResponse( playerid, dialogid, response, listitem, inputtext[ ] )
|
hook OnDialogResponse( playerid, dialogid, response, listitem, inputtext[ ] )
|
||||||
{
|
{
|
||||||
if ( dialogid == DIALOG_GARAGE_INTERIORS )
|
if ( dialogid == DIALOG_GARAGE_INTERIORS )
|
||||||
|
@ -1270,9 +1270,6 @@ public OnGameModeInit()
|
|||||||
initializeActors( );
|
initializeActors( );
|
||||||
|
|
||||||
/* ** Loading default string values - Makes it efficient. ** */
|
/* ** Loading default string values - Makes it efficient. ** */
|
||||||
for( new i = 0; i < sizeof( g_garageInteriorData ); i++ )
|
|
||||||
format( szg_garageInteriors, sizeof( szg_garageInteriors ), "%s"COL_GREY"%d Vehicle Slots"COL_WHITE"\t%s\n", szg_garageInteriors, g_garageInteriorData[ i ] [ E_VEHICLE_CAPACITY ], g_garageInteriorData[ i ] [ E_NAME ] );
|
|
||||||
|
|
||||||
for( new i = 0; i < sizeof( g_informationPickupsData ); i++ )
|
for( new i = 0; i < sizeof( g_informationPickupsData ); i++ )
|
||||||
{
|
{
|
||||||
g_informationPickupsData[ i ] [ E_PICKUP_ID ] = CreateDynamicPickup( 1239, 2, g_informationPickupsData[ i ] [ E_X ], g_informationPickupsData[ i ] [ E_Y ], g_informationPickupsData[ i ] [ E_Z ] );
|
g_informationPickupsData[ i ] [ E_PICKUP_ID ] = CreateDynamicPickup( 1239, 2, g_informationPickupsData[ i ] [ E_X ], g_informationPickupsData[ i ] [ E_Y ], g_informationPickupsData[ i ] [ E_Z ] );
|
||||||
|
Loading…
Reference in New Issue
Block a user