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

Rad Mutate Event #74602

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 2 additions & 0 deletions src/event.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ std::string enum_to_string<event_type>( event_type data )
case event_type::player_fails_conduct: return "player_fails_conduct";
case event_type::player_gets_achievement: return "player_gets_achievement";
case event_type::player_levels_spell: return "player_levels_spell";
case event_type::rad_mutate: return "rad_mutate";
case event_type::reads_book: return "reads_book";
case event_type::releases_subspace_specimens: return "releases_subspace_specimens";
case event_type::removes_cbm: return "removes_cbm";
Expand Down Expand Up @@ -206,6 +207,7 @@ DEFINE_EVENT_FIELDS( opens_spellbook )
DEFINE_EVENT_FIELDS( player_fails_conduct )
DEFINE_EVENT_FIELDS( player_gets_achievement )
DEFINE_EVENT_FIELDS( player_levels_spell )
DEFINE_EVENT_FIELDS( rad_mutate )
DEFINE_EVENT_FIELDS( removes_cbm )
DEFINE_EVENT_FIELDS( spellcasting_finish )
DEFINE_EVENT_FIELDS( telefrags_creature )
Expand Down
1 change: 1 addition & 0 deletions src/event.h
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@
player_levels_spell,
reads_book,
releases_subspace_specimens,
rad_mutate,
removes_cbm,
seals_hazardous_material_sarcophagus,
spellcasting_finish,
Expand Down Expand Up @@ -186,7 +187,7 @@
};
};

static_assert( static_cast<int>( event_type::num_event_types ) == 102,

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (src)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / build (other)

static assertion failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102': This static_assert is to remind you to add a specialization for your new event_type below [clang-diagnostic-error]

Check failure on line 190 in src/event.h

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

static_assert failed due to requirement 'static_cast<int>(event_type::num_event_types) == 102' "This static_assert is to remind you to add a specialization for your new event_type below"
"This static_assert is to remind you to add a specialization for your new "
"event_type below" );

Expand Down
2 changes: 1 addition & 1 deletion src/suffer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1170,7 +1170,7 @@ void suffer::from_radiation( Character &you )
// 1000 rads = 900 / 10000 = 9 / 100 = 10% !!!
// 2000 rads = 2000 / 10000 = 1 / 5 = 20% !!!
if( get_option<bool>( "RAD_MUTATION" ) && rng( 100, 10000 ) < you.get_rad() ) {
you.mutate();
get_event_bus().send<event_type::rad_mutate>( getID(), bp );
}
if( you.get_rad() > 50 && rng( 1, 3000 ) < you.get_rad() &&
( you.stomach.contains() > 0_ml || radiation_increasing || !you.in_sleep_state() ) ) {
Expand Down
Loading