UFO: Alien Invasion
cp_messages.h
Go to the documentation of this file.
1 
5 /*
6 Copyright (C) 2002-2022 UFO: Alien Invasion.
7 
8 This program is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License
10 as published by the Free Software Foundation; either version 2
11 of the License, or (at your option) any later version.
12 
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
16 
17 See the GNU General Public License for more details.
18 
19 You should have received a copy of the GNU General Public License
20 along with this program; if not, write to the Free Software
21 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
22 
23 */
24 
25 #pragma once
26 
27 #include "../../DateTime.h"
28 
29 #define MAX_MESSAGE_TEXT 256
30 
31 /* message systems */
32 typedef enum {
50 
55 
56 /* Russian timestamp (with UTF-8) is 23 bytes long */
57 #define TIMESTAMP_TEXT 24
59  char title[MAX_VAR];
61  char* text;
62  class DateTime date;
63  const char* iconName;
64  int lineUsed;
66 
69  struct technology_s* pedia;
70  struct eventMail_s* eventMail;
71 };
72 
74 
75 uiMessageListNodeMessage_t* MS_AddNewMessage(const char* title, const char* text, messageType_t type = MSG_STANDARD, struct technology_s* pedia = nullptr, bool popup = false, bool playSound = true);
76 void MS_MessageInit(void);
77 
char timestamp[TIMESTAMP_TEXT]
Definition: cp_messages.h:60
#define TIMESTAMP_TEXT
Definition: cp_messages.h:57
QGL_EXTERN GLint GLenum type
Definition: r_gl.h:94
struct uiMessageListNodeMessage_s * next
Definition: cp_messages.h:65
Class describing a point of time.
Definition: DateTime.h:30
messageType_t
Definition: cp_messages.h:32
struct eventMail_s * eventMail
Definition: cp_messages.h:70
#define MAX_MESSAGE_TEXT
Definition: cp_messages.h:29
#define MAX_VAR
Definition: shared.h:36
void MS_MessageInit(void)
char cp_messageBuffer[MAX_MESSAGE_TEXT]
Definition: cp_messages.cpp:33
struct technology_s * pedia
Definition: cp_messages.h:69
uiMessageListNodeMessage_t * MS_AddNewMessage(const char *title, const char *text, messageType_t type=MSG_STANDARD, struct technology_s *pedia=nullptr, bool popup=false, bool playSound=true)