03.08.2011, 23:44
When i attach some 0.3c object, after 1 sec it's disappear. I attached helmet and bag, and its disappear. I think its something in GM, but idk what
public OnGameModeInit() { // ConnectNPC("Bus_Driver0","busnpc0"); // ConnectNPC("Bus_Driver1","busnpc1"); new string[MAX_PLAYER_NAME]; new string1[MAX_PLAYER_NAME]; for (new x = 1; x < MAX_VEHICLES; x++) { VehicleLightsOn[x] = false; } for(new c=0;c<CAR_AMOUNT;c++) { Gas[c] = GasMax; } LoadCar(); CreateFoodMenus(); CreateGuideMenus(); CreateLicensesMenuMenus(); LoadProperty(); LoadBizz(); LoadSBizz(); LoadBoxer(); LoadStuff(); LoadIRC(); LoadFamilies(); LoadCK(); LoadTurfs(); LoadPapers(); LoadDrugSystem(); LoadMatsSystem(); LoadHQLocks(); LoadTrunk(); UcitajMaterijale();//TEST MATERIJALI UcitajDrogu(); UcitajZone(); ChangeWeather(); IRCInfo[0][iPlayers] = 0; IRCInfo[1][iPlayers] = 0; IRCInfo[2][iPlayers] = 0; IRCInfo[3][iPlayers] = 0; IRCInfo[4][iPlayers] = 0; IRCInfo[5][iPlayers] = 0; IRCInfo[6][iPlayers] = 0; IRCInfo[7][iPlayers] = 0; IRCInfo[8][iPlayers] = 0; IRCInfo[9][iPlayers] = 0; News[hTaken1] = 0; News[hTaken2] = 0; News[hTaken3] = 0; News[hTaken4] = 0; News[hTaken5] = 0; format(string, sizeof(string), "Nothing"); strmid(News[hAdd1], string, 0, strlen(string), 255); strmid(News[hAdd2], string, 0, strlen(string), 255); strmid(News[hAdd3], string, 0, strlen(string), 255); strmid(News[hAdd4], string, 0, strlen(string), 255); strmid(News[hAdd5], string, 0, strlen(string), 255); format(string1, sizeof(string1), "Niko"); strmid(News[hContact1], string1, 0, strlen(string1), 255); strmid(News[hContact2], string1, 0, strlen(string1), 255); strmid(News[hContact3], string1, 0, strlen(string1), 255); strmid(News[hContact4], string1, 0, strlen(string1), 255); strmid(News[hContact5], string1, 0, strlen(string1), 255); PlayerHaul[190][pCapasity] = 100; PlayerHaul[191][pCapasity] = 100; PlayerHaul[192][pCapasity] = 50; PlayerHaul[193][pCapasity] = 50; SetGameModeText("OG:RP"); SendRconCommand("mapname • Old-Generation •"); SendRconCommand("weburl www.og-samp.org"); format(objstore, sizeof(objstore), "MOLE: Trenutno nemam nista, javi se kasnije."); format(cbjstore, sizeof(cbjstore), "BAZA: Nema nista u vasoj blizini, out."); format(motd, sizeof(motd), "Dobrodosli na Old-Generation RP/DM Server."); gettime(ghour, gminute, gsecond); FixHour(ghour); ghour = shifthour; if(!realtime) { SetWorldTime(wtime); } SetPDistance(10); AllowInteriorWeapons(1); AllowAdminTeleport(0); UsePlayerPedAnims(); //unique walking //ShowPlayerMarkers(false); DisableInteriorEnterExits(); EnableStuntBonusForAll(0);
/* Credits: aleluja , Aleksandar. */ #include <a_samp> #include <zcmd> //============================================================================== new kaciga[MAX_PLAYERS]; //============================================================================== #define bijela 0xFFFFFFFF #define SCM SendClientMessage //============================================================================== CMD:stavikacigu(playerid, params[]) { new vehicleid = GetPlayerVehicleID(playerid); if(IsMotoBike(vehicleid)) { kaciga[playerid] = SetPlayerAttachedObject(playerid, 1, 18645, 2, 0.07, 0.04, 0, 88, 75); SCM(playerid, bijela,"Stavio si kacigu"); } else { SCM(playerid, bijela, "({F81414}Greska!{C3C3C3}) Moras biti na motoru!"); } return true; } CMD:skinikacigu(playerid, params[]) { RemovePlayerAttachedObject(playerid,kaciga[playerid]); SCM(playerid, bijela,"Skinio si kacigu"); return true; } //============================================================================== //STOCKS stock IsMotoBike(vehicleid) { new result; new model = GetVehicleModel(vehicleid); switch(model) { case 509, 481, 510, 462, 448, 581, 522, 461, 521, 523, 463, 586, 468, 471: result = model; default: result = 0; } return result; }
Helmet(kaciga on Serbian(my lang)), its worked on last mode, but on this, nope
Код:
/* Credits: aleluja , Aleksandar. */ #include <a_samp> #include <zcmd> //============================================================================== new kaciga[MAX_PLAYERS]; //============================================================================== #define bijela 0xFFFFFFFF #define SCM SendClientMessage //============================================================================== CMD:stavikacigu(playerid, params[]) { new vehicleid = GetPlayerVehicleID(playerid); if(IsMotoBike(vehicleid)) { kaciga[playerid] = SetPlayerAttachedObject(playerid, 1, 18645, 2, 0.07, 0.04, 0, 88, 75); SCM(playerid, bijela,"Stavio si kacigu"); } else { SCM(playerid, bijela, "({F81414}Greska!{C3C3C3}) Moras biti na motoru!"); } return true; } CMD:skinikacigu(playerid, params[]) { RemovePlayerAttachedObject(playerid,kaciga[playerid]); SCM(playerid, bijela,"Skinio si kacigu"); return true; } //============================================================================== //STOCKS stock IsMotoBike(vehicleid) { new result; new model = GetVehicleModel(vehicleid); switch(model) { case 509, 481, 510, 462, 448, 581, 522, 461, 521, 523, 463, 586, 468, 471: result = model; default: result = 0; } return result; } |