Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: on Mon 03/05/2004 21:43:02

Title: Transparent Areas clickable when scaled?
Post by: on Mon 03/05/2004 21:43:02
I have a character I just made and the transparent areas are clickable when I use scaling. Scaling is something I really want to use and I was wondering if there is a way around this.
Title: Re: Transparent Areas clickable when scaled?
Post by: Ben on Mon 03/05/2004 21:57:38
The manual says pixel-perfect click detection doesn't work on scaled characters. Is it really important for it to work in your game?
Title: Re: Transparent Areas clickable when scaled?
Post by: on Mon 03/05/2004 23:45:48
Well, of course if there's no other way around it then I'll just have to make it without scaling. I just think scaling looks more professional.
Title: Re: Transparent Areas clickable when scaled?
Post by: beaver on Tue 04/05/2004 01:03:20
does pixel perfect detection only work on characters or on gui's too? and if u have scaling does it make it not work on any element, or just characters?

ta
Title: Re: Transparent Areas clickable when scaled?
Post by: Ben on Tue 04/05/2004 02:18:27
Does your game absolutely need pixel-perfect click detection? Personally, I'd rather have scaling than have every click be 100% accurate. Unless you're doing something like a targer-shooting game, I don't see much need for it.
Title: Re: Transparent Areas clickable when scaled?
Post by: on Tue 04/05/2004 02:41:30
Well my character has a wide stance and a small head so there's all this extra transparent space on both sides of his head and chest area. It sucks cause I'll have a lot of stuff to interact with but I have to move my character away from the stuff before i can click on it.
Title: Re: Transparent Areas clickable when scaled?
Post by: ElectricMonk on Tue 04/05/2004 07:50:45
Just wondering... is it necessary for your character to be clickable in the game? Do the puzzles absolutely demand it?
If not, just check the "no interaction" button in the window of your character, and you'll save yourself a lot of trouble.
Title: Re: Transparent Areas clickable when scaled?
Post by: Scorpiorus on Tue 04/05/2004 12:57:19
Quote from: beaver on Tue 04/05/2004 01:03:20
does pixel perfect detection only work on characters or on gui's too?
Clicking on a GUI doesn't assume the pixel-prefect click detection at all. Regarless whether the GUI background has transparent pixels it's considered to be a solid rectangular area. And clicking on it doesn't trigger the on_mouse_click() function and thus doesn't trigger any interactrions beneath. You can, however, make AGS ignore mouse click on GUI by unticking Clickable checkbox in the GUI editor.

Quoteand if you have scaling does it make it not work on any element, or just characters?
It just doesn't work on scaled characters/objects. It would work fine on a none scaled actor.

[Edit]
Quote from: Scorpiorus on Tue 04/05/2004 12:57:19It just doesn't work on scaled characters/objects.
In fact, it would always work with objects since they are not scaled at all. :)