Gamestudio Links
Zorro Links
Newest Posts
Alpaca Plugin v1.5.2 Release
by kzhao. 01/11/26 13:42
Alpaca Plugin v1.4.0
by kzhao. 01/11/26 13:38
separating groups of 3 digits by a comma
by joe_kane. 01/11/26 00:01
MRC.c and WFO
by joe_kane. 01/10/26 23:58
BarOffset (default = 940 for daily bars?
by joe_kane. 01/10/26 23:46
NOMAX undeclared identifier.
by Petra. 01/09/26 21:12
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
0 registered members (), 2,814 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
joe_kane, Namitha_NN, Syndrela, agasior, mosfet
19189 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
define entity skill error #183790
02/14/08 06:25
02/14/08 06:25
Joined: Oct 2003
Posts: 702
Z
zazang Offline OP
User
zazang  Offline OP
User
Z

Joined: Oct 2003
Posts: 702
Hi

I am using a really simple thing which used to work previously,but
its giving me an error "entity_type is not a member of ENTITY" while
compiling.

Here is the code which causes error :-

Code:
  
if (dist < 6)
{
if (you != NULL)
{
if (you.entity_type == 2)
{
you.skill13 = 1; //hit a dragon
}
}
ent_create("smallbubble.bmp",my.x,puddle);
ent_remove(my);
return;
}



I have already defined entity_type in a wdl file.(with the same name as main c file) like this :-

define entity_type,skill77;

Any ideas why this error

regards
zazang


I like good 'views' because they have no 'strings' attached..
Re: define entity skill error [Re: zazang] #183791
02/14/08 10:20
02/14/08 10:20
Joined: Feb 2008
Posts: 9
Germany, Cologne
dinosaur Offline
Newbie
dinosaur  Offline
Newbie

Joined: Feb 2008
Posts: 9
Germany, Cologne
Hi zazang,

if i try to put a define in a .wdl (c-script) and try to do the rest with lite-C then i get a lot of problems.

So try to use a header-file(.h) for your defines and include it in your .c file

e.g.
mydefines.h
#define entity_type skill7


mymain.c
#include <acknex.h>
#include <mydefines.h>

.
.
.
if (you.entity_type == 2)
.
.
.

hope it will help.

regards
dinosaur

Re: define entity skill error [Re: dinosaur] #183792
02/14/08 11:52
02/14/08 11:52
Joined: Oct 2003
Posts: 702
Z
zazang Offline OP
User
zazang  Offline OP
User
Z

Joined: Oct 2003
Posts: 702
Thanks dinosaur it worked !


I like good 'views' because they have no 'strings' attached..

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

Gamestudio download | 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