Skip to content

Commit

Permalink
style(autofix.ci): automated formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
autofix-ci[bot] authored Dec 28, 2024
1 parent a690641 commit 8bdbe24
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,12 @@ Monster morale. Defines how low monster HP can get before it retreats. This numb
of their max HP.

## "aggro_character"

(bool, optional, default true)

If the monster will differentiate between monsters and characters (NPC, Player) when deciding on targets - if false the monster will ignore characters regardless of current anger/morale until a character trips and anger trigger. Resets randomly when the monster is at its base anger level.
If the monster will differentiate between monsters and characters (NPC, Player) when deciding on
targets - if false the monster will ignore characters regardless of current anger/morale until a
character trips and anger trigger. Resets randomly when the monster is at its base anger level.

## "speed"

Expand Down
6 changes: 4 additions & 2 deletions doc/src/content/docs/en/mod/json/reference/json_flags.md
Original file line number Diff line number Diff line change
Expand Up @@ -939,10 +939,12 @@ Flags used to describe monsters and define their properties and abilities.
- `FIRE` There's a fire nearby.
- `FRIEND_ATTACKED` A monster of the same type was attacked. Always triggers character aggro.
- `FRIEND_DIED` A monster of the same type died. Always triggers character aggro.
- `HURT` The monster is hurt. Always triggers character aggro. Triggers character aggro `<anger>%` of the time.
- `HURT` The monster is hurt. Always triggers character aggro. Triggers character aggro `<anger>%`
of the time.
- `MEAT` Meat or a corpse is nearby.
- `NULL` Source use only?
- `PLAYER_CLOSE` The player gets within a few tiles distance. Triggers character aggro `<anger>%` of the time.
- `PLAYER_CLOSE` The player gets within a few tiles distance. Triggers character aggro `<anger>%` of
the time.
- `PLAYER_WEAK` The player is hurt.
- `SOUND` Heard a sound.
- `STALK` Increases when following the player.
Expand Down
2 changes: 1 addition & 1 deletion src/monstergenerator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -813,7 +813,7 @@ void mtype::load( const JsonObject &jo, const std::string &src )
remove_regeneration_modifiers( tmp, "regeneration_modifiers", src );
}
}

optional( jo, was_loaded, "starting_ammo", starting_ammo );
optional( jo, was_loaded, "luminance", luminance, 0 );
optional( jo, was_loaded, "revert_to_itype", revert_to_itype, itype_id() );
Expand Down
2 changes: 1 addition & 1 deletion src/mtype.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ mtype::mtype()
harvest = harvest_id( "human" );
luminance = 0;
bash_skill = 0;

aggro_character = true;

flags
Expand Down
2 changes: 1 addition & 1 deletion src/mtype.h
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ struct mtype {
bool was_loaded = false;
bool upgrades;
bool reproduces;

// Do we indiscriminately attack characters, or should we wait until one annoys us?
bool aggro_character = true;

Expand Down

0 comments on commit 8bdbe24

Please sign in to comment.