SA-MP Forums Archive
Help Me Please , for text - 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: Help Me Please , for text (/showthread.php?tid=106304)



Help Me Please , for text - boynumber5 - 02.11.2009

if i want to insert text in variable example.

i have text "Yakuza"

i want to insert it to variable A

what should i do ?


Re: Help Me Please , for text - Mikep. - 02.11.2009

I THINK you can do:

pawn Код:
new string[7];
string = "Yakuza";
I don't use string variables for one word normally

Or do you mean #define?

If all else fails, see this: https://sampwiki.blast.hk/wiki/Format


Re: Help Me Please , for text - dice7 - 02.11.2009

Quote:
Originally Posted by Mikep.
I THINK you can do:

pawn Код:
new string[7];
string = "Yakuza";
This will only work if the 2 arrays lenght in cells are the same

Quote:
Originally Posted by Mikep.
If all else fails, see this: https://sampwiki.blast.hk/wiki/Format
Use this and you wont have any trouble


Re: Help Me Please , for text - Daren_Jacobson - 02.11.2009

pawn Код:
new string[] = "Yakuza";
= win

pawn Код:
new string[7];
format(string, sizeof(string), "Yakuza");
= fail

pawn Код:
new string[] = {89, 97, 107, 117, 122, 97, 0}
= now that's my kind of fail


Re: Help Me Please , for text - dice7 - 02.11.2009

Your method only works when declaring


Re: Help Me Please , for text - MenaceX^ - 02.11.2009

Quote:
Originally Posted by dice7
Quote:
Originally Posted by Mikep.
I THINK you can do:

pawn Код:
new string[7];
string = "Yakuza";
This will only work if the 2 arrays lenght in cells are the same

Quote:
Originally Posted by Mikep.
If all else fails, see this: https://sampwiki.blast.hk/wiki/Format
Use this and you wont have any trouble
They're.


Re: Help Me Please , for text - boynumber5 - 03.11.2009

Thx for every comment, i can do it now. thx again