27.05.2016, 00:52
Hello, im trying to make a few systems MySQL currently i'm using R6 and the following code aren't in the R6 MySQL but I have no idea to fix this.
How can I let this fix without using
Those functions are in MySQL R33 but Im using R6 and want to stay at this plugin.
Please do not send me to any wiki page, I have been trying to fix this for about 4 or 5 hours...
Код:
forward OnLoadDynamicMapIcon(index); public OnLoadDynamicMapIcon(index) { new string[256]; new rows, fields; cache_get_data(rows, fields, MainPipeline); for(new field;field<fields;field++) { cache_get_row(index, field, string, MainPipeline); switch(field) { case 0: DMPInfo[index][dmpSQLId] = strval(string); case 1: DMPInfo[index][dmpMarkerType] = strval(string); case 2: DMPInfo[index][dmpColor] = strval(string); case 3: DMPInfo[index][dmpVW] = strval(string); case 4: DMPInfo[index][dmpInt] = strval(string); case 5: DMPInfo[index][dmpPosX] = floatstr(string); case 6: DMPInfo[index][dmpPosY] = floatstr(string); case 7: DMPInfo[index][dmpPosZ] = floatstr(string); } } if(DMPInfo[index][dmpMarkerType] != 0) DMPInfo[index][dmpMapIconID] = CreateDynamicMapIcon(DMPInfo[index][dmpPosX], DMPInfo[index][dmpPosY], DMPInfo[index][dmpPosZ], DMPInfo[index][dmpMarkerType], DMPInfo[index][dmpColor], DMPInfo[index][dmpVW], DMPInfo[index][dmpInt], -1, 500.0); return 1; } stock LoadDynamicMapIcons() { printf("[LoadDynamicMapIcons] Loading data from database..."); mysql_query(MainPipeline, "SELECT * FROM `dmapicons`", true, "OnLoadDynamicMapIcons", ""); } forward OnLoadDynamicMapIcons(); public OnLoadDynamicMapIcons() { new string[256], iIndex = 0; new rows, fields; cache_get_data(rows, fields, MainPipeline); while(iIndex<rows) { for(new field;field<fields;field++) { cache_get_row(iIndex, field, string, MainPipeline); switch(field) { case 0: DMPInfo[iIndex][dmpSQLId] = strval(string); case 1: DMPInfo[iIndex][dmpMarkerType] = strval(string); case 2: DMPInfo[iIndex][dmpColor] = strval(string); case 3: DMPInfo[iIndex][dmpVW] = strval(string); case 4: DMPInfo[iIndex][dmpInt] = strval(string); case 5: DMPInfo[iIndex][dmpPosX] = floatstr(string); case 6: DMPInfo[iIndex][dmpPosY] = floatstr(string); case 7: DMPInfo[iIndex][dmpPosZ] = floatstr(string); } } if(DMPInfo[iIndex][dmpMarkerType] != 0) DMPInfo[iIndex][dmpMapIconID] = CreateDynamicMapIcon(DMPInfo[iIndex][dmpPosX], DMPInfo[iIndex][dmpPosY], DMPInfo[iIndex][dmpPosZ], DMPInfo[iIndex][dmpMarkerType], DMPInfo[iIndex][dmpColor], DMPInfo[iIndex][dmpVW], DMPInfo[iIndex][dmpInt], -1, 500.0); iIndex++; } if(iIndex > 0) printf("[LoadDynamicMapIcons] %d map icons rehashed/loaded.", iIndex); else printf("[LoadDynamicMapIcons] Failed to load any map icons."); return 1; }
PHP код:
cache_get_data
cache_get_row
Please do not send me to any wiki page, I have been trying to fix this for about 4 or 5 hours...