Freeciv-3.2: /fast/freeciv/nightly/S3_2/client/packhand_gen.h File Reference

Freeciv-3.2

Loading...
Searching...
No Matches
Functions
packhand_gen.h File Reference
`#include "shared.h"`
`#include "packets.h"`

Go to the source code of this file.

## Functions

bool | client_handle_packet (enum packet_type type, const void *packet)
void | handle_processing_started (void)
void | handle_processing_finished (void)
void | handle_investigate_started (const struct packet_investigate_started *packet)
void | handle_investigate_finished (const struct packet_investigate_finished *packet)
void | handle_server_join_reply (bool you_can_join, const char *message, const char *capability, const char *challenge_file, int conn_id)
void | handle_authentication_req (enum authentication_type type, const char *message)
void | handle_server_shutdown (void)
void | handle_endgame_report (const struct packet_endgame_report *packet)
void | handle_endgame_player (const struct packet_endgame_player *packet)
void | handle_tile_info (const struct packet_tile_info *packet)
void | handle_game_info (const struct packet_game_info *packet)
void | handle_calendar_info (const struct packet_calendar_info *packet)
void | handle_timeout_info (float seconds_to_phasedone, float last_turn_change_time)
void | handle_map_info (const struct packet_map_info *packet)
void | handle_nuke_tile_info (int tile)
void | handle_team_name_info (int team_id, const char *team_name)
void | handle_achievement_info (int id, bool gained, bool first)
void | handle_chat_msg (const struct packet_chat_msg *packet)
void | handle_early_chat_msg (const struct packet_early_chat_msg *packet)
void | handle_connect_msg (const char *message)
void | handle_server_info (const char *version_label, int major_version, int minor_version, int patch_version, int emerg_version)
void | handle_city_remove (int city_id)
void | handle_city_info (const struct packet_city_info *packet)
void | handle_city_nationalities (const struct packet_city_nationalities *packet)
void | handle_city_update_counters (const struct packet_city_update_counters *packet)
void | handle_city_short_info (const struct packet_city_short_info *packet)
void | handle_trade_route_info (const struct packet_trade_route_info *packet)
void | handle_city_name_suggestion_info (int unit_id, const char *name)
void | handle_city_sabotage_list (int actor_id, int city_id, bv_imprs improvements, action_id act_id, int request_kind)
void | handle_city_rally_point (const struct packet_city_rally_point *packet)
void | handle_worker_task (const struct packet_worker_task *packet)
void | handle_player_remove (int playerno)
void | handle_player_info (const struct packet_player_info *packet)
void | handle_player_attribute_chunk (const struct packet_player_attribute_chunk *packet)
void | handle_player_diplstate (const struct packet_player_diplstate *packet)
void | handle_research_info (const struct packet_research_info *packet)
void | handle_unknown_research (int id)
void | handle_unit_remove (int unit_id)
void | handle_unit_info (const struct packet_unit_info *packet)
void | handle_unit_short_info (const struct packet_unit_short_info *packet)
void | handle_unit_combat_info (const struct packet_unit_combat_info *packet)
void | handle_unit_action_answer (int actor_id, int target_id, int cost, action_id action_type, int request_kind)
void | handle_unit_actions (const struct packet_unit_actions *packet)
void | handle_diplomacy_init_meeting (int counterpart, int initiated_from)
void | handle_diplomacy_cancel_meeting (int counterpart, int initiated_from)
void | handle_diplomacy_create_clause (int counterpart, int giver, enum clause_type type, int value)
void | handle_diplomacy_remove_clause (int counterpart, int giver, enum clause_type type, int value)
void | handle_diplomacy_accept_treaty (int counterpart, bool I_accepted, bool other_accepted)
void | handle_page_msg (const char *caption, const char *headline, enum event_type event, int len, int parts)
void | handle_page_msg_part (const char *lines)
void | handle_conn_info (const struct packet_conn_info *packet)
void | handle_conn_ping_info (int connections, const int *conn_id, const float *ping_time)
void | handle_conn_ping (void)
void | handle_end_phase (void)
void | handle_start_phase (int phase)
void | handle_new_year (int year, int fragments, int turn)
void | handle_begin_turn (void)
void | handle_end_turn (void)
void | handle_freeze_client (void)
void | handle_thaw_client (void)
void | handle_spaceship_info (const struct packet_spaceship_info *packet)
void | handle_ruleset_unit (const struct packet_ruleset_unit *packet)
void | handle_ruleset_unit_bonus (const struct packet_ruleset_unit_bonus *packet)
void | handle_ruleset_unit_flag (const struct packet_ruleset_unit_flag *packet)
void | handle_ruleset_unit_class_flag (const struct packet_ruleset_unit_class_flag *packet)
void | handle_ruleset_game (const struct packet_ruleset_game *packet)
void | handle_ruleset_specialist (const struct packet_ruleset_specialist *packet)
void | handle_ruleset_government_ruler_title (const struct packet_ruleset_government_ruler_title *packet)
void | handle_ruleset_tech (const struct packet_ruleset_tech *packet)
void | handle_ruleset_tech_class (const struct packet_ruleset_tech_class *packet)
void | handle_ruleset_tech_flag (const struct packet_ruleset_tech_flag *packet)
void | handle_ruleset_government (const struct packet_ruleset_government *packet)
void | handle_ruleset_terrain_control (const struct packet_ruleset_terrain_control *packet)
void | handle_rulesets_ready (void)
void | handle_ruleset_nation_sets (const struct packet_ruleset_nation_sets *packet)
void | handle_ruleset_nation_groups (const struct packet_ruleset_nation_groups *packet)
void | handle_ruleset_nation (const struct packet_ruleset_nation *packet)
void | handle_nation_availability (int ncount, const bool *is_pickable, bool nationset_change)
void | handle_ruleset_style (const struct packet_ruleset_style *packet)
void | handle_ruleset_city (const struct packet_ruleset_city *packet)
void | handle_ruleset_building (const struct packet_ruleset_building *packet)
void | handle_ruleset_impr_flag (const struct packet_ruleset_impr_flag *packet)
void | handle_ruleset_terrain (const struct packet_ruleset_terrain *packet)
void | handle_ruleset_terrain_flag (const struct packet_ruleset_terrain_flag *packet)
void | handle_ruleset_unit_class (const struct packet_ruleset_unit_class *packet)
void | handle_ruleset_extra (const struct packet_ruleset_extra *packet)
void | handle_ruleset_extra_flag (const struct packet_ruleset_extra_flag *packet)
void | handle_ruleset_base (const struct packet_ruleset_base *packet)
void | handle_ruleset_road (const struct packet_ruleset_road *packet)
void | handle_ruleset_goods (const struct packet_ruleset_goods *packet)
void | handle_ruleset_disaster (const struct packet_ruleset_disaster *packet)
void | handle_ruleset_achievement (const struct packet_ruleset_achievement *packet)
void | handle_ruleset_trade (const struct packet_ruleset_trade *packet)
void | handle_ruleset_action (const struct packet_ruleset_action *packet)
void | handle_ruleset_action_enabler (const struct packet_ruleset_action_enabler *packet)
void | handle_ruleset_action_auto (const struct packet_ruleset_action_auto *packet)
void | handle_ruleset_counter (const struct packet_ruleset_counter *packet)
void | handle_ruleset_music (const struct packet_ruleset_music *packet)
void | handle_ruleset_multiplier (const struct packet_ruleset_multiplier *packet)
void | handle_ruleset_clause (const struct packet_ruleset_clause *packet)
void | handle_ruleset_control (const struct packet_ruleset_control *packet)
void | handle_ruleset_summary (const struct packet_ruleset_summary *packet)
void | handle_ruleset_description_part (const struct packet_ruleset_description_part *packet)
void | handle_single_want_hack_reply (bool you_have_hack)
void | handle_ruleset_choices (const struct packet_ruleset_choices *packet)
void | handle_game_load (bool load_successful, const char *load_filename)
void | handle_server_setting_control (const struct packet_server_setting_control *packet)
void | handle_server_setting_const (const struct packet_server_setting_const *packet)
void | handle_server_setting_bool (const struct packet_server_setting_bool *packet)
void | handle_server_setting_int (const struct packet_server_setting_int *packet)
void | handle_server_setting_str (const struct packet_server_setting_str *packet)
void | handle_server_setting_enum (const struct packet_server_setting_enum *packet)
void | handle_server_setting_bitwise (const struct packet_server_setting_bitwise *packet)
void | handle_set_topology (int topology_id, int wrap_id)
void | handle_ruleset_effect (const struct packet_ruleset_effect *packet)
void | handle_ruleset_resource (const struct packet_ruleset_resource *packet)
void | handle_scenario_info (const struct packet_scenario_info *packet)
void | handle_scenario_description (const char *description)
void | handle_vote_new (const struct packet_vote_new *packet)
void | handle_vote_update (int vote_no, int yes, int no, int abstain, int num_voters)
void | handle_vote_remove (int vote_no)
void | handle_vote_resolve (int vote_no, bool passed)
void | handle_edit_startpos (const struct packet_edit_startpos *packet)
void | handle_edit_startpos_full (const struct packet_edit_startpos_full *packet)
void | handle_edit_object_created (int tag, int id)
void | handle_play_music (const char *tag)
void | handle_web_city_info_addition (int id, bool cma_enabled, const struct cm_parameter *cm_parameter, int granary_size, int granary_turns, bv_utypes can_build_unit, bv_imprs can_build_improvement, const int *output_food, const int *output_shield, const int *output_trade)
void | handle_web_player_info_addition (int playerno, int expected_income)
void | handle_web_ruleset_unit_addition (Unit_type_id id, bv_actions utype_actions)

