25.01.2010, 02:53
nope dident work and this is the code i forgot to put and also there is 1 more error that i dident put..
C:\Users\lizzy\Desktop\Script PAWNO\Script Pawno v 1.3\gamemodes\c&r.pwn(1069) : error 028: invalid subscript (not an array or too many subscripts): "BizInfo"
C:\Users\lizzy\Desktop\Script PAWNO\Script Pawno v 1.3\gamemodes\c&r.pwn(1069) : error 001: expected token: ";", but found "]"
C:\Users\lizzy\Desktop\Script PAWNO\Script Pawno v 1.3\gamemodes\c&r.pwn(1069) : error 029: invalid expression, assumed zero
C:\Users\lizzy\Desktop\Script PAWNO\Script Pawno v 1.3\gamemodes\c&r.pwn(1069) : fatal error 107: too many error messages on one line
C:\Users\lizzy\Desktop\Script PAWNO\Script Pawno v 1.3\gamemodes\c&r.pwn(1069) : error 028: invalid subscript (not an array or too many subscripts): "BizInfo"
C:\Users\lizzy\Desktop\Script PAWNO\Script Pawno v 1.3\gamemodes\c&r.pwn(1069) : error 001: expected token: ";", but found "]"
C:\Users\lizzy\Desktop\Script PAWNO\Script Pawno v 1.3\gamemodes\c&r.pwn(1069) : error 029: invalid expression, assumed zero
C:\Users\lizzy\Desktop\Script PAWNO\Script Pawno v 1.3\gamemodes\c&r.pwn(1069) : fatal error 107: too many error messages on one line
Код:
stock CreateHouse(Filename[], Cost, Float:Pickupx, Float:Pickupy, Float:Pickupz, Float:Telex, Float:Teley, Float:Telez, interior, sell) { if(!dini_Exists("Owners.ini")) { dini_Create("Owners.ini"); } BizCount ++; new ID = BizCount; //HouseID format(BizInfo[ID][BizNames], 60, "%s", Filename); //Saves the HouseName into a variable BizInfo[ID][BizCost] = Cost; BizInfo[ID][BizIsBought] = 0; BizInfo[ID][PickupX] = Pickupx; BizInfo[ID][Virtual] = 2000000 + ID; BizInfo[ID][PickupY] = Pickupy; BizInfo[ID][PickupZ] = Pickupz; BizInfo[ID][TeleX] = Telex; BizInfo[ID][TeleY] = Teley; BizInfo[ID][TeleZ] = Telez; BizInfo[ID][Interior] = interior; BizInfo[ID][BizSell] = sell; if(strlen(dini_Get("Owners.ini", Filename))) //This is to see if there is any owner. { format(BizInfo[ID][BizOwner], 24, "%s", dini_Get("Owners.ini", Filename)); BizInfo[ID][Owned] = 1; } PickupID[ID] = CreatePickup(1273, 23, Pickupx, Pickupy, Pickupz, -1); //Creates the pickup :). //Create3DTextLabel("House", 0x00A0F6AA, Pickupx, Pickupy, Pickupz + 0.75, 15.0, 0, 1); } public OnPlayerPickUpPickup(playerid, pickupid) //Pickup callback { for(new J; J<MAX_BIZ; J++) //Loops through all houses { if(pickupid == PickupID[J]) //If the pickupid is one of our house ones { new str[75]; if(BizInfo[J][Owned] == 1) { format(str, sizeof(str), "~r~House Info~n~~g~Owner: ~w~%s", BizInfo[J][BizOwner]); } if(BizInfo[J][Owned] == 0) { format(str, sizeof(str), "~r~House Info~n~~g~Owner: ~w~Nobody"); SendClientMessage(playerid, 0x67F6F6AA, "This house is up for sale! Type /buy to buy it"); } new str2[75]; format(str2, sizeof(str2), "~g~Cost price:%d ~w~%d~n~~g~Sell Price:~w~ %d", BizInfo[J][BizCost], BizInfo[J][BizSell]); new str3[150]; format(str3, sizeof(str3), "%s~n~%s", str, str2); GameTextForPlayer(playerid, str3, 3500, 3); } } return 1; }