Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
3 registered members (AndrewAMD, Ayumi, NewbieZorro), 14,141 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Visible / Invisible #238871
11/30/08 21:19
11/30/08 21:19
Joined: Nov 2008
Posts: 53
Switzerland (Luzern)
F
flutschi Offline OP
Junior Member
flutschi  Offline OP
Junior Member
F

Joined: Nov 2008
Posts: 53
Switzerland (Luzern)
HiHo


I want to turn this code into lite-c:

c-script:
Quote:

action door_schalter
{
my.enable_scan = on;
my.event = scan_event;
}


and got this:

lite-c:
Quote:

action door_schalter()
{
set(my,ENABLE_SCAN);
my.event = EVENT_SCAN;
}


The problem now is, the door get invisible.. in c-script, it worked.. it just worked fine.. but now the door get invisible smirk

if i take the door_schalter action out of the object in MED, the door is there if i run.. but if i do the door_schalter into the object, the door gets invisible smirk


My System:
Intel Core 2 Duo CPU P8400 @ 2.26 GHz
4 GB Ram
NVIDIA GeForce 9600M GT
32 Bit Windows Vista
***********************************
Gamestudio Pro 7.50 / WED V6.875
Re: Visible / Invisible [Re: flutschi] #238875
11/30/08 21:27
11/30/08 21:27
Joined: Jul 2002
Posts: 4,436
Germany, Luebeck
Xarthor Offline
Expert
Xarthor  Offline
Expert

Joined: Jul 2002
Posts: 4,436
Germany, Luebeck
The set() makro is used for flags, not for event types.
Use the emask instead:

Code:
function scan_event()
{
  if(EVENT_TYPE == EVENT_SCAN)
  {
     ..
  }
}

action door_schalter()
{
  my.emask |= (ENABLE_SCAN);
  my.event = scan_event;
}


Re: Visible / Invisible [Re: Xarthor] #238893
12/01/08 00:55
12/01/08 00:55
Joined: Nov 2008
Posts: 53
Switzerland (Luzern)
F
flutschi Offline OP
Junior Member
flutschi  Offline OP
Junior Member
F

Joined: Nov 2008
Posts: 53
Switzerland (Luzern)
thx, i try it out!


My System:
Intel Core 2 Duo CPU P8400 @ 2.26 GHz
4 GB Ram
NVIDIA GeForce 9600M GT
32 Bit Windows Vista
***********************************
Gamestudio Pro 7.50 / WED V6.875

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