News: Welcome back to Bullworth! If you haven't already, you will need to reset your password..


Author Topic: How do I set timer?  (Read 1185 times)

0 Members and 1 Guest are viewing this topic.

Offline UltimateGamer9

  • Full Member
  • ***
  • Posts: 190
  • Gender: Male
    • View Profile
How do I set timer?
« on: September 04, 2015, 11:37:33 AM »
How do I make a clock appear and set timers in it? I will do this in my mission.

Offline Unknownsoldier

  • Hero Member
  • ****
  • Posts: 2,773
    • View Profile
Re: How do I set timer?
« Reply #1 on: September 04, 2015, 12:42:21 PM »
  LawnMowingSetTimer(timerSpeed)
  MissionTimerStart(timerSpeed)
  MinigameStart()
  MinigameEnableHUD(true)


u can replace "timerSpeed" with the speed u want for ur timer. 200 is REALLY slow. i think somewhere in like 98 should do it idk. here's an example of it being used:

Code: [Select]
local l_time = 200 -- timer speed

function MissionSetup()
  AreaTransitionXYZ(0, 270, -110, 6)
  LawnMowingSetTimer(l_time)
  MissionTimerStart(l_time)
  MinigameStart()
  MinigameEnableHUD(true)
end

function MissionCleanup()
  gMissionRunning = false
  collectgarbage()
end

function main()
  gMissionRunning = true
  while gMissionRunning do
    Wait(0)
  end
end

i just found out how to do this stuff literally 10 minutes ago, so i still need to mess around with it and find more stuff.