Posted By: Roy
FONT* not working?? - 11/01/08 19:26
Hello,
I've tried to set a font for my text in lite-c, but for some (strange?) reason it won't work. I've done this:
FONT* arial_font = "Arial#14b";
To me, it seems right, but the engine thinks differently.
When i hit the run button, i get the following error:
Keyword unknowd FONT*
What is happening?
Thanks,
Roy
Posted By: DJBMASTER
Re: FONT* not working?? - 11/01/08 19:40
are you sure you are using lite-c and that the script's file extension is .c and not .wdl?
If it's .wdl, it's c-script and this syntax is wrong.
Posted By: Quad
Re: FONT* not working?? - 11/01/08 19:41
or you forgot to include acknex.h
Posted By: Roy
Re: FONT* not working?? - 11/01/08 19:46
I did indeed not include acknex.h, because if i include it:
<#include <acknex.h> #include <default.c> BMAP* name = "file.bmp";>
Script error - No C code in .WDL scripts!
with the following script:
#include <acknex.h>
#include <default.c>
BMAP* name = "file.bmp";
I've just updated a7 (that might be the problem)
Before i updated, everything (except the font definition) worked fine. Because the font didn't work, i updated. But then it only got worse...
I am sure that is .c
Roy
Posted By: Quad
Re: FONT* not working?? - 11/01/08 20:38
Script error - No C code in .WDL scripts!
meanss it is a wdl, make sure it is not .c.wdl
Posted By: DJBMASTER
Re: FONT* not working?? - 11/01/08 20:57
when you save your script, you have to explicitly write .c as the extension.
Posted By: Roy
Re: FONT* not working?? - 11/01/08 21:13
I'm sorry, it indeed wasn't a .c
Thanks for your help!
Roy
Posted By: maffmommie
Re: FONT* not working?? - 11/11/08 15:46
I am having the same problem. I made sure that my file extension was .c and not .wdl. I added acknex.h along with the supplementary files and this is the error I'm getting:
< #include <litec.h> #include <compat.h> typedef fixed var;>
acknex.h 10:0 (): Script error - no C code in .WDL scripts!
< typedef fixed function;>
acknex.h 11:0 (): Keyword unknown typedef
< typedef void action;>
acknex.h 12:0 (): Keyword unknown typedef
< #include <atypes.h> #define EXT #define F(f) f #define afuncs_dll_h>
acknex.h 24:0 (): Script error - no C code in .WDL scripts!
< STRING* txt_str^TEXT*);>
acknex.h 31:3 (): Syntax error - TEXT* invalid character *
Posted By: croman
Re: FONT* not working?? - 11/11/08 16:37
have you added it like:
#include <acknex.h>
Posted By: maffmommie
Re: FONT* not working?? - 11/11/08 17:12
no i included like this:
include <acknex.h>
when I change it to #include <acknex.h> I get another error that says that
Error in MAIN line 9: 'path' undeclared identifier
path "..\\template_6"
Posted By: croman
Re: FONT* not working?? - 11/11/08 17:20
you need to include it like i said. path doesnt exist in lite-c. you cant use that keyword. comment that path.... line and it'll work then
Posted By: Quad
Re: FONT* not working?? - 11/11/08 17:26
save your file as .c not wdl and dont mix lite-c and WDL FONT* is lite-c
Posted By: maffmommie
Re: FONT* not working?? - 11/11/08 17:27
I figured it out.. I have to have the files in source folder