Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (dr_panther, 7th_zorro), 1,203 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
strange problem - any ideas? #241227
12/14/08 23:00
12/14/08 23:00
Joined: Apr 2002
Posts: 224
Twickenham,England
kiamonster Offline OP
Member
kiamonster  Offline OP
Member

Joined: Apr 2002
Posts: 224
Twickenham,England
STRING* sTitle = "";
STRING* sTitlt = " ";
STRING* namest = "na";

When I do a debug run, the first line is accepted, but when I put anything between the quotes, it errors with invalid character.
The syntax is fine I think - so why the error?

Re: strange problem - any ideas? [Re: kiamonster] #241228
12/14/08 23:05
12/14/08 23:05
Joined: Aug 2005
Posts: 343
Germany
HPW Offline
Senior Member
HPW  Offline
Senior Member

Joined: Aug 2005
Posts: 343
Germany
Do you declare the strings inside a function?
Only global string declaration is ok with this syntax.
For declaring inside a function the follow syntax should be used.
Code:
function my_func()
{
  STRING* namest;
  namest = str_create("na");
}



Evil Blood (v. 0.52) RPG
Commport.de (Social Network Community)
Re: strange problem - any ideas? [Re: HPW] #241231
12/14/08 23:17
12/14/08 23:17
Joined: Apr 2002
Posts: 224
Twickenham,England
kiamonster Offline OP
Member
kiamonster  Offline OP
Member

Joined: Apr 2002
Posts: 224
Twickenham,England
Thanks for the reply HPW
This is a global string or it should be!!!
It is in a script which only defines data items - no functions,


Last edited by kiamonster; 12/14/08 23:27.
Re: strange problem - any ideas? [Re: kiamonster] #241233
12/14/08 23:30
12/14/08 23:30
Joined: Aug 2005
Posts: 343
Germany
HPW Offline
Senior Member
HPW  Offline
Senior Member

Joined: Aug 2005
Posts: 343
Germany
The syntax is correct for Lite-C (filename.c or filename.h) and global declaration.
Maybe it's an engine bug with the warn_level you use? I use warn_level = 1;
But it could also a syntax problem with a include before your declaration. Maybe somewhat like commentation at the end of a file or a include of a empty file. This is not allowed.

Last edited by HPW; 12/14/08 23:31.

Evil Blood (v. 0.52) RPG
Commport.de (Social Network Community)
Re: strange problem - any ideas? [Re: HPW] #241235
12/14/08 23:34
12/14/08 23:34
Joined: Aug 2005
Posts: 343
Germany
HPW Offline
Senior Member
HPW  Offline
Senior Member

Joined: Aug 2005
Posts: 343
Germany
Do you also include in the first line of your main script one of this lines?
#include <acknex.h> // Pure Mode
or
#include <litec.h> // Legacy Mode


Evil Blood (v. 0.52) RPG
Commport.de (Social Network Community)
Re: strange problem - any ideas? [Re: HPW] #241236
12/14/08 23:47
12/14/08 23:47
Joined: Apr 2002
Posts: 224
Twickenham,England
kiamonster Offline OP
Member
kiamonster  Offline OP
Member

Joined: Apr 2002
Posts: 224
Twickenham,England
Thanks again HPW

I use acknex.h

Howecer, just moved it elsewhere - it failed - so I moved it back - it worked?
As Murphys' laws of programming state:
Does the damn thing work?
If yes then don't touch it!
Thanks again though. Very thoughtful.


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