From 3c487c5cd69c53d6fea948643c0a76df03516605 Mon Sep 17 00:00:00 2001 From: Aki Date: Fri, 1 Apr 2022 21:23:39 +0200 Subject: Moved Stars45 to StarsEx --- Stars45/NetChat.cpp | 51 --------------------------------------------------- 1 file changed, 51 deletions(-) delete mode 100644 Stars45/NetChat.cpp (limited to 'Stars45/NetChat.cpp') diff --git a/Stars45/NetChat.cpp b/Stars45/NetChat.cpp deleted file mode 100644 index 7c1f4d2..0000000 --- a/Stars45/NetChat.cpp +++ /dev/null @@ -1,51 +0,0 @@ -/* Starshatter: The Open Source Project - Copyright (c) 2021-2022, Starshatter: The Open Source Project Contributors - Copyright (c) 2011-2012, Starshatter OpenSource Distribution Contributors - Copyright (c) 1997-2006, Destroyer Studios LLC. - - AUTHOR: John DiCamillo - - - OVERVIEW - ======== - Single chat message and sender -*/ - - -#include "NetChat.h" -#include "NetLayer.h" - -// +-------------------------------------------------------------------+ - -static int chat_id_key = 1000; - -// +-------------------------------------------------------------------+ - -NetChatEntry::NetChatEntry(const NetUser* u, const char* s) -: id(chat_id_key++), msg(s) -{ - if (u) { - user = u->Name(); - color = u->GetColor(); - } - else { - user = "unknown"; - color = Color::Gray; - } - - time = NetLayer::GetUTC(); -} - -NetChatEntry::NetChatEntry(int msg_id, const char* u, const char* s) -: id(msg_id), user(u), msg(s) -{ - color = Color::Gray; - time = NetLayer::GetUTC(); - - if (id >= chat_id_key) - chat_id_key = id + 1; -} - -NetChatEntry::~NetChatEntry() -{ } - -- cgit v1.1