It looks like you're new here. If you want to get involved, click one of these buttons!
Steps for competiting:
-- Push Ups
function setup()
--- AMOUNT OF PUSH UPS ---
n = 0
--- SYSTEM DATA - TOUCH, DISPLAY, ... ---
touching = false
col = color(72, 189, 64, 255) -- You can change this.
displayMode(FULLSCREEN)
--- SECURITY OF ACCIDENTAL DOUBLE TOUCH ---
pauseNeeded = 50 -- You can change this.
pause = pauseNeeded
canDoNext = true
--- GIVE UP ---
letterList = {}
local DEMOTIVATION = "Give up!"
for x = 1, #DEMOTIVATION do
table.insert(letterList, Letter(string.sub(DEMOTIVATION, x, x), WIDTH*.5+(x-#DEMOTIVATION/2)*25, HEIGHT*.1))
end
--- MOTIVATING STRINGS EVERY N PUSH UPS ---
motivationStrings = {"Come on! You can do it!", "Don't give up! One more!", "You're not done yet!", "You just started!", "The crowd applouses...", "You didn't even become red, yet!!", "We trust in you!"} -- You can change this.
pushUpsForMotivation = 5 -- You can change this.
motivationID = 1
end
function draw()
fill(col)
background(0)
if touching then
rect(0, 0, WIDTH, HEIGHT)
end
if n > 0 then
fontSize(85)
font("AmericanTypewriter")
text(n, WIDTH*.5, HEIGHT*.5)
for a, b in ipairs(letterList) do
b:draw()
end
if n%pushUpsForMotivation == 0 then
font("SourceSansPro-Regular")
text(motivationStrings[motivationID], WIDTH*.5, HEIGHT*.35)
else
motivationID = math.random(1, pushUpsForMotivation)
end
end
if not canDoNext then
pause = pause - 1
if pause < 0 then
canDoNext = true
end
end
end
function touched(t)
if t.state == BEGAN then
touching = true
elseif t.state == ENDED then
if t.y < HEIGHT*.2 then
setup()
return
end
touching = false
if canDoNext then
n = n + 1
canDoNext = false
pause = pauseNeeded
end
end
end
Letter = class()
function Letter:init(letter, x, y)
self.string = letter
self.pos = vec2(x, y)
self.fontSize = 50 -- You can change this
self.rotRandom = math.random(1, 10)
self.xRandom = math.random(1, 10)
self.yRandom = math.random(1, 10)
end
function Letter:draw()
fontSize(self.fontSize)
font("GillSans")
ROTATION = 15*math.sin(ElapsedTime*self.rotRandom*n/10)
X_MODIFIER = 15*math.sin(ElapsedTime*self.xRandom*n/10)
Y_MODIFIER = 15*math.sin(ElapsedTime*self.yRandom*n/10)
translate(self.pos.x + X_MODIFIER, self.pos.y + Y_MODIFIER)
rotate(ROTATION)
text(self.string, 0, 0)
rotate(-ROTATION)
translate(-self.pos.x - X_MODIFIER, -self.pos.y - Y_MODIFIER)
end
https://i.imgur.com/2uoUYv5.jpg
https://i.imgur.com/c3BjGD5.jpg
You can develop the project to your own new game!
Of course, be pleased to share your score, but pay attention, if you release a picture with your face, it cannot be undone!
Comments
@TokOut This is interesting, but I guess this would have to be done on the honor system. I can sit on the couch and bring the iPad to my nose a lot more than if I actually did pushups.
Of course! But in our community, everyone is full of honor! Another developer would just change the
n = 0
ton = 99
Btw. I made the project for you, guys! I know developers sitting all day and enjoying the code from my experience about me! But let’s take a small break and join the challenge
Edit: Those two pictures above ^ are two different hunts, the first one was just to demonstrate what to do, then I started it actually. What you see there with the 37 is after some long minute!
and sadly my current Highscore 
@TokOut this is so cool, will give it a try later and post my score. I love what you've done with the animated text at the bottom of the screen
@Simeon, yeah, thought would be cool. Btw. I think it’s possible to do the same somehow faster, I just don’t get yet how. Also to make the letters be completely random on their curve, I’ll need to make a formula based of two
math.sin
s where one contains an irrational factor, and the other a natural. I just hadn’t time yet, due to school and other stuffUpdate
Attention! This is not a push up challenge but a contribution to Simeon’s favorite part of the code.
Hi @Simeon, so I’ve made here the code for you to play around a bit
I hope you love it 
I can think of a “read the message” codea game or something based of this
@TokOut really nice effect, I like seeing these sorts of transformations applied to individual letters in text.
I see you have a fixed character spacing of 25 so I tried to modify your code to use the substring length to position the next character. It's not perfect but you get slightly better character alignment.
I also used retained backing mode to add some motion blur