Please login or register.

Login with username, password and session length
Advanced search  

News:

For WME related articles and tutorials visit WME Resource Center.

Author Topic: Sprite visibility  (Read 2960 times)

0 Members and 1 Guest are viewing this topic.

ahedov

  • Lurker
  • *
  • Karma: 2
  • Offline Offline
  • Posts: 29
    • View Profile
Sprite visibility
« on: August 20, 2011, 05:13:14 PM »

Hi all. I'm in a desperate need of an advice.

In my scene I have entity that is not visible, so in my script I wrote these lines>

Code: [Select]
var spoon = Scene.GetNode("spoon");
spoon.Active = false;

Then my character do something, that recover this item on the scene, so I wrote these lines:

Code: [Select]
var spoon = Scene.GetNode("spoon");
spoon.Active = true;

But now, if the item appears on the screen, my character is always behind them, so even if it is on the table in tha far side of the screen, when my character walk by, this item is alway in front of him.

Does anybody know how to fix it?

Thanx.
« Last Edit: August 20, 2011, 05:16:43 PM by ahedov »
Logged

Spellbreaker

  • Supporter
  • Frequent poster
  • *
  • Karma: 4
  • Offline Offline
  • Gender: Male
  • Posts: 376
    • View Profile
    • Apeiron Studios
Re: Sprite visibility
« Reply #1 on: August 20, 2011, 06:02:01 PM »

Is it a free entity or a normal entity? I think it has to be a free entity, maybe the de-/activating brings the entity to the end of the entity list?
Logged

ahedov

  • Lurker
  • *
  • Karma: 2
  • Offline Offline
  • Posts: 29
    • View Profile
Re: Sprite visibility
« Reply #2 on: August 20, 2011, 06:34:25 PM »

Thanx, it's fixed now.
Logged
 

Page created in 0.042 seconds with 19 queries.