Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Another anomalies patch #3068

Merged
merged 49 commits into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
648ed42
Яддрооо
AmShegars Jan 4, 2025
84d8ae9
debug fix
AmShegars Jan 4, 2025
cfe49da
Дал детектор артов ЛЭКу
AmShegars Jan 4, 2025
df9140c
Merge branch 'dev-sierra' into anomaly_update
AmShegars Jan 4, 2025
d3ba634
Merge branch 'dev-sierra' into anomaly_update
AmShegars Jan 4, 2025
2a19385
Ещё пачка
AmShegars Jan 4, 2025
b7b148d
Merge branch 'anomaly_update' of https://github.com/SierraBay/SierraB…
AmShegars Jan 4, 2025
7a39d47
skrell
AmShegars Jan 4, 2025
dc18a19
dam
AmShegars Jan 4, 2025
251fbf9
list fixes
AmShegars Jan 4, 2025
578f1cf
map_fixes
AmShegars Jan 4, 2025
abcd924
fix
AmShegars Jan 4, 2025
c26e1eb
fix
AmShegars Jan 4, 2025
d8afb2c
bam
AmShegars Jan 4, 2025
0e2852a
map_fixes
AmShegars Jan 4, 2025
98072e8
test
AmShegars Jan 4, 2025
a3df810
test
AmShegars Jan 4, 2025
f4b8030
fix
AmShegars Jan 4, 2025
6c3b0d6
dam
AmShegars Jan 4, 2025
e63c1cf
Merge branch 'dev-sierra' into anomaly_update
AmShegars Jan 4, 2025
9ea26f8
fixes
AmShegars Jan 4, 2025
82c769e
Merge branch 'anomaly_update' of https://github.com/SierraBay/SierraB…
AmShegars Jan 4, 2025
068401d
fix maybe
AmShegars Jan 4, 2025
1f627cc
fixes
AmShegars Jan 4, 2025
1dd071d
detector
AmShegars Jan 4, 2025
98faef1
bam
AmShegars Jan 5, 2025
f82023f
Merge branch 'dev-sierra' into anomaly_update
AmShegars Jan 5, 2025
cac1e96
Delete d.dm
AmShegars Jan 5, 2025
fcd809c
Merge branch 'anomaly_update' of https://github.com/SierraBay/SierraB…
AmShegars Jan 5, 2025
e1e4616
вылавливание проблемной руины
AmShegars Jan 6, 2025
c5bf4e1
Merge branch 'dev-sierra' into anomaly_update
AmShegars Jan 6, 2025
0bed60e
ловлю ловлю
AmShegars Jan 6, 2025
dc16bd5
Merge branch 'anomaly_update' of https://github.com/SierraBay/SierraB…
AmShegars Jan 6, 2025
65b350e
интересно, вернул все руины обратно
AmShegars Jan 6, 2025
ebb4b4a
ловлю
AmShegars Jan 6, 2025
3c37cbe
ловлю...
AmShegars Jan 6, 2025
df9fe28
Update _anomaly.dme
AmShegars Jan 6, 2025
3946382
test
AmShegars Jan 6, 2025
efb4424
test
AmShegars Jan 6, 2025
e5ce628
lol
AmShegars Jan 6, 2025
11433f8
бункир
AmShegars Jan 6, 2025
555a70a
бункир, генератор
AmShegars Jan 6, 2025
576f1fc
test
AmShegars Jan 6, 2025
61dc834
test
AmShegars Jan 6, 2025
ba7eaf0
suka
AmShegars Jan 6, 2025
2ff21b7
тим плей
AmShegars Jan 6, 2025
1963da9
Merge branch 'dev-sierra' into anomaly_update
AmShegars Jan 7, 2025
ebc0635
bam
AmShegars Jan 7, 2025
17b77d8
мелкий фикс процессинга и детектора
AmShegars Jan 7, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions maps/sierra/z1-z5_sierra.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -45041,6 +45041,7 @@
},
/obj/item/storage/bolt_bag/full_of_beacons,
/obj/item/clothing/gloves/anomaly_detector,
/obj/item/artefact_detector,
/turf/simulated/floor/tiled,
/area/command/exploration_leader)
"gDH" = (
Expand Down
2 changes: 1 addition & 1 deletion mods/RnD/code/tech_engineering.dm
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@
required_tech_levels = list()
cost = 500

unlocks_designs = list("depth_scanner", "ano_scanner", "pick_set", "collector")
unlocks_designs = list("depth_scanner", "ano_scanner", "pick_set", "collector", "anomaly_detector", "electro_beacon")


/datum/technology/engineering/excavation_drill
Expand Down
4 changes: 2 additions & 2 deletions mods/anomaly/_anomaly.dm
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/singleton/modpack/colony_types
/singleton/modpack/anomaly
name = "Интерактивные аномалии"
desc = "Добавляет в игру полноценные аномалии, вдохновлённые Ашаном, пикником на обочине и сталкером."
author = "Shegar"
author = "Shegar(Код), HonkByEmo(Спрайты), AK200(Спрайты)"
27 changes: 14 additions & 13 deletions mods/anomaly/_anomaly.dme
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,11 @@
#include "code\artefacts\artefact_flyer.dm"
//#include "code\artefacts\artefact_zjemchug.dm"


//Код больших артефактов
#include "code\big_artefacts\_core.dm"
#include "code\big_artefacts\gravi_concetration.dm"
#include "code\big_artefacts\electra_gem.dm"
#include "code\big_artefacts\fire_ball.dm"

//Детекторы и прочее оборудование
#include "code\detectors_and_etc\bolt.dm"
Expand All @@ -66,22 +70,18 @@
#include "code\detectors_and_etc\deployer.dm"
#include "code\detectors_and_etc\beacon.dm"
#include "code\detectors_and_etc\research_machine.dm"
#include "code\detectors_and_etc\artefact_detector.dm"
#include "code\detectors_and_etc\rig_detector.dm"
#include "code\detectors_and_etc\flux_detector.dm"



//Погода и эффекты на мониторе
#include "code\monitor_effects\monitor_core.dm"
#include "code\monitor_effects\monitor_vars.dm"
#include "code\monitor_effects\snow_monitor_effect.dm"
#include "code\monitor_effects\swamp_monitor_effect.dm"
#include "code\monitor_effects\vulcan_monitor_effect.dm"

#include "code\anomalies\anomaly_teamplay.dm" //Помощь игрокам друг другу в аномалии

//Размещение аномалий в игре
#include "code\spawn_anomalies_protocol\core_spawn_protocol.dm"
#include "code\spawn_anomalies_protocol\spawn_anomaly_with_big_artefact.dm" //Код, отвечающий за спавн аномалий вокруг больших артефактов
#include "code\spawn_anomalies_protocol\spawn_with_ruins.dm"
#include "code\spawn_anomalies_protocol\bsd_event_protocol.dm"
#include "code\spawn_anomalies_protocol\planet_big_artefacts.dm"
//Планетарный спавн
#include "code\spawn_anomalies_protocol\planet_spawn_protocol\_planet_spawn_core.dm"
//Летающие острова[WIP]
Expand All @@ -90,16 +90,17 @@
//Ледяная планета[WIP]
#include "code\spawn_anomalies_protocol\planet_spawn_protocol\ice.dm"
//Вулкан
#include "code\spawn_anomalies_protocol\planet_spawn_protocol\vulcanic.dm"
//Саргасово болото [WIP-WIP]
// #include "code\spawn_anomalies_protocol\planet_spawn_protocol\sargas.dm"
#include "code\spawn_anomalies_protocol\spawn_on_planet.dm" //Спавн на планетах


#include "code\spawn_anomalies_protocol\planet_spawn_protocol\another_planets.dm"

//Карты, диреликты и прочее
#include "maps\electra_ruins\electra_ruins.dm"
#include "maps\zharka_ruins\zharka_ruins.dm"
#include "maps\electra_ruins\garage.dm"
//#include "maps\electra_ruins\bunker.dm"
//#include "maps\electra_ruins\deployed_generator.dm"
//Код островов
#include "maps\flying_islands\flying_island.dm"
#include "maps\flying_islands\flying_island_ball.dm"
Expand Down
15 changes: 15 additions & 0 deletions mods/anomaly/code/anomalies/anomaly_teamplay.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/obj/anomaly/part/handle_human_teamplay(mob/living/carbon/human/target, mob/living/carbon/human/helper)
core.handle_human_teamplay(target, helper)

/obj/anomaly/proc/handle_human_teamplay(mob/living/carbon/human/target, mob/living/carbon/human/helper)
visible_message(SPAN_GOOD("[helper] с силой дёргает [target] на себя!"))
target.forceMove(get_turf(helper))
target.Weaken(5)
helper.Weaken(5)


/mob/living/carbon/help_shake_act(mob/living/carbon/M)
if(isanomalyhere(get_turf(src)))
var/obj/anomaly/handled_anomaly = locate() in get_turf(src)
handled_anomaly.handle_human_teamplay(src, M)
..()
10 changes: 7 additions & 3 deletions mods/anomaly/code/anomalies/single/electra.dm
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@
anomaly.activate_anomaly(FALSE)

/obj/anomaly/electra/get_effect_by_anomaly(atom/movable/target)
set waitfor = FALSE
//Понадобится нам, если обьект по какой-либо причине будет удалён из-за удара, дабы "лучу" было куда идти
var/target_turf = get_turf(target)
if(!isturf(target.loc))
Expand All @@ -87,7 +88,10 @@
return
//Если цель подходит под критерии удара, мы рисуем молнию
var/create_line = FALSE

if(isaurora(target))
var/obj/structure/aurora/aurora = target
aurora.wake_up(rand(5 SECONDS, 10 SECONDS))
create_line = TRUE



Expand Down Expand Up @@ -128,7 +132,7 @@
var/mob/living/carbon/human/victim = target
if(victim.health == 0)
SSanom.add_last_gibbed(target, "Электра")
anything_in_remains(victim)
victim.dust()
return

if(victim.lying) //Если цель лежит нам не нужно просчитывать путь до земли. Просто делаем удар в любую конечность
Expand Down Expand Up @@ -158,7 +162,7 @@
create_line = TRUE
var/mob/living/victim = target
if(victim.health == 0)
anything_in_remains(victim)
victim.dust()
return
victim.electoanomaly_act(100, src)

Expand Down
24 changes: 24 additions & 0 deletions mods/anomaly/code/anomalies/single/rvach.dm
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,12 @@
Weaken(5)

/mob/living/carbon/human/rvach_anomaly_pull(turf/target, current_size)
//На не лежачих не воздействуем.
if(get_turf(target) == get_turf(src))
Weaken(5)
return
if(!lying)
return
if(get_turf(target) != get_turf(src))
step_towards(src, target)
Weaken(5)
Expand All @@ -164,6 +170,10 @@
O.forceMove(get_turf(src))
else if(can_be_activated(O))
activate_anomaly()
step_towards(O, src)
if(isliving(O))
var/mob/living/detected_living = O
detected_living.Weaken(5)

//Человек пытается выбраться из рвача FALSE - не даём вылезти, TRUE - даём
/obj/anomaly/rvach/Uncross(O)
Expand All @@ -187,5 +197,19 @@
helper.Weaken(5)
return TRUE

/obj/anomaly/rvach/handle_human_teamplay(mob/living/carbon/human/target, mob/living/carbon/human/helper)
visible_message(SPAN_GOOD("[helper] с силой дёргает [target] на себя!"))
var/turf/target_turf = get_ranged_target_turf(target, get_dir(target, helper), 2)
if(TurfBlocked(target_turf))
to_chat(helper, "Чёрт, мне не куда отходить!")
target.forceMove(get_turf(helper))
target.Weaken(5)
helper.Weaken(5)
else
target.forceMove(target_turf)
helper.forceMove(target_turf)
target.Weaken(5)
helper.Weaken(5)

/obj/anomaly/rvach/get_detection_icon()
return "rvach_detection"
3 changes: 2 additions & 1 deletion mods/anomaly/code/anomaly_controller.dm
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,8 @@ PROCESSING_SUBSYSTEM_DEF(anom)
var/interactions_with_artefacts_by_players_ammount = 0
var/bad_interactions_with_artefacts_by_players_ammount = 0
var/good_interactions_with_artefacts_by_players_ammount = 0

//Большие артефакты
var/list/big_anomaly_artefacts = list()


//[ИНФА ПО АНОМАЛИЯМ]
Expand Down
2 changes: 2 additions & 0 deletions mods/anomaly/code/artefacts/_anomaly_artefacts.dm
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,13 @@
if(AnomaliesAmmountInTurf(get_turf(src)) == 0)
connected_to_anomaly = FALSE
input_collector.try_insert_artefact(user, src)
SSanom.collected_artefacts_by_player++
else
for(var/obj/anomaly/anomka in src.loc.contents)
if(prob(25 * user.get_skill_value(SKILL_SCIENCE)))
to_chat(user, SPAN_GOOD("Вы аккуратно, при помощи специальных щупов, помещаете обьект в контейнер."))
connected_to_anomaly = FALSE
SSanom.collected_artefacts_by_player++
input_collector.try_insert_artefact(user, src)
else
to_chat(user, SPAN_WARNING("Обьект уплывает из хвата щупов"))
Expand Down
1 change: 1 addition & 0 deletions mods/anomaly/code/artefacts/_artefact_processing.dm
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
//Артефакт процессится абсолютно всегда в силу того что невозможно без изменения кор кода предотвратить ситуации, когда артефакт
//Не влият на носителя, например при скидывании на пол и поднятии рюкзака обратно (Как сообщить артефакту о этм событии? Срать в код.)
/obj/item/artefact/Process()
..()
if(world.time - last_long_user_check >= user_long_check_cooldown)
last_long_user_check = world.time
additional_process()
Expand Down
66 changes: 66 additions & 0 deletions mods/anomaly/code/big_artefacts/_core.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
/obj/structure/big_artefact
name = "Something"
desc = "A large something."
icon = 'mods/anomaly/icons/big_artefacts.dmi'
density = TRUE
waterproof = FALSE
var/min_anomalies_ammout = 100
var/max_anomalies_ammout = 200
var/min_artefacts_ammount = 1
var/max_artefacts_ammount = 2
var/range_spawn = 30
var/list/possible_anomalies = list()

/obj/structure/big_artefact/Initialize()
. = ..()
born_anomalies()

///Функция, которая заспавнит вокруг большого артефакта аномалии
/obj/structure/big_artefact/proc/born_anomalies()
set background = 1
var/started_in = world.time
var/list/turfs_for_spawn = list()
//У нас нет турфа?
if(!src.loc)
return
//Собираем все турфы в определённом радиусе
for(var/turf/turfs in RANGE_TURFS(src.loc, range_spawn))
if(!TurfBlocked(turfs) || TurfBlockedByAnomaly(turfs))
LAZYADD(turfs_for_spawn, turfs)
generate_anomalies_in_turfs(possible_anomalies, turfs_for_spawn, min_anomalies_ammout, max_anomalies_ammout, min_artefacts_ammount, max_artefacts_ammount, null, null, "big artefact generation", started_in)

/obj/structure/big_artefact/shuttle_land_on()
delete_artefact()

/obj/structure/big_artefact/proc/delete_artefact()
LAZYREMOVE(SSanom.big_anomaly_artefacts, src)
qdel(src)

/obj/structure/big_artefact/MouseDrop(obj/machinery/anomaly_container/over_object, mob/user)
if(istype(over_object) && CanMouseDrop(over_object, usr))
if (over_object.health_dead())
visible_message(SPAN_WARNING("\The [over_object]'s containment is broken shut."))
return
if (!over_object.allowed(usr))
visible_message(SPAN_WARNING("\The [over_object] blinks red, refusing to open."))
return
user.visible_message(
SPAN_NOTICE("\The [usr] begins placing \the [src] into \the [over_object]."),
SPAN_NOTICE("You begin placing \the [src] into \the [over_object].")
)
if(!do_after(usr, 4 SECONDS, over_object, DO_PUBLIC_UNIQUE))
return
user.visible_message(SPAN_NOTICE("The bolts on \the [over_object] drop with an hydraulic hiss, sealing its contents."))
playsound(loc, 'sound/mecha/hydraulic.ogg', 40)
Bumped(usr)
over_object.contain(src)
return

/obj/structure/big_artefact/forceMove()
..()
if(is_processing)
if(get_turf(src) != loc)
STOP_PROCESSING(SSanom, src)
else
if(get_turf(src) == loc)
START_PROCESSING(SSanom, src)
40 changes: 40 additions & 0 deletions mods/anomaly/code/big_artefacts/electra_gem.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/obj/structure/big_artefact/electra
icon_state = "electra_anomalies"
min_anomalies_ammout = 70
max_anomalies_ammout = 150
range_spawn = 30
possible_anomalies = list(
/obj/anomaly/electra/three_and_three = 1,
/obj/anomaly/electra/three_and_three/tesla = 2,
/obj/anomaly/electra/three_and_three/tesla_second = 3,
/obj/anomaly/cooler/two_and_two = 1,
/obj/anomaly/cooler/three_and_three = 1
)
//
var/datum/beam = null
var/last_electra_attack
var/electra_attack_cooldown

/obj/structure/big_artefact/electra/Initialize()
.=..()
if(!is_processing)
START_PROCESSING(SSanom, src)
electra_attack_cooldown = rand(20 SECONDS, 50 SECONDS)
last_electra_attack = world.time

//Пусть кусается молниями в пределах 3 турфов.
/obj/structure/big_artefact/electra/Process()
if(world.time - last_electra_attack > electra_attack_cooldown)
electra_attack()

/obj/structure/big_artefact/electra/proc/electra_attack()
set waitfor = FALSE
last_electra_attack = world.time
var/turf/picked_turf
picked_turf = pick(RANGE_TURFS(src, 3))
for(var/mob/living/picked_living in picked_turf)
picked_living.electoanomaly_act(50, src)
for(var/obj/structure/aurora/picked_aurora in picked_turf)
picked_aurora.wake_up(5 SECONDS)
beam = src.Beam(BeamTarget = picked_turf, icon_state = "electra_long",icon='mods/anomaly/icons/effects.dmi',time = 0.3 SECONDS)
playsound(src, 'mods/anomaly/sounds/electra_blast.ogg', 100, FALSE )
9 changes: 9 additions & 0 deletions mods/anomaly/code/big_artefacts/fire_ball.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
/obj/structure/big_artefact/hot
icon_state = "hot_anomalies"
min_anomalies_ammout = 100
max_anomalies_ammout = 200
range_spawn = 30
possible_anomalies = list(
/obj/anomaly/zharka/short_effect = 1,
/obj/anomaly/zharka/long_effect = 2,
)
32 changes: 32 additions & 0 deletions mods/anomaly/code/big_artefacts/gravi_concetration.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/obj/structure/big_artefact/gravi
icon_state = "gravi_anomalies"
min_anomalies_ammout = 60
max_anomalies_ammout = 120
range_spawn = 30
possible_anomalies = list(
/obj/anomaly/thamplin/random = 2,
/obj/anomaly/rvach/three_and_three = 1
)
var/last_gravi_attack
var/gravi_attack_cooldown

/obj/structure/big_artefact/gravi/Initialize()
.=..()
if(!is_processing)
START_PROCESSING(SSanom, src)
gravi_attack_cooldown = rand(20 SECONDS, 50 SECONDS)
last_gravi_attack = world.time

/obj/structure/big_artefact/gravi/Process()
if(world.time -last_gravi_attack > gravi_attack_cooldown)
gravi_attack()

/obj/structure/big_artefact/gravi/proc/gravi_attack()
set waitfor = FALSE
last_gravi_attack = world.time
for(var/turf/picked_turf in RANGE_TURFS(src, 5))
for(var/mob/living/picked_living in picked_turf)
picked_living.Weaken(3)
picked_living.stun_effect_act(3,1)
to_chat(picked_living, SPAN_WARNING("Что-то с силой прижимает вас к земле."))
shake_camera(picked_living, 3, 1)
Loading
Loading