Skip to content

Commit

Permalink
bam2
Browse files Browse the repository at this point in the history
У грави появился звук
Убрал возможный лагогенератор от погоды
Исправил анимацию включения выключения у детекторов
Русифицировал все логи игроку и админам
  • Loading branch information
AmShegars committed Jan 22, 2025
1 parent a81870a commit 0ef7753
Show file tree
Hide file tree
Showing 27 changed files with 57 additions and 56 deletions.
2 changes: 1 addition & 1 deletion mods/anomaly/code/anomalies/anomaly_core.dm
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@
if(ranzomize_with_initialize)
ranzomize_parameters()
icon_state = idle_effect_type
if(have_static_sound)
if(static_sound_type)
GLOB.sound_player.PlayLoopingSound(src, "\ref[src]", static_sound_type, 10, 6)
if(detectable_effect_range)
calculate_effected_turfs_from_new_anomaly(src)
Expand Down
4 changes: 1 addition & 3 deletions mods/anomaly/code/anomalies/anomaly_sound.dm
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@
var/sound_type
///Мощность аномалии
var/effect_power = MOMENTUM_ANOMALY_EFFECT
//У аномалии есть статичный звук
var/have_static_sound = FALSE
//Путь до звука статики
var/static_sound_type = 'mods/anomaly/sounds/any_idle.ogg'
var/static_sound_type

var/preload_sound_type
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
/obj/item/artefact/pruzhina = 80,
/obj/item/artefact/svetlyak = 20
)
have_static_sound = TRUE
var/play_sound_second_time = FALSE //Костыль, чтоб тесла при ударе по целям вдаль тоже играла звук удара
static_sound_type = 'mods/anomaly/sounds/electra_idle.ogg'
var/datum/beam = null
Expand Down Expand Up @@ -71,11 +70,14 @@

/obj/anomaly/electra/get_effect_by_anomaly(atom/movable/target)
set waitfor = FALSE
set background = TRUE
electroanomaly_act(target, src)


///Функция обрабатывающее влияние электроаномалии на цель
/proc/electroanomaly_act(atom/movable/target, obj/anomaly/electra/input_electra, called_by_tesla = FALSE)
set waitfor = FALSE
set background = TRUE
//Понадобится нам, если обьект по какой-либо причине будет удалён из-за удара, дабы "лучу" было куда идти
var/target_turf = get_turf(target)
if(!isturf(target.loc))
Expand Down
1 change: 1 addition & 0 deletions mods/anomaly/code/anomalies/anomaly_types/rvach.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
anomaly_tag = "Rvach"
with_sound = TRUE
sound_type = 'mods/anomaly/sounds/rvach_activation.ogg'
static_sound_type = 'mods/anomaly/sounds/gravi_idle.ogg'
idle_effect_type = "rvach_idle"
activation_effect_type = "gravy_anomaly_down"
detection_icon_state = "hot_anomaly"
Expand Down
6 changes: 1 addition & 5 deletions mods/anomaly/code/big_artefacts/_core.dm
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,6 @@
var/range_spawn = 30
var/list/possible_anomalies = list()

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

///Функция, которая заспавнит вокруг большого артефакта аномалии
/obj/structure/big_artefact/proc/born_anomalies(biggest_x, biggest_y)
set background = 1
Expand All @@ -27,7 +23,7 @@
for(var/turf/choosed_turf in RANGE_TURFS(src.loc, range_spawn))
if(!TurfBlocked(choosed_turf) || TurfBlockedByAnomaly(choosed_turf) && turf_in_playable_place(choosed_turf, biggest_x, biggest_y))
LAZYADD(turfs_for_spawn, choosed_turf)
generate_anomalies_in_turfs(possible_anomalies, turfs_for_spawn, min_anomalies_ammout, max_anomalies_ammout, min_artefacts_ammount, max_artefacts_ammount, null, null, "big anomaly artefact generation", started_in)
generate_anomalies_in_turfs(possible_anomalies, turfs_for_spawn, min_anomalies_ammout, max_anomalies_ammout, min_artefacts_ammount, max_artefacts_ammount, null, null, "Большой аномальный артефакт", started_in)

/obj/structure/big_artefact/shuttle_land_on()
delete_artefact()
Expand Down
6 changes: 3 additions & 3 deletions mods/anomaly/code/detectors_and_etc/bolt.dm
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

