aboutsummaryrefslogtreecommitdiff
path: root/ui.lua
diff options
context:
space:
mode:
authorRibbon <ambiguousmachine@gmail.com>2022-02-11 09:52:06 -0800
committerRibbon <ambiguousmachine@gmail.com>2022-02-11 09:52:06 -0800
commitba21794f28d67f2be5c3154fa3d30b114fd6c37c (patch)
tree41be6cc844a5e57c319decc4c6c09f058b3a483c /ui.lua
parent2debf09efb92513ef69bfdcf6120bf2d1a9725a7 (diff)
moved sprites, updated text on title screen, added mock up of high score display
also made some edits to sfx channels
Diffstat (limited to 'ui.lua')
-rw-r--r--ui.lua102
1 files changed, 64 insertions, 38 deletions
diff --git a/ui.lua b/ui.lua
index e53f59c..1709885 100644
--- a/ui.lua
+++ b/ui.lua
@@ -1,5 +1,31 @@
menuscroll = 0
menushipscroll = 0
+
+function invaderslogotext(x,y)
+ --default values
+ -- x = 12
+ -- y = 20
+
+ --font
+ local text = "i n v a d e r s"
+ print(text, x, y+1, 3)
+ print(text, x, y-1, 3)
+ print(text, x+1, y, 3)
+ print(text, x-1, y, 3)
+ print(text, x-1, y+1, 3)
+ print(text, x+1, y+1, 3)
+ print(text, x-1, y-1, 3)
+ print(text, x+1, y-1, 3)
+ print(text, x+1, y+1, 3)
+ print(text, x-1, y+2, 3)
+ print(text, x+1, y+2, 3)
+ print(text, x, y+2, 3)
+ print(text, x, y, 14)
+ clip(x, y, 60, 3)
+ print(text, x, y, 11)
+ clip()
+end
+
function drawlogo(x,y)
--default values
-- x = 24
@@ -7,38 +33,17 @@ function drawlogo(x,y)
--this is a horrible way to draw the logo, but I'm doing it anyways. x3
-- muahahahahahahaha!!!!!!
- sspr(0,24,16,8,x-1,y+2,32,16) --to shadow
- sspr(16,24,8,8,x+53,y+2,16,16) --ic shadow
- sspr(0,24,16,8,x-1,y+1,32,16) --to
- sspr(16,24,8,8,x+53,y+1,16,16) --ic
- --X shadow
- sspr(24,24,8,8,x+26,y-6,16,16)
- sspr(24,24,8,8,x+42,y-6,16,16,true)
- sspr(32,24,8,8,x+26,y+10,16,16, true)
- sspr(32,24,8,8,x+42,y+10,16,16)
+ sspr(16,24,16,8,x-3,y+2,32,16) --to shadow
+ sspr(16,24,16,8,x-3,y,32,16) --to
+ sspr(48,24,8,8,x+55,y+2,16,16) --ic shadow
+ sspr(48,24,8,8,x+55,y,16,16) --ic
--X
- sspr(24,24,8,8,x+26,y-8,16,16)
- sspr(24,24,8,8,x+42,y-8,16,16,true)
- sspr(32,24,8,8,x+26,y+8,16,16, true)
- sspr(32,24,8,8,x+42,y+8,16,16)
- --font
- local text = "i n v a d e r s"
- print(text, x+10, y+21, 3)
- print(text, x+10, y+19, 3)
- print(text, x+11, y+20, 3)
- print(text, x+9, y+20, 3)
- print(text, x+9, y+21, 3)
- print(text, x+11, y+21, 3)
- print(text, x+9, y+19, 3)
- print(text, x+11, y+19, 3)
- print(text, x+11, y+21, 3)
- print(text, x+9, y+22, 3)
- print(text, x+11, y+22, 3)
- print(text, x+10, y+22, 3)
- print(text, x+10, y+20, 14)
- clip(x+10, y+20, 60, 3)
- print(text, x+10, y+20, 11)
- clip()
+ sspr(32,24,8,8,x+26,y-9,16,16)
+ sspr(32,24,8,8,x+42,y-9,16,16,true)
+ sspr(40,24,8,8,x+26,y+7,16,16, true)
+ sspr(40,24,8,8,x+42,y+7,16,16)
+ --invaders
+ invaderslogotext(x+12,y+20)
end
function mainmenutext(x,y)
@@ -56,6 +61,21 @@ function mainmenutext(x,y)
print("(\151) - companion", x+15,y+17,6)
end
+function titlehighscores(x,y)
+ -- default values
+ -- 52
+ -- 110
+
+ --1P high score
+ print("000000", x-20,y+1,15)
+ print("000000", x-20,y,12)
+ print("-", x+10,y+1,5)
+ print("-", x+10,y,6)
+ --2P high score
+ print("000000", x+20,y+1,2)
+ print("000000", x+20,y,9)
+end
+
function credits(x,y)
-- default vaues
-- x = 10
@@ -63,19 +83,25 @@ function credits(x,y)
palt(2,true)
palt(0,false)
- spr(53,x-4,y+6+sin(t())*2,1,1,(t()%2<1)) --duck
- --pset(x+3,y+10+sin(t())*2,13) --extra dot for glasses
- spr(54,x+104,y+6+cos(t())*2,1,1,(t()%2<1)) --bot
+ spr(48,x-4,y+6+sin(t())*2,1,1,(t()%2<1)) --duck
+ spr(49,x+104,y+6+cos(t())*2,1,1,(t()%2<1)) --bot
palt(2,false)
palt(0,true)
- print("1029chris ribboncable", x+9,y+6,0)
- print("1029chris ribboncable", x+9,y+5,9)
- print("code/tunes art/sounds", x+8,y+13,0)
- print("code/tunes art/sounds", x+8,y+12,9)
+ print("1029chris", x+10,y+6,2)
+ print("1029chris", x+10,y+5,9)
+ print("ribboncable", x+56,y+6,15)
+ print("ribboncable", x+56,y+5,12)
+ print("code tunes", x+8,y+13,3)
+ print("code tunes", x+8,y+12,11)
+ print("sprites sfx", x+56,y+13,3)
+ print("sprites sfx", x+56,y+12,11)
+
-- print("made in vancouver - 2022", x+6,y+22,0)
-- print("made in vancouver - 2022", x+6,y+21,4)
end
+--sfx for the intro transition
+sfx(13,3)
-- drawlogo(24,26)
-- mainmenutext(24,62)