mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-22 04:24:20 +01:00
Merge pull request #2401 from caelaislinn/bleeding-edge-freeze
RUST updates, event tweaks, shielding updates
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
oneShot = 1
|
||||
|
||||
var/list/obj/machinery/vending/vendingMachines = list()
|
||||
var/list/obj/machinery/vending/infectedVendingMachines = list()
|
||||
var/obj/machinery/vending/originMachine
|
||||
|
||||
|
||||
@@ -28,20 +29,29 @@
|
||||
|
||||
/datum/event/brand_intelligence/tick()
|
||||
if(!vendingMachines.len || !originMachine || originMachine.shut_up) //if every machine is infected, or if the original vending machine is missing or has it's voice switch flipped
|
||||
end()
|
||||
kill()
|
||||
return
|
||||
|
||||
if(IsMultiple(activeFor, 3))
|
||||
var/obj/machinery/vending/infectedMachine = pick(vendingMachines)
|
||||
vendingMachines.Remove(infectedMachine)
|
||||
infectedMachine.shut_up = 0
|
||||
infectedMachine.shoot_inventory = 1
|
||||
if(IsMultiple(activeFor, 5))
|
||||
if(prob(25))
|
||||
var/obj/machinery/vending/infectedMachine = pick(vendingMachines)
|
||||
vendingMachines.Remove(infectedMachine)
|
||||
infectedVendingMachines.Add(infectedMachine)
|
||||
infectedMachine.shut_up = 0
|
||||
infectedMachine.shoot_inventory = 1
|
||||
|
||||
if(IsMultiple(activeFor, 12))
|
||||
originMachine.speak(pick("Try our aggressive new marketing strategies!", \
|
||||
"You should buy products to feed your lifestyle obession!", \
|
||||
"Consume!", \
|
||||
"Your money can buy happiness!", \
|
||||
"Engage direct marketing!", \
|
||||
"Advertising is legalized lying! But don't let that put you off our great deals!", \
|
||||
"You don't want to buy anything? Yeah, well I didn't want to buy your mom either."))
|
||||
if(IsMultiple(activeFor, 12))
|
||||
originMachine.speak(pick("Try our aggressive new marketing strategies!", \
|
||||
"You should buy products to feed your lifestyle obession!", \
|
||||
"Consume!", \
|
||||
"Your money can buy happiness!", \
|
||||
"Engage direct marketing!", \
|
||||
"Advertising is legalized lying! But don't let that put you off our great deals!", \
|
||||
"You don't want to buy anything? Yeah, well I didn't want to buy your mom either."))
|
||||
|
||||
/datum/event/brand_intelligence/end()
|
||||
for(var/obj/machinery/vending/infectedMachine in infectedVendingMachines)
|
||||
if(prob(90))
|
||||
infectedMachine.shut_up = 1
|
||||
infectedMachine.shoot_inventory = 0
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
|
||||
/datum/event/carp_migration/end()
|
||||
for(var/mob/living/simple_animal/hostile/carp/C in spawned_carp)
|
||||
var/turf/T = get_turf(C)
|
||||
if(istype(T, /turf/space))
|
||||
del(C)
|
||||
if(!C.stat)
|
||||
var/turf/T = get_turf(C)
|
||||
if(istype(T, /turf/space))
|
||||
del(C)
|
||||
|
||||
@@ -43,17 +43,17 @@
|
||||
possibleEvents[/datum/event/carp_migration] = 50 + 50 * active_with_role["Engineer"]
|
||||
possibleEvents[/datum/event/brand_intelligence] = 50 + 25 * active_with_role["Janitor"]
|
||||
|
||||
possibleEvents[/datum/event/rogue_drone] = 50 + 25 * active_with_role["Engineer"] + 25 * active_with_role["Security"]
|
||||
possibleEvents[/datum/event/rogue_drone] = 25 + 25 * active_with_role["Engineer"] + 25 * active_with_role["Security"]
|
||||
possibleEvents[/datum/event/infestation] = 50 + 25 * active_with_role["Janitor"]
|
||||
|
||||
possibleEvents[/datum/event/communications_blackout] = 50 + 25 * active_with_role["AI"] + active_with_role["Scientist"] * 25
|
||||
possibleEvents[/datum/event/ionstorm] = active_with_role["AI"] * 25 + active_with_role["Cyborg"] * 25 + active_with_role["Engineer"] * 10 + active_with_role["Scientist"] * 5
|
||||
possibleEvents[/datum/event/grid_check] = 10 * active_with_role["Engineer"]
|
||||
possibleEvents[/datum/event/ionstorm] = 25 + active_with_role["AI"] * 25 + active_with_role["Cyborg"] * 25 + active_with_role["Engineer"] * 10 + active_with_role["Scientist"] * 5
|
||||
possibleEvents[/datum/event/grid_check] = 25 + 10 * active_with_role["Engineer"]
|
||||
possibleEvents[/datum/event/electrical_storm] = 75 + 25 * active_with_role["Janitor"] + 5 * active_with_role["Engineer"]
|
||||
|
||||
if(!spacevines_spawned)
|
||||
possibleEvents[/datum/event/spacevine] = 5 + 10 * active_with_role["Engineer"]
|
||||
if(active_with_role["Engineer"] > 0 && minutes_passed >= 30) // Give engineers time to set up engine
|
||||
if(minutes_passed >= 30) // Give engineers time to set up engine
|
||||
possibleEvents[/datum/event/meteor_wave] = 20 * active_with_role["Engineer"]
|
||||
possibleEvents[/datum/event/meteor_shower] = 80 * active_with_role["Engineer"]
|
||||
possibleEvents[/datum/event/blob] = 30 * active_with_role["Engineer"]
|
||||
@@ -64,8 +64,8 @@
|
||||
possibleEvents[/datum/event/spontaneous_appendicitis] = active_with_role["Medical"] * 75
|
||||
possibleEvents[/datum/event/viral_outbreak] = active_with_role["Medical"] * 5
|
||||
|
||||
possibleEvents[/datum/event/prison_break] = active_with_role["Security"] * 50
|
||||
if(active_with_role["Security"] > 0)
|
||||
possibleEvents[/datum/event/prison_break] = active_with_role["Security"] * 50
|
||||
if(!sent_spiders_to_station)
|
||||
possibleEvents[/datum/event/spider_infestation] = max(active_with_role["Security"], 5) + 5
|
||||
if(aliens_allowed && !sent_aliens_to_station)
|
||||
@@ -73,6 +73,15 @@
|
||||
if(!sent_ninja_to_station && toggle_space_ninja)
|
||||
possibleEvents[/datum/event/space_ninja] = max(active_with_role["Security"], 5)
|
||||
|
||||
// Debug code below here, very useful for testing so don't delete please.
|
||||
/*var/debug_message = "Firing random event. "
|
||||
for(var/V in active_with_role)
|
||||
debug_message += "#[V]:[active_with_role[V]] "
|
||||
debug_message += "||| "
|
||||
for(var/V in possibleEvents)
|
||||
debug_message += "[V]:[possibleEvents[V]]"
|
||||
message_admins(debug_message)*/
|
||||
|
||||
var/picked_event = pickweight(possibleEvents)
|
||||
if(!picked_event)
|
||||
return
|
||||
@@ -160,32 +169,32 @@
|
||||
for(var/mob/M in player_list)
|
||||
if(!M.client || M.client.inactivity > 10 * 10 * 60) // longer than 10 minutes AFK counts them as inactive
|
||||
continue
|
||||
switch(role)
|
||||
if("Engineer")
|
||||
if(istype(M, /mob/living/silicon/robot) && M:module && M:module.name == "engineering robot module")
|
||||
active_with_role["Engineer"]++
|
||||
if(M.mind.assigned_role in list("Chief Engineer", "Station Engineer"))
|
||||
active_with_role["Engineer"]++
|
||||
if("Medical")
|
||||
if(istype(M, /mob/living/silicon/robot) && M:module && M:module.name == "medical robot module")
|
||||
active_with_role["Medical"]++
|
||||
if(M.mind.assigned_role in list("Chief Medical Officer", "Medical Doctor"))
|
||||
active_with_role["Medical"]++
|
||||
if("Security")
|
||||
if(istype(M, /mob/living/silicon/robot) && M:module && M:module.name == "security robot module")
|
||||
active_with_role["Security"]++
|
||||
if(M.mind.assigned_role in security_positions)
|
||||
active_with_role["Security"]++
|
||||
if("Scientist")
|
||||
if(M.mind.assigned_role in list("Research Director", "Scientist"))
|
||||
active_with_role["Scientist"]++
|
||||
if("AI")
|
||||
if(M.mind.assigned_role == "AI")
|
||||
active_with_role["AI"]++
|
||||
if("Cyborg")
|
||||
if(M.mind.assigned_role == "Cyborg")
|
||||
active_with_role["Cyborg"]++
|
||||
if("Janitor")
|
||||
if(M.mind.assigned_role == "Janitor")
|
||||
active_with_role["Janitor"]++
|
||||
|
||||
if(istype(M, /mob/living/silicon/robot) && M:module && M:module.name == "engineering robot module")
|
||||
active_with_role["Engineer"]++
|
||||
if(M.mind.assigned_role in list("Chief Engineer", "Station Engineer"))
|
||||
active_with_role["Engineer"]++
|
||||
|
||||
if(istype(M, /mob/living/silicon/robot) && M:module && M:module.name == "medical robot module")
|
||||
active_with_role["Medical"]++
|
||||
if(M.mind.assigned_role in list("Chief Medical Officer", "Medical Doctor"))
|
||||
active_with_role["Medical"]++
|
||||
|
||||
if(istype(M, /mob/living/silicon/robot) && M:module && M:module.name == "security robot module")
|
||||
active_with_role["Security"]++
|
||||
if(M.mind.assigned_role in security_positions)
|
||||
active_with_role["Security"]++
|
||||
|
||||
if(M.mind.assigned_role in list("Research Director", "Scientist"))
|
||||
active_with_role["Scientist"]++
|
||||
|
||||
if(M.mind.assigned_role == "AI")
|
||||
active_with_role["AI"]++
|
||||
|
||||
if(M.mind.assigned_role == "Cyborg")
|
||||
active_with_role["Cyborg"]++
|
||||
|
||||
if(M.mind.assigned_role == "Janitor")
|
||||
active_with_role["Janitor"]++
|
||||
|
||||
return active_with_role
|
||||
|
||||
@@ -3,8 +3,7 @@ var/list/potentialRandomEvents = typesof(/datum/event) - /datum/event
|
||||
//var/list/potentialRandomEvents = typesof(/datum/event) - /datum/event - /datum/event/spider_infestation - /datum/event/alien_infestation
|
||||
|
||||
var/eventTimeLower = 15000 //15 minutes
|
||||
var/eventTimeUpper = 30000 //45 minutes
|
||||
|
||||
var/eventTimeUpper = 30000 //30 minutes
|
||||
var/scheduledEvent = null
|
||||
|
||||
|
||||
@@ -19,17 +18,17 @@ var/scheduledEvent = null
|
||||
/proc/checkEvent()
|
||||
if(!scheduledEvent)
|
||||
//more players = more time between events, less players = less time between events
|
||||
var/playercount_modifier = 0.5
|
||||
var/playercount_modifier = 1
|
||||
switch(player_list.len)
|
||||
if(0 to 10)
|
||||
playercount_modifier = 1.2
|
||||
if(11 to 15)
|
||||
playercount_modifier = 1.1
|
||||
if(16 to 20)
|
||||
if(16 to 25)
|
||||
playercount_modifier = 1
|
||||
if(21 to 25)
|
||||
if(26 to 35)
|
||||
playercount_modifier = 0.9
|
||||
if(26 to 100000)
|
||||
if(36 to 100000)
|
||||
playercount_modifier = 0.8
|
||||
scheduledEvent = world.timeofday + rand(eventTimeLower, eventTimeUpper) * playercount_modifier
|
||||
|
||||
@@ -63,4 +62,4 @@ var/scheduledEvent = null
|
||||
|
||||
if(ispath(type))
|
||||
new type
|
||||
message_admins("[key_name_admin(usr)] has triggered an event. ([type])", 1)
|
||||
message_admins("[key_name_admin(usr)] has triggered an event. ([type])", 1)
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
|
||||
#define VERM_MICE 0
|
||||
#define VERM_LIZARDS 1
|
||||
#define VERM_SLIMES 2
|
||||
#define VERM_SPIDERS 2
|
||||
|
||||
/datum/event/infestation
|
||||
announceWhen = 10
|
||||
@@ -70,32 +70,30 @@
|
||||
turfs += F
|
||||
|
||||
var/list/spawn_types = list()
|
||||
var/max_number
|
||||
vermin = rand(0,2)
|
||||
switch(vermin)
|
||||
if(VERM_MICE)
|
||||
spawn_types = list(/mob/living/simple_animal/mouse/gray, /mob/living/simple_animal/mouse/brown, /mob/living/simple_animal/mouse/white)
|
||||
max_number = 12
|
||||
vermstring = "mice"
|
||||
if(VERM_LIZARDS)
|
||||
spawn_types = list(/mob/living/simple_animal/lizard)
|
||||
max_number = 6
|
||||
vermstring = "lizards"
|
||||
if(VERM_SLIMES)
|
||||
spawn_types = list(/mob/living/carbon/slime)
|
||||
max_number = 3
|
||||
vermstring = "slimes"
|
||||
|
||||
if(VERM_SPIDERS)
|
||||
spawn_types = list(/obj/effect/spider/spiderling)
|
||||
max_number = 6
|
||||
vermstring = "spiders"
|
||||
spawn(0)
|
||||
var/num = rand(2,max_number)
|
||||
var/num = rand(1, 3)
|
||||
while(turfs.len > 0 && num > 0)
|
||||
var/turf/simulated/floor/T = pick(turfs)
|
||||
turfs.Remove(T)
|
||||
var/spawn_type = pick(spawn_types)
|
||||
new spawn_type(T)
|
||||
num--
|
||||
//world << "[vermstring] spawned in [spawn_area_type]"
|
||||
|
||||
if(vermin == VERM_SPIDERS)
|
||||
var/obj/effect/spider/spiderling/S = new(T)
|
||||
S.amount_grown = -1
|
||||
else
|
||||
var/spawn_type = pick(spawn_types)
|
||||
new spawn_type(T)
|
||||
/datum/event/infestation/announce()
|
||||
command_alert("Bioscans indicate that [vermstring] have been breeding in [locstring]. Clear them out, before this starts to affect productivity.", "Vermin infestation")
|
||||
|
||||
@@ -111,4 +109,4 @@
|
||||
|
||||
#undef VERM_MICE
|
||||
#undef VERM_LIZARDS
|
||||
#undef VERM_SLIMES
|
||||
#undef VERM_SPIDERS
|
||||
@@ -8,7 +8,7 @@ datum/event/viral_infection/setup()
|
||||
severity = rand(1, 3)
|
||||
|
||||
datum/event/viral_infection/announce()
|
||||
command_alert("Confirmed outbreak of level [severity + rand(2,3)] biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert")
|
||||
command_alert("Confirmed outbreak of level five biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert")
|
||||
world << sound('sound/AI/outbreak5.ogg')
|
||||
|
||||
datum/event/viral_infection/start()
|
||||
|
||||
@@ -8,7 +8,7 @@ datum/event/viral_outbreak/setup()
|
||||
severity = rand(2, 4)
|
||||
|
||||
datum/event/viral_outbreak/announce()
|
||||
command_alert("Confirmed outbreak of level [severity + rand(3,5)] biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert")
|
||||
command_alert("Confirmed outbreak of level 7 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert")
|
||||
world << sound('sound/AI/outbreak7.ogg')
|
||||
|
||||
datum/event/viral_outbreak/start()
|
||||
|
||||
@@ -34,6 +34,13 @@
|
||||
for(var/mob/M in view())
|
||||
M << 'sound/effects/mousesqueek.ogg'
|
||||
|
||||
if(prob(0.5) && stat == CONSCIOUS)
|
||||
stat = UNCONSCIOUS
|
||||
icon_state = "mouse_[color]_sleep"
|
||||
if(stat == UNCONSCIOUS && prob(1))
|
||||
stat = CONSCIOUS
|
||||
icon_state = "mouse_[color]"
|
||||
|
||||
/mob/living/simple_animal/mouse/New()
|
||||
..()
|
||||
if(!color)
|
||||
|
||||
@@ -382,11 +382,30 @@
|
||||
*/
|
||||
|
||||
/datum/sprite_accessory/hair
|
||||
tentacle_m
|
||||
name = "Skrell Male Tentacles"
|
||||
icon_state = "skrell_hair_m"
|
||||
species_allowed = list("Skrell")
|
||||
gender = MALE
|
||||
spines_long
|
||||
name = "Long Unathi Spines"
|
||||
icon_state = "soghun_longspines"
|
||||
species_allowed = list("Unathi")
|
||||
|
||||
spines_short
|
||||
name = "Short Unathi Spines"
|
||||
icon_state = "soghun_shortspines"
|
||||
species_allowed = list("Unathi")
|
||||
|
||||
frills_long
|
||||
name = "Long Unathi Frills"
|
||||
icon_state = "soghun_longfrills"
|
||||
species_allowed = list("Unathi")
|
||||
|
||||
frills_short
|
||||
name = "Short Unathi Frills"
|
||||
icon_state = "soghun_shortfrill"
|
||||
species_allowed = list("Unathi")
|
||||
|
||||
horns
|
||||
name = "Unathi Horns"
|
||||
icon_state = "soghun_horns"
|
||||
species_allowed = list("Unathi")
|
||||
|
||||
tentacle_f
|
||||
name = "Skrell Female Tentacles"
|
||||
@@ -499,6 +518,7 @@
|
||||
name = "Smallsatche"
|
||||
icon_state = "facial_smallstache"
|
||||
species_allowed = list("Tajaran")
|
||||
|
||||
//skin styles - WIP
|
||||
//going to have to re-integrate this with surgery
|
||||
//let the icon_state hold an icon preview for now
|
||||
|
||||
@@ -186,6 +186,9 @@
|
||||
M.powernet = PN
|
||||
P = M.get_connections()
|
||||
|
||||
else
|
||||
return
|
||||
|
||||
if(P.len == 0) return
|
||||
|
||||
O = P[1]
|
||||
|
||||
@@ -43,14 +43,14 @@
|
||||
toxmob(A)
|
||||
if((istype(A,/obj/machinery/the_singularitygen))||(istype(A,/obj/machinery/singularity/)))
|
||||
A:energy += energy
|
||||
else if( istype(A,/obj/machinery/rust/particle_catcher) )
|
||||
var/obj/machinery/rust/particle_catcher/collided_catcher = A
|
||||
else if( istype(A,/obj/effect/rust_particle_catcher) )
|
||||
var/obj/effect/rust_particle_catcher/collided_catcher = A
|
||||
if(particle_type && particle_type != "neutron")
|
||||
if(collided_catcher.AddParticles(particle_type, 1 + additional_particles))
|
||||
collided_catcher.parent.AddEnergy(energy,mega_energy)
|
||||
del (src)
|
||||
else if( istype(A,/obj/machinery/rust/core) )
|
||||
var/obj/machinery/rust/core/collided_core = A
|
||||
else if( istype(A,/obj/machinery/power/rust_core) )
|
||||
var/obj/machinery/power/rust_core/collided_core = A
|
||||
if(particle_type && particle_type != "neutron")
|
||||
if(collided_core.AddParticles(particle_type, 1 + additional_particles))
|
||||
var/energy_loss_ratio = abs(collided_core.owned_field.frequency - frequency) / 1e9
|
||||
|
||||
Reference in New Issue
Block a user