/obj/item/storage/bolt_bag/examine(mob/user, distance, is_adjacent)
. = ..()
to_chat(user, SPAN_GOOD("Use RBM and use Toggle autocollect to toggle autocollect."))
to_chat(user, SPAN_GOOD("Нажмите ПКМ по мешку, выберите toggle autocollect для переключения режима автоподбора."))

/obj/item/storage/bolt_bag/verb/toggle_autocollect()
set category = "Object"
Expand All @@ -43,9 +43,9 @@

autocollect = !autocollect
if(autocollect)
to_chat(usr, SPAN_NOTICE("Now you will automaticly collect bolts and beacons in this bag."))
to_chat(usr, SPAN_GOOD("Теперь вы автоматически складываете болты/маяки в мешочек при пересечении с ними."))
else
to_chat(usr, SPAN_NOTICE("Now you will NOT automaticly collect bolts and beacons in this bag."))
to_chat(usr, SPAN_BAD("Больше вы НЕ складываете автоматически болты/маяки в мешочек при пересечении с ними."))

/obj/item/storage/bolt_bag/full_of_bolts
startswith = list(
Expand Down
7 changes: 3 additions & 4 deletions mods/anomaly/code/detectors_and_etc/collector.dm
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@
/obj/item/collector/use_tool(obj/item/item, mob/living/user, list/click_params)
. = ..()
if(closed)
to_chat(user,SPAN_NOTICE("\the [src] clossed."))
to_chat(user,SPAN_NOTICE("\the [src] закрыт."))
return
if(istype(item, /obj/item/artefact))
try_insert_artefact(user, item)


/obj/item/collector/proc/try_insert_artefact(mob/living/user, obj/item/item)
if(!stored_artefact)
to_chat(user,SPAN_NOTICE("You inserted [item] in [src]."))
to_chat(user,SPAN_NOTICE("Вы поместили [item] в [src]."))
insert_artefact(user, item)


Expand All @@ -45,7 +45,7 @@

/obj/item/collector/proc/try_pop_out_artefact(mob/living/user)
if(stored_artefact)
to_chat(user,SPAN_NOTICE("You pop-out [stored_artefact] from [src]."))
to_chat(user,SPAN_NOTICE("Вы вытащили [stored_artefact] из [src]."))
pop_out_artefact(user)


Expand Down Expand Up @@ -126,4 +126,3 @@
materials = list(MATERIAL_ALUMINIUM = 1000, MATERIAL_STEEL = 5000, MATERIAL_GLASS = 2500, MATERIAL_PLASTEEL = 2500, MATERIAL_PLASTIC = 1000)
build_path = /obj/item/collector
sort_string = "VAWAB"

6 changes: 5 additions & 1 deletion mods/anomaly/code/detectors_and_etc/detector.dm
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
desc = "A complex technological device designed taking into account all possible dangers of anomalies."
icon = 'mods/anomaly/icons/detector.dmi'
on_turf_icon = 'mods/anomaly/icons/on_floor_icons/anomaly_radar_on_floor.dmi'
icon_state = "detector_idle"
icon_state = "detector_turned_off"
var/destroyed = FALSE // Детектор убит из-за ЭМИ и уже никогда не проснётся.
//Базовое название детектора используемое в коде смена иконок.
var/detector_basic_name = "detector"
Expand Down Expand Up @@ -44,10 +44,14 @@
to_chat(usr, SPAN_NOTICE("Устройство не реагирует на нажатие кнопки. Похоже, оно уже не включится."))
return
if(!is_processing)
flick("[detector_basic_name]_turning_on", src)
icon_state = "[detector_basic_name]_idle"
to_chat(usr, SPAN_NOTICE("Вы включили детектор"))
START_PROCESSING(SSanom, src)
SSanom.processing_ammount++
else
flick("[detector_basic_name]_turning_off", src)
icon_state = "[detector_basic_name]_turned_off"
to_chat(usr, SPAN_NOTICE("Вы выключили детектор"))
STOP_PROCESSING(SSanom, src)
SSanom.processing_ammount--
Expand Down
2 changes: 1 addition & 1 deletion mods/anomaly/code/detectors_and_etc/flux_detector.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "Flux-detector"
desc = "An extremely complex device created by the Skrell civilization."
icon = 'mods/anomaly/icons/flux_detector.dmi'
icon_state = "flux_undeployed"
icon_state = "flux_turned_off"
detector_basic_name = "flux"
action_button_name = "Scan anomalies"
//Устройство не лезет на кисть.
Expand Down
4 changes: 1 addition & 3 deletions mods/anomaly/code/detectors_and_etc/gurza_detector.dm
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
name = "Gurza"
desc = "An incredibly homemade detector clearly designed by a talented engineer. It is capable of detecting static voltage and determining its direction and distance. Despite its homemade nature, it looks extremely reliable. Apparently, the assembly involved blue duct tape."
icon = 'mods/anomaly/icons/gurza_detector.dmi'
icon_state = "gurza_undeployed"
icon_state = "gurza_turned_off"
detector_basic_name = "gurza"
action_button_name = "Scan anomalies"
//Устройство не лезет на кисть.
Expand All @@ -22,13 +22,11 @@
/obj/item/clothing/gloves/anomaly_detector/gurza/switch_toggle()
if(!is_processing)
to_chat(usr, SPAN_NOTICE("Вы включили детектор."))
flick("gurza_undeploing", src)
icon_state = "gurza_scanning"
usr.update_action_buttons()
START_PROCESSING(SSanom, src)
SSanom.processing_ammount++
else
flick("gurza_deploing", src)
to_chat(usr, SPAN_NOTICE("Вы выключили детектор."))
STOP_PROCESSING(SSanom, src)
icon_state = "gurza_undeployed"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,10 @@
for(var/turf/picked_turf as anything in RANGE_TURFS(picked_drive.loc, 25))
if(!TurfBlocked(picked_turf, space_allowed = FALSE) || TurfBlockedByAnomaly(picked_turf))
LAZYADD(turfs_for_spawn, picked_turf)
all_spawned_anomalies = generate_anomalies_in_turfs(possible_anomalies, turfs_for_spawn, 25, 40, 0, 0, 9, 9, "BSD event", started_in)
all_spawned_anomalies = generate_anomalies_in_turfs(possible_anomalies, turfs_for_spawn, 25, 40, 0, 0, 9, 9, "Пролив БСД", started_in)


/datum/event/bsd_instability/end()
.=..()
for(var/obj/anomaly/picked_anomaly in all_spawned_anomalies)
picked_anomaly.delete_anomaly()

Original file line number Diff line number Diff line change
Expand Up @@ -186,8 +186,8 @@ source - Источник(Причина) генерации аномалий н
var/spended_time = world.time - started_in
//Отчитаемся
if(spawned_anomalies_ammount > 0)
report_progress("Spawned [spawned_anomalies_ammount] anomalies with [spawned_artefacts_ammount] artefacts by: [source], spended [spended_time] ticks ")
LAZYADD(SSanom.important_logs, "Spawned [spawned_anomalies_ammount] anomalies with [spawned_artefacts_ammount] artefacts by: [source], spended [spended_time] ticks ")
report_progress("Создано [spawned_anomalies_ammount] аномалий, создано [spawned_artefacts_ammount] артефактов в них. Источник: [source], затрачено [spended_time] тиков. ")
LAZYADD(SSanom.important_logs, "Создано [spawned_anomalies_ammount] аномалий, создано [spawned_artefacts_ammount] артефактов в них. Источник: [source], затрачено [spended_time] тиков. ")
return spawned_anomalies

///Функция генерация артефактов в аномалиях. Спавнит количество артефактов, находящиеся в диапазоне между min_artefacts_ammoun и max_artefacts_ammount
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@

i++

report_progress("Spawned [spawned_big_artefacts] big anomaly artefacts (Tryed to spawn [result_big_artefacts_amount]) for anomaly planet. Spended [world.time - started_in] ticks ")
report_progress("Создано [spawned_big_artefacts] больших аномальных артефактов (Требовали создать [result_big_artefacts_amount]) для аномальной планеты. Затрачено [world.time - started_in] тиков. ")


/obj/overmap/visitable/sector/exoplanet/proc/collect_good_turfs()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
habitability_weight = HABITABILITY_EXTREME
has_trees = FALSE
flora_diversity = 5
//Следующие руины нам НЕ подойдут из-за того что на облакал они выглядят крайне убого


/obj/overmap/visitable/sector/exoplanet/flying/build_level()
Expand All @@ -41,7 +40,7 @@
var/planet_z = get_z(any_turf)
var/datum/event/change_z_skybox = new /datum/event/change_z_skybox(new /datum/event_meta(EVENT_LEVEL_MAJOR))
change_z_skybox.affecting_z = list(planet_z)
change_z_skybox.setup('mods/anomaly/icons/planet_backgrounds.dmi', "flying")
change_z_skybox.setup('mods/anomaly/icons/planet_backgrounds.dmi', "mods/anomaly/sounds/gravi_planet_wind_1.ogg")
SSskybox.generate_skybox(planet_z)
update_sun()

Expand Down Expand Up @@ -73,8 +72,8 @@
mineral_turf = /turf/simulated/floor/exoplanet/grass

/area/exoplanet/flying
ambience = list('sound/effects/wind/tundra0.ogg','sound/effects/wind/tundra1.ogg','sound/effects/wind/tundra2.ogg','sound/effects/wind/spooky0.ogg','sound/effects/wind/spooky1.ogg')
base_turf = /turf/simulated/floor/exoplanet/grass
ambience = list('sound/effects/wind/tundra0.ogg','mods/anomaly/sounds/gravi_planet_wind_1.ogg')
base_turf = /turf/simulated/floor/exoplanet/clouds



Expand All @@ -85,8 +84,9 @@
var/high_brightness = 2
var/low_color = "#ff9933"
var/high_color = "#ff9933"
var/min = 2
var/max = 2
var/min = 0.70
var/max = 1.0
sun_position = 1

var/interpolate_weight = (sun_position - min) / (max - min)
var/new_brightness = (Interpolate(low_brightness, high_brightness, interpolate_weight) ) * sun_brightness_modifier
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@


/area/exoplanet/ice
ambience = list('sound/effects/wind/tundra0.ogg','sound/effects/wind/tundra1.ogg','sound/effects/wind/tundra2.ogg','sound/effects/wind/spooky0.ogg','sound/effects/wind/spooky1.ogg')
ambience = list('sound/effects/wind/tundra0.ogg','sound/effects/wind/tundra1.ogg','mods/anomaly/sounds/electra_planet_wind_2.ogg')
base_turf = /turf/simulated/floor/exoplanet/ice


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,4 @@
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)
generate_anomalies_in_turfs(possible_anomalies, turfs_for_spawn, min_anomalies_ammout, max_anomalies_ammout, min_artefacts_ammount, max_artefacts_ammount, null, null, "Обычный большой артефакт (Архотек)", started_in)
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
if(!LAZYLEN(all_turfs))
log_and_message_admins("ОШИБКА. В результате анализа планеты, код отвечающий за размещение аномалий на планете не нашёл подходящих турфов.")
CRASH("ОШИБКА. В результате анализа планеты, код отвечающий за размещение аномалий на планете не нашёл подходящих турфов.")
generate_anomalies_in_turfs(anomalies_type, all_turfs, min_anomalies_ammout, max_anomalies_ammout, min_artefacts_ammount, max_artefacts_ammount, min_anomaly_size, max_anomaly_size, "planet generation protocol", started_in)
generate_anomalies_in_turfs(anomalies_type, all_turfs, min_anomalies_ammout, max_anomalies_ammout, min_artefacts_ammount, max_artefacts_ammount, min_anomaly_size, max_anomaly_size, "Планета [name]", started_in)

