mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-01-04 22:42:07 +00:00
Migrate basic build to drone (#10651)
* Adds drone tasks to Execute UTs on Aurora and Exodus * Adds a drone task to Migrate SQL and Perform the SQL UT on Runtime * Changes the SQL UT to respect the config.sql_enabled setting and use that sql connection * Changes the default config.sql_enabled state to 0, so uncommenting SQL_ENABLED has a actual effect * Moves a number of UT tests into a helper script (code_check.sh) * Updates the way the RUST_G dll/so is located * Adds a check to load_databases to verify that sql is enabled * Adds a check to establish_db_connection to verify that sql is enabled * Adds spearate config files used during the UTs (which hold the UT db connection info and enable/disable the db epending on the UT)
This commit is contained in:
@@ -44,22 +44,25 @@ paiicon is the pai icon sprite name
|
||||
robot_custom_icons[synthsprite] = synth
|
||||
|
||||
/proc/loadsynths_from_sql()
|
||||
if(!establish_db_connection(dbcon))
|
||||
log_debug("SQL ERROR - Failed to connect. - Falling back to JSON")
|
||||
if(!config.sql_enabled)
|
||||
log_debug("Synthsprites: SQL Disabled - Falling back to JSON")
|
||||
loadsynths_from_json()
|
||||
return
|
||||
else
|
||||
|
||||
var/DBQuery/customsynthsprites = dbcon.NewQuery("SELECT synthname, synthckey, synthicon, aichassisicon, aiholoicon, paiicon FROM ss13_customsynths ORDER BY synthckey ASC")
|
||||
customsynthsprites.Execute()
|
||||
while(customsynthsprites.NextRow())
|
||||
CHECK_TICK
|
||||
|
||||
var/datum/custom_synth/synth = new()
|
||||
synth.synthname = customsynthsprites.item[1]
|
||||
synth.synthckey = customsynthsprites.item[2]
|
||||
synth.synthicon = customsynthsprites.item[3]
|
||||
synth.aichassisicon = customsynthsprites.item[4]
|
||||
synth.aiholoicon = customsynthsprites.item[5]
|
||||
synth.paiicon = customsynthsprites.item[6]
|
||||
robot_custom_icons[synth.synthname] = synth
|
||||
if(!establish_db_connection(dbcon))
|
||||
log_debug("Synthsprites: SQL ERROR - Failed to connect. - Falling back to JSON")
|
||||
loadsynths_from_json()
|
||||
return
|
||||
|
||||
var/DBQuery/customsynthsprites = dbcon.NewQuery("SELECT synthname, synthckey, synthicon, aichassisicon, aiholoicon, paiicon FROM ss13_customsynths ORDER BY synthckey ASC")
|
||||
customsynthsprites.Execute()
|
||||
while(customsynthsprites.NextRow())
|
||||
CHECK_TICK
|
||||
|
||||
var/datum/custom_synth/synth = new()
|
||||
synth.synthname = customsynthsprites.item[1]
|
||||
synth.synthckey = customsynthsprites.item[2]
|
||||
synth.synthicon = customsynthsprites.item[3]
|
||||
synth.aichassisicon = customsynthsprites.item[4]
|
||||
synth.aiholoicon = customsynthsprites.item[5]
|
||||
synth.paiicon = customsynthsprites.item[6]
|
||||
robot_custom_icons[synth.synthname] = synth
|
||||
|
||||
Reference in New Issue
Block a user