Freeciv-3.2
|
#include <stdio.h>
#include <stdlib.h>
#include "bitvector.h"
#include "fcintl.h"
#include "log.h"
#include "mem.h"
#include "ai.h"
#include "diptreaty.h"
#include "events.h"
#include "game.h"
#include "map.h"
#include "packets.h"
#include "player.h"
#include "research.h"
#include "unit.h"
#include "luascript_types.h"
#include "citytools.h"
#include "cityturn.h"
#include "maphand.h"
#include "plrhand.h"
#include "notify.h"
#include "techtools.h"
#include "unittools.h"
#include "autosettlers.h"
#include "script_server.h"
#include "diplhand.h"
Go to the source code of this file.
Macros | |
#define | TURNS_LEFT 16 |
#define TURNS_LEFT 16 |
Definition at line 60 of file diplhand.c.
|
static |
Calls treaty_accepted function if such is set for AI player.
Definition at line 76 of file diplhand.c.
Referenced by handle_diplomacy_accept_treaty_req().
|
static |
Calls treaty_evaluate function if such is set for AI player.
Definition at line 65 of file diplhand.c.
Referenced by handle_diplomacy_create_clause_req(), and handle_diplomacy_remove_clause_req().
Cancels all meetings of player.
Definition at line 926 of file diplhand.c.
Referenced by kill_player(), player_set_to_ai_mode(), and player_set_under_human_control().
|
static |
Return the closest of the two diplstate types.
Definition at line 87 of file diplhand.c.
Referenced by set_diplstate_type(), and valid_dst_closest().
Create an embassy. pplayer gets an embassy with aplayer.
Definition at line 701 of file diplhand.c.
Referenced by diplomat_embassy(), handle_diplomacy_accept_treaty_req(), and split_player().
pplayer clicked the accept button. If they accepted the treaty we check the clauses. If both players have now accepted the treaty we execute the agreed clauses.
Definition at line 150 of file diplhand.c.
Referenced by dai_treaty_evaluate(), and server_handle_packet().
Handle meeting cancelling request.
Definition at line 833 of file diplhand.c.
Referenced by server_handle_packet().
void handle_diplomacy_create_clause_req | ( | struct player * | pplayer, |
int | counterpart, | ||
int | giver, | ||
enum clause_type | type, | ||
int | value | ||
) |
Handle request to add clause to treaty between two players.
Definition at line 756 of file diplhand.c.
Referenced by dai_diplomacy_suggest(), and server_handle_packet().
Handle meeting opening request.
Definition at line 848 of file diplhand.c.
Referenced by dai_diplomacy_suggest(), and server_handle_packet().
void handle_diplomacy_remove_clause_req | ( | struct player * | pplayer, |
int | counterpart, | ||
int | giver, | ||
enum clause_type | type, | ||
int | value | ||
) |
Handle request to remove clause from treaty.
Definition at line 723 of file diplhand.c.
Referenced by server_handle_packet().
|
static |
Cancel meeting. No sanity checking of input parameters, so don't call this with input directly from untrusted source.
Definition at line 807 of file diplhand.c.
Referenced by cancel_all_meetings(), and handle_diplomacy_cancel_meeting_req().
Reject all treaties currently being negotiated
Definition at line 938 of file diplhand.c.
Referenced by handle_diplomacy_cancel_pact().
void send_diplomatic_meetings | ( | struct connection * | dest | ) |
Send information on any on-going diplomatic meetings for connection's player. For re-connections.
Definition at line 888 of file diplhand.c.
Referenced by begin_phase(), and connection_attach_real().
void set_diplstate_type | ( | struct player_diplstate * | state1, |
struct player_diplstate * | state2, | ||
enum diplstate_type | type | ||
) |
Set diplstate between two players.
Definition at line 125 of file diplhand.c.
Referenced by barbarian_initial_wars(), handle_diplomacy_accept_treaty_req(), make_contact(), split_player(), and srv_ready().
enum diplstate_type valid_dst_closest | ( | struct player_diplstate * | dst | ) |
Return closest diplstate dst has had, with extra sanity checking (i.e. may return state other than the recorder max_state)
Definition at line 111 of file diplhand.c.
Referenced by sg_load_player_main(), and sg_load_player_main().