Freeciv-3.2
Loading...
Searching...
No Matches
api_server_notify.c
Go to the documentation of this file.
1/*****************************************************************************
2 Freeciv - Copyright (C) 2005 - The Freeciv Project
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
14#ifdef HAVE_CONFIG_H
15#include <fc_config.h>
16#endif
17
18/* common */
19#include "featured_text.h"
20#include "research.h"
21
22/* common/scriptcore */
23#include "luascript.h"
24
25/* server */
26#include "notify.h"
27
28#include "api_server_notify.h"
29
30
31/**********************************************************************/
35 int event, const char *message)
36{
38
39 notify_embassies(pplayer, ptile, event, ftc_any, "%s", message);
40}
41
42/**********************************************************************/
45void api_notify_event_msg(lua_State *L, Player *pplayer, Tile *ptile,
46 int event, const char *message)
47{
49
50 notify_player(pplayer, ptile, event, ftc_any, "%s", message);
51}
52
53/**********************************************************************/
57 bool include_plr,
58 int event, const char *message)
59{
60 struct research *pres;
61
63
64 pres = research_get(pplayer);
65
67 ftc_any, "%s", message);
68}
69
70/**********************************************************************/
74 int event, const char *message)
75{
76 struct research *pres;
77
79
80 pres = research_get(pplayer);
81
83}
void api_notify_event_msg(lua_State *L, Player *pplayer, Tile *ptile, int event, const char *message)
void api_notify_embassies_msg(lua_State *L, Player *pplayer, Tile *ptile, int event, const char *message)
void api_notify_research_embassies_msg(lua_State *L, Player *pplayer, int event, const char *message)
void api_notify_research_msg(lua_State *L, Player *pplayer, bool include_plr, int event, const char *message)
char * incite_cost
Definition comments.c:75
enum event_type event
Definition events.c:81
const struct ft_color ftc_any
#define LUASCRIPT_CHECK_STATE(L,...)
Definition luascript.h:117
void notify_research(const struct research *presearch, const struct player *exclude, enum event_type event, const struct ft_color color, const char *format,...)
Definition notify.c:393
void notify_player(const struct player *pplayer, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...)
Definition notify.c:291
void notify_research_embassies(const struct research *presearch, const struct player *exclude, enum event_type event, const struct ft_color color, const char *format,...)
Definition notify.c:433
void notify_embassies(const struct player *pplayer, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...)
Definition notify.c:315
struct research * research_get(const struct player *pplayer)
Definition research.c:128
Definition tile.h:50