Hallo Community,
Ich habe ein Großes Problem undzwar wenn ich diesen Code einfüge Crasht mein Compiler
Code/s:
Floats:
new Float:RandomItemSpawns[][] =
{
{1057.5122,-3185.7463,3.3078},
{981.4232,-3189.4038,3.3436},
{981.4219,-3200.7007,3.3738},
{986.5856,-3201.0986,3.3078},
{994.0450,-3212.1487,3.3078},
{982.9638,-3211.6038,3.3078},
{992.5591,-3195.8413,3.3078},
{1000.8713,-3165.4905,3.3078},
{1008.9341,-3165.2146,3.3078},
{1010.5052,-3131.7791,3.3078},
{1013.3318,-3107.5586,3.3078},
{1001.3504,-3107.0776,3.3078},
{1007.9680,-3104.2666,3.3078},
{987.8438,-3108.5261,3.3078},
};
new Float:RanGunModel[] ={
1575, 331, 333, 334, 335, 336, 337, 338, 339, 341, 321, 322, 323, 324, 325, 326, 342, 343, 344, -1, -1 , -1 ,
346, 347, 348, 349, 350, 351, 352, 353, 355, 356, 372, 357, 358, 359, 360, 361, 362, 363, 364, 365, 366, 367,
368, 369, 1575
};
new Float:RanGunAmmo[] ={
25,
50,
55,
60,
75,
80,
85,
90,
95,
100,
105,
110,
125
};
Public:
forward SpawnWeapons();
public SpawnWeapons();
{
new Float:X,Float:Y,Float:Z;
new RanAmmo = random(sizeof(RanGunAmmo));
new RanGun = random(sizeof(RanGunModel));
new RanISpawn = random(sizeof(RandomItemSpawns));
DropRanGun(RanGunModel[RanGun][0], RanGunAmmo[RanAmmo][0], RandomItemSpawns[RanISpawn][0], RandomItemSpawns[RanISpawn][1], RandomItemSpawns[RanISpawn][2]-1, 0, 0)
}
Stock DropRanGun:
stock DropRanGun(GunID, GunAmmo, Float:X, Float:Y, Float:Z, world, interior)
{
DropInfo[i][DropGunAmmount][0] = GunID;
DropInfo[i][DropGunAmmount][1] = GunAmmo;
DropInfo[i][DropGunPosX] = X;
DropInfo[i][DropGunPosY] = Y;
DropInfo[i][DropGunPosZ] = Z;
DropInfo[i][DropGunVWorld] = world;
DropInfo[i][DropGunInterior] = interior;
DropObject[i] = CreateDynamicObject(GetGunObjectID(GunID), X, Y, Z-1, 80.0, 0.0, 0.0, world);
return 1;
}
Ich hoffe ihr Könnt mir bei dem Problem helfen denn ich verzweifel dran :O
#edit Ein Paar Sachen Hinzugefügt
Mit Freundlichen Grüßen
- Kevin/iEaZyEr