## Function Documentation

## ◆ client_handle_packet()

bool client_handle_packet | ( | enum packet_type | type,
|  | const void * | packet
| ) |  |

Definition at line 17 of file packhand_gen.c.

Referenced by client_packet_input().

## ◆ handle_achievement_info()

void handle_achievement_info | ( | int | id,
|  | bool | gained,
|  | bool | first
| ) |  |

Received package about gaining an achievement.

Definition at line 2996 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_authentication_req()

void handle_authentication_req | ( | enum authentication_type | type,
|  | const char * | message
| ) |  |

Configure the dialog depending on what type of authentication request the server is making.

Popup passwd dialog depending on what type of authentication request the server is making.

Definition at line 991 of file pages.c.

Referenced by client_handle_packet().

## ◆ handle_begin_turn()

void handle_begin_turn | ( | void |  | ) |

Called when begin-turn packet is received. Server has finished processing turn change.

Definition at line 1470 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_calendar_info()

void handle_calendar_info | ( | const struct packet_calendar_info * | pcalendar | ) |

Packet calendar_info handler.

Definition at line 2332 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_chat_msg()

void handle_chat_msg | ( | const struct packet_chat_msg * | packet | ) |

Handle a message packet. This includes all messages - both in-game messages and chats from other players.

Definition at line 1524 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_city_info()

