Gamestudio Links
Zorro Links
Newest Posts
New FXCM FIX Plugin
by flink. 06/04/24 07:30
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (AndrewAMD, juanex), 1,240 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19056 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
Lite-c programming doesn't work! #231775
10/16/08 21:16
10/16/08 21:16
Joined: Oct 2008
Posts: 58
Marc_Gagne Offline OP
Junior Member
Marc_Gagne  Offline OP
Junior Member

Joined: Oct 2008
Posts: 58
Good day, my name is Marc.
I have recently purchased the Commercial edition of the Gamestudio A7 engine. Shortly after I downloaded the workshops. I read them, opened the sample files, etc. All was well. I was truly amazed by the power of the Lite-c programming language. That's when I hit a little snag: when I tried to program my own files, it didn't work! I even copied and pasted the code from the lite-c sample files but that didn't work either!I tried saving my script under different file extensions but that didn't work either! I tried to open the sample files again. They worked, but the instant I copied the text id didn't work.
Please help me!!!!!!!!!!!
Marc cry

Re: Lite-c programming doesn't work! [Re: Marc_Gagne] #231779
10/16/08 21:51
10/16/08 21:51
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Quad Offline
Senior Expert
Quad  Offline
Senior Expert

Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
your files must be .c files. if you dont add any extension while saving, sed will save it as .wdl file.


3333333333
Re: Lite-c programming doesn't work! [Re: Quad] #231781
10/16/08 22:03
10/16/08 22:03
Joined: Oct 2008
Posts: 58
Marc_Gagne Offline OP
Junior Member
Marc_Gagne  Offline OP
Junior Member

Joined: Oct 2008
Posts: 58
No, that doesn't work.

Re: Lite-c programming doesn't work! [Re: Marc_Gagne] #231782
10/16/08 22:18
10/16/08 22:18
Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
Pappenheimer Offline
Senior Expert
Pappenheimer  Offline
Senior Expert

Joined: Sep 2003
Posts: 5,900
Bielefeld, Germany
Start with the most simple that you can think of. Write a main and start it. What happens? Nothing? Just a fast shut down? An error message? Try to be more informative, otherwise we have to guess in fog...

Re: Lite-c programming doesn't work! [Re: Pappenheimer] #231784
10/16/08 22:28
10/16/08 22:28
Joined: Oct 2008
Posts: 58
Marc_Gagne Offline OP
Junior Member
Marc_Gagne  Offline OP
Junior Member

Joined: Oct 2008
Posts: 58
What's a main? Could you write some code please?

Re: Lite-c programming doesn't work! [Re: Pappenheimer] #231785
10/16/08 22:30
10/16/08 22:30
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
Also have a look in the folder your script lives in and open the "acklog.txt"
file and have a read through. That may help.

If you cant make sense of it, or cant see anything important, post its contents here.


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial
Re: Lite-c programming doesn't work! [Re: EvilSOB] #231786
10/16/08 22:52
10/16/08 22:52
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Quad Offline
Senior Expert
Quad  Offline
Senior Expert

Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
do you see any error messages, or engine producing eny acklog.txt file?


3333333333
Re: Lite-c programming doesn't work! [Re: Quad] #231788
10/16/08 23:16
10/16/08 23:16
Joined: Apr 2006
Posts: 737
Ottawa, Canada
O
Ottawa Offline
User
Ottawa  Offline
User
O

Joined: Apr 2006
Posts: 737
Ottawa, Canada
Hi Marc smile

You will find an example of a main function
in the Gstudio directory under templates6

Look at the codes for A7_project...short but it's a main
it's a start. smile

Salut
Ottawa


Last edited by Ottawa; 10/16/08 23:17.
Re: Lite-c programming doesn't work! [Re: Quad] #231789
10/16/08 23:22
10/16/08 23:22
Joined: Oct 2008
Posts: 58
Marc_Gagne Offline OP
Junior Member
Marc_Gagne  Offline OP
Junior Member

Joined: Oct 2008
Posts: 58
Well this is the script I tried (you will notice that it's the same code from Workshop 2, except that it's been saved under another name):
////////////////////////////////////////////////////////////////////
#include <acknex.h>
#include <default.c>

var a = 0;
var b = 0;
var c = 0;

/////////////////////////////////////////////////////////////////////

PANEL* panDisplay =
{
digits(35, 10, "a = %0.f", *, 1, a);
digits(35, 19, "b = %0.f", *, 1, b);
digits(35, 28, "c = %0.f", *, 1, c);
flags = VISIBLE;
}

/////////////////////////////////////////////////////////////////////

function main()
{
video_mode = 7; // create a program window of 800x600 pixels
screen_color.blue = 150; // and make its background dark blue
while (1)
{
c = a + b;
wait (1);
}

In the folder where this script lives there's a file called OUIETERR.txt, and this is what's written it (it's the same as the error message I get when I test the script):

< #include <acknex.h> #include <default.c> var a = 0;>
ATEST.WDL 5:0 (): Script error - no C code in .WDL scripts!

< PANEL* panDisplay = {>
ATEST.WDL 12:0 (): Parameter unknown PANEL* bad keyword in { }

< digits(35, 10, "a = %0.f", *, 1, a);>
ATEST.WDL 13:0 (): Parameter unknown digits bad keyword in { }

< digits(35, 19, "b = %0.f", *, 1, b);>
ATEST.WDL 14:0 (): Parameter unknown digits bad keyword in { }

< digits(35, 28, "c = %0.f", *, 1, c);>
ATEST.WDL 15:0 (): Parameter unknown digits bad keyword in { }

< flags = VISIBLE;>
ATEST.WDL 16:0 (): Parameter unknown flags bad keyword in { }

< function^main() {>
ATEST.WDL 22:1 (): Script error missing bracket


Could you please tell me what this means?

Re: Lite-c programming doesn't work! [Re: Ottawa] #231790
10/16/08 23:26
10/16/08 23:26
Joined: Oct 2008
Posts: 58
Marc_Gagne Offline OP
Junior Member
Marc_Gagne  Offline OP
Junior Member

Joined: Oct 2008
Posts: 58
When I try the A7_project it works, but when I copy it, it doesn't work!

Page 1 of 2 1 2

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1