mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-23 21:27:01 +01:00
Merge branch 'master' into vorespawn-pred
This commit is contained in:
@@ -30,6 +30,7 @@
|
||||
var/cloaked = FALSE //If we're cloaked or not
|
||||
var/image/cloaked_selfimage //The image we use for our client to let them see where we are
|
||||
var/belly_cycles = 0 //CHOMPEdit: Counting current belly process cycles for autotransfer.
|
||||
var/autotransferable = TRUE //CHOMPEdit: Toggle for autotransfer mechanics.
|
||||
|
||||
/atom/movable/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
@@ -25,10 +25,16 @@
|
||||
break
|
||||
if(dest_belly)
|
||||
for(var/atom/movable/M in autotransfer_queue)
|
||||
if(!M.autotransferable)
|
||||
autotransfer_queue -= M
|
||||
continue
|
||||
transfer_contents(M, dest_belly)
|
||||
autotransfer_queue.Cut()
|
||||
var/tally = 0
|
||||
for(var/atom/movable/M in autotransferables)
|
||||
if(!M.autotransferable)
|
||||
autotransferables -= M
|
||||
continue
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
if(L.absorbed)
|
||||
@@ -152,7 +158,7 @@
|
||||
formatted_message = replacetext(formatted_message, "%countprey", living_count)
|
||||
formatted_message = replacetext(formatted_message, "%count", contents.len)
|
||||
to_chat(M, "<span class='notice'>[formatted_message]</span>")
|
||||
|
||||
|
||||
if(to_update)
|
||||
updateVRPanels()
|
||||
|
||||
|
||||
@@ -237,6 +237,7 @@
|
||||
P.latejoin_prey = src.latejoin_prey
|
||||
P.receive_reagents = src.receive_reagents
|
||||
P.give_reagents = src.give_reagents
|
||||
P.autotransferable = src.autotransferable
|
||||
|
||||
|
||||
var/list/serialized = list()
|
||||
@@ -279,6 +280,7 @@
|
||||
latejoin_prey = P.latejoin_prey
|
||||
receive_reagents = P.receive_reagents
|
||||
give_reagents = P.give_reagents
|
||||
autotransferable = P.autotransferable
|
||||
|
||||
if(bellies)
|
||||
release_vore_contents(silent = TRUE)
|
||||
@@ -893,6 +895,7 @@
|
||||
dispvoreprefs += "<b>Digestable:</b> [digestable ? "Enabled" : "Disabled"]<br>"
|
||||
dispvoreprefs += "<b>Devourable:</b> [devourable ? "Enabled" : "Disabled"]<br>"
|
||||
dispvoreprefs += "<b>Feedable:</b> [feeding ? "Enabled" : "Disabled"]<br>"
|
||||
dispvoreprefs += "<b>Autotransferable:</b> [autotransferable ? "Enabled" : "Disabled"]<br>" //CHOMPstation edit
|
||||
dispvoreprefs += "<b>Absorption Permission:</b> [absorbable ? "Allowed" : "Disallowed"]<br>"
|
||||
dispvoreprefs += "<b>Leaves Remains:</b> [digest_leave_remains ? "Enabled" : "Disabled"]<br>"
|
||||
dispvoreprefs += "<b>Mob Vore:</b> [allowmobvore ? "Enabled" : "Disabled"]<br>"
|
||||
|
||||
@@ -64,6 +64,7 @@ V::::::V V::::::VO:::::::OOO:::::::ORR:::::R R:::::REE::::::EEEEEE
|
||||
var/give_reagents = FALSE
|
||||
var/latejoin_vore = FALSE
|
||||
var/latejoin_prey = FALSE
|
||||
var/autotransferable = TRUE
|
||||
//CHOMP stuff end
|
||||
|
||||
var/list/belly_prefs = list()
|
||||
@@ -160,6 +161,7 @@ V::::::V V::::::VO:::::::OOO:::::::ORR:::::R R:::::REE::::::EEEEEE
|
||||
latejoin_prey = json_from_file["latejoin_prey"]
|
||||
receive_reagents = json_from_file["receive_reagents"]
|
||||
give_reagents = json_from_file["give_reagents"]
|
||||
autotransferable = json_from_file["autotransferable"]
|
||||
|
||||
|
||||
//Quick sanitize
|
||||
@@ -203,6 +205,8 @@ V::::::V V::::::VO:::::::OOO:::::::ORR:::::R R:::::REE::::::EEEEEE
|
||||
receive_reagents = FALSE
|
||||
if(isnull(give_reagents))
|
||||
give_reagents = FALSE
|
||||
if(isnull(autotransferable))
|
||||
autotransferable = TRUE
|
||||
|
||||
return TRUE
|
||||
|
||||
@@ -234,6 +238,7 @@ V::::::V V::::::VO:::::::OOO:::::::ORR:::::R R:::::REE::::::EEEEEE
|
||||
"belly_prefs" = belly_prefs,
|
||||
"receive_reagents" = receive_reagents,
|
||||
"give_reagents" = give_reagents,
|
||||
"autotransferable" = autotransferable
|
||||
)
|
||||
|
||||
//List to JSON
|
||||
|
||||
@@ -302,6 +302,7 @@
|
||||
//CHOMPedit start, liquid belly prefs
|
||||
"liq_rec" = host.receive_reagents,
|
||||
"liq_giv" = host.give_reagents,
|
||||
"autotransferable" = host.autotransferable,
|
||||
"noisy_full" = host.noisy_full //Belching while full
|
||||
//CHOMPedit end
|
||||
)
|
||||
@@ -543,6 +544,12 @@
|
||||
host.client.prefs_vr.give_reagents = host.give_reagents
|
||||
unsaved_changes = TRUE
|
||||
return TRUE
|
||||
if("toggle_autotransferable")
|
||||
host.autotransferable = !host.autotransferable
|
||||
if(host.client.prefs_vr)
|
||||
host.client.prefs_vr.autotransferable = host.autotransferable
|
||||
unsaved_changes = TRUE
|
||||
return TRUE
|
||||
//Belch code
|
||||
if("toggle_noisy_full")
|
||||
host.noisy_full = !host.noisy_full
|
||||
|
||||
@@ -1106,6 +1106,7 @@ const VoreUserPreferences = (props, context) => {
|
||||
noisy_full,
|
||||
liq_rec,
|
||||
liq_giv,
|
||||
autotransferable,
|
||||
} = data.prefs;
|
||||
|
||||
const {
|
||||
@@ -1387,6 +1388,19 @@ const VoreUserPreferences = (props, context) => {
|
||||
disabled: "Do Not Allow Taking Liquids",
|
||||
},
|
||||
},
|
||||
autotransferable: {
|
||||
action: "toggle_autotransferable",
|
||||
test: autotransferable,
|
||||
tooltip: {
|
||||
main: "This button is for allowing or preventing belly auto-transfer mechanics from moving you.",
|
||||
enable: "Click here to allow autotransfer.",
|
||||
disable: "Click here to prevent autotransfer.",
|
||||
},
|
||||
content: {
|
||||
enabled: "Auto-Transfer Allowed",
|
||||
disabled: "Do Not Allow Auto-Transfer",
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
return tabIndex===4 ? null : (
|
||||
@@ -1450,6 +1464,9 @@ const VoreUserPreferences = (props, context) => {
|
||||
<Flex.Item basis="32%">
|
||||
<VoreUserPreferenceItem spec={preferences.spontaneous_tf} />
|
||||
</Flex.Item>
|
||||
<Flex.Item basis="32%">
|
||||
<VoreUserPreferenceItem spec={preferences.autotransferable} />
|
||||
</Flex.Item>
|
||||
<Flex.Item basis="49%">
|
||||
<Button
|
||||
fluid
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user