EvEmu  0.8.4
11 September 2021
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
HoloscreenMgrService.cpp
Go to the documentation of this file.
1 /*
2  ------------------------------------------------------------------------------------
3  LICENSE:
4  ------------------------------------------------------------------------------------
5  This file is part of EVEmu: EVE Online Server Emulator
6  Copyright 2006 - 2021 The EVEmu Team
7  For the latest information visit https://evemu.dev
8  ------------------------------------------------------------------------------------
9  This program is free software; you can redistribute it and/or modify it under
10  the terms of the GNU Lesser General Public License as published by the Free Software
11  Foundation; either version 2 of the License, or (at your option) any later
12  version.
13 
14  This program is distributed in the hope that it will be useful, but WITHOUT
15  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
16  FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
17 
18  You should have received a copy of the GNU Lesser General Public License along with
19  this program; if not, write to the Free Software Foundation, Inc., 59 Temple
20  Place - Suite 330, Boston, MA 02111-1307, USA, or go to
21  http://www.gnu.org/copyleft/lesser.txt.
22  ------------------------------------------------------------------------------------
23  Author: Ubiquitatis
24 */
25 
26 #include "eve-server.h"
27 
28 #include "PyServiceCD.h"
30 
32 
34 : PyService(mgr, "holoscreenMgr"),
35  m_dispatch(new Dispatcher(this))
36 {
37  _SetCallDispatcher(m_dispatch);
38 
39  PyCallable_REG_CALL(HoloscreenMgrService, GetTwoHourCache);
40  PyCallable_REG_CALL(HoloscreenMgrService, GetRuntimeCache);
41  PyCallable_REG_CALL(HoloscreenMgrService, GetRecentEpicArcCompletions);
42 }
43 
45 {
46  delete m_dispatch;
47 }
48 
49 //those objects should be cached
50 
51 PyResult HoloscreenMgrService::Handle_GetRecentEpicArcCompletions(PyCallArgs& call)
52 { // this is cached object!!!
53  sLog.Debug("HoloscreenMgrService", "Called GetRecentEpicArcCompletions stub.");
54 
55  /*
56  * characterID
57  * completionDate
58  */
59 
60  return nullptr;
61 }
62 
63 PyResult HoloscreenMgrService::Handle_GetTwoHourCache(PyCallArgs& call)
64 {
65  PyDict* agents = new PyDict();
66  agents->SetItemString("Agent_DUMMY", new PyDict());
67  PyDict* args = new PyDict();
68  args->SetItemString("careerAgents", agents);
69  args->SetItemString("incursionReport", new PyList());
70  args->SetItemString("epicArcAgents", new PyDict());
71  args->SetItemString("sovChangesReport", new PyList());
72  return new PyObject("util.KeyVal", args);
73 }
74 
75 PyResult HoloscreenMgrService::Handle_GetRuntimeCache(PyCallArgs& call)
76 {
77  PyDict* agents = new PyDict();
78  agents->SetItemString("Agent_DUMMY", new PyDict());
79  PyDict* args = new PyDict();
80  args->SetItemString("careerAgents", agents);
81  args->SetItemString("incursionReport", new PyList());
82  args->SetItemString("epicArcAgents", new PyDict());
83  args->SetItemString("sovChangesReport", new PyList());
84  return new PyObject("util.KeyVal", args);
85 }
86 
87 /* sovChangesReport
88  solarSystemID
89  oldOwnerID
90  newOwnerID
91  */
92 
93 /* incursionReport
94  influence
95  stagingSolarSystemID
96  */
97 
98 /*
99 ideas for holoscreen in CQ:
100  - corp recruit ads
101  - incursion data
102  - relevant system data for player's current system
103  - others?
104  - more?
105 
106  */
107 
108 
109 
110 /*
111  *
112  [PySubStream 112 bytes]
113  [PyTuple 4 items]
114  [PyInt 1]
115  [PyString "GetCachableObject"]
116  [PyTuple 4 items]
117  [PyInt 1]
118  [PyTuple 3 items]
119  [PyString "Method Call"]
120  [PyString "server"]
121  [PyTuple 2 items]
122  [PyString "holoscreenMgr"]
123  [PyString "GetRuntimeCache"]
124  [PyTuple 2 items]
125  [PyIntegerVar 129519218650427395]
126  [PyInt 53737]
127  [PyInt 700318]
128 
129  [PySubStream 774 bytes]
130  [PyObjectData Name: objectCaching.CachedObject]
131  [PyTuple 7 items]
132  [PyTuple 2 items]
133  [PyIntegerVar 129519242704509384]
134  [PyInt 9603]
135  [PyNone]
136  [PyInt 700322]
137  [PyInt 1]
138  [PyString "xm?Kka??L????m?T
139  ? ??6TP.*?%?k?b??4??*?2I?n??? ??i??h????????C?? ?_?}G:?B????????i????f? ???D?5r8[??5-??1??-_?7^N,K?2???`9m?UF???x`??<pK? g???P}?6HE???2rI?_????9mJ?
140  ?? ?? }N?A?9??? ?}??Nd^???? ?l???# ???0?Q?+ ? ?`X@??UwA?UiD?????????&d??DJe?;Ad???
141  "u3?? 2V??"uS]/?T?U
142 
143  */
Dispatcher *const m_dispatch
Python's dictionary.
Definition: PyRep.h:719
* args
#define sLog
Evaluates to a NewLog instance.
Definition: LogNew.h:250
Python object.
Definition: PyRep.h:826
#define PyCallable_REG_CALL(c, m)
Definition: PyServiceCD.h:78
PyCallable_Make_InnerDispatcher(HoloscreenMgrService) HoloscreenMgrService
Dispatcher *const m_dispatch
Python list.
Definition: PyRep.h:639
void SetItemString(const char *key, PyRep *value)
SetItemString adds or sets a database entry.
Definition: PyRep.h:812