Search the Community
Showing results for tags 'transparency check'.
Found 1 result
michahell posted a topic in Pixi.jsHi forum, I am working on a proof of concept for a game where i need to be able to place buildings (like any RTS you know). I already have some terrain generation going (I do not use tilemaps) with trees and later on other stuff. I'd like to know if it is possible somehow to calculate where a user can place buildings, and possible even draw (using PIXI.Graphics) a green colored area (around the building) where it is possible to place / install it. Circle based collisions would help at this stage, but alpha channel transparency checks would be better: i have tree textures as transparent 256*256 and 512*512 PNG's with shadow, i'd like to know when a building is being placed right near a/some tree(s). http://www.powergeek.nl/proj/mongento/versions/5/ (no preloader, working version. zooming is buggy but too lazy to work on that right now :> ). Thanks for any tips / pointers!