///Проверяет, что турф находится в играбельной зоне планеты
/proc/turf_in_playable_place(turf/inputed_turf, x_limit, y_limit)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
min_artefacts_ammount = 1
if(!max_artefacts_ammount)
max_artefacts_ammount = 1
generate_anomalies_in_turfs(null, all_turfs_for_spawn, min_anomalies_ammout, max_anomalies_ammout, min_artefacts_ammount, max_artefacts_ammount,min_anomaly_size, max_anomaly_size, "direlict protocol", started_in)
generate_anomalies_in_turfs(null, all_turfs_for_spawn, min_anomalies_ammout, max_anomalies_ammout, min_artefacts_ammount, max_artefacts_ammount,min_anomaly_size, max_anomaly_size, "планетарная руина", started_in)

//Очистка и забытие всех спавнеров.
for(var/obj/anomaly_spawner/spawner in all_turfs_for_spawn)
Expand Down
Binary file modified mods/anomaly/icons/detector.dmi
Binary file not shown.
Binary file modified mods/anomaly/icons/flux_detector.dmi
Binary file not shown.
Binary file modified mods/anomaly/icons/gurza_detector.dmi
Binary file not shown.
Binary file removed mods/anomaly/sounds/any_idle.ogg
Binary file not shown.
Binary file added mods/anomaly/sounds/gravi_idle.ogg
Binary file not shown.
File renamed without changes.
30 changes: 15 additions & 15 deletions mods/dev_mode/code/dev_map/_dev_map.dm
Original file line number Diff line number Diff line change
Expand Up @@ -136,21 +136,21 @@
#include "../../../../mods/_maps/ascent_seedship/_map_ascent_seedship.dme"
#include "../../../../mods/_maps/ascent_caulship/_map_ascent_caulship.dme"

