mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-27 07:08:00 +01:00
Merge conflict fix
This commit is contained in:
@@ -8,6 +8,8 @@
|
||||
|
||||
var/timing = 0
|
||||
var/time = 5
|
||||
var/saved_time = 5
|
||||
var/loop = 0
|
||||
|
||||
|
||||
/obj/item/device/assembly/timer/New()
|
||||
@@ -47,6 +49,8 @@
|
||||
cooldown = 2
|
||||
spawn(10)
|
||||
process_cooldown()
|
||||
if(loop)
|
||||
timing = 1
|
||||
update_icon()
|
||||
|
||||
|
||||
@@ -56,7 +60,7 @@
|
||||
if(time <= 0)
|
||||
timing = 0
|
||||
timer_end()
|
||||
time = initial(time)
|
||||
time = saved_time
|
||||
|
||||
|
||||
/obj/item/device/assembly/timer/update_icon()
|
||||
@@ -74,6 +78,7 @@
|
||||
var/second = time % 60
|
||||
var/minute = (time - second) / 60
|
||||
var/dat = "<TT><B>Timing Unit</B>\n[(timing ? "<A href='?src=\ref[src];time=0'>Timing</A>" : "<A href='?src=\ref[src];time=1'>Not Timing</A>")] [minute]:[second]\n<A href='?src=\ref[src];tp=-30'>-</A> <A href='?src=\ref[src];tp=-1'>-</A> <A href='?src=\ref[src];tp=1'>+</A> <A href='?src=\ref[src];tp=30'>+</A>\n</TT>"
|
||||
dat += "<BR><BR><A href='?src=\ref[src];repeat=[(loop ? "0'>Stop repeating" : "1'>Set to repeat")]</A>"
|
||||
dat += "<BR><BR><A href='?src=\ref[src];refresh=1'>Refresh</A>"
|
||||
dat += "<BR><BR><A href='?src=\ref[src];close=1'>Close</A>"
|
||||
var/datum/browser/popup = new(user, "timer", name)
|
||||
@@ -96,11 +101,14 @@
|
||||
bombers += timer_message
|
||||
log_game("[key_name(usr)] activated [src] attachment for [loc]")
|
||||
update_icon()
|
||||
if(href_list["repeat"])
|
||||
loop = text2num(href_list["repeat"])
|
||||
|
||||
if(href_list["tp"])
|
||||
var/tp = text2num(href_list["tp"])
|
||||
time += tp
|
||||
time = min(max(round(time), 1), 600)
|
||||
saved_time = time
|
||||
|
||||
if(href_list["close"])
|
||||
usr << browse(null, "window=timer")
|
||||
|
||||
Reference in New Issue
Block a user