Browse Source

oops, restoring pixel display code

pixelbath 3 years ago
parent
commit
5a54ecef85
1 changed files with 43 additions and 1 deletions
  1. 43 1
      alter-ego-by-kyuchumimo.lua

+ 43 - 1
alter-ego-by-kyuchumimo.lua

@@ -515,8 +515,50 @@ function TIC()
 		cls()
         particleupdate()
         particledraw()
-		map(30*m%240,17*(m//8),30,17,0,0,0,1)
+		map(30*m%240,17*(m//8),30,17,0,0,0,1,
+			function(tile)
+				if tile>=80 and tile<=111 and anix==0 and aniy==0 and px==0 and aepx==0 then
+					return tile*(t%38//19)
+				end
+				if tile==6 or tile==22 or tile==38 or tile==54 or tile==8 or tile==24 then
+					return tile+(t%38//19)
+				else
+					if tile~=6 and tile~=22 and tile~=38 and tile~=54 and tile~=8 and tile~=24 and not (tile>=64 and tile<=79) then return tile end
+				end
+			end
+		)
     
+	--PIXELS DISPLAY
+	map(30*m%240,17*(m//8),30,17,0,0,0,1,
+		function(tile)
+			if tile==64 or tile==72 then
+				print(t%20//2.5, 2, 120)
+				return tile+(t%20//2.5)
+			end
+			if tile==65 or tile==73 then
+				return tile+(((t+2.5)%20//2.5)-1)
+			end
+			if tile==66 or tile==74 then
+				return tile+(((t+5)%20//2.5)-2)
+			end
+			if tile==67 or tile==75 then
+				return tile+(((t+7.5)%20//2.5)-3)
+			end
+			if tile==68 or tile==76 then
+				return tile+(((t+10)%20//2.5)-4)
+			end
+			if tile==69 or tile==77 then
+				return tile+(((t+12.5)%20//2.5)-5)
+			end
+			if tile==70 or tile==78 then
+				return tile+(((t+15)%20//2.5)-6)
+			end
+			if tile==71 or tile==79 then
+				return tile+(((t+17.5)%20//2.5)-7)
+			end
+		end
+	)
+
 	--SKULLH LIMITS(1-28,1-14)
 	--skullh(12,10,0,0)
 	--if btn(5) then	skullh(25,3,0,0) end