mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-07-14 00:26:02 +01:00
Adds weight machines and weight variables
Exactly what it says on the tin. Weight descriptions aren't in yet, but the machines remove weight and nutrition. Compiles without errors/warnings.
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
/*
|
||||
|
||||
/obj/machinery/bodyscanner/proc/get_occupant_data_vr(list/incoming = list(),mob/living/carbon/human/H)
|
||||
incoming["Weight"] = H.weight
|
||||
return
|
||||
|
||||
|
||||
|
||||
/obj/machinery/body_scanconsole/proc/med_info2(var/list/occ, var/dat = "<font color='blue'><b>Scan performed at [occ["stationtime"]]</b></font><br>")
|
||||
dat += text("Body Weight (to scale): [occ["weight"]]lbs / [occ["weight"] / 2.20463]kg<br><HR>")
|
||||
|
||||
*/
|
||||
//WIP sleeper code.
|
||||
|
||||
//attempt_vr(src,"get_occupant_data_vr",list(occupant_data,H)) //VOREStation Code
|
||||
|
||||
//attempt_vr(src,"med_info2",list(occupant_data,occ)) //VOREStation Code
|
||||
@@ -4,7 +4,9 @@
|
||||
var/datum/belly/vore_selected // Default to no vore capability.
|
||||
var/list/vore_organs = list() // List of vore containers inside a mob
|
||||
var/absorbed = 0 // If a mob is absorbed into another
|
||||
var/weight = 100 // Weight for mobs for weightgain system
|
||||
var/weight = 137 // Weight for mobs for weightgain system
|
||||
var/weight_gain = 1 //How fast you gain weight
|
||||
var/weight_loss = 0.5 //How fast you lose weight
|
||||
|
||||
//
|
||||
// Hook for generic creation of stuff on new creatures
|
||||
|
||||
@@ -35,6 +35,8 @@ V::::::V V::::::VO:::::::OOO:::::::ORR:::::R R:::::REE::::::EEEEEE
|
||||
/datum/vore_preferences
|
||||
var/digestable = 1
|
||||
var/list/belly_prefs = list()
|
||||
var/weight_gain = 1
|
||||
var/weight_loss = 0.5
|
||||
|
||||
//
|
||||
// Adding procs to types to support vore
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 2.6 KiB |
@@ -0,0 +1,154 @@
|
||||
/obj/machinery/workout
|
||||
name = "fitness lifter"
|
||||
icon = 'code/modules/vore/weight/fit_vr.dmi'
|
||||
icon_state = "fitnesslifter" //Sprites ripped from goon.
|
||||
desc = "A utility often used to lose weight."
|
||||
anchored = 1
|
||||
use_power = 0
|
||||
idle_power_usage = 0
|
||||
active_power_usage = 0
|
||||
|
||||
/obj/machinery/workout/attackby(obj/item/W, var/mob/living/user)
|
||||
if(istype(W, /obj/item/weapon/wrench))
|
||||
src.add_fingerprint(user)
|
||||
user.visible_message("<span class='warning'>[user] has [anchored ? "un" : ""]secured \the [src].</span>", "<span class='notice'>You [anchored ? "un" : ""]secure \the [src].</span>")
|
||||
anchored = !anchored
|
||||
playsound(src.loc, 'sound/items/Ratchet.ogg', 50, 1)
|
||||
return
|
||||
|
||||
/obj/machinery/workout/attack_hand(var/mob/living/user)
|
||||
if(!anchored)
|
||||
user << "<span class='notice'>For safety reasons, you are required to have this equipment wrenched down before using it!</span>"
|
||||
return
|
||||
if(user.loc != src.loc)
|
||||
user << "<span class='notice'>For safety reasons, you need to be sitting in the fitness lifter for it to work!</span>"
|
||||
return
|
||||
if(user.nutrition > 70 && user.weight > 70) //If they have enough nutrition and body weight, they can exercise.
|
||||
user.dir = src.dir
|
||||
user.nutrition = user.nutrition - 20 //Working out burns a lot of calories!
|
||||
user.weight = user.weight - 0.05 //Burn a bit of weight. Not much, but quite a bit. This can't be spammed, as they'll need nutrition to be able to work out.
|
||||
icon_state = "fitnesslifter2"
|
||||
user << "<span class='notice'>You lift some weights.</span>"
|
||||
sleep(50)
|
||||
icon_state = "fitnesslifter"
|
||||
|
||||
|
||||
else if(user.nutrition < 70)
|
||||
user << "<span class='notice'>You need more energy to workout on the mat!</span>"
|
||||
|
||||
else if(user.weight < 70)
|
||||
user << "<span class='notice'>You're too skinny to risk losing any more weight!</span>"
|
||||
|
||||
else
|
||||
user << "<span class='notice'>You're unable to use the fitness lifter.</span>"
|
||||
return //Something went wrong. They shouldn't see this.
|
||||
|
||||
/obj/machinery/workout/shipped
|
||||
anchored = 0 // For cargo.
|
||||
|
||||
|
||||
/obj/machinery/punching_bag
|
||||
name = "punching bag"
|
||||
icon = 'code/modules/vore/weight/fit_vr.dmi'
|
||||
icon_state = "punchingbag"
|
||||
desc = "A bag often used to releive stress and burn fat."
|
||||
anchored = 1
|
||||
density = 1
|
||||
use_power = 0
|
||||
idle_power_usage = 0
|
||||
active_power_usage = 0
|
||||
|
||||
/obj/machinery/punching_bag/attack_hand(var/mob/living/user)
|
||||
|
||||
if(user.nutrition > 35 && user.weight > 70) //If they have enough nutrition and body weight, they can exercise.
|
||||
var/workout = rand(1,2)
|
||||
user.nutrition = user.nutrition - 10 //A punching bag uses less calories.
|
||||
user.weight = user.weight - 0.025 //And burns less weight.
|
||||
icon_state = "punchingbag2"
|
||||
switch(workout)
|
||||
if(1)
|
||||
user << "<span class='notice'>You slam your fist into the punching bag.</span>"
|
||||
if(2)
|
||||
user << "<span class='notice'>You jab the punching bag with your elbow.</span>"
|
||||
playsound(src.loc, "punch", 50, 1)
|
||||
sleep(50)
|
||||
icon_state = "punchingbag"
|
||||
|
||||
|
||||
else if(user.nutrition < 35)
|
||||
user << "<span class='notice'>You need more energy to workout on the mat!</span>"
|
||||
|
||||
else if(user.weight < 70)
|
||||
user << "<span class='notice'>You're too skinny to risk losing any more weight!</span>"
|
||||
|
||||
else
|
||||
user << "<span class='notice'>You're unable to use the punching bag.</span>"
|
||||
return //Something went wrong. They shouldn't see this.
|
||||
|
||||
|
||||
/obj/machinery/punching_clown
|
||||
name = "clown punching bag"
|
||||
icon = 'code/modules/vore/weight/fit_vr.dmi'
|
||||
icon_state = "bopbag"
|
||||
desc = "A bag often used to releive stress and burn fat. It has a clown on the front of it."
|
||||
anchored = 0
|
||||
density = 1
|
||||
use_power = 0
|
||||
idle_power_usage = 0
|
||||
active_power_usage = 0
|
||||
|
||||
/obj/machinery/punching_clown/attack_hand(var/mob/living/user)
|
||||
|
||||
if(user.nutrition > 35 && user.weight > 70) //If they have enough nutrition and body weight, they can exercise.
|
||||
var/workout = rand(1,4)
|
||||
user.nutrition = user.nutrition - 10
|
||||
user.weight = user.weight - 0.025
|
||||
icon_state = "bopbag2"
|
||||
switch(workout)
|
||||
if(1)
|
||||
user << "<span class='notice'>You slam your fist into the punching bag.</span>"
|
||||
if(2)
|
||||
user << "<span class='notice'>You jab the punching bag with your elbow.</span>"
|
||||
if(3)
|
||||
user << "<span class='notice'>You hammer the clown right in it's face with your fist.</span>"
|
||||
if(4)
|
||||
user << "<span class='notice'>A honk emits from the punching bag as you hit it.</span>"
|
||||
playsound(src.loc, "punch", 50, 1)
|
||||
playsound(src.loc, "clownstep", 50, 1)
|
||||
playsound(src.loc, 'sound/items/bikehorn.ogg', 50, 1)
|
||||
sleep(50)
|
||||
icon_state = "bopbag"
|
||||
|
||||
|
||||
else if(user.nutrition < 35)
|
||||
user << "<span class='notice'>You need more energy to workout on the mat!</span>"
|
||||
|
||||
else if(user.weight < 70)
|
||||
user << "<span class='notice'>You're too skinny to risk losing any more weight!</span>"
|
||||
|
||||
else
|
||||
user << "<span class='notice'>You're unable to use the punching bag.</span>"
|
||||
return //Something went wrong. They shouldn't see this.
|
||||
|
||||
|
||||
|
||||
|
||||
/obj/machinery/scale
|
||||
name = "scale"
|
||||
icon = 'code/modules/vore/weight/fit_vr.dmi'
|
||||
icon_state = "scale"
|
||||
desc = "A scale used to measure ones weight relative to their size and species."
|
||||
anchored = 1 // Set to 0 when we can construct or dismantle these.
|
||||
use_power = 0
|
||||
idle_power_usage = 0
|
||||
active_power_usage = 0
|
||||
var/kilograms
|
||||
|
||||
/obj/machinery/scale/attack_hand(var/mob/living/user)
|
||||
if(user.loc != src.loc)
|
||||
user << "<span class='notice'>You need to be standing on top of the scale for it to work!</span>"
|
||||
return
|
||||
if(user.weight) //Just in case.
|
||||
kilograms = round(text2num(user.weight),4) / 2.20463
|
||||
user << "<span class='notice'>Your relative weight is [user.weight]lb / [kilograms]kg.</span>"
|
||||
user.visible_message("<span class='warning'>[user]'s relative weight is [user.weight]lb / [kilograms]kg.</span>")
|
||||
@@ -374,6 +374,7 @@
|
||||
#include "code\game\jobs\job\security.dm"
|
||||
#include "code\game\jobs\job\silicon.dm"
|
||||
#include "code\game\machinery\adv_med.dm"
|
||||
#include "code\game\machinery\adv_med_vr.dm"
|
||||
#include "code\game\machinery\ai_slipper.dm"
|
||||
#include "code\game\machinery\alarm.dm"
|
||||
#include "code\game\machinery\atmo_control.dm"
|
||||
@@ -990,6 +991,7 @@
|
||||
#include "code\modules\client\preferences_savefile.dm"
|
||||
#include "code\modules\client\preferences_spawnpoints.dm"
|
||||
#include "code\modules\client\preferences_toggle_procs.dm"
|
||||
#include "code\modules\client\preferences_vr.dm"
|
||||
#include "code\modules\client\ui_style.dm"
|
||||
#include "code\modules\client\preference_setup\preference_setup.dm"
|
||||
#include "code\modules\client\preference_setup\antagonism\01_basic.dm"
|
||||
@@ -1889,6 +1891,7 @@
|
||||
#include "code\modules\vore\eating\vore_vr.dm"
|
||||
#include "code\modules\vore\eating\vorehooks_vr.dm"
|
||||
#include "code\modules\vore\eating\vorepanel_vr.dm"
|
||||
#include "code\modules\vore\weight\fitness_machines_vr.dm"
|
||||
#include "code\modules\xgm\xgm_gas_data.dm"
|
||||
#include "code\modules\xgm\xgm_gas_mixture.dm"
|
||||
#include "code\unit_tests\loadout_tests.dm"
|
||||
|
||||
Reference in New Issue
Block a user