void handle_city_info | ( | const struct packet_city_info * | packet | ) |

A city-info packet contains all information about a city. If we receive this packet then we know everything about the city internals.

Definition at line 650 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_city_name_suggestion_info()

void handle_city_name_suggestion_info | ( | int | unit_id,
|  | const char * | name
| ) |  |

Handle reply to our city name request.

Definition at line 4839 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_city_nationalities()

void handle_city_nationalities | ( | const struct packet_city_nationalities * | packet | ) |

Handle city nationalities packet.

Definition at line 983 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_city_rally_point()

void handle_city_rally_point | ( | const struct packet_city_rally_point * | packet | ) |

Handle city rally point packet.

Definition at line 1003 of file packhand.c.

## ◆ handle_city_remove()

void handle_city_remove | ( | int | city_id | ) |

Handles a remove-city packet, used by the server to tell us any time a city is no longer there.

Definition at line 468 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_city_sabotage_list()

void handle_city_sabotage_list | ( | int | actor_id,
|  | int | city_id,
|  | bv_imprs | improvements,
|  | action_id | act_id,
|  | int | request_kind
| ) |  |

Handle list of potenttial buildings to sabotage.

Definition at line 5159 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_city_short_info()

void handle_city_short_info | ( | const struct packet_city_short_info * | packet | ) |

A city-short-info packet is sent to tell us about any cities we can't see the internals of. Most of the time this includes any cities owned by someone else.

Definition at line 1154 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_city_update_counters()

void handle_city_update_counters | ( | const struct packet_city_update_counters * | packet | ) |

Handle updating city's counters, when server request

Definition at line 5591 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_conn_info()

void handle_conn_info | ( | const struct packet_conn_info * | pinfo | ) |

Remove, add, or update dummy connection struct representing some connection to the server, with info from packet_conn_info. Updates player and game connection lists. Calls players_dialog_update() in case info for that has changed.

Definition at line 2867 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_conn_ping()

void handle_conn_ping | ( | void |  | ) |

Reply to 'ping' packet with 'pong'

Definition at line 5347 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_conn_ping_info()

void handle_conn_ping_info | ( | int | connections,
|  | const int * | conn_id,
|  | const float * | ping_time
| ) |  |

Handles a conn_ping_info packet from the server. This packet contains ping times for each connection.

Definition at line 2973 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_connect_msg()

void handle_connect_msg | ( | const char * | message | ) |

