mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Optimized pulse reagent checking a little.
This commit is contained in:
@@ -1702,26 +1702,19 @@
|
|||||||
if(status_flags & FAKEDEATH)
|
if(status_flags & FAKEDEATH)
|
||||||
temp = PULSE_NONE //pretend that we're dead. unlike actual death, can be inflienced by meds
|
temp = PULSE_NONE //pretend that we're dead. unlike actual death, can be inflienced by meds
|
||||||
|
|
||||||
|
//handles different chems' influence on pulse
|
||||||
for(var/datum/reagent/R in reagents.reagent_list)
|
for(var/datum/reagent/R in reagents.reagent_list)
|
||||||
if(R.id in bradycardics)
|
if(R.id in bradycardics)
|
||||||
if(temp <= PULSE_THREADY && temp >= PULSE_NORM)
|
if(temp <= PULSE_THREADY && temp >= PULSE_NORM)
|
||||||
temp--
|
temp--
|
||||||
break //one reagent is enough
|
|
||||||
//comment out the breaks to make med effects stack
|
|
||||||
for(var/datum/reagent/R in reagents.reagent_list) //handles different chems' influence on pulse
|
|
||||||
if(R.id in tachycardics)
|
if(R.id in tachycardics)
|
||||||
if(temp <= PULSE_FAST && temp >= PULSE_NONE)
|
if(temp <= PULSE_FAST && temp >= PULSE_NONE)
|
||||||
temp++
|
temp++
|
||||||
break
|
if(R.id in heartstopper) //To avoid using fakedeath
|
||||||
for(var/datum/reagent/R in reagents.reagent_list) //To avoid using fakedeath
|
|
||||||
if(R.id in heartstopper)
|
|
||||||
temp = PULSE_NONE
|
temp = PULSE_NONE
|
||||||
break
|
if(R.id in cheartstopper) //Conditional heart-stoppage
|
||||||
for(var/datum/reagent/R in reagents.reagent_list) //Conditional heart-stoppage
|
|
||||||
if(R.id in cheartstopper)
|
|
||||||
if(R.volume >= R.overdose)
|
if(R.volume >= R.overdose)
|
||||||
temp = PULSE_NONE
|
temp = PULSE_NONE
|
||||||
break
|
|
||||||
|
|
||||||
return temp
|
return temp
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user