Raised This Month: $32 Target: $400
 8% 

[ZP]String formatted incorrectly - parameter 11 (total 10)


  
 
 
Thread Tools Display Modes
Author Message
Winchester90
Senior Member
Join Date: May 2013
Location: Dale! RG4L Baby
Old 09-07-2013 , 08:57   [ZP]String formatted incorrectly - parameter 11 (total 10)
#1

[ZP]String formatted incorrectly - parameter 11 (total 10)
Code:
// Save/Load player data player_data(id, save, load) { if(!g_isconnected[id] || g_isbot[id]) return; // Wishes to save? if(save) { static data[900] // Format data file formatex(data, charsmax(data), "%d %d %d %d", g_ammopacks[id], g_level[id], g_reset[id], g_skill_points[id][0][5]) fvault_set_data(vault_levels, g_playername[id], data) // Format status data formatex(data, charsmax(data), "%d %d %d %d %d %d", rojo[id], verde[id], azul[id], g_nvg[id][0], g_nvg[id][1], g_nvg[id][2], HUD_STATS_T[id]) // Saved all statsg fvault_set_data(vault_stats, g_playername[id], data) // Format status data formatex(data, charsmax(data), "%d %d %d %d %d %d %d %d", g_gastados[id][0], g_gastados[id][1], g_skill_points_type[id][0], g_skill_points_type[id][1], g_skill_points[id][0][1], g_skill_points[id][0][2], g_skill_points[id][0][3]) // Saved all stats fvault_set_data(vault_stats1, g_playername[id], data) // Format status data formatex(data, charsmax(data), "%d %d %d %d %d %d %d", g_skill_points[id][0][0], g_skill_points[id][0][4], g_skill_points[id][1][0], g_skill_points[id][1][1], g_skill_points[id][1][2], g_skill_points[id][1][3], g_skill_points[id][1][4]) // Saved all statsg fvault_set_data(vault_stats2, g_playername[id], data) } if(load) { static data[900] // Didnt get the name? if(!fvault_get_data(vault_levels, g_playername[id], data, charsmax(data))) server_print("Playername %s not found.", g_playername[id]) else { static lvl[10], ap[10], rst[10] parse(data, ap, charsmax(ap), lvl, charsmax(lvl), rst, charsmax(rst)) g_level[id] = str_to_num(lvl) g_ammopacks[id] = str_to_num(ap) g_reset[id] = str_to_num(rst) } // Didnt get the name? if(!fvault_get_data(vault_stats, g_playername[id], data, charsmax(data))) server_print("Playername %s not found.", g_playername[id]) else { // Fuck this is big o.0 static inf[28], hkill[28], zkill[28], pt[45], ev[28], bkill[28], re[28] parse(data, inf, charsmax(inf), hkill, charsmax(hkill), zkill, charsmax(zkill), pt, charsmax(pt), ev, charsmax(ev), bkill, charsmax(bkill), re, charsmax(re)) // Load it into the stats $: rojo[id] = str_to_num(inf) verde[id] = str_to_num(hkill) azul[id] = str_to_num(zkill) g_nvg[id][0] = str_to_num(pt) g_nvg[id][1] = str_to_num(ev) g_nvg[id][2] = str_to_num(bkill) HUD_STATS_T[id] = str_to_num(re) } // Didnt get the name? if(!fvault_get_data(vault_stats1, g_playername[id], data, charsmax(data))) server_print("Playername %s not found.", g_playername[id]) else { // Fuck this is big o.0 static gastados[28], gastados1[28], skilltype[28], skilltype1[28], zm0[28], zm1[28], zm2[28] parse(data, gastados, charsmax(gastados), gastados1, charsmax(gastados1), skilltype, charsmax(skilltype1), zm0, charsmax(zm0), zm1, charsmax(zm1), zm2, charsmax(zm2), zm1, charsmax(zm1), zm2, charsmax(zm2)) // Load it into the stats $: g_gastados[id][0] = str_to_num(gastados) g_gastados[id][1] = str_to_num(gastados1) g_skill_points_type[id][0] = str_to_num(skilltype) g_skill_points_type[id][1] = str_to_num(skilltype1) g_skill_points[id][0][1] = str_to_num(zm0) g_skill_points[id][0][2] = str_to_num(zm1) g_skill_points[id][0][3] = str_to_num(zm2) } // Didnt get the name? if(!fvault_get_data(vault_stats2, g_playername[id], data, charsmax(data))) server_print("Playername %s not found.", g_playername[id]) else { // Fuck this is big o.0 static zm2[28], zm3[28], zm1[28], hm1[28], hm2[28], hm3[28], hm4[28], hm5[28] parse(data, zm2, charsmax(zm2), zm3, charsmax(zm3), zm1, charsmax(zm1), hm1, charsmax(hm1), hm2, charsmax(hm2), hm3, charsmax(hm3), hm4, charsmax(hm4), hm5, charsmax(hm5)) // Load it into the stats $: g_skill_points[id][0][0] = str_to_num(zm2) g_skill_points[id][0][4] = str_to_num(zm3) g_skill_points[id][1][0] = str_to_num(zm1) g_skill_points[id][1][1] = str_to_num(hm1) g_skill_points[id][1][2] = str_to_num(hm2) g_skill_points[id][1][3] = str_to_num(hm3) g_skill_points[id][1][4] = str_to_num(hm4) g_skill_points[id][0][5] = str_to_num(hm5) } } }
__________________
Proyectos No comercio XD
Zombie Resurection 1.0 (45%)

Last edited by lucas_7_94; 09-07-2013 at 19:48.
Winchester90 is offline
lucas_7_94
Leche Loco
Join Date: Mar 2009
Location: Argentina
Old 09-07-2013 , 19:49   Re: [ZP]String formatted incorrectly - parameter 11 (total 10)
#2

No borres el contenido , puede servirle a alguien.

Respecto a la duda/problema es..

Tiene mas datos a entregar que las variables. Ejemplo , tiene 5 %d y 3 variables para mostrar.

PHP Code:
formatex(datacharsmax(data), "%d %d %d %d %d %d"rojo[id], verde[id], azul[id], g_nvg[id][0], g_nvg[id][1], g_nvg[id][2], HUD_STATS_T[id]) 
en este caso 7 variables y 6 %d.
__________________
ATWWMH - MiniDuels
Madness is like gravity, just need a little push.
lucas_7_94 is offline
Send a message via Skype™ to lucas_7_94
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 04:31.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode