Skip to content

Commit

Permalink
Revert "Merge pull request CleverRaven#74854 from db48x/follower_rule…
Browse files Browse the repository at this point in the history
…s_UI"

This reverts commit 3f6bf65, reversing
changes made to 9a083b3.
this
  • Loading branch information
SurFlurer committed Aug 26, 2024
1 parent 6ac9f09 commit 328a640
Show file tree
Hide file tree
Showing 9 changed files with 651 additions and 641 deletions.
613 changes: 612 additions & 1 deletion data/json/npcs/common_chat/TALK_COMMON_ALLY.json

Large diffs are not rendered by default.

108 changes: 0 additions & 108 deletions data/json/npcs/talk_tags.json
Original file line number Diff line number Diff line change
Expand Up @@ -2107,114 +2107,6 @@
"it's a million miles away!"
]
},
{
"type": "snippet",
"category": "<ally_rule_cbm_recharge_all_text>",
"text": "<mypronoun> will recharge power CBMs until <mypronoun> has 90% of total power."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_recharge_most_text>",
"text": "<mypronoun> will recharge power CBMs until <mypronoun> has 75% of total power."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_recharge_some_text>",
"text": "<mypronoun> will recharge power CBMs until <mypronoun> has 50% of total power."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_recharge_little_text>",
"text": "<mypronoun> will recharge power CBMs until <mypronoun> has 25% of total power."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_recharge_none_text>",
"text": "<mypronoun> will recharge power CBMs until <mypronoun> has 10% of total power."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_reserve_all_text>",
"text": "<mypronoun> will reserve 100% of CBM power for defense or utility CBMs."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_reserve_most_text>",
"text": "<mypronoun> will reserve 75% of CBM power for defense or utility CBMs."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_reserve_some_text>",
"text": "<mypronoun> will reserve 50% of CBM power for defense or utility CBMs."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_reserve_little_text>",
"text": "<mypronoun> will reserve 25% of CBM power for defense or utility CBMs."
},
{
"type": "snippet",
"category": "<ally_rule_cbm_reserve_none_text>",
"text": "<mypronoun> will not reserve any power for defense or utility CBMs."
},
{
"type": "snippet",
"category": "<ally_rule_aim_when_convenient>",
"text": "<mypronoun> will aim when it's convenient."
},
{
"type": "snippet",
"category": "<ally_rule_aim_spray>",
"text": "<mypronoun> will not bother to aim at all."
},
{
"type": "snippet",
"category": "<ally_rule_aim_precise>",
"text": "<mypronoun> will take time and aim carefully."
},
{
"type": "snippet",
"category": "<ally_rule_aim_strictly_precise>",
"text": "<mypronoun> will only shoot after taking a long time to aim."
},
{
"type": "snippet",
"category": "<ally_rule_engagement_none>",
"text": "<mypronoun> won't fight unless their life depends on it."
},
{
"type": "snippet",
"category": "<ally_rule_engagement_close>",
"text": "<mypronoun> will attack enemies that get too close."
},
{
"type": "snippet",
"category": "<ally_rule_engagement_weak>",
"text": "<mypronoun> will attack enemies that they can kill easily."
},
{
"type": "snippet",
"category": "<ally_rule_engagement_hit>",
"text": "<mypronoun> will attack only enemies that you attack first."
},
{
"type": "snippet",
"category": "<ally_rule_engagement_all>",
"text": [
{ "text": "<mypronoun> will attack anything they want.", "weight": 999 },
{ "text": "<npc_name> has permission to go <color_red>ABSOLUTELY AXE CRAZY!</color>", "weight": 1 }
]
},
{
"type": "snippet",
"category": "<ally_rule_engagement_free_fire>",
"text": "<mypronoun> will attack any enemy within range of their ranged weapon, but won't move."
},
{
"type": "snippet",
"category": "<ally_rule_engagement_no_move>",
"text": "<mypronoun> will attack only enemies they can reach without moving."
},
{
"type": "snippet",
"category": "<ally_rule_use_guns_true_text>",
Expand Down
2 changes: 1 addition & 1 deletion src/mission_ui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ void mission_ui::draw_mission_ui()

p_impl.last_action = ctxt.handle_input();

if( p_impl.last_action == "QUIT" || !p_impl.get_is_open() ) {
if( p_impl.last_action == "QUIT" ) {
break;
}
}
Expand Down
5 changes: 0 additions & 5 deletions src/npc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3755,11 +3755,6 @@ void npc_follower_rules::clear_overrides()
override_enable = ally_rule::DEFAULT;
}

void npc_follower_rules::clear_flags()
{
flags = ally_rule::DEFAULT;
}

int npc::get_thirst() const
{
return Character::get_thirst() - units::to_milliliter<int>( stomach.get_water() ) / 5;
Expand Down
1 change: 0 additions & 1 deletion src/npc.h
Original file line number Diff line number Diff line change
Expand Up @@ -532,7 +532,6 @@ struct npc_follower_rules {
void clear_override( ally_rule clearit );

void set_danger_overrides();
void clear_flags();
void clear_overrides();
};

Expand Down
13 changes: 0 additions & 13 deletions src/npctalk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@
#include "mutation.h"
#include "npc.h"
#include "npctalk.h"
#include "npctalk_rules.h"
#include "npctrade.h"
#include "output.h"
#include "overmapbuffer.h"
Expand Down Expand Up @@ -3527,14 +3526,6 @@ talk_effect_fun_t::func f_add_debt( const JsonObject &jo, std::string_view membe
};
}

talk_effect_fun_t::func f_npc_rules_menu()
{
return []( dialogue const & d ) {
follower_rules_ui new_ui;
new_ui.draw_follower_rules_ui( d.actor( true )->get_npc() );
};
}

talk_effect_fun_t::func f_toggle_npc_rule( const JsonObject &jo, std::string_view member,
const std::string_view )
{
Expand Down Expand Up @@ -6870,10 +6861,6 @@ void talk_effect_t::parse_string_effect( const std::string &effect_id, const Jso
set_effect( talk_effect_fun_t( talk_effect_fun::f_wants_to_talk( true ) ) );
return;
}
if( effect_id == "npc_rules_menu" ) {
set_effect( talk_effect_fun_t( talk_effect_fun::f_npc_rules_menu() ) );
return;
}
jo.throw_error_at( effect_id, "unknown effect string" );
}

Expand Down
Loading

0 comments on commit 328a640

Please sign in to comment.