Handle a connect message packet. Server sends connect message to client immediately when client connects.

Definition at line 1558 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_diplomacy_accept_treaty()

void handle_diplomacy_accept_treaty | ( | int | counterpart,
|  | bool | I_accepted,
|  | bool | other_accepted
| ) |  |

Server tells us that either party has accepted treaty

Definition at line 5532 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_diplomacy_cancel_meeting()

void handle_diplomacy_cancel_meeting | ( | int | counterpart,
|  | int | initiated_from
| ) |  |

Meeting has been cancelled.

Definition at line 5541 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_diplomacy_create_clause()

void handle_diplomacy_create_clause | ( | int | counterpart,
|  | int | giver,
|  | enum clause_type | type,
|  | int | value
| ) |  |

Add clause to the meeting

Definition at line 5549 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_diplomacy_init_meeting()

void handle_diplomacy_init_meeting | ( | int | counterpart,
|  | int | initiated_from
| ) |  |

Open meeting

Definition at line 5524 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_diplomacy_remove_clause()

void handle_diplomacy_remove_clause | ( | int | counterpart,
|  | int | giver,
|  | enum clause_type | type,
|  | int | value
| ) |  |

Remove clause from meeting.

Definition at line 5558 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_early_chat_msg()

void handle_early_chat_msg | ( | const struct packet_early_chat_msg * | packet | ) |

Handle an early message packet. Thease have format like other chat messages but server sends them only about events related to establishing the connection and other setup in the early phase. They are a separate packet just so that client knows thse to be already relevant when it's only setting itself up - other chat messages might be just something sent to all clients, and we might want to still consider ourselves "not connected" (not receivers of those messages) until we are fully in the game.

Definition at line 1544 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_edit_object_created()

void handle_edit_object_created | ( | int | tag,
|  | int | id
| ) |  |

Handle a notification from the server that an object was successfully created. The 'tag' was previously sent to the server when the client requested the creation. The 'id' is the identifier of the newly created object.

Definition at line 5374 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_edit_startpos()

void handle_edit_startpos | ( | const struct packet_edit_startpos * | packet | ) |

Handle start position creation/removal.

Definition at line 5382 of file packhand.c.

## ◆ handle_edit_startpos_full()

void handle_edit_startpos_full | ( | const struct packet_edit_startpos_full * | packet | ) |

Handle start position internal information.

Definition at line 5420 of file packhand.c.

## ◆ handle_end_phase()

void handle_end_phase | ( | void |  | ) |

Called by the network code when an end-phase packet is received. This signifies the end of our phase (it's not sent for other player's phases).

Definition at line 1400 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_end_turn()

void handle_end_turn | ( | void |  | ) |

Called when end-turn packet is received. Server starts processing turn change.

Definition at line 1484 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_endgame_player()

void handle_endgame_player | ( | const struct packet_endgame_player * | packet | ) |

Pass endgame report about single player.

Definition at line 5229 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_endgame_report()

void handle_endgame_report | ( | const struct packet_endgame_report * | packet | ) |

Pass the header information about things be displayed in a gui-specific endgame dialog.

Definition at line 5220 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_freeze_client()

void handle_freeze_client | ( | void |  | ) |

We have received PACKET_FREEZE_CLIENT.

Definition at line 5326 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_game_info()

void handle_game_info | ( | const struct packet_game_info * | pinfo | ) |

Packet game_info handler.

Definition at line 2256 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_game_load()

void handle_game_load | ( | bool | load_successful,
|  | const char * | filename
| ) |  |

This regenerates the player information from a loaded game on the server.

Provide a packet handler for packet_game_load.

This regenerates the player information from a loaded game on the server.

Provide a packet handler for packet_game_load

Definition at line 2825 of file pages.c.

Referenced by client_handle_packet().

## ◆ handle_investigate_finished()

void handle_investigate_finished | ( | const struct packet_investigate_finished * | packet | ) |

Receive an investigate_finished packet

Definition at line 2138 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_investigate_started()

void handle_investigate_started | ( | const struct packet_investigate_started * | packet | ) |

Receive an investigate_started packet

Can't rely on generic packet_processing_started, as that works for the requesting connection only, and not for observers.

Definition at line 2114 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_map_info()

void handle_map_info | ( | const struct packet_map_info * | packet | ) |

Receive information about the map size and topology from the server. We initialize some global variables at the same time.

Definition at line 2216 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_nation_availability()

void handle_nation_availability | ( | int | ncount,
|  | const bool * | is_pickable,
|  | bool | nationset_change
| ) |  |

