Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
If you are using the 'entities', you could do something like:
=========
game.full_timer = 300
game.moving_thing = game.new_entity(
  :moving_thing,
  x: rand * 1279,
  y: rand * 719,
  timer: game.full_timer
)
=========
Then in your tick:
========= game.moving_thing.timer -= 1
if game.moving_time.timer <0
  game.moving_thing.x = rand * 1279
  game.moving_thing.y = rand * 719
end
=========
Then if your mouse click is detected on the `moving_thing` reduce game.full_timer to something smaller.