Freeciv-3.3
|
#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 "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 57 of file diplhand.c.
|
static |
Calls treaty_accepted function if such is set for AI player.
Definition at line 73 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 62 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 923 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 84 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 698 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 147 of file diplhand.c.
Referenced by dai_treaty_evaluate(), and server_handle_packet().
Handle meeting cancelling request.
Definition at line 830 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 753 of file diplhand.c.
Referenced by dai_diplomacy_suggest(), and server_handle_packet().
Handle meeting opening request.
Definition at line 845 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 720 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 804 of file diplhand.c.
Referenced by cancel_all_meetings(), and handle_diplomacy_cancel_meeting_req().
Reject all treaties currently being negotiated
Definition at line 935 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 885 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 122 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 108 of file diplhand.c.
Referenced by sg_load_player_main(), and sg_load_player_main().