SA-MP Forums Archive
YINI Parsefile. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: YINI Parsefile. (/showthread.php?tid=606141)



YINI Parsefile. - Dayrion - 30.04.2016

Hello!
I want to load vehicle's infos from an .ini file. I'm using YINI. The problem is: parameters can't be loaded. The problem comes from INI_ParseFile (bad configuration by myself) or my public function LoadUserV.
There is the full code: http://pastebin.com/6AQ58PNS
I'm learning pawn and English. Sorry for mistakes.
Have a good day



Re: YINI Parsefile. - Logic_ - 30.04.2016

Show us your enumerator that to use for the vehicle loading.

EDIT: I think "PlayerVehicle" enumerator.
EDIT 2: INI_ParseFile(chemin, "LoadUserV_%i", .bExtra = true, .extra = i); <- problem is here i think.


Re: YINI Parsefile. - Dayrion - 30.04.2016

Yeah i think the problem is here but I don't know how to resolve it.. :/
I mean there is a lot of parameter for INI_Parsefile.


Re: YINI Parsefile. - Logic_ - 30.04.2016

Show me the "enum PlayerVehicle".


Re: YINI Parsefile. - Dayrion - 30.04.2016

Код:
#define MAX_VEHICLE 300

enum vInfo
{
	vID,
	Float:vX,
	Float:vY,
	Float:vZ,
	Float:vZr,
	vColor1,
	vColor2,
	Float:vHealth,
	vModel,
	vPrio[MAX_PLAYER_NAME],
	vTake
}

new PlayerVehicle[MAX_VEHICLE][vInfo];



Re: YINI Parsefile. - Dayrion - 30.04.2016

Any ideas ALIScripter ? ^^


Re: YINI Parsefile. - Dayrion - 01.05.2016

(ninja) BUMP !


Re: YINI Parsefile. - Dayrion - 01.05.2016

I still needing help!


Re: YINI Parsefile. - Jefff - 01.05.2016

it prints printf("Vehicle ID : %i", i); ? you need also add tag before INI_Write, INI_Set_Tag or something


Re: YINI Parsefile. - SyS - 02.05.2016

try this im not sure if it work or not
change
PHP код:
INI_ParseFile(chemin"LoadUserV_%i", .bExtra true, .extra i); 
to
PHP код:
INI_ParseFile(chemin"LoadUserV_data", .bExtra true, .extra i);