Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: Engine/engine.cpp
- Revision:
- 3:31ff7b3e2005
- Parent:
- 2:cc9d8ec2e1f4
diff -r cc9d8ec2e1f4 -r 31ff7b3e2005 Engine/engine.cpp
--- a/Engine/engine.cpp Fri May 15 17:44:25 2020 +0000
+++ b/Engine/engine.cpp Fri May 15 20:32:27 2020 +0000
@@ -4,12 +4,10 @@
void engine::init(){
}
-events engine::evet_check(chara &p, obs &b, Gamepad &pad){
+events engine::event_check(chara &p, obs &b, Gamepad &pad){
xy pxy = p.getxy();
- int width = p.getwidth();
- int height = p.getheight();
if(b.x>-1){
- if(((pxy.x - b.width < b.x)&&(pxy.x+width>b.x)) &&((pxy.y-b.height<b.y)&&(pxy.y+height>b.y))){
+ if(((pxy.x - b.width < b.x)&&(pxy.x+7>b.x)) &&((pxy.y-b.height<b.y)&&(pxy.y+8>b.y))){
return DEAD;
}
}