Computer Science Canada

Bullet Game

Author:  upthescale [ Sun Mar 26, 2006 1:19 am ]
Post subject:  Bullet Game

Here yeh go...

Author:  Delos [ Sun Mar 26, 2006 10:18 am ]
Post subject: 

Learn to use View.Update(), it will remove all of your flickering.
Learn to use procedures, they will cut down the length of your programme from ~400 lines to ~50 lines.
I don't see the point in using breaks for any other purpose than debugging. In this situation, you could just as easily have used a function that would check to see if the mouse coordinates were in the screen. If not, it would return a false value (boolean), which could be used to exit the loop.

i.e.
code:

fcn checkMouse () : boolean
  if mouse.x < 0 or mouse.x > _maxx or
    mouse.y < 0 or mouse.y > _maxy then
    result false
  end if
  result true
end checkMouse

%...
loop
  % do stuff
  exit if not checkMouse
end loop

Author:  upthescale [ Sun Mar 26, 2006 10:52 am ]
Post subject: 

view up date never werks, it still flickers whree do i put it?

Author:  DIIST [ Sun Mar 26, 2006 11:01 am ]
Post subject: 

upthescale wrote:
view up date never werks, it still flickers whree do i put it?


Did u forget to setscreen to "offscreenonly"? Cool
You put it at the end where all drawing are done.

Author:  upthescale [ Sun Mar 26, 2006 7:29 pm ]
Post subject: 

umm when i do setscreen to "offscreenonly" the game sdoens't werk

Author:  Cervantes [ Sun Mar 26, 2006 8:31 pm ]
Post subject: 

Did you spell it right? Is it applying to the correct window (if there are more than one)? Did you put the View.Update in the correct spot (ie. after everything is drawn, inside your loop)?

Author:  Delos [ Sun Mar 26, 2006 8:58 pm ]
Post subject: 

Cervantes wrote:
Did you spell it right?


Ouch! Laughing
Seriously though, post up a little code and we might be able to help you better. Being nebulous only ever helped Edwin Hubble.


: