mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-24 04:28:12 +01:00
removes var/ inside all procs (#19450)
* removes var/ inside all procs * . * ugh
This commit is contained in:
@@ -34,7 +34,7 @@
|
||||
var/beacons = FALSE
|
||||
var/sandbags = FALSE
|
||||
|
||||
/obj/item/stack/Initialize(mapload, var/starting_amount)
|
||||
/obj/item/stack/Initialize(mapload, starting_amount)
|
||||
. = ..()
|
||||
if(!stacktype)
|
||||
stacktype = type
|
||||
@@ -167,7 +167,7 @@
|
||||
|
||||
return FALSE
|
||||
|
||||
/obj/item/stack/proc/produce_recipe(datum/stack_recipe/recipe, var/quantity, mob/user)
|
||||
/obj/item/stack/proc/produce_recipe(datum/stack_recipe/recipe, quantity, mob/user)
|
||||
var/required = quantity*recipe.req_amount
|
||||
var/produced = min(quantity*recipe.res_amount, recipe.max_res_amount)
|
||||
|
||||
@@ -258,7 +258,7 @@
|
||||
|
||||
//Return 1 if an immediate subsequent call to use() would succeed.
|
||||
//Ensures that code dealing with stacks uses the same logic
|
||||
/obj/item/stack/proc/can_use(var/used)
|
||||
/obj/item/stack/proc/can_use(used)
|
||||
if(used < 0 || (used != round(used)))
|
||||
stack_trace("Tried to use a bad stack amount: [used]")
|
||||
return 0
|
||||
@@ -266,7 +266,7 @@
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/item/stack/proc/use(var/used)
|
||||
/obj/item/stack/proc/use(used)
|
||||
if(!can_use(used))
|
||||
return 0
|
||||
if(!uses_charge)
|
||||
@@ -287,7 +287,7 @@
|
||||
S.use_charge(charge_costs[i] * used) // Doesn't need to be deleted
|
||||
return 1
|
||||
|
||||
/obj/item/stack/proc/add(var/extra)
|
||||
/obj/item/stack/proc/add(extra)
|
||||
if(extra < 0 || (extra != round(extra)))
|
||||
stack_trace("Tried to add a bad stack amount: [extra]")
|
||||
return 0
|
||||
@@ -305,7 +305,7 @@
|
||||
var/datum/matter_synth/S = synths[i]
|
||||
S.add_charge(charge_costs[i] * extra)
|
||||
|
||||
/obj/item/stack/proc/set_amount(var/new_amount, var/no_limits = FALSE)
|
||||
/obj/item/stack/proc/set_amount(new_amount, no_limits = FALSE)
|
||||
if(new_amount < 0 || (new_amount != round(new_amount)))
|
||||
stack_trace("Tried to set a bad stack amount: [new_amount]")
|
||||
return 0
|
||||
@@ -333,7 +333,7 @@
|
||||
*/
|
||||
|
||||
//attempts to transfer amount to S, and returns the amount actually transferred
|
||||
/obj/item/stack/proc/transfer_to(obj/item/stack/S, var/tamount=null, var/type_verified)
|
||||
/obj/item/stack/proc/transfer_to(obj/item/stack/S, tamount=null, type_verified)
|
||||
if (!get_amount())
|
||||
return 0
|
||||
if ((stacktype != S.stacktype) && !type_verified)
|
||||
@@ -360,7 +360,7 @@
|
||||
return 0
|
||||
|
||||
//creates a new stack with the specified amount
|
||||
/obj/item/stack/proc/split(var/tamount)
|
||||
/obj/item/stack/proc/split(tamount)
|
||||
if (!amount)
|
||||
return null
|
||||
if(uses_charge)
|
||||
|
||||
Reference in New Issue
Block a user