Handle nation availability info. This can change during pregame so is separate from ruleset_nation.

Definition at line 4666 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_new_year()

void handle_new_year | ( | int | year,
|  | int | fragments,
|  | int | turn
| ) |  |

Handle turn and year advancement.

Definition at line 1351 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_nuke_tile_info()

void handle_nuke_tile_info | ( | int | tile | ) |

The tile (x,y) has been nuked!

Definition at line 545 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_page_msg()

void handle_page_msg | ( | const char * | caption,
|  | const char * | headline,
|  | enum event_type | event,
|  | int | len,
|  | int | parts
| ) |  |

Page_msg header handler.

Definition at line 1583 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_page_msg_part()

void handle_page_msg_part | ( | const char * | lines | ) |

Page_msg part handler.

Definition at line 1614 of file packhand.c.

Referenced by client_handle_packet(), and handle_page_msg().

## ◆ handle_play_music()

void handle_play_music | ( | const char * | tag | ) |

Play suitable music

Definition at line 5516 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_player_attribute_chunk()

void handle_player_attribute_chunk | ( | const struct packet_player_attribute_chunk * | packet | ) |

Packet player_attribute_chunk handler.

Definition at line 5245 of file packhand.c.

## ◆ handle_player_diplstate()

void handle_player_diplstate | ( | const struct packet_player_diplstate * | packet | ) |

Packet player_diplstate handler.

Definition at line 2766 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_player_info()

void handle_player_info | ( | const struct packet_player_info * | pinfo | ) |

Handle information about a player. If the packet refers to a player slot that is not currently used, then this function will set that slot to used and update the total player count.

Definition at line 2426 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_player_remove()

void handle_player_remove | ( | int | playerno | ) |

Handle a notification that the player slot identified by 'playerno' has become unused. If the slot is already unused, then just ignore. Otherwise update the total player count and the GUI.

Definition at line 2381 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_processing_finished()

void handle_processing_finished | ( | void |  | ) |

Handle request to stop processing packet.

Definition at line 5282 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_processing_started()

void handle_processing_started | ( | void |  | ) |

Handle request to start processing packet.

Definition at line 5264 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_research_info()

void handle_research_info | ( | const struct packet_research_info * | packet | ) |

Receive a research info packet.

Definition at line 2652 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_achievement()

void handle_ruleset_achievement | ( | const struct packet_ruleset_achievement * | p | ) |

Handle a packet about a particular achievement type.

Definition at line 4490 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_action()

void handle_ruleset_action | ( | const struct packet_ruleset_action * | p | ) |

Handle a packet about a particular action.

Definition at line 4378 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_action_auto()

void handle_ruleset_action_auto | ( | const struct packet_ruleset_action_auto * | p | ) |

Handle a packet about a particular action auto performer rule.

Definition at line 4446 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_action_enabler()

void handle_ruleset_action_enabler | ( | const struct packet_ruleset_action_enabler * | p | ) |

Handle a packet about a particular action enabler.

Definition at line 4412 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_base()

void handle_ruleset_base | ( | const struct packet_ruleset_base * | p | ) |

Handle a packet about a particular base type.

Definition at line 4301 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_building()

void handle_ruleset_building | ( | const struct packet_ruleset_building * | p | ) |

Packet ruleset_building handler.

Definition at line 3864 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_choices()

void handle_ruleset_choices | ( | const struct packet_ruleset_choices * | packet | ) |

Handle the list of rulesets sent by the server.

Definition at line 757 of file connectdlg_common.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_city()

void handle_ruleset_city | ( | const struct packet_ruleset_city * | packet | ) |

Handle city style packet.

Definition at line 4719 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_clause()

void handle_ruleset_clause | ( | const struct packet_ruleset_clause * | p | ) |

Handle a packet about a particular clause.

Definition at line 4696 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_control()

void handle_ruleset_control | ( | const struct packet_ruleset_control * | packet | ) |

Take arrival of ruleset control packet to indicate that current allocated governments should be free'd, and new memory allocated for new size. The same for nations.

Definition at line 3385 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_counter()

void handle_ruleset_counter | ( | const struct packet_ruleset_counter * | packet | ) |

Handle each counter's ruleset packet sent from server instance to this client.

Definition at line 5568 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_description_part()

void handle_ruleset_description_part | ( | const struct packet_ruleset_description_part * | packet | ) |

Next part of ruleset description.

Definition at line 3499 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_disaster()

void handle_ruleset_disaster | ( | const struct packet_ruleset_disaster * | p | ) |

