setscreen ("graphics:800;600,offscreenonly,title:Snake Remix V1.0 Copyright 2004 by Josh Rosen,nocursor,noecho")
colourback (7)
cls
process music
Music.PlayFile ("sound1.mp3")
end music
proc title_screen
%Declare Variables Here
var font1 : int %holds font1
var font2 : int %holds font2
var font3 : int %holds font3
var x1, y1 : int %the x and y of the title
var s1 : int %holds the size of the title
var x2, y2 : int %holds the x and y of josh's name
var screenHist : int %holds a shot of the whole screen
var a : int %holds wheather or not to flash the title in the colours
var b : boolean %holds which message to flash
var c : int %holds wheather or not to change the value of d
var d : boolean %holds wheather or not to decrease the delay
var randx, randy : int %holds the random co-ordiantes for the flashes of the word
%Initialize Variables and Fonts Here
font1 := Font.New ("arial:24:bold")
font3 := Font.New ("arial:14")
x1 := 500
y1 := 210
s1 := 24
x2 := 350
y2 := 190
b := true
fork music
%declare variables here
var timer : int := 500
for i : 35 .. 255
randint (randx, 10, 750)
randint (randy, 10, 550)
a := i mod 5
c := i mod 2
if c = 0 then
d := true
elsif c > 0 then
d := false
end if
colourback (i)
cls
if a = 0 then
if b = true then
Font.Draw ("Snake", randx, randy, font3, white)
b := false
elsif b = false then
Font.Draw ("Remix", randx, randy, font3, white)
b := true
end if
end if
View.Update
delay (timer)
if timer > 10 and d = true then
timer -= 10
end if
end for
colourback (7)
cls
%loads the snake pics for a brief flash
%loads the snake head on the right (open mouth)
Pic.ScreenLoad ("snakehead1.1.jpg", 400, 100, picMerge)
%loads the snake on the left (closed mouth)
Pic.ScreenLoad ("snakehead2.1.jpg", 0, 120, picMerge)
View.Update
delay (10)
%quickly flahsed the background again
for i : 1 .. 10
colourback (i)
cls
View.Update
end for
colourback (7)
cls
%loads the snake pics
%loads the snake head on the right (open mouth)
Pic.ScreenLoad ("snakehead1.1.jpg", 400, 100, picCopy)
%loads the snake on the left (closed mouth)
Pic.ScreenLoad ("snakehead2.1.jpg", 0, 120, picCopy)
View.Update
delay (100)
%Make Words come out of Open Mouth
loop
cls
x1 -= 10
%loads the snake head on the right (open mouth)
Pic.ScreenLoad ("snakehead1.1.jpg", 400, 100, picMerge)
%loads the snake on the left (closed mouth)
Pic.ScreenLoad ("snakehead2.1.jpg", 0, 120, picMerge)
Font.Draw ("Snake Remix", x1, y1, font1, 9)
View.Update
exit when x1 = 300
end loop
%loads the snake head on the right (open mouth)
Pic.ScreenLoad ("snakehead1.1.jpg", 400, 100, picMerge)
%loads the snake on the left (closed mouth)
Pic.ScreenLoad ("snakehead2.1.jpg", 0, 120, picMerge)
Font.Draw ("Snake Remix", x1, y1, font1, 9)
View.Update
delay (200)
%MAKE TITLE MOVE UP AND GET BIGGER
loop
y1 += 20
x1 -= 15
s1 += 3
font2 := Font.New ("arial:" + intstr (s1) + ":bold")
Font.Draw ("Snake Remix", x1, y1, font2, 9)
View.Update
Font.Free (font2)
delay (10)
exit when s1 = 60
end loop
font2 := Font.New ("arial:" + intstr (s1) + ":bold")
Font.Draw ("Snake Remix", x1, y1, font2, 10)
%Make Screen flash and then names appear
%takes picture of the screen so it can be re-drawn after the flash
screenHist := Pic.New (1, 1, 799, 599)
cls
View.Update
Draw.FillBox (0, 0, 800, 600, yellow)
View.Update
delay (50)
Pic.Draw (screenHist, 0, 0, picMerge)
View.Update
Font.Draw ("By: Josh Rosen and Misha Veprinsky", 150, 40, font1, 9)
View.Update
delay (2000)
Font.Draw ("Press Enter to Continue", 300, 140, font3, 9)
View.Update
Input.Pause
return
end title_screen
%call the procedure
title_screen
|