#1

Hello, i was working on my gamemode and i got this.

Код:
C:\Users\Administrator\Desktop\All Folders\Scripting\Edited Gamemode\Roleplay\gamemodes\rp.pwn(52) : warning 201: redefinition of constant/macro (symbol "strcpy(%0,%1,%2)")
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Warning.
And This Is The Code

Код:
#define strcpy(%0,%1,%2) %0="",strcat(%0,%2,%1)
Thanks!
Reply
#2

Quote:
Originally Posted by Tass007
Посмотреть сообщение
Hello, i was working on my gamemode and i got this.

Код:
C:\Users\Administrator\Desktop\All Folders\Scripting\Edited Gamemode\Roleplay\gamemodes\rp.pwn(52) : warning 201: redefinition of constant/macro (symbol "strcpy(%0,%1,%2)")
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Warning.
And This Is The Code

Код:
#define strcpy(%0,%1,%2) %0="",strcat(%0,%2,%1)
Thanks!
Remove the line, strcpy is already coming in the default package just like the other string functions. If you can use strcmp, strcat, strlen, strval and these nature you can use strcpy. It means you a re-defining a native afaik.
Reply
#3

I Removed That Line And Then Got 6 Errors....
Reply
#4

Remove it from the other place.
Reply
#5

pawn Код:
#if defined strcpy
    #undef strcpy
#endif

#define strcpy(%0,%1,%2) %0="",strcat(%0,%2,%1)
What about this one?

What about this strcpy ?
I got this one from Nero_3D's post
pawn Код:
#define strcpy(%0,%1,%2) strcat((%0[0] = '\0', %0), %1, %2)
@ admantis I'm not sure strcpy is available in the default server package? or it have?
Reply
#6

I got it working i replaced the strcpy with strlen and i changed everything with strcpy with it into strlen

But Thanks For Offering to help me i really thank you!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)