mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 02:16:05 +00:00
maybe fix votes randomly not coming up
This commit is contained in:
@@ -340,6 +340,7 @@
|
||||
crewmonitor.sendResources(src)
|
||||
if(adv_camera && minimapinit)
|
||||
adv_camera.sendResources(src)
|
||||
vote.interface.sendAssets(src)
|
||||
|
||||
/proc/get_role_desire_str(var/rolepref)
|
||||
//writepanic("[__FILE__].[__LINE__] (no type)([usr ? usr.ckey : ""]) \\/proc/get_role_desire_str() called tick#: [world.time]")
|
||||
|
||||
@@ -5,19 +5,19 @@ var/global/datum/controller/vote/vote = new()
|
||||
#define VOTE_SCREEN_HEIGHT 400
|
||||
|
||||
|
||||
/datum/html_interface/nanotrasen/registerResources()
|
||||
/datum/html_interface/nanotrasen/vote/registerResources()
|
||||
. = ..()
|
||||
|
||||
register_asset("voting.js", 'voting.js')
|
||||
register_asset("voting.css", 'voting.css')
|
||||
|
||||
/datum/html_interface/nanotrasen/sendAssets(var/client/client)
|
||||
/datum/html_interface/nanotrasen/vote/sendAssets(var/client/client)
|
||||
..()
|
||||
|
||||
send_asset(client, "voting.js")
|
||||
send_asset(client, "voting.css")
|
||||
|
||||
/datum/html_interface/nanotrasen/Topic(href, href_list[])
|
||||
/datum/html_interface/nanotrasen/vote/Topic(href, href_list[])
|
||||
..()
|
||||
if(href_list["html_interface_action"] == "onclose")
|
||||
|
||||
@@ -40,7 +40,7 @@ var/global/datum/controller/vote/vote = new()
|
||||
var/list/ismapvote
|
||||
var/chosen_map
|
||||
var/name = "datum"
|
||||
var/datum/html_interface/nanotrasen/interface
|
||||
var/datum/html_interface/nanotrasen/vote/interface
|
||||
var/list/data
|
||||
var/list/status_data
|
||||
var/last_update = 0
|
||||
@@ -53,7 +53,7 @@ var/global/datum/controller/vote/vote = new()
|
||||
src.status_data = list()
|
||||
spawn(5)
|
||||
if(!src.interface)
|
||||
src.interface = new/datum/html_interface/nanotrasen(src, "Voting Panel", 400, 400, vote_head)
|
||||
src.interface = new/datum/html_interface/nanotrasen/vote(src, "Voting Panel", 400, 400, vote_head)
|
||||
src.interface.updateContent("content", "<div id='vote_main'></div><div id='vote_choices'></div><div id='vote_admin'></div>")
|
||||
initialized = 1
|
||||
if (vote != src)
|
||||
@@ -345,7 +345,7 @@ var/global/datum/controller/vote/vote = new()
|
||||
|
||||
/datum/controller/vote/proc/update(refresh = 0)
|
||||
if(!interface)
|
||||
interface = new/datum/html_interface/nanotrasen(src, "Voting Panel", 400, 400, vote_head)
|
||||
interface = new/datum/html_interface/nanotrasen/vote(src, "Voting Panel", 400, 400, vote_head)
|
||||
interface.updateContent("content", "<div id='vote_main'></div><div id='vote_choices'></div><div id='vote_admin'></div>")
|
||||
|
||||
if(world.time < last_update + 2)
|
||||
|
||||
Reference in New Issue
Block a user