Invisible stacks

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
magice
Posts: 457
Joined: Wed Mar 18, 2009 12:57 am

Invisible stacks

Post by magice » Mon Apr 11, 2011 5:57 am

I am trying to create a range marker app to be used with 3D MMO games. My idea is to create several movable buttons on a narrow stack that floats above everything. The button positions can then be moved to match screen locations of items at specific distances away. In this way I calibrate the range finder to the game being played. I have skinned stacks to specific shapes using gifs with an alpha channel. Now I am trying to do something slightly different. My stack needs to show only its buttons. That would be easy, except that the buttons need to be user movable. This means that if I use windowshape to create the invisible areas, then the buttons disappear when in those invisible areas because they are no longer in the area of the stack. Is there a way to make an invisible color in the stack (where programs running under the app will show through) and yet still allow buttons to be seen anywhere they are moved within that area?

deebee
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 89
Joined: Mon Jul 19, 2010 6:59 am
Location: Illinois, USA

Re: Invisible stacks

Post by deebee » Tue Apr 12, 2011 1:57 am

Maybe if each button was it's own stack windowshaped as the button, set to be always on top. However, maybe I'm thinking too far out of the box for what you are trying to accomplish.

magice
Posts: 457
Joined: Wed Mar 18, 2009 12:57 am

Re: Invisible stacks

Post by magice » Tue Apr 12, 2011 4:25 pm

deebee wrote:Maybe if each button was it's own stack windowshaped as the button, set to be always on top. However, maybe I'm thinking too far out of the box for what you are trying to accomplish.

I think you might just be on to something there. Thank you

BvG
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1236
Joined: Sat Apr 08, 2006 1:10 pm
Location: Zurich
Contact:

Re: Invisible stacks

Post by BvG » Wed Apr 13, 2011 1:21 am

you could also create the windowshape image on the fly. So when the button is placed somewhere, you set that region to be opaque by creatign an image that has that part black. To help with that, whenever a button begins to be dragged, make a screenshot at dragstart, and thus fake the screen being visible... But that is really very much more complicated then having each button being it's own stack, i guess :)
Various teststacks and stuff:
http://bjoernke.com

Chat with other RunRev developers:
chat.freenode.net:6666 #livecode

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”