#include "../../../../mods/antagonists/_antagonists.dme"
#include "../../../../mods/ascent/_ascent.dme"
#include "../../../../mods/fancy_sofas/_fancy_sofas.dme"
#include "../../../../mods/guns/_guns.dme"
#include "../../../../mods/jukebox_tapes/_jukebox_tapes.dme"
#include "../../../../mods/legalese_language/_legalese.dme"
#include "../../../../mods/petting_zoo/_petting_zoo.dme"
#include "../../../../mods/resomi/_resomi.dme"
#include "../../../../mods/screentips/_screentips.dme"
#include "../../../../mods/tajara/_tajara.dme"
#include "../../../../mods/sauna_props/_sauna_props.dme"
#include "../../../../mods/wyccbay_optimization/_wyccbay_optimization.dme"
#include "../../../../mods/contraband_vending/_contraband_vending.dme"
#include "../../../../mods/telecomms/_telecomms.dme"
#include "../../../../mods/modernUI/_modernUI.dme"
#include "../../../../mods/antagonists/_antagonists_includes.dm"
#include "../../../../mods/ascent/_ascent_includes.dm"
#include "../../../../mods/fancy_sofas/_fancy_sofas_includes.dm"
#include "../../../../mods/guns/_guns_includes.dm"
#include "../../../../mods/jukebox_tapes/_jukebox_tapes_includes.dm"
#include "../../../../mods/legalese_language/_legalese_includes.dm"
#include "../../../../mods/petting_zoo/_petting_zoo_includes.dm"
#include "../../../../mods/resomi/_resomi_includes.dm"
#include "../../../../mods/screentips/_screentips_includes.dm"
#include "../../../../mods/tajara/_tajara_includes.dm"
#include "../../../../mods/sauna_props/_sauna_props_includes.dm"
#include "../../../../mods/wyccbay_optimization/_wyccbay_optimization_includes.dm"
#include "../../../../mods/contraband_vending/_contraband_vending_includes.dm"
#include "../../../../mods/telecomms/_telecomms_includes.dm"
#include "../../../../mods/modernUI/_modernUI_includes.dm"

