Author Topic: Overlay glitching out?  (Read 1135 times)

Offline Irony

  • long
  • ***
  • Posts: 151
    • View Profile
Overlay glitching out?
« on: March 25, 2014, 08:37:35 pm »
Egon, can you make a wild guess what could be wrong if an overlay is not visible? It should be rendered on world.renderscene, right?

Debug code:
Code: [Select]

if (arrow==null) arrow = new Overlay(man.world, fb, "arrow");
arrow.setNewCoordinates(50, 50, 200, 200);
arrow.setVisibility(true);

Still, no overlay :(

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11745
    • View Profile
    • http://www.jpct.net
Re: Overlay glitching out?
« Reply #1 on: March 25, 2014, 08:43:36 pm »

Offline Irony

  • long
  • ***
  • Posts: 151
    • View Profile
Re: Overlay glitching out?
« Reply #2 on: March 25, 2014, 08:48:35 pm »
This helps somewhat. I see it in one scene, but not in the next.
Do I have to do anything with the overlay when I switch cameras?

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11745
    • View Profile
    • http://www.jpct.net
Re: Overlay glitching out?
« Reply #3 on: March 25, 2014, 09:46:59 pm »
"Switch cameras" means setting another camera instance to the same world instance that the overlay belongs to?

Offline Irony

  • long
  • ***
  • Posts: 151
    • View Profile
Re: Overlay glitching out?
« Reply #4 on: March 25, 2014, 10:29:40 pm »
World.setcamerato (if this answers the question?)
Btw, using ES 2.0 if this is relevant.

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11745
    • View Profile
    • http://www.jpct.net
Re: Overlay glitching out?
« Reply #5 on: March 25, 2014, 10:31:45 pm »
Yes, that's what i meant. Which version of jPCT-AE are you using? If it's not the latest, please upgrade and try again. If it is the latest...do you have a test case for me to look at to verify this problem?
« Last Edit: March 25, 2014, 10:54:40 pm by EgonOlsen »

Offline Irony

  • long
  • ***
  • Posts: 151
    • View Profile
Re: Overlay glitching out?
« Reply #6 on: March 25, 2014, 10:46:26 pm »
Probably the latest. Already late today so I'll check on it and prepare a test code tomorrow. Thank you so far and good night  :)

Offline Irony

  • long
  • ***
  • Posts: 151
    • View Profile
Re: Overlay glitching out?
« Reply #7 on: March 28, 2014, 09:06:55 pm »
I am now disposing and recreating the overlay after scene change and together with the changed depth, it seems to work.

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11745
    • View Profile
    • http://www.jpct.net
Re: Overlay glitching out?
« Reply #8 on: March 28, 2014, 11:17:30 pm »
I'm still not sure, what the actual issue is...but if it works this way... ;)