24.03.2011, 13:17
(
Последний раз редактировалось woaha; 14.04.2011 в 18:19.
)
I have little problem with this!
If i call this function from ongamemodeinit, i am getting only CJ skin available on spawn. Why?
No errors/warnings on compile.
If i call this function from ongamemodeinit, i am getting only CJ skin available on spawn. Why?
pawn Код:
#define MAX_FIXADS 150
#define FIXCNTERKYLTTIFILE "ads/korjaamols/kyltit.ini" // ff
enum FixADInfo
{
dblank,
Float:adX,
Float:adY,
Float:adZ,
adloop,
Text3D:adloope
};
new kyltticoords[MAX_FIXADS][FixADInfo];
stock LoadFixCenterAds()
{
new SplitDiv[3][MAX_FIXADS];
new filestring[256];
new File: file = fopen(FIXCNTERKYLTTIFILE, io_read);
if (file)
{
for(new fixadid = 0; fixadid < MAX_FIXADS; fixadid++)
{
fread(file, filestring);
split(filestring, SplitDiv, ',');
kyltticoords[fixadid][adX] = floatstr(SplitDiv[0]);
kyltticoords[fixadid][adY] = floatstr(SplitDiv[1]);
kyltticoords[fixadid][adZ] = floatstr(SplitDiv[2]);
kyltticoords[fixadid][adloop] = CreateDynamic3DTextLabel(fixcentername[fixcenteradtext], ADS_COLOR, kyltticoords[fixadid][adX], kyltticoords[fixadid][adY], kyltticoords[fixadid][adZ], DRAW_DISRANCE_3DTEXT, INVALID_PLAYER_ID, INVALID_VEHICLE_ID, TEST_LOS, -1, -1, -1, 100.0);
kyltticoords[fixadid][adloope] = CreateDynamicPickup(cSetting[fixadid], PICKUP_TYPE_NONE, kyltticoords[fixadid][adX], kyltticoords[fixadid][adY], kyltticoords[fixadid][adZ]);
}
}
fclose(file);
}