Writing gamemode in some files, like mta resources. W/ #include?
#1

Hello!
I got problems with my gamemode...

Код:
.pwn(11) : error 017: undefined symbol "getServerVersion"
init.pwn:
Код:
#include <a_samp>


#define RCRP_ComplieProtect
#include "../../gamemodes/rcrp_sources/config.pwn"
#include "../../gamemodes/rcrp_sources/functions.pwn"
main()
{
	print("samp@anthonygates: Red County Roleplay");
	print("samp@anthonygates: Written by Anthony Gates");
	printf("samp@anthonygates: Loading version %s", getServerVersion());
}
config.pwn:
Код:
#if !defined RCRP_ComplieProtect
	#error Nem jу fбjlt prуbбlsz fordнtani!! // if you try complie this file
#endif

//VERSION
#define MOD "RC-RP"
#define MAJOR 1
#define MINOR 0
#define PATCH 0
functions.pwn:
Код:
#if !defined RCRP_ComplieProtect
	#error Nem jу fбjlt prуbбlsz fordнtani!! // if you try complie this file
#endif

stock getServerVersion(){
	new output[] = "RC-RP x.x.xxx";
	format(output, sizeof(output), "%s %d.%d.%d",MOD,MAJOR, MINOR, PATCH);
	return output;
}
Any ideas?
Only the first "../../gamemodes/rcrp_sources/*.pwn" loading.
Reply
#2

Use backslashes. The Pawn compiler behaves weird if you use forward slashes and the include path is longer than 30 characters.
Reply
#3

Thank you!



Solved.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)