Handle a packet about a particular disaster type.

Definition at line 4468 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_effect()

void handle_ruleset_effect | ( | const struct packet_ruleset_effect * | packet | ) |

Add effect data to ruleset cache.

Definition at line 5363 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_extra()

void handle_ruleset_extra | ( | const struct packet_ruleset_extra * | p | ) |

Handle a packet about a particular extra type.

Definition at line 4137 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_extra_flag()

void handle_ruleset_extra_flag | ( | const struct packet_ruleset_extra_flag * | p | ) |

Packet ruleset_extra_flag handler.

Definition at line 4275 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_game()

void handle_ruleset_game | ( | const struct packet_ruleset_game * | packet | ) |

Packet ruleset_game handler.

Definition at line 4768 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_goods()

void handle_ruleset_goods | ( | const struct packet_ruleset_goods * | p | ) |

Handle a packet about a particular goods type.

Definition at line 4353 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_government()

void handle_ruleset_government | ( | const struct packet_ruleset_government * | p | ) |

Packet ruleset_government handler.

Definition at line 3969 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_government_ruler_title()

void handle_ruleset_government_ruler_title | ( | const struct packet_ruleset_government_ruler_title * | packet | ) |

Packet ruleset_government_ruler_title handler.

Definition at line 3995 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_impr_flag()

void handle_ruleset_impr_flag | ( | const struct packet_ruleset_impr_flag * | p | ) |

Packet ruleset_impr_flag handler.

Definition at line 3915 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_multiplier()

void handle_ruleset_multiplier | ( | const struct packet_ruleset_multiplier * | p | ) |

Packet ruleset_multiplier handler.

Definition at line 3941 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_music()

void handle_ruleset_music | ( | const struct packet_ruleset_music * | packet | ) |

Handle music style packet.

Definition at line 4745 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_nation()

void handle_ruleset_nation | ( | const struct packet_ruleset_nation * | packet | ) |

Handle initial ruleset nation info.

Definition at line 4576 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_nation_groups()

void handle_ruleset_nation_groups | ( | const struct packet_ruleset_nation_groups * | packet | ) |

Handle the list of nation groups, sent as part of the ruleset.

Definition at line 4554 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_nation_sets()

void handle_ruleset_nation_sets | ( | const struct packet_ruleset_nation_sets * | packet | ) |

Handle the list of nation sets, sent as part of the ruleset.

Definition at line 4533 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_resource()

void handle_ruleset_resource | ( | const struct packet_ruleset_resource * | p | ) |

Handle a packet about a particular terrain resource.

Definition at line 4118 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_road()

void handle_ruleset_road | ( | const struct packet_ruleset_road * | p | ) |

Handle a packet about a particular road type.

Definition at line 4322 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_specialist()

void handle_ruleset_specialist | ( | const struct packet_ruleset_specialist * | p | ) |

Handle info about a single specialist.

Definition at line 4813 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_style()

void handle_ruleset_style | ( | const struct packet_ruleset_style * | p | ) |

Handle a packet about a particular style.

Definition at line 4684 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_summary()

void handle_ruleset_summary | ( | const struct packet_ruleset_summary * | packet | ) |

Ruleset summary.

Definition at line 3481 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_tech()

void handle_ruleset_tech | ( | const struct packet_ruleset_tech * | p | ) |

Packet ruleset_tech handler.

Definition at line 3761 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_tech_class()

void handle_ruleset_tech_class | ( | const struct packet_ruleset_tech_class * | p | ) |

Packet ruleset_tech_class handler.

Definition at line 3826 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_tech_flag()

void handle_ruleset_tech_flag | ( | const struct packet_ruleset_tech_flag * | p | ) |

Packet ruleset_tech_flag handler.

Definition at line 3839 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_terrain()

void handle_ruleset_terrain | ( | const struct packet_ruleset_terrain * | p | ) |

Packet ruleset_terrain handler.

Definition at line 4010 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_terrain_control()

void handle_ruleset_terrain_control | ( | const struct packet_ruleset_terrain_control * | p | ) |

Handle the terrain control ruleset packet sent by the server.

Definition at line 4520 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_terrain_flag()

void handle_ruleset_terrain_flag | ( | const struct packet_ruleset_terrain_flag * | p | ) |

Packet ruleset_terrain_flag handler.

Definition at line 4093 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_trade()

void handle_ruleset_trade | ( | const struct packet_ruleset_trade * | p | ) |

Handle a packet about a particular trade route type.

Definition at line 4506 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_unit()

