Freeciv-3.3
Loading...
Searching...
No Matches
goto.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__GOTO_H
14#define FC__GOTO_H
15
16#ifdef __cplusplus
17extern "C" {
18#endif /* __cplusplus */
19
20struct pf_path;
21struct tile;
22struct unit;
23struct unit_list;
24
32
33void init_client_goto(void);
34void free_client_goto(void);
35
36void enter_goto_state(struct unit_list *punits);
37void exit_goto_state(void);
38
39void goto_unit_killed(struct unit *punit);
40
41bool goto_is_active(void);
42bool goto_get_turns(int *min, int *max);
43bool goto_tile_state(const struct tile *ptile, enum goto_tile_state *state,
44 int *turns, bool *waypoint);
45bool goto_add_waypoint(void);
46bool goto_pop_waypoint(void);
47
48bool is_valid_goto_destination(const struct tile *ptile);
49bool is_valid_goto_draw_line(struct tile *dest_tile);
50
52void send_goto_path(struct unit *punit, struct pf_path *path,
53 struct unit_order *last_order);
54bool send_goto_tile(struct unit *punit, struct tile *ptile);
55bool send_rally_tile(struct city *pcity, struct tile *ptile, bool persistent);
56bool send_attack_tile(struct unit *punit, struct tile *ptile);
57void send_patrol_route(void);
58void send_goto_route(void);
59void send_connect_route(enum unit_activity activity,
60 struct extra_type *tgt);
61
63struct tile *tile_before_end_path(struct unit *punit, struct tile *ptile);
64
65#ifdef __cplusplus
66}
67#endif /* __cplusplus */
68
69#endif /* FC__GOTO_H */
char * incite_cost
Definition comments.c:76
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 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
Definition dialogs_g.h:78
void exit_goto_state(void)
Definition goto.c:1033
struct tile * tile_before_end_path(struct unit *punit, struct tile *ptile)
Definition goto.c:2036
bool goto_is_active(void)
Definition goto.c:1070
bool send_attack_tile(struct unit *punit, struct tile *ptile)
Definition goto.c:1639
struct pf_path * path_to_nearest_allied_city(struct unit *punit)
Definition goto.c:2007
void init_client_goto(void)
Definition goto.c:153
void send_patrol_route(void)
Definition goto.c:1666
void send_goto_path(struct unit *punit, struct pf_path *path, struct unit_order *last_order)
Definition goto.c:1548
bool send_rally_tile(struct city *pcity, struct tile *ptile, bool persistent)
Definition goto.c:1593
bool is_valid_goto_draw_line(struct tile *dest_tile)
Definition goto.c:1350
goto_tile_state
Definition goto.h:25
@ GTS_EXHAUSTED_MP
Definition goto.h:28
@ GTS_MP_LEFT
Definition goto.h:27
@ GTS_TURN_STEP
Definition goto.h:26
@ GTS_COUNT
Definition goto.h:30
bool goto_add_waypoint(void)
Definition goto.c:489
bool send_goto_tile(struct unit *punit, struct tile *ptile)
Definition goto.c:1569
bool goto_pop_waypoint(void)
Definition goto.c:528
void send_connect_route(enum unit_activity activity, struct extra_type *tgt)
Definition goto.c:1733
void goto_unit_killed(struct unit *punit)
Definition goto.c:1051
void free_client_goto(void)
Definition goto.c:163
void enter_goto_state(struct unit_list *punits)
Definition goto.c:1011
void send_goto_route(void)
Definition goto.c:1894
bool is_valid_goto_destination(const struct tile *ptile)
Definition goto.c:180
bool goto_get_turns(int *min, int *max)
Definition goto.c:1079
void request_orders_cleared(struct unit *punit)
Definition goto.c:1377
static GtkWidget * persistent
Definition city.h:317
Definition tile.h:50
Definition unit.h:140