// UNUSED MODS
// Keep them in ascending alphabetical order too, please
Expand Down
8 changes: 4 additions & 4 deletions mods/weather/code/aurora_objects.dm
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
//Обьект прошлого просыпается. Зажигаются фары/огни/монитор и прочее
/obj/structure/aurora/proc/wake_up(wake_up_time)
set waitfor = FALSE
set background = TRUE
if(waked_up)
return
sleep(rand(2,10)) //Для того чтоб техника не зажигалась одновременно
Expand Down Expand Up @@ -127,12 +128,11 @@
//Смес бьёт
/obj/structure/aurora/smes/proc/electra_attack()
set waitfor = FALSE
set background = TRUE
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)
electroanomaly_act(picked_living, src)
for(var/obj/structure/aurora/picked_aurora in picked_turf)
picked_aurora.wake_up(5 SECONDS)
for(var/atom/picked_atom in picked_turf)
electroanomaly_act(picked_atom, src)
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 )
4 changes: 4 additions & 0 deletions mods/weather/code/weather_manager.dm
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,16 @@
start_blowout()

/obj/weather_manager/proc/change_stage()
set waitfor = FALSE
set background = TRUE
for(var/obj/weather/connected_weather in connected_weather_turfs)
connected_weather.update()
last_change_time = world.time
calculate_change_time()

/obj/weather_manager/proc/start_blowout()
set waitfor = FALSE
set background = TRUE
var/need_blowout = FALSE
calculate_blowout_message_delay_time()
report_progress("DEBUG ANOM: Начинается выброс. Стадия - подготовка.")
Expand Down

0 comments on commit 0ef7753

Please sign in to comment.