Text Size
Text Size
Exit Full Screen
Python Mini
Show
Source Code
View Source Code in Full Screen
Open in New Tab
from processing import * from random import randint, choice animations = { "0.02":0, "bookIn":[20,18,16,14,12,10,8,6,4,2+30],#110 total "bookNow":110, "bookList":0, "page":0, } catchData = { "zone":206, "gauge":234, "measure":50, "direction":"up", } #167-177: orange #160-166: yellow #150: perfect #141-159: green #134-140: yellow #123-133: orange class Bobber: instances = [] def __init__(self,x,y,vx=0,vy=0,stx=None,sty=None): self.x = x self.y = y self.vx = vx self.vy = vy self.stx = stx self.sty = sty Bobber.instances.append(self) class Fish: def __init__(self,name,diff,image,points,diff2,diff3,note): self.name = name self.diff = diff self.image = image self.points = points self.diff2 = diff2 self.diff3 = diff3 self.note = note class Reel: def __init__(self,name,style,image): self.name = name self.style = style self.image = image def setup(): global trout, bassorc, bass, sardine, tuna, squid, salmon, pufferfish, clownfish, eel, shrimp, sunfish trout = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-1.png") bassorc = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-2.png") bass = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-3.png") sardine = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-4.png") tuna = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-5.png") squid = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-6.png") salmon = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-7.png") pufferfish = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-8.png") clownfish = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-9.png") eel = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-10.png") shrimp = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-11.png") sunfish = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fish-12.png") global Starlight, Whirler Starlight = Reel("Starlight",0,None) Whirler = Reel("Whirler",1,None) global Trout, BassOrc, Bass, Sardine, Tuna, Squid, Salmon, Pufferfish, Clownfish, Eel, Shrimp, Sunfish Trout = Fish("Trout",0,trout,10,0,0,":) i like this one") BassOrc = Fish("Bass (Orchestral)",6,bassorc,200,0,0,'"And this time, with passion!"') Bass = Fish("Bass",2,bass,100,0.1,0.4,"At least a C+.") Sardine = Fish("Sardine",0,sardine,5,-0.2,0.2,"hehe tiny") Tuna = Fish("Tuna",1.5,tuna,40,0.2,0.3,"You can tune a piano...") Squid = Fish("Squid",8,squid,250,0,0.5,"are you a squid or a kid... definitely a squid") Salmon = Fish("Salmon",3,salmon,70,0,0.5,"insert funny quote here") Pufferfish = Fish("Pufferfish",3,pufferfish,90,0.5,-0.2,"+carrot") Clownfish = Fish("Clownfish",1,clownfish,40,0.3,0.5,"You're the entire circusfish") Eel = Fish("Eel",5,eel,70,0.2,0.3,"looooooong") Shrimp = Fish("Shrimp",0,shrimp,23.626341223,0.5,0.5,"are you going to eat that?") Sunfish = Fish("Sunfish",2,sunfish,87,0.2,0.2,"square?") global red, green, yellow, orange, perfect red = [Trout,Sardine,Sardine,Sardine,Trout,Shrimp,Trout,Trout,Salmon] orange = [Tuna,Sardine,Tuna,Pufferfish,Sunfish,Trout,Shrimp,Shrimp,Pufferfish,Salmon] yellow = [Shrimp,Sunfish,Pufferfish,Clownfish,Eel,Eel,Salmon] green = [Trout,BassOrc,BassOrc,Clownfish,Bass,Bass,Salmon] perfect = [BassOrc,Bass,Tuna,Bass,Squid,Squid,Squid,BassOrc,Salmon] size(500,500) global stage, randomtimer, secondrandomtimer, fishType, stored, usingReel, radarOn stage = 0 randomtimer = 0 secondrandomtimer = 0 fishType = 0 stored = 0 usingReel = Starlight radarOn = False global waterTop1, waterTop2, water1, water2, waterEdge, water waterTop1 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/water-1.png") waterTop2 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/water-2.png") water1 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/water-3.png") water2 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/water-4.png") waterEdge = [waterTop1,waterTop2] water = [water1,water2] global dock1, dock2, dock dock1 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Dock-4.png") dock2 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Dock-5.png") dock = [dock1,dock2] global fisherIdle1, fisherIdle2, fisherIdle fisherIdle1 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fisher-1.png") fisherIdle2 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fisher-2.png") fisherIdle = [fisherIdle1, fisherIdle2] global fisherStart1, fisherStart2, fisherStart3, fisherStart, fisherCatch fisherStart1 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fisher-3.png") fisherStart2 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fisher-4.png") fisherStart3 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fisher-5.png") fisherCatch = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/fisher-6.png") fisherStart = [fisherStart1,fisherStart2,fisherStart3,fisherStart3,fisherStart2] global barPower, gauge, barCatch, catchZone, catchGauge barPower = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-1.png") gauge = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-2.png") barCatch = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-3.png") catchZone = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-4.png") catchGauge = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-5.png") global arrowUp, arrowLeft, arrowDown, arrowRight, barEmpty arrowUp = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-6.png") arrowLeft = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-7.png") arrowDown = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-8.png") arrowRight = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-9.png") barEmpty = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/bar-10.png") global bookData, bookClosed, bookE, bookIcon, book1, book2, book3, bookIconClosed bookData = [] bookClosed = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-1.png") bookE = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-2.png") bookIcon = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-3.png") bookIconClosed = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-4.png") book1 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-5.png") book2 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-6.png") book3 = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-11.png") global shopOff, shop, shopUse, shopCheck shopOff = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-7.png") shop = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-8.png") shopUse = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-9.png") shopCheck = loadImage("https://oyohub.s3.amazonaws.com/spriteeditor/projects/59ff7bf1ca292c38749df130/Compendium-10.png") global cheatcode, redamt cheatcode = "" redamt = 156 def keyPressed(): global stage, randomtimer, fishType, cheatcode if keyboard.key == " ": if stage == 0: stage = 1 if stage == 2: randomtimer = 4 if stage == 4: stage = -2 if stage == -1: stage = 1 randomtimer = 2 if stage == 5: stage = 6 if secondrandomtimer == 150: fishType = choice(perfect) elif secondrandomtimer >= 141 and secondrandomtimer <= 159: fishType = choice(green) elif secondrandomtimer >= 134 and secondrandomtimer <= 166: fishType = choice(yellow) elif secondrandomtimer >= 123 and secondrandomtimer <= 177: fishType = choice(orange) else: fishType = choice(red) cheatcode += keyboard.key def mousePressed(): global stage, fishType, usingReel, radarOn if mouse.x > 420 and mouse.y < 80: if stage == -1 or stage == 0: stage = -5 if stage == -4 or stage == -3 or stage == -7: stage = -1 if stage == -4: if animations["page"] == 0: if "Trout" in bookData: if mouse.x > 50 and mouse.y > 50 and mouse.x < 250 and mouse.y < 170: fishType = Trout stage = -3 if "Bass" in bookData: if mouse.x > 50 and mouse.y > 170 and mouse.x < 250 and mouse.y < 290: fishType = Bass stage = -3 if "Bass (Orchestral)" in bookData: if mouse.x > 300 and mouse.y > 50 and mouse.x < 420 and mouse.y < 330: fishType = BassOrc stage = -3 if mouse.x > 370 and mouse.y > 380 and mouse.x < 430 and mouse.y < 440: animations["page"] += 1 elif animations["page"] == 1: if mouse.x > 70 and mouse.y > 380 and mouse.x < 130 and mouse.y < 440: animations["page"] -= 1 if mouse.x > 370 and mouse.y > 380 and mouse.x < 430 and mouse.y < 440: animations["page"] += 1 if "Sardine" in bookData: if mouse.x > 50 and mouse.y > 50 and mouse.x < 200 and mouse.y < 130: fishType = Sardine stage = -3 if "Tuna" in bookData: if mouse.x > 60 and mouse.y > 150 and mouse.x < 140 and mouse.y < 300: fishType = Tuna stage = -3 if "Salmon" in bookData: if mouse.x > 140 and mouse.y > 150 and mouse.x < 240 and mouse.y < 400: fishType = Salmon stage = -3 if "Squid" in bookData: if mouse.x > 270 and mouse.y > 60 and mouse.x < 410 and mouse.y < 380: fishType = Squid stage = -3 elif animations["page"] == 2: if mouse.x > 70 and mouse.y > 380 and mouse.x < 130 and mouse.y < 440: animations["page"] -= 1 if "Pufferfish" in bookData: if mouse.x > 80 and mouse.y > 50 and mouse.x < 200 and mouse.y < 170: fishType = Pufferfish stage = -3 if "Clownfish" in bookData: if mouse.x > 55 and mouse.y > 170 and mouse.x < 230 and mouse.y < 285: fishType = Clownfish stage = -3 if "Eel" in bookData: if mouse.x > 55 and mouse.y > 285 and mouse.x < 240 and mouse.y < 380: fishType = Eel stage = -3 if "Shrimp" in bookData: if mouse.x > 300 and mouse.y > 60 and mouse.x < 410 and mouse.y < 170: fishType = Shrimp stage = -3 if "Sunfish" in bookData: if mouse.x > 280 and mouse.y > 170 and mouse.x < 430 and mouse.y < 340: fishType = Sunfish stage = -3 if stage == -3: if mouse.x > 70 and mouse.y > 380 and mouse.x < 130 and mouse.y < 440: stage = -4 if mouse.x > 420 and mouse.y > 80 and mouse.y < 150: if stage == -1 or stage == 0: stage = -6 if stage == -7: if mouse.x > 70 and mouse.y > 225 and mouse.x < 160 and mouse.y < 285: usingReel = Starlight if mouse.x > 315 and mouse.y > 225 and mouse.x < 405 and mouse.y < 285: usingReel = Whirler if mouse.x > 195 and mouse.y > 205 and mouse.x < 285 and mouse.y < 265: if radarOn: radarOn = False else: radarOn = True def reel(): Bobber.instances[0].x = hone(Bobber.instances[0].x,265,5) Bobber.instances[0].y = hone(Bobber.instances[0].y,270,5) def catch(reel): global stage if radarOn: text(fishType.name,300,50) if reel.style == 0: if keyboard.keyCode == 32: catchData["gauge"] += 2 + fishType.diff else: catchData["gauge"] -= 4 image(barCatch,300,100,60,160) pushMatrix() rectMode(CORNERS) rect(331,249-catchData["measure"],342,249)#110-249 popMatrix() image(catchZone,300,catchData["zone"],60,160)#starlight: 100-206 image(catchGauge,300,catchData["gauge"],60,160)#starlight: 100-234 if catchData["gauge"] > 234: catchData["gauge"] = 234 if catchData["gauge"] < 100: catchData["gauge"] = 100 if catchData["direction"] == "up": catchData["zone"] -= 1 else: catchData["zone"] += 1 if catchData["zone"] > 206: catchData["direction"] = "up" if catchData["zone"] < 100: catchData["direction"] = "down" if catchData["gauge"] >= catchData["zone"] and catchData["gauge"] <= catchData["zone"] + 28: catchData["measure"] += 1.0 - fishType.diff2#139 max else: catchData["measure"] -= 0.5 + fishType.diff3 if catchData["measure"] > 139: stage = 7 elif catchData["measure"] < 0: stage = -2 if reel.style == 1: if catchData["direction"] == "up": image(arrowUp,250,20,120,320) if keyboard.keyCode == 38: catchData["direction"] = "left" catchData["measure"] += 5.0 - (fishType.diff2/2) elif catchData["direction"] == "left": image(arrowLeft,250,20,120,320) if keyboard.keyCode == 37: catchData["direction"] = "down" catchData["measure"] += 5.0 - (fishType.diff2/2) elif catchData["direction"] == "down": image(arrowDown,250,20,120,320) if keyboard.keyCode == 40: catchData["direction"] = "right" catchData["measure"] += 5.0 - (fishType.diff2/2) elif catchData["direction"] == "right": image(arrowRight,250,20,120,320) if keyboard.keyCode == 39: catchData["direction"] = "up" catchData["measure"] += 5.0 - (fishType.diff2/2) catchData["measure"] -= 0.2 + (fishType.diff3/2) + (fishType.diff/8) image(barEmpty,400,100,60,160) pushMatrix() rectMode(CORNERS) rect(424,249-catchData["measure"],434,249)#110-249 popMatrix() if catchData["measure"] > 139: stage = 7 elif catchData["measure"] < 0: stage = -2 def hone(var,target,step): if var < step+target and var > target-step and var != target: var = target elif var > target: var -= step elif var < target: var += step return var def draw(): global stage, randomtimer, secondrandomtimer, fishType, stored, catchData, catchDataBackup, bookData, redamt, cheatcode animations["0.02"] += 0.02 if animations["0.02"] > 2: animations["0.02"] = 0 background(redamt, 210, 255) #text(animations["page"],10,10) #text(stage,10,20) #text(secondrandomtimer,10,30) if stage == -1 or stage == 0: image(bookIcon,0,0,500,500) for i in range(10): image(waterEdge[int(animations["0.02"])],i*50,334,50,50) for i in range(10): for j in range(3): image(water[int(animations["0.02"])],i*50,384+j*50,50,50) image(dock[int(animations["0.02"])],300,300,200,120) fill(255,0,0) for i in Bobber.instances: ellipse(i.x,i.y,10,10) if cheatcode == "givemeallofthefish": bookData = ["Trout", "Bass", "Bass (Orchestral)", "Sardine", "Tuna", "Salmon", "Squid", "Pufferfish", "Clownfish", "Eel", "Shrimp", "Sunfish"] redamt = 255 cheatcode = "a" if redamt > 156: redamt -= 1 if stage == 0: image(fisherIdle[int(animations["0.02"])],250,250,120,120) elif stage == -2: image(fisherStart2,250,250,120,120) stroke(255) line(Bobber.instances[0].x,Bobber.instances[0].y,265,260) stroke(0) reel() randomtimer = 0 secondrandomtimer = 0 catchData["measure"] = 50 catchData["zone"] = 206 catchData["gauge"] = 234 catchData["direction"] = "up" if Bobber.instances[0].x == 265 and Bobber.instances[0].y == 270: stage = -1 del Bobber.instances[0] elif stage == -1: image(fisherStart2,250,250,120,120) animations["bookNow"] = 110 animations["bookList"] = 0 animations["page"] = 0 randomtimer = 0 secondrandomtimer = 0 catchData["zone"] = 206 catchData["gauge"] = 234 catchData["measure"] = 50 catchData["direction"] = "up" elif stage == 1: image(fisherStart[int(randomtimer)],250,250,120,120) randomtimer += 0.02 if randomtimer > 2: stage = 2 Bobber(360,265) elif stage == 2: image(fisherStart[int(randomtimer)],250,250,120,120) stroke(255) line(Bobber.instances[0].x,Bobber.instances[0].y,360,255) stroke(0) randomtimer += 0.02 secondrandomtimer += 6 image(barPower,300,100,60,160) image(gauge,300,-50+secondrandomtimer,60,160) if randomtimer > 4: stage = 3 Bobber.instances[0].x = 265 Bobber.instances[0].y = 260 Bobber.instances[0].vx = randint(-6,-3) Bobber.instances[0].vy = randint(-15,-5) Bobber.instances[0].sty = randint(380,430) elif stage == 3: image(fisherStart[int(randomtimer)],250,250,120,120) stroke(255) line(Bobber.instances[0].x,Bobber.instances[0].y,265,260) stroke(0) Bobber.instances[0].x += Bobber.instances[0].vx Bobber.instances[0].y += Bobber.instances[0].vy Bobber.instances[0].vy += 1 image(barPower,300,100,60,160) image(gauge,300,-50+secondrandomtimer,60,160) if Bobber.instances[0].y > Bobber.instances[0].sty: stage = 4 Bobber.instances[0].vx /= 2 Bobber.instances[0].vy /= 10 randomtimer = 0 stored = randint(100,1000) elif stage == 4: image(fisherStart2,250,250,120,120) stroke(255) line(Bobber.instances[0].x,Bobber.instances[0].y,265,260) stroke(0) Bobber.instances[0].vx = hone(Bobber.instances[0].vx, 0, 0.1) Bobber.instances[0].vy = hone(Bobber.instances[0].vy, 0, 0.1) Bobber.instances[0].x += Bobber.instances[0].vx Bobber.instances[0].y += Bobber.instances[0].vy randomtimer += 1 if randomtimer > stored: stage = 5 randomtimer = 0 Bobber.instances[0].vy = 8 elif stage == 5: image(fisherStart2,250,250,120,120) Bobber.instances[0].vy -= 0.6 Bobber.instances[0].y += Bobber.instances[0].vy stroke(255) line(Bobber.instances[0].x,Bobber.instances[0].y,265,260) stroke(0) if Bobber.instances[0].y < Bobber.instances[0].sty: stage = 4 randomtimer = 0 Bobber.instances[0].y = Bobber.instances[0].sty Bobber.instances[0].vy = 0 elif stage == 6: image(fisherCatch,250,250,120,120) stroke(255) line(Bobber.instances[0].x,Bobber.instances[0].y,260,255) stroke(0) catch(usingReel) elif stage == 7: image(fisherStart3,250,250,120,120) stroke(255) line(Bobber.instances[0].x,Bobber.instances[0].y,360,255) stroke(0) Bobber.instances[0].x = hone(Bobber.instances[0].x,360,5) Bobber.instances[0].y = hone(Bobber.instances[0].y,255,5) imageMode(CENTER) image(fishType.image,Bobber.instances[0].x,Bobber.instances[0].y+10,64,32) imageMode(CORNER) if Bobber.instances[0].x == 360 and Bobber.instances[0].y == 255: stage = -3 del Bobber.instances[0] elif stage == -3: image(fisherStart2,250,250,120,120) if animations["bookNow"] > 0: image(bookClosed,0,0-animations["bookNow"],500,500) animations["bookNow"] -= animations["bookIn"][animations["bookList"]] animations["bookList"] += 1 elif animations["bookNow"] < 0: image(bookClosed,0,0,500,500) animations["bookNow"] += 1 elif animations["bookNow"] == 0: image(bookE,0,0,500,500) imageMode(CENTER) image(fishType.image,250,150,300,150) imageMode(CORNER) textAlign(CENTER) fill(0) textSize(50) text(fishType.name,250,250) textSize(20) text(fishType.note,250,300) textSize(25) text("Points: "+str(fishType.points),250,400) image(bookIconClosed,0,0,500,500) if fishType.name not in bookData: bookData.append(fishType.name) elif stage == -5: if animations["bookNow"] > 0: image(bookClosed,0,0-animations["bookNow"],500,500) animations["bookNow"] -= animations["bookIn"][animations["bookList"]] animations["bookList"] += 1 elif animations["bookNow"] < 0: image(bookClosed,0,0,500,500) animations["bookNow"] += 1 elif animations["bookNow"] == 0: stage = -4 elif stage == -4: if animations["page"] == 0: image(book1,0,0,500,500) if "Trout" in bookData: image(trout,-10,35,320,160) if "Bass" in bookData: image(bass,-10,150,320,160) if "Bass (Orchestral)" in bookData: pushMatrix() translate(440,15) rotate(TAU/4) image(bassorc,0,0,320,160) popMatrix() if animations["page"] == 1: image(book2,0,0,500,500) if "Sardine" in bookData: image(sardine,-35,10,320,160) if "Tuna" in bookData: pushMatrix() translate(180,75) rotate(TAU/4) image(tuna,0,0,320,160) popMatrix() if "Salmon" in bookData: pushMatrix() translate(270,105) rotate(TAU/4) image(salmon,0,0,320,160) popMatrix() if "Squid" in bookData: pushMatrix() translate(420,60) rotate(TAU/4) image(squid,0,0,320,160) popMatrix() if animations["page"] == 2: image(book3,0,0,500,500) if "Pufferfish" in bookData: image(pufferfish,-15,35,320,160) if "Clownfish" in bookData: image(clownfish,-15,145,320,160) if "Eel" in bookData: image(eel,-10,250,320,160) if "Shrimp" in bookData: image(shrimp,195,35,320,160) if "Sunfish" in bookData: image(sunfish,195,175,320,160) image(bookIconClosed,0,0,500,500) elif stage == -6: if animations["bookNow"] > 0: image(shopOff,0,0-animations["bookNow"],500,500) animations["bookNow"] -= animations["bookIn"][animations["bookList"]] animations["bookList"] += 1 elif animations["bookNow"] < 0: image(shopOff,0,0,500,500) animations["bookNow"] += 1 elif animations["bookNow"] == 0: stage = -7 elif stage == -7: image(shop,0,0,500,500) if usingReel == Starlight: image(shopCheck,-135,5,500,500) image(shopUse,110,5,500,500) else: image(shopUse,-135,5,500,500) image(shopCheck,110,5,500,500) if radarOn: image(shopCheck,-10,-15,500,500) else: image(shopUse,-10,-15,500,500) image(bookIconClosed,0,0,500,500) #fill(0xff0000ff,127) #rectMode(CORNERS) #rect(0,60,500,380) run()
fishingminigame.py
( around 567 lines python code )
Published By:
luyfru
Published on
2023-09-21T19:15:48Z
Python Mini
- an
OYOclass
application,
own your own class today
.
Run
Result
×
Error message shows here