Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Seizure Machine
Index -> Programming, Turing -> Turing Submissions
View previous topic Printable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Metal-Head91




PostPosted: Thu Jun 07, 2007 11:35 pm   Post subject: Seizure Machine

This was a project writen be me and a partner for our computer sciences class. It's a game where the object is to click the ball that moves before it moves again. there are some glitches that me nor my partner knew how to fix, but it can be enjoyable in a way i guess. The first 3 screens are blank because their supposed to be a title page and 2 pages of instructions but we made those in paint which i dont have so just hit any key 3 times and ignore it. and i would be very pleased if someone can help me with my glitch once oyu find it. enjoy

%Francis Kurevija & Luke Doherty
%May 23, 2007
%Seizure Machine

var count, x, y, x2, y2, button : int

proc Title
Pic.ScreenLoad ("H:/My Pictures/Seizure Machine.bmp", 0, 0, picUnderMerge) %Loads picture
Input.Pause %Gets input from keyboard
cls
end Title

proc Instructions1
Pic.ScreenLoad ("H:/My Pictures/Instructions1.bmp", 0, 0, picUnderMerge)
Input.Pause
cls
end Instructions1

proc Instructions2
Pic.ScreenLoad ("H:/My Pictures/instructions2.bmp", 0, 0, picUnderMerge)
Input.Pause
cls
end Instructions2


proc Level1
count := 0
loop
x := Rand.Int (0, maxx) % Creates random integer
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen) %Draws backround
Draw.FillOval (x, y, 20, 20, black) %Draws circle
delay (1500)
if Mouse.ButtonMoved ("down") then %If statement is initiated when the mouse button is
%pressed
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown) %When the mouse
%button is pressed it's co-ordinates are checked and assigned to a variable
Draw.FillOval (x2, y2, 5, 5, brightred) %A red dot appears over the black circle
%to tell the user when they have hit the black circle
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then %If the
%co-ordinates of the mouse are within the vicinity of the circle the if statement
%is initiated
count := count + 10
put count
delay (500)
end if
end if
exit when count = 30
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level1

proc Level2
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 20, 20, black)
delay (1200)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 60
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level2

proc Level3
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 20, 20, black)
delay (1000)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 90
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level3

proc Level4
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 20, 20, black)
delay (800)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 120
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level4

proc Level5
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 20, 20, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 150
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level5

proc Level6
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 25, 25, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 25 and x2 <= x + 25) and (y2 >= y - 25 and y2 <= y + 25) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 30
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level6

proc Level7
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 20, 20, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 60
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level7

proc Level8
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 15, 15, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 15 and x2 <= x + 15) and (y2 >= y - 15 and y2 <= y + 15) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 90
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level8

proc Level9
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 10, 10, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 10 and x2 <= x + 10) and (y2 >= y - 10 and y2 <= y + 10) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 120
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level9

proc Level10
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightgreen)
Draw.FillOval (x, y, 5, 5, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 5 and x2 <= x + 5) and (y2 >= y - 5 and y2 <= y + 5) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 150
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level10

proc Level11
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, brightred)
Draw.FillOval (x, y, 20, 20, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 150
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level11

proc Level12
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, blue)
Draw.FillOval (x, y, 20, 20, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 150
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level12

proc Level13
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, green)
Draw.FillOval (x, y, 20, 20, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 150
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level13

proc Level14
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, 113)
Draw.FillOval (x, y, 20, 20, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 150
end loop
cls
put "You have advance to the next level."
delay (3000)
end Level14

proc Level15
count := 0
loop
x := Rand.Int (0, maxx)
y := Rand.Int (0, maxy)
Draw.FillBox (0, 0, maxx, maxy, 17)
Draw.FillOval (x, y, 20, 20, black)
delay (500)
if Mouse.ButtonMoved ("down") then
var buttonnumber, buttonupdown : int
Mouse.ButtonWait ("down", x2, y2, buttonnumber, buttonupdown)
Draw.FillOval (x2, y2, 5, 5, brightred)
if (x2 >= x - 20 and x2 <= x + 20) and (y2 >= y - 20 and y2 <= y + 20) then
count := count + 10
put count
delay (500)
end if
end if
exit when count = 150
end loop
end Level15

proc Win
cls
put "CONGRADULATIONS!"
put "YOU WIN!"
end Win

%---------------|
Title % |
Instructions1 % |
Instructions2 % |
Level1 % |
Level2 % |
Level3 % |
Level4 % |
Level5 % |
Level6 % |
Level7 % |------ Calls all procedures
Level8 % |
Level9 % |
Level10 % |
Level11 % |
Level12 % |
Level13 % |
Level14 % |
Level15 % |
Win % |
%---------------|
Sponsor
Sponsor
Sponsor
sponsor
ashiphire




PostPosted: Sun Jun 10, 2007 8:03 pm   Post subject: RE:Seizure Machine

u should put all the levels in one procedure
UraniumLobster




PostPosted: Wed Sep 12, 2007 10:14 am   Post subject: RE:Seizure Machine

What motivated you to make a game that could cause epilepsy? haha
aspire




PostPosted: Fri Sep 14, 2007 1:39 pm   Post subject: RE:Seizure Machine

That is really cool. Very Happy I love looking at things like these Razz. They make me feel special lol.
Display posts from previous:   
   Index -> Programming, Turing -> Turing Submissions
View previous topic Tell A FriendPrintable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 4 Posts ]
Jump to:   


Style:  
Search: