So for my project in college im making a 'space invaders' type game, but I cant get my tank to move? the code for this is:
but when pressing the left and right arrow keys nothing is happening? Where have I gone wrong in this?Code:onClipEvent(2){ if(this._x<=0) this._x=2; if(this._x>=580) this._x=478; if(this._x>80 && this._x=480; if(Key.isDown (Key.RIGHT)) this._x+=5 } else if(Key.isDown (Key.LEFT)){ this._x-=5 } if(Key.isDown (Key.SPACE)) if(_root.bullet._y>600) { bullet._x=this._x bulley._y=this._y } } }
Unless it has something to do with the code on my button on frame one which is
Really stumped with this one!Code:on(release) { gotoAndStop(2) }


LinkBack URL
About LinkBacks
Reply With Quote