Freeciv-3.3
Loading...
Searching...
No Matches
notify.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__NOTIFY_H
14#define FC__NOTIFY_H
15
16#include <stdarg.h>
17
18/* utility */
19#include "support.h" /* fc__attribute */
20
21/* common */
22#include "events.h"
23#include "fc_types.h"
24#include "featured_text.h" /* ftc_*: color pre-definitions. */
25#include "packets.h"
26
27/* server */
28#include "srv_main.h" /* enum server_states */
29
30struct research;
31
32
34 const struct connection *sender,
35 const struct ft_color color,
36 const char *format, ...)
41 const char *format,
44 const struct tile *ptile,
47 const char *format, ...)
50 const struct tile *ptile,
53 const char *format,
55
57 const struct tile *ptile,
60 const char *format, ...)
63 const struct tile *ptile,
66 const char *format, ...)
69 const struct tile *ptile,
72 const char *format, ...)
75 const struct tile *ptile,
78 const char *format, ...)
81 const struct tile *ptile,
84 const char *format, ...)
87 const struct player *exclude,
90 const char *format, ...)
93 const struct player *exclude,
96 const char *format, ...)
98
99/* Event cache. */
100
101/* The type of event target. */
103
104void event_cache_init(void);
105void event_cache_free(void);
106void event_cache_clear(void);
107void event_cache_remove_old(void);
108
112 const struct player *pplayer);
115 const struct player *pplayer)
118 struct event_cache_players *players);
119
121
123
127
128#endif /* FC__NOTIFY_H */
char * incite_cost
Definition comments.c:76
enum event_type event
Definition events.c:81
void void void notify_player(const struct player *pplayer, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void event_cache_remove_old(void)
Definition notify.c:602
void void void void void void notify_research(const struct research *presearch, const struct player *exclude, enum event_type event, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void send_pending_events(struct connection *pconn, bool include_public)
Definition notify.c:753
void event_cache_add_for_players(const struct packet_chat_msg *packet, struct event_cache_players *players)
Definition notify.c:671
void void void void notify_embassies(const struct player *pplayer, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void event_cache_load(struct section_file *file, const char *section)
Definition notify.c:783
void void vpackage_chat_msg(struct packet_chat_msg *packet, const struct connection *sender, const struct ft_color color, const char *format, va_list vargs)
Definition notify.c:104
void void notify_conn_early(struct conn_list *dest, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void package_chat_msg(struct packet_chat_msg *packet, const struct connection *sender, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void void void void void void void notify_research_embassies(const struct research *presearch, const struct player *exclude, enum event_type event, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void void void void void notify_team(const struct player *pplayer, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void void vpackage_event(struct packet_chat_msg *packet, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format, va_list vargs)
Definition notify.c:147
void event_cache_clear(void)
Definition notify.c:594
void event_cache_free(void)
Definition notify.c:582
void event_cache_phases_invalidate(void)
Definition notify.c:977
void event_cache_add_for_global_observers(const struct packet_chat_msg *packet)
Definition notify.c:630
void notify_conn(struct conn_list *dest, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void event_cache_add_for_player(const struct packet_chat_msg *packet, const struct player *pplayer)
Definition notify.c:645
struct event_cache_players * event_cache_player_add(struct event_cache_players *players, const struct player *pplayer) fc__warn_unused_result
Definition notify.c:703
void event_cache_add_for_all(const struct packet_chat_msg *packet)
Definition notify.c:619
void package_event(struct packet_chat_msg *packet, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...) fc__attribute((__format__(__printf__
void event_cache_save(struct section_file *file, const char *section)
Definition notify.c:903
void event_cache_init(void)
Definition notify.c:570
Definition colors.h:21
Definition tile.h:50
#define fc__attribute(x)
Definition support.h:99
#define fc__warn_unused_result
Definition support.h:109