180 if (
pclause->from == pplayer) {
187 log_error(
"Requirements of a clause between %s and %s not fulfilled",
197 log_error(
"%s tried to give embassy to %s, who already "
208 log_error(
"Treaty: %s can't have tech %s",
212 _(
"The %s can't accept %s."),
220 log_error(
"Nation %s try to give unknown tech %s to nation %s.",
225 _(
"You don't have tech %s, you can't accept treaty."),
235 _(
"City you are trying to give no longer exists, "
236 "you can't accept treaty."));
241 _(
"You are not owner of %s, you can't accept treaty."),
247 _(
"Your capital (%s) is requested, "
248 "you can't accept treaty."),
269 _(
"You cannot form an alliance because you are "
270 "at war with an ally of %s."),
274 _(
"You cannot form an alliance because %s is "
275 "at war with an ally of yours."),
285 _(
"You don't have enough gold, "
286 "you can't accept treaty."));
321 PL_(
"A treaty containing %d clause was agreed upon.",
322 "A treaty containing %d clauses was agreed upon.",
326 PL_(
"A treaty containing %d clause was agreed upon.",
327 "A treaty containing %d clauses was agreed upon.",
345 _(
"Clause requirements are no longer fulfilled. "
346 "Treaty with %s canceled!"),
349 _(
"Clause requirements are no longer fulfilled. "
350 "Treaty with %s canceled!"),
362 _(
"One of the cities the %s are giving away"
363 " is destroyed! Treaty canceled!"),
366 _(
"One of the cities the %s are giving away"
367 " is destroyed! Treaty canceled!"),
373 _(
"The %s no longer control %s! "
378 _(
"The %s no longer control %s! "
386 _(
"Your capital (%s) is requested, "
387 "you can't accept treaty."),
416 _(
"The %s don't have the promised amount "
417 "of gold! Treaty canceled!"),
420 _(
"The %s don't have the promised amount "
421 "of gold! Treaty canceled!"),
450 _(
"You gave an embassy to %s."),
453 _(
"%s allowed you to create an embassy!"),
467 "that %s want to give them.",
476 _(
"You are taught the knowledge of %s."),
485 _(
"You have acquired %s thanks to the %s "
486 "treaty with the %s."),
493 Q_(
"?fromplr:The %s have acquired %s from the %s."),
511 pdest->economic.gold += received;
513 PL_(
"You get %d gold.",
514 "You get %d gold.", received), received);
521 _(
"You receive the %s worldmap."),
530 _(
"You receive the %s seamap."),
540 log_error(
"Treaty city id %d not found - skipping clause.",
546 _(
"You receive the city of %s from %s."),
550 _(
"You give the city of %s to %s."),
569 _(
"You agree on a cease-fire with %s."),
572 _(
"You agree on a cease-fire with %s."),
594 PL_(
"You agree on an armistice with the %s. In %d turn, "
595 "it will become a peace treaty. Move your "
596 "military units out of %s territory to avoid them "
598 "You agree on an armistice with the %s. In %d turns, "
599 "it will become a peace treaty. Move any "
600 "military units out of %s territory to avoid them "
608 PL_(
"You agree on an armistice with the %s. In %d turn, "
609 "it will become a peace treaty. Move your "
610 "military units out of %s territory to avoid them "
612 "You agree on an armistice with the %s. In %d turns, "
613 "it will become a peace treaty. Move any "
614 "military units out of %s territory to avoid them "
633 _(
"You agree on an alliance with %s."),
636 _(
"You agree on an alliance with %s."),
646 _(
"You give shared vision to %s."),
649 _(
"%s gives you shared vision."),
659 _(
"You share your tiles with %s."),
662 _(
"%s shares their tiles with you."),
717 int counterpart,
int giver,
750 int counterpart,
int giver,
810 _(
"%s canceled the meeting!"),
817 _(
"Meeting with %s canceled."),
857 _(
"Your diplomatic envoy was decapitated!"));
#define CALL_PLR_AI_FUNC(_func, _player,...)
bool is_capital(const struct city *pcity)
#define city_tile(_pcity_)
#define city_owner(_pcity_)
struct unit struct city struct unit struct tile struct extra_type const struct act_prob *act_probs int actor_unit_id struct unit struct unit int const struct action *paction struct unit struct city * pcity
void establish_embassy(struct player *pplayer, struct player *aplayer)
void send_diplomatic_meetings(struct connection *dest)
static void call_treaty_accepted(struct player *pplayer, struct player *aplayer, struct treaty *ptreaty)
void handle_diplomacy_remove_clause_req(struct player *pplayer, int counterpart, int giver, enum clause_type type, int value)
void handle_diplomacy_create_clause_req(struct player *pplayer, int counterpart, int giver, enum clause_type type, int value)
void reject_all_treaties(struct player *pplayer)
enum diplstate_type valid_dst_closest(struct player_diplstate *dst)
static void call_treaty_evaluate(struct player *pplayer, struct player *aplayer, struct treaty *ptreaty)
void set_diplstate_type(struct player_diplstate *state1, struct player_diplstate *state2, enum diplstate_type type)
void handle_diplomacy_init_meeting_req(struct player *pplayer, int counterpart)
void cancel_all_meetings(struct player *pplayer)
void handle_diplomacy_cancel_meeting_req(struct player *pplayer, int counterpart)
static enum diplstate_type dst_closest(enum diplstate_type a, enum diplstate_type b)
static void really_diplomacy_cancel_meeting(struct player *pplayer, struct player *pother)
void handle_diplomacy_accept_treaty_req(struct player *pplayer, int counterpart)
void treaty_remove(struct treaty *ptreaty)
void treaty_add(struct treaty *ptreaty)
struct treaty * find_treaty(struct player *plr0, struct player *plr1)
void init_treaty(struct treaty *ptreaty, struct player *plr0, struct player *plr1)
bool add_clause(struct treaty *ptreaty, struct player *pfrom, enum clause_type type, int val, struct player *client_player)
bool remove_clause(struct treaty *ptreaty, struct player *pfrom, enum clause_type type, int val)
struct clause_info * clause_info_get(enum clause_type type)
bool could_meet_with_player(const struct player *pplayer, const struct player *aplayer)
#define clause_list_iterate_end
#define clause_list_iterate(clauselist, pclause)
#define is_pact_clause(x)
int get_player_bonus(const struct player *pplayer, enum effect_type effect_type)
#define PL_(String1, String2, n)
const struct ft_color ftc_server
const char * city_link(const struct city *pcity)
struct city * game_city_by_number(int id)
#define log_verbose(message,...)
#define fc_assert(condition)
#define fc_assert_action(condition, action)
#define log_error(message,...)
void dlsend_packet_diplomacy_init_meeting(struct conn_list *dest, int counterpart, int initiated_from)
void dlsend_packet_diplomacy_remove_clause(struct conn_list *dest, int counterpart, int giver, enum clause_type type, int value)
int dsend_packet_diplomacy_create_clause(struct connection *pc, int counterpart, int giver, enum clause_type type, int value)
int dsend_packet_diplomacy_init_meeting(struct connection *pc, int counterpart, int initiated_from)
void dlsend_packet_diplomacy_create_clause(struct conn_list *dest, int counterpart, int giver, enum clause_type type, int value)
void dlsend_packet_diplomacy_accept_treaty(struct conn_list *dest, int counterpart, bool I_accepted, bool other_accepted)
void dlsend_packet_diplomacy_cancel_meeting(struct conn_list *dest, int counterpart, int initiated_from)
int dsend_packet_diplomacy_accept_treaty(struct connection *pc, int counterpart, bool I_accepted, bool other_accepted)
void give_map_from_player_to_player(struct player *pfrom, struct player *pdest)
void give_seamap_from_player_to_player(struct player *pfrom, struct player *pdest)
void give_citymap_from_player_to_player(struct city *pcity, struct player *pfrom, struct player *pdest)
bool map_is_known_and_seen(const struct tile *ptile, const struct player *pplayer, enum vision_layer vlayer)
void give_shared_vision(struct player *pfrom, struct player *pto)
const char * nation_rule_name(const struct nation_type *pnation)
const char * nation_adjective_for_player(const struct player *pplayer)
struct nation_type * nation_of_player(const struct player *pplayer)
const char * nation_plural_for_player(const struct player *pplayer)
void notify_research(const struct research *presearch, const struct player *exclude, enum event_type event, const struct ft_color color, const char *format,...)
void notify_player(const struct player *pplayer, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...)
void notify_research_embassies(const struct research *presearch, const struct player *exclude, enum event_type event, const struct ft_color color, const char *format,...)
struct player * player_by_number(const int player_id)
int player_number(const struct player *pplayer)
enum dipl_reason pplayer_can_make_treaty(const struct player *p1, const struct player *p2, enum diplstate_type treaty)
const char * player_name(const struct player *pplayer)
bool player_has_real_embassy(const struct player *pplayer, const struct player *pplayer2)
int player_index(const struct player *pplayer)
struct player_diplstate * player_diplstate_get(const struct player *plr1, const struct player *plr2)
#define players_iterate_end
@ DIPL_ALLIANCE_PROBLEM_THEM
@ DIPL_ALLIANCE_PROBLEM_US
#define players_iterate(_pplayer)
#define player_list_iterate(playerlist, pplayer)
static bool is_barbarian(const struct player *pplayer)
#define player_list_iterate_end
void send_player_all_c(struct player *src, struct conn_list *dest)
void update_players_after_alliance_breakup(struct player *pplayer, struct player *pplayer2, const struct unit_list *pplayer_seen_units, const struct unit_list *pplayer2_seen_units)
bool are_reqs_active(const struct req_context *context, const struct req_context *other_context, const struct requirement_vector *reqs, const enum req_problem_type prob_type)
struct research * research_get(const struct player *pplayer)
enum tech_state research_invention_state(const struct research *presearch, Tech_type_id tech)
bool research_invention_gettable(const struct research *presearch, const Tech_type_id tech, bool allow_holes)
int research_pretty_name(const struct research *presearch, char *buf, size_t buf_len)
void script_server_signal_emit(const char *signal_name,...)
#define BAD_HEURISTIC_INIT(_ini_val_)
struct packet_game_info info
struct civ_game::@32::@36 server
struct requirement_vector receiver_reqs
struct requirement_vector giver_reqs
bool tech_trade_allow_holes
enum diplstate_type max_state
struct conn_list * connections
struct player_economic economic
const struct player * player
struct clause_list * clauses
const struct player_list * team_members(const struct team *pteam)
struct advance * advance_by_number(const Tech_type_id atype)
const char * advance_name_translation(const struct advance *padvance)
const char * advance_rule_name(const struct advance *padvance)