Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Reashu

Pages: 1
1
Old Bugs (1.x/2.x) / Memory leak?
« on: June 17, 2011, 01:04:51 pm »
During startup and before doing anything, StencylWorks uses about 100MB of memory. Every time I open a resource, this increases by 10-20MB (which already seems like a lot). Every time I close a resource memory isn't affected. If I repeatedly open and close the same resource, memory usage just keeps climbing. Once StencylWorks reaches the default JVM max heap size of 512MB, which happens pretty quickly, things (understandably) start moving really slowly. Closing a game has no effect on this, restarting SW is the only thing that helps.
Is it just me?

I doubt they cover things like this, but I've attached my logs just in case.

2
Resolved Questions / [Solved] Collision map for button
« on: June 16, 2011, 12:07:40 am »
Hi all! I was recently notified by a friend of mine that StencylWorks was in open beta, and I figured I owed it to myself to try it out. I'm running into a couple of bumps though...

One in particular I'd like share with you, and it has to do with buttons, or really anything that reacts to the cursor. I've looked, and searched, around a bit and surprisingly didn't find anything on this topic. But I still feel that I can't be the only one who doesn't want to rely on bounding boxes to decide whether the user presses a button or not. And so we've reached the topic of this thread. How should I go about using either
a) the non-transparent pixels of the actor's current animation or
b) the collision map of the actor's current animation
to decide whether the cursor is really over a button?

I tried (regretfully) making a 1x1 actor follow the cursor and use that to detect collisions, but my "solution" has at least two flaws:
1) Inelegant. It should be very possible to "eliminate the middleman" and straight-up compare to the cursor's position.
2) Incorrect. Once a collision has been detected, the hover animation will not stop until the cursor leaves the button's bounding box. There's probably something I can do to fix this, but I'm at a loss.

My "cursor tracker" and button both have their collision areas set to "sensor" and have proper collision groups set - it doesn't seem to be a problem with the tracker leaving the collision area, but rather with something not updating when I expect it to. I've tried with a collision area much smaller than that of the button's bounding box - it only triggers when an actual collision happens, but the button will stay lit up until the cursor leaves it completely.

I've attached an image of my button (to help visualize the problem :) ) and a screen-shot of my "button" design blocks.

Is there anything I can do to make the described design work properly? Am I overlooking a very useful block (or piece of AS) which would remove the need for a cursor tracker? Should I move on to square-shaped buttons?

Thanks in advance! (But I'll still thank you afterwards, too...)

Pages: 1