SA-MP Forums Archive
Trying to Half a script. - 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)
+--- Thread: Trying to Half a script. (/showthread.php?tid=536997)



Trying to Half a script. - fonia5 - 13.09.2014

Hello am trying to half a script so i have less lines etc, if see what am on about on the code below.


Okay so am making #include "./includes/OnPlayerText" put when i add all my onplayertext commands its coming up with errors.


Код:
// Custom Includes
#include "./includes/defines.pwn"
#include "./includes/forwards.pwn"
#include "./includes/OnGameModeInit.pwn"
#include "./includes/OnPlayerText.pwn"
errors.
Код:
./includes/OnGameModeInit.pwn(28) : error 017: undefined symbol "Gas"
./includes/OnGameModeInit.pwn(41) : error 017: undefined symbol "ghour"
./includes/OnGameModeInit.pwn(42) : error 017: undefined symbol "ghour"
./includes/OnGameModeInit.pwn(43) : error 017: undefined symbol "ghour"
./includes/OnGameModeInit.pwn(44) : error 017: undefined symbol "realtime"
./includes/OnGameModeInit.pwn(46) : error 017: undefined symbol "wtime"
./includes/OnGameModeInit.pwn(48) : error 017: undefined symbol "realtime"
./includes/OnGameModeInit.pwn(55) : error 017: undefined symbol "shifthour"
./includes/OnGameModeInit.pwn(59) : error 017: undefined symbol "News"
./includes/OnGameModeInit.pwn(59) : error 017: undefined symbol "News"
./includes/OnGameModeInit.pwn(59) : error 017: undefined symbol "News"
./includes/OnGameModeInit.pwn(59) : fatal error 107: too many error messages on one line
i just made a blank pwn and put all of my commands inside it.
by the way this happens when i recompile my main gamemode not the other pwn.


Re: Trying to Half a script. - Stinged - 13.09.2014

Try
#include "../includes/defines.pwn" etc..
Or
#include ".../includes/defines.pwn" etc..


Re: Trying to Half a script. - fonia5 - 13.09.2014

it won't find the other .pwn if i add to .. or ... to it only works with one but i get errors as i posted.

won't i need to add something like #endif and #if on the blank pwn were the commands are the defines and forwards work perfectly it's just the last one > #include "./includes/OnPlayerText.pwn"

EDIT not onplayetext my mistake its on OnGamemodeInit code.