Freeciv-3.3
Loading...
Searching...
No Matches
unithand.h
Go to the documentation of this file.
1/***********************************************************************
2 Freeciv - Copyright (C) 1996 - A Kjeldberg, L Gregersen, P Unold
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; either version 2, or (at your option)
6 any later version.
7
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12***********************************************************************/
13#ifndef FC__UNITHAND_H
14#define FC__UNITHAND_H
15
16/* common */
17#include "explanation.h"
18#include "unit.h"
19
20/* server */
21#include <hand_gen.h> /* <> so looked from the build directory first. */
22
28 struct extra_type **new_target,
31 bool rehome);
32
33bool unit_move_handling(struct unit *punit, struct tile *pdesttile,
35
36void unit_do_action(struct player *pplayer,
37 const int actor_id,
38 const int target_id,
39 const int sub_tgt_id,
40 const char *name,
41 const action_id action_type);
42
43bool unit_perform_action(struct player *pplayer,
44 const int actor_id,
45 const int target_id,
46 const int sub_tgt_id,
47 const char *name,
48 const action_id action_type,
49 const enum action_requester requester);
50
51void illegal_action_msg(struct player *pplayer,
52 const enum event_type event,
53 struct unit *actor,
55 const struct tile *target_tile,
56 const struct city *target_city,
57 const struct unit *target_unit);
58
60 action_id act_id,
61 const struct tile *target_tile,
62 const struct city *target_city,
63 const struct unit *target_unit);
64
65bool unit_server_side_agent_set(struct player *pplayer,
66 struct unit *punit,
68
69void create_trade_route(struct city *from, struct city *to,
70 struct goods_type *goods);
71
72#endif /* FC__UNITHAND_H */
char * incite_cost
Definition comments.c:76
struct unit struct city struct unit * target_unit
Definition dialogs_g.h:56
struct unit struct city struct unit struct tile struct extra_type const struct act_prob *act_probs int actor_unit_id struct unit * actor
Definition dialogs_g.h:73
struct unit struct city struct unit struct tile * target_tile
Definition dialogs_g.h:57
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 * punit
Definition dialogs_g.h:74
struct unit struct city * target_city
Definition dialogs_g.h:56
enum event_type event
Definition events.c:81
ane_kind
Definition explanation.h:22
int action_id
Definition fc_types.h:248
const char * name
Definition inputfile.c:127
Definition agents.h:40
Definition city.h:317
Definition tile.h:50
Definition unit.h:140
static struct goods_type goods[MAX_GOODS_TYPES]
Definition traderoutes.c:43
bool unit_activity_handling_targeted(struct unit *punit, enum unit_activity new_activity, struct extra_type **new_target, enum gen_action trigger_action)
Definition unithand.c:6735
void illegal_action_msg(struct player *pplayer, const enum event_type event, struct unit *actor, const action_id stopped_action, const struct tile *target_tile, const struct city *target_city, const struct unit *target_unit)
Definition unithand.c:2515
bool unit_move_handling(struct unit *punit, struct tile *pdesttile, bool move_diplomat_city)
Definition unithand.c:5715
bool unit_activity_handling(struct unit *punit, enum unit_activity new_activity, enum gen_action trigger_action)
Definition unithand.c:6663
void create_trade_route(struct city *from, struct city *to, struct goods_type *goods)
Definition unithand.c:6373
void unit_do_action(struct player *pplayer, const int actor_id, const int target_id, const int sub_tgt_id, const char *name, const action_id action_type)
Definition unithand.c:3338
void unit_change_homecity_handling(struct unit *punit, struct city *new_pcity, bool rehome)
Definition unithand.c:4072
bool unit_server_side_agent_set(struct player *pplayer, struct unit *punit, enum server_side_agent agent)
Definition unithand.c:6562
enum ane_kind action_not_enabled_reason(struct unit *punit, action_id act_id, const struct tile *target_tile, const struct city *target_city, const struct unit *target_unit)
Definition unithand.c:1936
bool unit_perform_action(struct player *pplayer, const int actor_id, const int target_id, const int sub_tgt_id, const char *name, const action_id action_type, const enum action_requester requester)
Definition unithand.c:3358