summaryrefslogtreecommitdiff
path: root/towernbullet.h
diff options
context:
space:
mode:
authorGravatar chirs241097@gmail.com <chirs241097@gmail.com@c17bf020-1265-9734-9302-a83f62007ddb> 2014-03-28 09:15:17 +0000
committerGravatar chirs241097@gmail.com <chirs241097@gmail.com@c17bf020-1265-9734-9302-a83f62007ddb> 2014-03-28 09:15:17 +0000
commit37c999d3e449754c33586588f06dc073341f72ce (patch)
treefb4f6772f31d8fc839400147d2619b7b241bb577 /towernbullet.h
parent8b96010f277756c9e1a6e4e17ccf5722ed8d87e3 (diff)
downloadbullet-lab-remix-37c999d3e449754c33586588f06dc073341f72ce.tar.xz
Modify the new assessment level, add a new bullet attribute.
Diffstat (limited to 'towernbullet.h')
-rw-r--r--towernbullet.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/towernbullet.h b/towernbullet.h
index 71de714..22c735b 100644
--- a/towernbullet.h
+++ b/towernbullet.h
@@ -67,6 +67,7 @@ int CreateBullet2(double x,double y,double bs,double rad,bool eff=false,bool inv
}
bullet[i].exist=true;
bullet[i].addblend=false;
+ bullet[i].extborder=false;
bullet[i].inv=invi;
bullet[i].bullettype=2;
bullet[i].bulletpos.x=x;
@@ -413,7 +414,8 @@ void ProcessBullet2(int i)
else
{
double dis=GetDist(bullet[i].bulletpos,playerpos);
- if (bullet[i].bulletpos.x<=-25||bullet[i].bulletpos.x>=825||bullet[i].bulletpos.y<=-25||bullet[i].bulletpos.y>=625)
+ if ((!bullet[i].extborder&&(bullet[i].bulletpos.x<=-25||bullet[i].bulletpos.x>=825||bullet[i].bulletpos.y<=-25||bullet[i].bulletpos.y>=625))||
+ (bullet[i].extborder&&(bullet[i].bulletpos.x<=-225||bullet[i].bulletpos.x>=1025||bullet[i].bulletpos.y<=-225||bullet[i].bulletpos.y>=825)))
{
bullet[i].exist=false;
bullet[i].bulletpos.x=bullet[i].bulletpos.y=-999;