Re: NUMBERF/CKER (formerly Numberwang) - math game (not 2048
Posted: Fri Jul 17, 2015 9:45 am
DAMN. Good job on that.
Damn, congrats.micha wrote:Boom!Nicely done. I like the sweeping animation.
That sounds pretty interesting, could you elaborate how it works and/or show some code for it?VideahGams wrote:For funsies, I'm writing a crappy little bot for this.
I need to rethink some of the logic for the bot, but it can get around 60-80 points.
Sure!Guard13007 wrote:That sounds pretty interesting, could you elaborate how it works and/or show some code for it?
Code: Select all
board = {}
size_w = 3
size_h = 3
n = 0
min, max = 1, 9
gameover = false
biggest_x, biggest_y = 0, 0
bigfont = love.graphics.newFont("swag/Junction-bold.otf", 25)
smallfont = love.graphics.newFont("swag/Junction-bold.otf", 32)
bg = {0, 0, 0}--{255, 60, 60}--
anim_from_x, anim_from_y = 0, 0
anim_to_x, anim_to_y = 0, 0
anim_from, anim_to = 0, 0
anim_dt = 0
anim_time = 0.35
anim_after = nil
Code: Select all
function love.load()
io.stdout:setvbuf("no")
generate()
require 'NFBot'
end
Code: Select all
local originalDraw = love.draw -- Get NumberFuckers draw function.
local originalUpdate = love.update -- Get NumberFuckers update function.
function love.draw()
originalDraw()
-- We can draw our own stuff here.
end
function love.update(dt)
originalUpdate(dt)
-- We can do our own logic here.
end