SA-MP Forums Archive
Create3DTextProblem problem. - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Create3DTextProblem problem. (/showthread.php?tid=130163)



Create3DTextProblem problem. - Martin_M - 25.02.2010

Hey, guys. I'm building my own business system, and there is one problem.
I have created a function, witch change business name. Everythings included GUI.
So. Then i changed business name to, for example "Forum Support", it's shows:
Quote:

Business: `

But it should to look like:
Quote:

Business: Forum Support

Maybe the string too little? It's
Код:
new msg[258];
Is it good enough?

Any ideas?


Re: Create3DTextProblem problem. - Martin_M - 25.02.2010

Код:
    new NewName[258];
	if(sscanf(inputtext,"u",NewName)) return ShowPlayerDialog(playerid,36,DIALOG_STYLE_INPUT,"Business.","Type business name.","Create","Close");
	new file[258],NewOwner[MAX_PLAYER_NAME],msg[128];
    GetPlayerName(playerid,NewOwner,MAX_PLAYER_NAME);
	for(new i=0;i<MaxBusiness+1;i++){
	if(IsPlayerInRangeOfPoint(playerid,IejimuR,verslasDB[i][X],verslasDB[i][Y],verslasDB[i][Z])){
    verslasDB[i][name] = NewName;
	dini_Set(file,"Name",NewName);
	verslasDB[i][owner] = NewOwner;
	dini_Set(file,"Owner",NewOwner);
	Delete3DTextLabel(Business3D[i]);
	format(msg,128,"Bussines \"%s\"\nOwner: %s.",verslasDB[i][name],verslasDB[i][owner]);
	Business3D[i] = Create3DTextLabel(msg,Verslo3DSpalva,verslasDB[i][X],verslasDB[i][Y],verslasDB[i][Z],Distance3D,AllowTransparent);



Re: Create3DTextProblem problem. - Martin_M - 25.02.2010

bump.
Still didn't solved.


Re: Create3DTextProblem problem. - dice7 - 25.02.2010

You're using sscanf wrong

https://sampwiki.blast.hk/wiki/Fast_Commands#Data_types


Re: Create3DTextProblem problem. - Joe Staff - 25.02.2010

You can only bump after 12 hours, it's only been 1 hour.

I thought that the 'u' parameter in sscanf was only for players. Change it to 's'


Re: Create3DTextProblem problem. - Martin_M - 25.02.2010

Joe Staff, thanks for alerting.
Ant thanks you both.
Fixed.