replace_all
hi
How would I be able to replace the ^ symbol in a name? I've tried this but it doesn't work replace_all(szName, 31, "^4", "^1" ); |
Re: replace_all
replace_all(szName, 31, "^", " " );
|
Re: replace_all
Quote:
|
Re: replace_all
Works thank you for the quick help.
There is another issue which occurred before as well. PHP Code:
It would take everything till the space and new nickname becomes = "^1Dirk^1" Im assuming replace_all by default would remove spacing. Are there symbols to maintain spacing in users name? |
Re: replace_all
cont szName2
for(new i=0;i<=((sizeof szName)-1);i++) { if(szName[i]!='^^') { szName2[i]=szNAme[i+1] i++ } } someone fix it if the transition between c++ and pawn is wrong, but this would be the very basic handling of what you want, probably what replace_all does(except it changes to what you want instead of deleting) |
Re: replace_all
I've tried the following
PHP Code:
|
Re: replace_all
Quote:
|
Re: replace_all
Yes just sorted it.
PHP Code:
PHP Code:
|
Re: replace_all
For changing someones name, use engclient_cmd(id, "name", "new name here").
|
Re: replace_all
Interesting, can you also tell me the reason why or what the difference is?
Would guess one difference to be the spacing to be of no issue :) |
| All times are GMT -4. The time now is 18:07. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.