Код:
//Garbage Job
GarbageBinX[0] = -26.9373;
GarbageBinY[0] = 1165.1471;
GarbageBinZ[0] = 18.9955;
//--
GarbageBinX[1] = -44.2732;
GarbageBinY[1] = 1177.5211;
GarbageBinZ[1] = 19.0542;
//--
GarbageBinX[2] = -88.5424;
GarbageBinY[2] = 1163.4060;
GarbageBinZ[2] = 19.3672;
//--
GarbageBinX[3] = -157.5972;
GarbageBinY[3] = 1234.1190;
GarbageBinZ[3] = 19.3671;
//--
GarbageBinX[4] = 1338.5819;
GarbageBinY[4] = 1166.2308;
GarbageBinZ[4] = 10.4453;
//--
GarbageBinX[5] = 1301.3914;
GarbageBinY[5] = 1102.4868;
GarbageBinZ[5] = 10.4453;
//--
GarbageBinX[6] = 1341.1475;
GarbageBinY[6] = 1066.2333;
GarbageBinZ[6] = 10.4452;
They are all tag mismatches? Can you not set an array to a variable or am I doing it wrong?
pawn Код:
/* I'm assuming you use incognito's streamer */
#define MAX_GARBAGE_BINS 30
#define GARBAGE_MDL_ID 3035
enum EGarbageBinInfo {
EGBModelID,
Float:GarbageBinX,
Float:GarbageBinY,
Float:GarbageBinZ,
Float:GarbageBinRotX,
Float:GarbageBinRotY,
Float:GarbageBinRotZ,
EGBObjID,
};
new GarbageBins[MAX_GARBAGE_BINS][EGarbageBinInfo] = {
//MDL, X, Y, Z, RX, RY, RZ
//Add as many as you want
{GARBAGE_MDL_ID, 2069.4067, -1767.8309, 13.5622, 0.0, 0.0, 90.0},
{GARBAGE_MDL_ID, 2069.4067, -1767.8309, 13.5622, 0.0, 0.0, 90.0}
};
OnGameModeInit() {
for(new i=0; i<sizeof(GarbageBins); i++) {
GarbageBins[i][EGBObjID] = CreateDynamicObject(GarbageBins[i][EGBModelID],GarbageBins[i][GarbageBinX],GarbageBins[i][GarbageBinY],GarbageBins[i][GarbageBinZ]-0.30, GarbageBins[i][GarbageBinRotX], GarbageBins[i][GarbageBinRotY], GarbageBins[i][GarbageBinRotZ]);
}
return 1;
}
OnGameModeExit() {
for(new i=0; i<sizeof(GarbageBins); i++) {
DestroyDynamicObject(GarbageBins[i][EGBObjID]);
}
return 1;
}