void handle_ruleset_unit | ( | const struct packet_ruleset_unit * | p | ) |

Packet ruleset_unit handler.

Definition at line 3581 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_unit_bonus()

void handle_ruleset_unit_bonus | ( | const struct packet_ruleset_unit_bonus * | p | ) |

Packet ruleset_unit_bonus handler.

Definition at line 3654 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_unit_class()

void handle_ruleset_unit_class | ( | const struct packet_ruleset_unit_class * | p | ) |

Packet ruleset_unit_class handler.

Definition at line 3563 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_unit_class_flag()

void handle_ruleset_unit_class_flag | ( | const struct packet_ruleset_unit_class_flag * | p | ) |

Packet ruleset_unit_class_flag handler.

Definition at line 3699 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_ruleset_unit_flag()

void handle_ruleset_unit_flag | ( | const struct packet_ruleset_unit_flag * | p | ) |

Packet ruleset_unit_flag handler.

Definition at line 3674 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_rulesets_ready()

void handle_rulesets_ready | ( | void |  | ) |

Received packet indicating that all rulesets have now been received.

Definition at line 3509 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_scenario_description()

void handle_scenario_description | ( | const char * | description | ) |

Received packet containing description of current scenario

Definition at line 3373 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_scenario_info()

void handle_scenario_info | ( | const struct packet_scenario_info * | packet | ) |

Received packet containing info about current scenario

Definition at line 3352 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_server_info()

void handle_server_info | ( | const char * | version_label,
|  | int | major_version,
|  | int | minor_version,
|  | int | patch_version,
|  | int | emerg_version
| ) |  |

Handle server info packet. Server sends info packet as soon as it knows client to be compatible.

Definition at line 1567 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_server_join_reply()

void handle_server_join_reply | ( | bool | you_can_join,
|  | const char * | message,
|  | const char * | capability,
|  | const char * | challenge_file,
|  | int | conn_id
| ) |  |

After we send a join packet to the server we receive a reply. This function handles the reply.

Definition at line 400 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_server_setting_bitwise()

void handle_server_setting_bitwise | ( | const struct packet_server_setting_bitwise * | packet | ) |

Receive a bitwise server setting info packet.

Definition at line 4561 of file options.c.

Referenced by client_handle_packet().

## ◆ handle_server_setting_bool()

void handle_server_setting_bool | ( | const struct packet_server_setting_bool * | packet | ) |

Receive a boolean server setting info packet.

Definition at line 4355 of file options.c.

Referenced by client_handle_packet().

## ◆ handle_server_setting_const()

void handle_server_setting_const | ( | const struct packet_server_setting_const * | packet | ) |

Receive a server setting info packet.

Definition at line 4297 of file options.c.

Referenced by client_handle_packet().

## ◆ handle_server_setting_control()

void handle_server_setting_control | ( | const struct packet_server_setting_control * | packet | ) |

Allocate the server options and categories.

Definition at line 4263 of file options.c.

Referenced by client_handle_packet().

## ◆ handle_server_setting_enum()

void handle_server_setting_enum | ( | const struct packet_server_setting_enum * | packet | ) |

Receive an enumerator server setting info packet.

Definition at line 4472 of file options.c.

Referenced by client_handle_packet().

## ◆ handle_server_setting_int()

void handle_server_setting_int | ( | const struct packet_server_setting_int * | packet | ) |

Receive a integer server setting info packet.

Definition at line 4390 of file options.c.

Referenced by client_handle_packet().

## ◆ handle_server_setting_str()

void handle_server_setting_str | ( | const struct packet_server_setting_str * | packet | ) |

Receive a string server setting info packet.

Definition at line 4427 of file options.c.

Referenced by client_handle_packet().

## ◆ handle_server_shutdown()

void handle_server_shutdown | ( | void |  | ) |

Handle server shutdown.

Definition at line 5355 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_set_topology()

void handle_set_topology | ( | int | topology_id,
|  | int | wrap_id
| ) |  |

Server requested topology change.

Definition at line 2193 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_single_want_hack_reply()

void handle_single_want_hack_reply | ( | bool | you_have_hack | ) |

Handle response (by the server) if the client has got hack or not.

Definition at line 715 of file connectdlg_common.c.

Referenced by client_handle_packet().

## ◆ handle_spaceship_info()

void handle_spaceship_info | ( | const struct packet_spaceship_info * | p | ) |

Packet spaceship_info handler.

Definition at line 3052 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_start_phase()

void handle_start_phase | ( | int | phase | ) |

