nak3ddogs Posted October 23, 2014 Share Posted October 23, 2014 hi!the container is moving too fast and ignore the collision between the player. 2. the container have a scale tween :this.add.tween(container.scale).to({y : 0.8}, 300, Phaser.Easing.Linear.None, true, 0, Number.MAX_VALUE, true).loop();and when stand on the container coz this tween the player fall across .here the link for the test:https://googledrive.com/host/0B7yR-x0Q935jODNfYkhueGFuamc/index.htmland here the code:https://drive.google.com/file/d/0B7yR-x0Q935jQzhDZ3JIcDhiQzQ/view?usp=sharingty for any in advance Link to comment Share on other sites More sharing options...
valueerror Posted October 23, 2014 Share Posted October 23, 2014 you can not tween the objects x and y position.. this is like beaming it from one place to another.. no collision will happen.. you need to use velocitiy instead. Link to comment Share on other sites More sharing options...
valueerror Posted October 23, 2014 Share Posted October 23, 2014 oh and the scale collision problem is a different thing.. i don't know much about arcade physics -- i just was surprised that scaling the sprite also scales the physics body.. in p2 you need to change the shape separately. here is a working example of a scaled object with a player standing on i with p2 http://test.xapient.net/phaser/wobbleball/ Link to comment Share on other sites More sharing options...
nak3ddogs Posted October 23, 2014 Author Share Posted October 23, 2014 ty but i done the whole game with arcade psychic. the collision is check in every frame. i think i have to change the delta time.can i fix the size of the body for the scale tween. it can solve the scale tween collision.or i have to attach a invisible rectangle to the sprite and use collision for this?sry for bad english Link to comment Share on other sites More sharing options...
Recommended Posts