mirror of
https://github.com/wassname/phaser.git
synced 2026-09-12 12:40:47 +08:00
Tilemap collision working but needs speeding up
This commit is contained in:
@@ -632,7 +632,7 @@ module Phaser {
|
||||
*/
|
||||
public execute(): bool {
|
||||
|
||||
console.log('quadtree execute');
|
||||
//console.log('quadtree execute');
|
||||
|
||||
var overlapProcessed: bool = false;
|
||||
var iterator: LinkedList;
|
||||
|
||||
@@ -127,7 +127,7 @@ module Phaser {
|
||||
|
||||
if (tempBounds.intersects(object.bounds))
|
||||
{
|
||||
result.push(true);
|
||||
result.push(Collision.separateTile(object, { x: tempBounds.x, y: tempBounds.y, width: tempBounds.width, height: tempBounds.height, mass: 1.0, immovable: true, allowCollisions: Collision.ANY }));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -34,9 +34,9 @@ module Phaser {
|
||||
|
||||
if (typeof keycode === 'object')
|
||||
{
|
||||
for (var code in keycode)
|
||||
for (var i:number = 0; i < keycode.length; i++)
|
||||
{
|
||||
this._capture[code] = true;
|
||||
this._capture[keycode[i]] = true;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user