Called by the network code when an start-phase packet is received. This may be the start of our phase or someone else's phase.

Definition at line 1411 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_team_name_info()

void handle_team_name_info | ( | int | team_id,
|  | const char * | team_name
| ) |  |

The name of team 'team_id'

Definition at line 553 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_thaw_client()

void handle_thaw_client | ( | void |  | ) |

We have received PACKET_THAW_CLIENT

Definition at line 5336 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_tile_info()

void handle_tile_info | ( | const struct packet_tile_info * | packet | ) |

Packet tile_info handler.

Definition at line 3097 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_timeout_info()

void handle_timeout_info | ( | float | seconds_to_phasedone,
|  | float | last_turn_change_time
| ) |  |

Sets the remaining turn time.

Definition at line 2340 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_trade_route_info()

void handle_trade_route_info | ( | const struct packet_trade_route_info * | packet | ) |

A trade route-info packet contains information about one end of a trade route

Definition at line 1119 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_unit_action_answer()

void handle_unit_action_answer | ( | int | actor_id,
|  | int | target_id,
|  | int | cost,
|  | action_id | action_type,
|  | int | request_kind
| ) |  |

Handle the requested follow up question about an action

The action can be a valid action or the special value ACTION_NONE. ACTION_NONE indicates that performing the action is impossible.

Definition at line 4875 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_unit_actions()

void handle_unit_actions | ( | const struct packet_unit_actions * | packet | ) |

Handle reply to possible actions.

Note that a reply to a foreground request (a reply where request_kind is REQEST_PLAYER_INITIATED) must result in its clean up.

Definition at line 5089 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_unit_combat_info()

void handle_unit_combat_info | ( | const struct packet_unit_combat_info * | packet | ) |

A combat packet. The server tells us the attacker and defender as well as both of their hitpoints after the combat is over (in most combat, one unit always dies and their HP drops to zero). If make_winner_veteran is set then the surviving unit becomes veteran.

Definition at line 568 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_unit_info()

void handle_unit_info | ( | const struct packet_unit_info * | packet | ) |

Packet unit_info.

Definition at line 1640 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_unit_remove()

void handle_unit_remove | ( | int | unit_id | ) |

Handle a remove-unit packet, sent by the server to tell us any time a unit is no longer there.

Definition at line 491 of file packhand.c.

Referenced by client_handle_packet(), and handle_unit_packet_common().

## ◆ handle_unit_short_info()

void handle_unit_short_info | ( | const struct packet_unit_short_info * | packet | ) |

Receive a short_unit info packet.

Definition at line 2145 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_unknown_research()

void handle_unknown_research | ( | int | id | ) |

Received a packet indicating we don't know the research details any more.

Definition at line 2736 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_vote_new()

void handle_vote_new | ( | const struct packet_vote_new * | packet | ) |

Create a new vote and add it to the queue. Refresh the GUI.

Definition at line 5481 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_vote_remove()

void handle_vote_remove | ( | int | vote_no | ) |

A vote no longer exists. Remove from queue and update gui.

Definition at line 5451 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_vote_resolve()

void handle_vote_resolve | ( | int | vote_no,
|  | bool | passed
| ) |  |

Update the vote's status and refresh the GUI.

Definition at line 5498 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_vote_update()

void handle_vote_update | ( | int | vote_no,
|  | int | yes,
|  | int | no,
|  | int | abstain,
|  | int | num_voters
| ) |  |

Find and update the corresponding vote and refresh the GUI.

Definition at line 5460 of file packhand.c.

Referenced by client_handle_packet().

## ◆ handle_web_city_info_addition()

void handle_web_city_info_addition | ( | int | id,
|  | bool | cma_enabled,
|  | const struct cm_parameter * | cm_parameter,
|  | int | granary_size,
|  | int | granary_turns,
|  | bv_utypes | can_build_unit,
|  | bv_imprs | can_build_improvement,
|  | const int * | output_food,
|  | const int * | output_shield,
|  | const int * | output_trade
| ) |  |

## ◆ handle_web_player_info_addition()

void handle_web_player_info_addition | ( | int | playerno,
|  | int | expected_income
| ) |  |

## ◆ handle_web_ruleset_unit_addition()

void handle_web_ruleset_unit_addition | ( | Unit_type_id | id,
|  | bv_actions | utype_actions
| ) |  |

## ◆ handle_worker_task()

void handle_worker_task | ( | const struct packet_worker_task * | packet | ) |

Handle worker task assigned to the city

Definition at line 1294 of file packhand.c.