new AHouseInteriors[][THouseInterior] ={{\"Dummy\", 0, 0.0, 0.0, 0.0}, // Dummy interior (Level 0), as the house-level starts at 1{\"Small motel room\", 10, 2262.83, -1137.71, 1050.63}, // Level 1{\"Small house\", 2, 2467.36, -1698.38, 1013.51}, // Level 2{\"Small house 2\", 1, 223.00, 1289.26, 1082.20}, // Level 3{\"Medium house\", 10, 2260.76, -1210.45, 1049.02}, // Level 4{\"Medium house 2\", 8, 2365.42, -1131.85, 1050.88}, // Level 5{\"Duplex house\", 12, 2324.33, -1144.79, 1050.71}, // Level 6{\"Big house\", 15, 295.14, 1474.47, 1080.52}, // Level 7{\"Big duplex house\", 3, 235.50, 1189.17, 1080.34}, // Level 8{\"Huge house\", 7, 225.63, 1022.48, 1084.07}, // Level 9{\"Mansion\", 5, 1299.14, -794.77, 1084.00} // Level 10};
House_UpdateEntrance(HouseID){ new Msg[128], Float:x, Float:y, Float:z;x = AHouseData[HouseID][HouseX];y = AHouseData[HouseID][HouseY];z = AHouseData[HouseID][HouseZ]; if (IsValidDynamicPickup(AHouseData[HouseID][PickupID]))DestroyDynamicPickup(AHouseData[HouseID][PickupID]);if (IsValidDynamicMapIcon(AHouseData[HouseID][MapIconID]))DestroyDynamicMapIcon(AHouseData[HouseID][MapIconID]);if (IsValidDynamic3DTextLabel(AHouseData[HouseID][DoorText]))DestroyDynamic3DTextLabel(AHouseData[HouseID][DoorText]);if (AHouseData[HouseID][Owned] == true){ AHouseData[HouseID][PickupID] = CreateDynamicPickup(1272, 1, x, y, z, 0);if (AHouseData[HouseID][staticHouse] == true) format(Msg, 128, \"{00DDFF}%s háza.\\n{33ff33}ID: %i\",AHouseData[HouseID][Owner], HouseID);else format(Msg, 128, \"{00DDFF}%s háza.\\n{33ff33}ID: %i\", AHouseData[HouseID][Owner], HouseID);AHouseData[HouseID][DoorText] = CreateDynamic3DTextLabel(Msg, 0x008080FF, x, y, z + 0.5, 20.0);if (ShowBoughtHouses == true) AHouseData[HouseID][MapIconID] = CreateDynamicMapIcon(x, y, z, 32, 0, 0, 0, -1, 150.0);}else{ AHouseData[HouseID][PickupID] = CreateDynamicPickup(1273, 1, x, y, z, 0);if (AHouseData[HouseID][staticHouse] == true) format(Msg, 128, \"{00DDFF}Ez a ház eladó!\\n{f5ae16}Vételár: %i{33AA33}$\\n{33ff33}ID: %i\\n{33FF33}Interior: {33CCFF}%s\", AHouseData[HouseID][HousePrice], HouseID,ide mit?);else format(Msg, 128, \"{00DDFF}Ez a ház eladó!\\n{f5ae16}Vételár: %i{33AA33}$\\n{33ff33}ID: %i\\n{33FF33}Interior: {33CCFF}%s\", AHouseData[HouseID][HousePrice], HouseID,ide mit?);AHouseData[HouseID][DoorText] = CreateDynamic3DTextLabel(Msg, 0x008080FF, x, y, z + 0.7, 20.0);AHouseData[HouseID][MapIconID] = CreateDynamicMapIcon(x, y, z, 31, 0, 0, 0, -1, 150.0);}}És oda \"lekérdezés\" hellyére nem tudom mit kell oda irni, hogy lekérdezzük vele a ház interiorját.Ámbár megtaláltam a scriptben egy helyen de az 1 for ciklussal van megcsinálva és nem értem mit akar és, hogy kellene átalakítanomEzt is bemásolomcase 1: // Upgrade the house { // Only the house-owner can use this option if (House_PlayerIsOwner(playerid, HouseID) == 1) { // Check if it\'s possible to upgrade further if (AHouseData[HouseID][HouseLevel] < AHouseData[HouseID][HouseMaxLevel]) { // Add only the upgrades above the current house-level to the upgradelist for (new i = AHouseData[HouseID][HouseLevel] + 1; i <= AHouseData[HouseID][HouseMaxLevel]; i++) { Counter++; // Add 1 to the counter each time an upgrade is added to the upgradelist UpgradePrice = ((AHouseData[HouseID][HousePrice] * Counter) / 100) * HouseUpgradePercent; // Add the upgrade-info in green if the player can afford it, and in red if he cannot afford it if (INT_GetPlayerMoney(playerid) >= UpgradePrice) format(UpgradeList, 2000, \"%s{00FF00}%s (level %i)\\t\\t$%i\\n\", UpgradeList, AHouseInteriors[interiorName], i, UpgradePrice); ami pirossal van itt ugy kérdi le de igy nem jó nekem else format(UpgradeList, 2000, \"%s{FF0000}%s (level %i)\\t\\t$%i\\n\", UpgradeList, AHouseInteriors[interiorName], i, UpgradePrice); } // Show another dialog to let the player select which upgrade he wants for his house ShowPlayerDialog(playerid, DialogUpgradeHouse, DIALOG_STYLE_LIST, \"Select upgrade:\", UpgradeList, \"Select\", \"Cancel\"); } else SendClientMessage(playerid, 0xFFFFFFFF, \"{FF0000}Your house has reached the maximum level, you cannot upgrade it further\"); } else SendClientMessage(playerid, 0xFFFFFFFF, \"{FF0000}Only the house-owner can use this option\"); }
House_UpdateEntrance(HouseID){ new Msg[128], Float:x, Float:y, Float:z, HouseType; x = AHouseData[HouseID][HouseX]; y = AHouseData[HouseID][HouseY]; z = AHouseData[HouseID][HouseZ]; if (IsValidDynamicPickup(AHouseData[HouseID][PickupID])) DestroyDynamicPickup(AHouseData[HouseID][PickupID]); if (IsValidDynamicMapIcon(AHouseData[HouseID][MapIconID])) DestroyDynamicMapIcon(AHouseData[HouseID][MapIconID]); if (IsValidDynamic3DTextLabel(AHouseData[HouseID][DoorText])) DestroyDynamic3DTextLabel(AHouseData[HouseID][DoorText]); if (AHouseData[HouseID][Owned] == true) { AHouseData[HouseID][PickupID] = CreateDynamicPickup(1272, 1, x, y, z, 0); if (AHouseData[HouseID][staticHouse] == true) format(Msg, 128, \"{00DDFF}%s háza.\\n{33ff33}ID: %i\",AHouseData[HouseID][Owner], HouseID); else format(Msg, 128, \"{00DDFF}%s háza.\\n{33ff33}ID: %i\", AHouseData[HouseID][Owner], HouseID); AHouseData[HouseID][DoorText] = CreateDynamic3DTextLabel(Msg, 0x008080FF, x, y, z + 0.5, 20.0); if (ShowBoughtHouses == true) AHouseData[HouseID][MapIconID] = CreateDynamicMapIcon(x, y, z, 32, 0, 0, 0, -1, 150.0); } else { AHouseData[HouseID][PickupID] = CreateDynamicPickup(1273, 1, x, y, z, 0); if (AHouseData[HouseID][staticHouse] == true) format(Msg, 128, \"{00DDFF}Ez a ház eladó!\\n{f5ae16}Vételár: %i{33AA33}$\\n{33ff33}ID: %i\\n{33FF33}Interior: {33CCFF}%s\", AHouseData[HouseID][HousePrice], HouseID,AHouseInteriors[HouseType][interiorName]); else format(Msg, 128, \"{00DDFF}Ez a ház eladó!\\n{f5ae16}Vételár: %i{33AA33}$\\n{33ff33}ID: %i\\n{33FF33}Interior: {33CCFF}%s\", AHouseData[HouseID][HousePrice], HouseID,AHouseInteriors[HouseType][interiorName]); AHouseData[HouseID][DoorText] = CreateDynamic3DTextLabel(Msg, 0x008080FF, x, y, z + 0.7, 20.0); AHouseData[HouseID][MapIconID] = CreateDynamicMapIcon(x, y, z, 31, 0, 0, 0, -1, 150.0); }}