Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Can a Sprite be Un GetSpriteHit for a period of time / on off ?

Author
Message
haliop_New
User Banned
Posted: 23rd Jan 2017 10:25
I use GetSpriteHit
but I have a lot of sprites on screen and I want to be able to hit just a few not all of them
at my current stage I'm using SetSpritePosition to move all unwanted sprites and then returning them after the hit test
can I disable some or is this the only way ?
Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 23rd Jan 2017 10:46
Instead of checking every sprite with GetSpriteHit, check only specific ones with GetSpriteHitTest.
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 23rd Jan 2017 11:00
Or add/take the sprite out of a group and use GetSpriteHitGroup
Using AppGameKit V2 Tier 1
CJB
Valued Member
20
Years of Service
User Offline
Joined: 10th Feb 2004
Location: Essex, UK
Posted: 23rd Jan 2017 16:59
Absolutely agree. Grouping sprites is super useful.
V2 T1 (Mostly)
Phone Tap!
Uzmadesign
haliop_New
User Banned
Posted: 24th Jan 2017 15:43
Yes i agree i didnt know this was so easy thank you .

Login to post a reply

Server time is: 2024-09-29 23:22:34
Your offset time is: 2024-09-29 23:22:34