EvEmu  0.8.4
11 September 2021
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
AgentBound.cpp
Go to the documentation of this file.
1 
13 /*
14  * # Agent Logging:
15  * AGENT__ERROR
16  * AGENT__WARNING
17  * AGENT__MESSAGE
18  * AGENT__DEBUG
19  * AGENT__INFO
20  * AGENT__TRACE
21  * AGENT__DUMP
22  * AGENT__RSP_DUMP
23  */
24 
25 #include "eve-server.h"
26 #include "../../eve-common/EVE_Missions.h"
27 #include "../../eve-common/EVE_Standings.h"
28 
29 #include "StaticDataMgr.h"
30 #include "account/AccountService.h"
31 #include "agents/AgentBound.h"
32 #include "station/Station.h"
33 
34 AgentBound::AgentBound(PyServiceMgr *mgr, Agent *agt)
35 : PyBoundObject(mgr),
36 m_dispatch(new Dispatcher(this)),
37 m_agent(agt)
38 {
39  _SetCallDispatcher(m_dispatch);
40 
41  m_strBoundObjectName = "AgentBound";
42 
44  PyCallable_REG_CALL(AgentBound, GetAgentLocationWrap);
46  PyCallable_REG_CALL(AgentBound, GetMissionBriefingInfo);
47  PyCallable_REG_CALL(AgentBound, GetMissionObjectiveInfo);
48  PyCallable_REG_CALL(AgentBound, GetMissionKeywords);
49  PyCallable_REG_CALL(AgentBound, GetMissionJournalInfo);
50  PyCallable_REG_CALL(AgentBound, GetDungeonShipRestrictions);
51  PyCallable_REG_CALL(AgentBound, RemoveOfferFromJournal);
52  PyCallable_REG_CALL(AgentBound, GetOfferJournalInfo);
53  PyCallable_REG_CALL(AgentBound, GetEntryPoint);
54  PyCallable_REG_CALL(AgentBound, GotoLocation);
55  PyCallable_REG_CALL(AgentBound, WarpToLocation);
56  PyCallable_REG_CALL(AgentBound, GetMyJournalDetails);
57 }
58 
59 PyResult AgentBound::Handle_GetAgentLocationWrap(PyCallArgs &call) {
60  // this is detailed info on agent's location
61  return m_agent->GetLocationWrap();
62 }
63 
64 PyResult AgentBound::Handle_GetInfoServiceDetails( PyCallArgs& call ) {
65  // this is agents personal info... level, division, station, etc.
67 }
68 
69 
74 PyResult AgentBound::Handle_DoAction(PyCallArgs &call) {
75  // this is first call when initiating agent convo
76  _log(AGENT__DUMP, "AgentBound::Handle_DoAction() - size= %u", call.tuple->size() );
77  call.Dump(AGENT__DUMP);
78 
79  // sends PyNone or actionID
80  Call_SingleArg args;
81  if (!args.Decode(&call.tuple)) {
82  _log(SERVICE__ERROR, "%s: Failed to decode arguments.", GetName());
83  return nullptr;
84  }
85  // this actually returns a complicated tuple depending on other variables involving this agent and char.
86  /*
87  agentSays, dialogue, extraInfo = self.__GetConversation(agentDialogueWindow, actionID)
88 
89  def __GetConversation(self, wnd, actionID):
90  tmp = wnd.sr.agentMoniker.DoAction(actionID)
91  ret, wnd.sr.oob = tmp
92  agentSays, wnd.sr.dialogue = ret
93  firstActionID = wnd.sr.dialogue[0][0]
94  firstActionDialogue = wnd.sr.dialogue[0][1]
95  wnd.sr.agentSays = self.ProcessMessage(agentSays, wnd.sr.agentID)
96  return (wnd.sr.agentSays, wnd.sr.dialogue, wnd.sr.oob)
97  *
98  */
99 
100  Character* pchar = call.client->GetChar().get();
101  float charStanding = StandingDB::GetStanding(m_agent->GetID(), pchar->itemID());
104  float standing = EvEMath::Agent::EffectiveStanding(charStanding, bonus);
105 
106  std::string response = "";
107  uint8 actionID = PyRep::IntegerValueU32(args.arg);
108  bool missionQuit = false, missionCompleted = false, missionDeclined = false;
109 
110  PyTuple* agentSays = new PyTuple(2);
111  // dialog is button info
112  PyList* dialog = new PyList();
113 
114  using namespace Dialog::Button;
115 
116  // to set 'admin dialog options' (which i dont know wtf they are yet), i *think* you add a tuple of *something* that is NOT dict or int.
117  if (false /*admin options*/) {
118  PyTuple* adminButton = new PyTuple(2);
119  adminButton->SetItem(0, new PyInt(Admin));
120  adminButton->SetItem(1, new PyString("Admin Options"));
121  dialog->AddItem(adminButton);
122  }
123 
124  if (m_agent->CanUseAgent(call.client)) {
125  switch (actionID) {
126  case 0: {
127  // if char has current mission with this agent, add this one.
128  MissionOffer offer = MissionOffer();
129  if (m_agent->HasMission(pchar->itemID(), offer)) {
130  PyTuple* button1 = new PyTuple(2);
131  button1->SetItem(0, new PyInt(ViewMission)); // this are buttonIDs which are unique and sequential to each agent, regardless of chars
132  button1->SetItem(1, new PyInt(ViewMission));
133  dialog->AddItem(button1);
134  if (call.client->IsMissionComplete(offer)) {
135  PyTuple* button2 = new PyTuple(2);
136  button2->SetItem(0, new PyInt(Complete));
137  button2->SetItem(1, new PyInt(Complete));
138  dialog->AddItem(button2);
139  }
140  agentSays->SetItem(0, new PyInt(offer.briefingID));
141  agentSays->SetItem(1, new PyInt(offer.characterID));
142  } else {
143  // dialogue data. if RequestMission is only option, client auto-responds with DoAction(RequestMission optionID)
144  PyTuple* button2 = new PyTuple(2);
145  button2->SetItem(0, new PyInt(RequestMission));
146  button2->SetItem(1, new PyInt(RequestMission));
147  dialog->AddItem(button2);
148  // response as string for custom data. response as pyint to use client data (using getlocale shit)
149  // default initial agent response based on agent location, level, bloodline, quality, and char/agent standings
150  // this will be modeled after UO speech data, in tiers and levels.
151  // if RequestMission is only option, this is ignored. see note under 'dialog data'
152  response = "Why the fuck am I looking at you again, ";
153  response += call.client->GetName();
154  response += "?";
155  agentSays->SetItem(0, new PyString(response)); //msgInfo -- if tuple[0].string then return msgInfo
156  agentSays->SetItem(1, PyStatic.NewNone()); // ContentID -- PyNone used when msgInfo is string (mostly for initial greetings)
157  }
158 
159  // if agent does location, add this one...
160  if (m_agent->IsLocator()) {
161  PyTuple* button3 = new PyTuple(2);
162  button3->SetItem(0, new PyInt(LocateCharacter));
163  button3->SetItem(1, new PyInt(LocateCharacter));
164  dialog->AddItem(button3);
165  }
166 
167  // if agent does research, add this one...
168  if (m_agent->IsResearch()) {
169  PyTuple* button4 = new PyTuple(2);
170  button4->SetItem(0, new PyInt(StartResearch));
171  button4->SetItem(1, new PyInt(StartResearch));
172  dialog->AddItem(button4);
173  }
174  } break;
175  case RequestMission: { //2
176  MissionOffer offer = MissionOffer();
177  m_agent->MakeOffer(pchar->itemID(), offer);
178  m_agent->SendMissionUpdate(call.client, "offered");
179 
180  // this one will get complicated and is based on agent/char interaction
181  // detail in /eve/client/script/ui/station/agents/agents.py
182 
183  /* agentSays is a tuple of msgData and contentID
184  * msgData can be single integer of briefingID, a string literal, or a tuple as defined above.
185  * contentID is used for specific char's mission keywords. we're not using it like there here....
186  */
187 
188  agentSays->SetItem(0, new PyInt(offer.briefingID));
189  agentSays->SetItem(1, new PyInt(offer.characterID));
190 
191  // dialog can also contain mission data.
192  // set a dialog tuple[1] to dict and fill with MissionBriefingInfo
193  PyTuple* button1 = new PyTuple(2);
194  button1->SetItem(0, new PyInt(Accept));
195  button1->SetItem(1, new PyInt(Accept));
196  dialog->AddItem(button1);
197  PyTuple* button2 = new PyTuple(2);
198  button2->SetItem(0, new PyInt(Decline));
199  button2->SetItem(1, new PyInt(Decline));
200  dialog->AddItem(button2);
201  PyTuple* button3 = new PyTuple(2);
202  button3->SetItem(0, new PyInt(Defer));
203  button3->SetItem(1, new PyInt(Defer));
204  dialog->AddItem(button3);
205  } break;
206  case ViewMission: { //1
207  MissionOffer offer = MissionOffer();
208  m_agent->GetOffer(pchar->itemID(), offer);
209  agentSays->SetItem(0, new PyInt(offer.briefingID));
210  agentSays->SetItem(1, new PyInt(offer.characterID));
211  if (offer.stateID < Mission::State::Accepted) {
212  PyTuple* button1 = new PyTuple(2);
213  button1->SetItem(0, new PyInt(Accept));
214  button1->SetItem(1, new PyInt(Accept));
215  dialog->AddItem(button1);
216  PyTuple* button2 = new PyTuple(2);
217  button2->SetItem(0, new PyInt(Decline));
218  button2->SetItem(1, new PyInt(Decline));
219  dialog->AddItem(button2);
220  PyTuple* button3 = new PyTuple(2);
221  button3->SetItem(0, new PyInt(Defer));
222  button3->SetItem(1, new PyInt(Defer));
223  dialog->AddItem(button3);
224  } else if (offer.stateID == Mission::State::Accepted) {
225  PyTuple* button1 = new PyTuple(2);
226  button1->SetItem(0, new PyInt(Quit));
227  button1->SetItem(1, new PyInt(Quit));
228  dialog->AddItem(button1);
229  if (call.client->IsMissionComplete(offer)) {
230  PyTuple* button2 = new PyTuple(2);
231  button2->SetItem(0, new PyInt(Complete));
232  button2->SetItem(1, new PyInt(Complete));
233  dialog->AddItem(button2);
234  }
235  }
236  } break;
237  case Accept: //3
238  case AcceptRemotely: { //5
239  MissionOffer offer = MissionOffer();
240  m_agent->GetOffer(pchar->itemID(), offer);
242  offer.dateAccepted = GetFileTimeNow();
243  offer.expiryTime = GetFileTimeNow() + (30 * m_agent->GetLevel() * EvE::Time::Minute); // 30m per agent level ? test this.
244  if (offer.courierTypeID) {
245  // add item to players hangar
246  sItemFactory.SetUsingClient(call.client);
247  ItemData data(offer.courierTypeID, pchar->itemID(), locTemp, flagNone, offer.courierAmount);
248  InventoryItemRef iRef = sItemFactory.SpawnItem(data);
249  iRef->Move(offer.originID, flagHangar, true);
250  sItemFactory.UnsetUsingClient();
251  }
252  m_agent->UpdateOffer(pchar->itemID(), offer);
253  m_agent->SendMissionUpdate(call.client, "offer_accepted");
254  agentSays->SetItem(0, new PyInt(m_agent->GetAcceptRsp(pchar->itemID())));
255  agentSays->SetItem(1, new PyInt(pchar->itemID()));
256  } break;
257  case Complete: //6
258  case CompleteRemotely: { //7
259  // need to verify all requirements have been met.
260  MissionOffer offer = MissionOffer();
261  m_agent->GetOffer(pchar->itemID(), offer);
263  offer.dateCompleted = GetFileTimeNow();
264  m_agent->UpdateOffer(pchar->itemID(), offer);
265  m_agent->SendMissionUpdate(call.client, "completed");
266  agentSays->SetItem(0, new PyInt(m_agent->GetCompleteRsp(pchar->itemID())));
267  agentSays->SetItem(1, new PyInt(pchar->itemID()));
268  if (offer.courierTypeID) {
269  // remove item from player possession
271  }
272  if (offer.rewardItemID) {
273  // add reward item to players hangar
274  sItemFactory.SetUsingClient(call.client);
275  ItemData data(offer.rewardItemID, pchar->itemID(), locTemp, flagNone, offer.rewardItemQty);
276  InventoryItemRef iRef = sItemFactory.SpawnItem(data);
277  iRef->Move(m_agent->GetStationID(), flagHangar, true);
278  sItemFactory.UnsetUsingClient();
279  }
281  if (offer.rewardISK)
283  if ((offer.bonusTime > 0) and (offer.bonusTime < (offer.dateAccepted - GetFileTimeNow())))
287  } break;
288  case Defer: { //10
289  // extend expiry time and close
290  MissionOffer offer = MissionOffer();
291  if (m_agent->HasMission(pchar->itemID(), offer)) {
292  offer.stateID = Mission::State::Allocated; //Defered
293  offer.expiryTime += EvE::Time::Day;
294  m_agent->UpdateOffer(pchar->itemID(), offer);
295  m_agent->SendMissionUpdate(call.client, "prolong");
296  agentSays->SetItem(0, new PyString("I can give you 24 hours to think about it.")); //msgInfo -- if tuple[0].string then return msgInfo
297  agentSays->SetItem(1, PyStatic.NewNone()); // ContentID -- PyNone used when msgInfo is string to return without processing
298  }
299  } break;
300  case Decline: { //9
301  missionDeclined = true;
302  m_agent->DeleteOffer(pchar->itemID());
303  m_agent->SendMissionUpdate(call.client, "offer_declined");
304  agentSays->SetItem(0, new PyInt(m_agent->GetDeclineRsp(pchar->itemID())));
305  agentSays->SetItem(1, new PyInt(pchar->itemID()));
308  } break;
309  case Quit: { //11
310  missionQuit = true;
311  MissionOffer offer = MissionOffer();
312  m_agent->GetOffer(pchar->itemID(), offer);
313  if (offer.courierTypeID) {
314  // remove item from player possession
316  }
317  // remove mission offer and set standings accordingly
318  m_agent->DeleteOffer(pchar->itemID());
319  m_agent->SendMissionUpdate(call.client, "quit");
320  agentSays->SetItem(0, new PyInt(m_agent->GetDeclineRsp(pchar->itemID())));
321  agentSays->SetItem(1, new PyInt(pchar->itemID()));
324  } break;
325  case Continue: { //8
326  // not sure what to do here.
327  } break;
328  case StartResearch: { //12
329  // not sure what to do here.
330  } break;
331  case CancelResearch: { //13
332  // not sure what to do here.
333  } break;
334  case BuyDatacores: { //14
335  // not sure what to do here.
336  } break;
337  case LocateCharacter: //15
338  case LocateAccept: { //16
339  // not sure what to do here.
340  } break;
341  case LocateReject: { //17
342  // not sure what to do here.
343  } break;
344  case Yes: { //18
345  // not sure what to do here.
346  } break;
347  case No: { //19
348  // not sure what to do here.
349  } break;
350  case AcceptChoice:{ //4
351  // i think this is for options
352  } break;
353  case Admin: { //20
354  // not sure what to do here.
355  } break;
356  default: {
357  // error
358  _log(AGENT__ERROR, "AgentBound::Handle_DoAction() - unhandled buttonID %u", actionID );
359  call.client->SendErrorMsg("Internal Server Error. Ref: ServerError xxxxx.");
360  return nullptr;
361  }
362  }
363  } else {
364  agentSays->SetItem(0, new PyInt(m_agent->GetStandingsRsp(pchar->itemID())));
365  agentSays->SetItem(1, PyStatic.NewNone() /*new PyInt(pchar->itemID())*/);
366  }
367 
368  // extraInfo data....
369  PyDict* xtraInfo = new PyDict();
370  xtraInfo->SetItemString("loyaltyPoints", new PyInt(call.client->GetLoyaltyPoints(m_agent->GetCorpID()))); // this is char current LP
371  xtraInfo->SetItemString("missionCompleted", new PyBool(missionCompleted));
372  xtraInfo->SetItemString("missionQuit", new PyBool(missionQuit));
373  xtraInfo->SetItemString("missionDeclined", new PyBool(missionDeclined));
374 
375  if (agentSays->empty()) {
376  agentSays->SetItem(0, PyStatic.NewNone()); // briefingID
377  agentSays->SetItem(1, PyStatic.NewNone()); // ContentID
378  }
379  PyTuple* inner = new PyTuple(2);
380  inner->SetItem(0, agentSays);
381  inner->SetItem(1, dialog);
382  PyTuple* outer = new PyTuple(2);
383  outer->SetItem(0, inner);
384  outer->SetItem(1, xtraInfo);
385 
386  if (is_log_enabled(AGENT__RSP_DUMP)) {
387  _log(AGENT__RSP_DUMP, "AgentBound::Handle_DoAction RSP:" );
388  outer->Dump(AGENT__RSP_DUMP, " ");
389  }
390 
391  return outer;
392 }
393 
394 PyResult AgentBound::Handle_GetMissionBriefingInfo(PyCallArgs &call) {
395  // called from iniate agent convo... should be populated when mission available
396  // will return PyNone if no mission avalible
397  _log(AGENT__MESSAGE, "AgentBound::Handle_GetMissionBriefingInfo()");
398 
399  MissionOffer offer = MissionOffer();
400  if (!m_agent->HasMission(call.client->GetCharacterID(), offer))
401  return PyStatic.NewNone();
402 
403  switch (offer.stateID) {
404  //case Mission::State::Allocated:
411  return PyStatic.NewNone();
412  }
413  }
414 
415  // these are found in the client data by MessageIDs .... i.e. {[location]objectiveDestinationID.name}
416  // contentID is the key for the keywords data on live...not used here
417  PyDict* keywords = new PyDict();
418  keywords->SetItemString("objectiveLocationID", new PyInt(offer.originID));
419  keywords->SetItemString("objectiveLocationSystemID", new PyInt(offer.originSystemID));
420  keywords->SetItemString("objectiveTypeID", new PyInt(offer.courierTypeID));
421  keywords->SetItemString("objectiveQuantity", new PyInt(offer.courierAmount));
422  keywords->SetItemString("objectiveDestinationID", new PyInt(offer.destinationID));
423  keywords->SetItemString("objectiveDestinationSystemID", new PyInt(offer.destinationSystemID));
424  if (offer.rewardISK) {
425  keywords->SetItemString("rewardTypeID", new PyInt(itemTypeCredits));
426  keywords->SetItemString("rewardQuantity", new PyInt(offer.rewardISK));
427  } else {
428  // wouldnt these be in 'extra' or ?
429  keywords->SetItemString("rewardTypeID", new PyInt(offer.rewardItemID));
430  keywords->SetItemString("rewardQuantity", new PyInt(offer.rewardItemQty));
431  }
432  keywords->SetItemString("dungeonLocationID", new PyInt(offer.dungeonLocationID));
433  keywords->SetItemString("dungeonSolarSystemID", new PyInt(offer.dungeonSolarSystemID));
434  PyDict *briefingInfo = new PyDict();
435  briefingInfo->SetItemString("ContentID", new PyInt(offer.characterID));
436  briefingInfo->SetItemString("Mission Keywords", keywords);
437  briefingInfo->SetItemString("Mission Title ID", new PyInt(offer.missionID));
438  briefingInfo->SetItemString("Mission Briefing ID", new PyInt(offer.briefingID));
439  switch(offer.typeID) {
441  briefingInfo->SetItemString("Mission Image", sMissionDataMgr.GetCourierRes()); break;
443  briefingInfo->SetItemString("Mission Image", sMissionDataMgr.GetMiningRes()); break;
445  briefingInfo->SetItemString("Mission Image", sMissionDataMgr.GetKillRes()); break;
446  }
447  // decline time OR expiration time. if not decline then expiration
448  briefingInfo->SetItemString("Decline Time", PyStatic.NewNone()); // -1 is generic decline msg
449  briefingInfo->SetItemString("Expiration Time", new PyLong(offer.expiryTime) );
450 
451  if (is_log_enabled(AGENT__RSP_DUMP)) {
452  _log(AGENT__RSP_DUMP, "AgentBound::Handle_GetMissionBriefingInfo() RSP:" );
453  briefingInfo->Dump(AGENT__RSP_DUMP, " ");
454  }
455 
456  return briefingInfo;
457 }
458 
459 PyResult AgentBound::Handle_GetMissionKeywords(PyCallArgs &call) {
460  // thse are the variables embedded in the messageIDs
461  //self.missionArgs[contentID] = self.GetAgentMoniker(agentID).GetMissionKeywords(contentID)
462  _log(AGENT__DUMP, "AgentBound::Handle_GetMissionKeywords() - size= %u", call.tuple->size() );
463  call.Dump(AGENT__DUMP);
464 
465  /* none of this really matters as we're not using 'contentID' like live does
466  Call_SingleArg args;
467  if (!args.Decode(&call.tuple)) {
468  _log(SERVICE__ERROR, "%s: Failed to decode arguments.", GetName());
469  return nullptr;
470  }
471 
472  uint32 contentID = PyRep::IntegerValueU32(args.arg);
473  if (contentID == 0)
474  return PyStatic.NewNone();
475  */
476  MissionOffer offer = MissionOffer();
477  if (!m_agent->HasMission(call.client->GetCharacterID(), offer))
478  return PyStatic.NewNone();
479 
480  PyDict* keywords = new PyDict();
481  keywords->SetItemString("objectiveLocationID", new PyInt(offer.originID));
482  keywords->SetItemString("objectiveLocationSystemID", new PyInt(offer.originSystemID));
483  keywords->SetItemString("objectiveTypeID", new PyInt(offer.courierTypeID));
484  keywords->SetItemString("objectiveQuantity", new PyInt(offer.courierAmount));
485  keywords->SetItemString("objectiveDestinationID", new PyInt(offer.destinationID));
486  keywords->SetItemString("objectiveDestinationSystemID", new PyInt(offer.destinationSystemID));
487  if (offer.rewardISK) {
488  keywords->SetItemString("rewardTypeID", new PyInt(itemTypeCredits));
489  keywords->SetItemString("rewardQuantity", new PyInt(offer.rewardISK));
490  } else {
491  // wouldnt these be in 'extra' or ?
492  keywords->SetItemString("rewardTypeID", new PyInt(offer.rewardItemID));
493  keywords->SetItemString("rewardQuantity", new PyInt(offer.rewardItemQty));
494  }
495  keywords->SetItemString("dungeonLocationID", new PyInt(offer.dungeonLocationID));
496  keywords->SetItemString("dungeonSolarSystemID", new PyInt(offer.dungeonSolarSystemID));
497 
498  if (is_log_enabled(AGENT__RSP_DUMP)) {
499  _log(AGENT__RSP_DUMP, "AgentBound::Handle_GetMissionKeywords() RSP:" );
500  keywords->Dump(AGENT__RSP_DUMP, " ");
501  }
502 
503  return keywords;
504 }
505 
506 PyResult AgentBound::Handle_GetMissionObjectiveInfo(PyCallArgs &call)
507 {
508  // sends charID, contentID
509  // returns PyDict loaded with mission info or PyNone
510  // returning mission info sets double-pane view, where PyNone sets single-pane view
511  _log(AGENT__DUMP, "AgentBound::Handle_GetMissionObjectiveInfo() - size= %u", call.tuple->size() );
512  call.Dump(AGENT__DUMP);
513 
514  MissionOffer offer = MissionOffer();
515  if (call.tuple->size() == 0)
516  if (!m_agent->HasMission(call.client->GetCharacterID(), offer))
517  return PyStatic.NewNone();
518 
519  switch (offer.stateID) {
520  //case Mission::State::Allocated:
522  //case Mission::State::Failed:
527  return PyStatic.NewNone();
528  }
529  }
530 
531  return GetMissionObjectiveInfo(call.client, offer);
532 }
533 
534 PyResult AgentBound::Handle_GetMyJournalDetails(PyCallArgs &call) {
535  //parallelCalls.append((sm.GetService('agents').GetAgentMoniker(agentID).GetMyJournalDetails, ()))
536  //missionState, importantMission, missionType, missionName, agentID, expirationTime, bookmarks, remoteOfferable, remoteCompletable = each
537  // this is to update ONLY info with this agent....
538  _log(AGENT__DUMP, "AgentBound::Handle_GetMyJournalDetails() - size= %u", call.tuple->size() );
539  call.Dump(AGENT__DUMP);
540 
541  PyTuple *tuple = new PyTuple(2);
542  //missions:
543  PyList* missions = new PyList();
544  MissionOffer offer = MissionOffer();
545  if (m_agent->HasMission(call.client->GetCharacterID(), offer)) {
546  if (offer.stateID < Mission::State::Completed) {
547  PyTuple* mData = new PyTuple(9);
548  mData->SetItem(0, new PyInt(offer.stateID)); //missionState .. these may be wrong also.
549  mData->SetItem(1, new PyInt(offer.important?1:0)); //importantMission -- integer boolean
550  mData->SetItem(2, new PyString(sMissionDataMgr.GetTypeLabel(offer.typeID))); //missionTypeLabel
551  mData->SetItem(3, new PyString(offer.name)); //missionName
552  mData->SetItem(4, new PyInt(offer.agentID)); //agentID
553  mData->SetItem(5, new PyLong(offer.expiryTime)); //expirationTime
554  mData->SetItem(6, offer.bookmarks->Clone()); //bookmarks -- if populated, this is PyList of PyDicts as defined below...
555  mData->SetItem(7, new PyBool(offer.remoteOfferable)); //remoteOfferable
556  mData->SetItem(8, new PyBool(offer.remoteCompletable)); //remoteCompletable
557  missions->AddItem(mData);
558  }
559  }
560  tuple->SetItem(0, missions);
561 
562  //research:
563  PyList* research = new PyList();
564  tuple->SetItem(1, research);
565 
566  if (is_log_enabled(AGENT__RSP_DUMP))
567  tuple->Dump(AGENT__RSP_DUMP, " ");
568  return tuple;
569 }
570 
571 PyResult AgentBound::Handle_GetMissionJournalInfo(PyCallArgs &call) {
572  //called on rclick in journal to "read details"
573  //ret = self.GetAgentMoniker(agentID).GetMissionJournalInfo(charID, contentID)
574  _log(AGENT__DUMP, "AgentBound::Handle_GetMissionJournalInfo() - size= %u", call.tuple->size() );
575  call.Dump(AGENT__DUMP);
576 
577  MissionOffer offer = MissionOffer();
578  if (!m_agent->HasMission(call.client->GetCharacterID(), offer))
579  return PyStatic.NewNone();
580 
581  PyDict* journalInfo = new PyDict();
582  journalInfo->SetItemString("contentID", new PyInt(offer.characterID));
583  journalInfo->SetItemString("missionNameID", new PyInt(offer.missionID));
584  journalInfo->SetItemString("briefingTextID", new PyInt(offer.briefingID));
585  journalInfo->SetItemString("missionState", new PyInt(offer.stateID));
586  journalInfo->SetItemString("expirationTime", new PyLong(offer.expiryTime) );
587  journalInfo->SetItemString("objectives", GetMissionObjectiveInfo(call.client, offer));
588  switch(offer.typeID) {
590  journalInfo->SetItemString("missionImage", sMissionDataMgr.GetCourierRes()); break;
592  journalInfo->SetItemString("missionImage", sMissionDataMgr.GetMiningRes()); break;
594  journalInfo->SetItemString("missionImage", sMissionDataMgr.GetKillRes()); break;
595  }
596 
597  if (is_log_enabled(AGENT__RSP_DUMP)) {
598  _log(AGENT__RSP_DUMP, "AgentBound::Handle_GetMissionJournalInfo() RSP:" );
599  journalInfo->Dump(AGENT__RSP_DUMP, " ");
600  }
601 
602  return journalInfo;
603 }
604 
606 {
607  PyDict* objectiveData = new PyDict();
608  objectiveData->SetItemString("missionTitleID", new PyInt(offer.missionID));
609  objectiveData->SetItemString("contentID", new PyInt(offer.characterID));
610  objectiveData->SetItemString("importantStandings", new PyInt(offer.important)); // boolean integer
611  // will need to test for this to set correctly.....
612  if (pClient->IsMissionComplete(offer)) { // Mission::Status:: data here 0=no, 1=yes, 2=cheat
613  objectiveData->SetItemString("completionStatus", new PyInt(Mission::Status::Complete));
614  } else {
615  objectiveData->SetItemString("completionStatus", new PyInt(Mission::Status::Incomplete));
616  }
617  objectiveData->SetItemString("missionState", new PyInt(offer.stateID /*Mission::State::Offered*/)); // Mission::State:: data here for agentGift populating. Accepted/failed to display gift items as accepted
618  objectiveData->SetItemString("loyaltyPoints", new PyInt(0));
619  objectiveData->SetItemString("researchPoints", new PyInt(0));
620 
621  /* this puts title/msg at bottom of right pane
622  if (offer.stateID == Mission::State::Accepted)
623  if (offer.typeID == Mission::Type::Courier) {
624  PyTuple* missionExtra = new PyTuple(2); // this is tuple(2) headerID, bodyID -- std locale msgIDs
625  missionExtra->SetItem(0, new PyString("Reminder....")); // this should be separate title from mission name
626  missionExtra->SetItem(1, new PyString("Remember to get the %s from your hangar before you leave.", call.client->GetCourierItemRef(m_agent->GetID())->name())); // this is additional info about mission, etc.
627  objectiveData->SetItemString("missionExtra", missionExtra);
628  } */
629 
630  PyList* locList = new PyList(); // tuple of list of locationIDs (pickup and dropoff)
631  locList->AddItem(new PyInt(offer.originSystemID));
632  locList->AddItem(new PyInt(offer.destinationSystemID));
633  objectiveData->SetItemString("locations", locList);
634 
635  PyList* giftList = new PyList(); // this is list of tuple(3) typeID, quantity, extra
636  /*
637  PyDict* extra = new PyDict(); // 'extra' is either specificItemID or blueprint data.
638  extra->SetItemString("specificItemID", PyStatic.NewNone());
639  extra->SetItemString("blueprintInfo", PyStatic.NewNone());
640  PyTuple* agentGift = new PyTuple(3);
641  agentGift->SetItem(0, PyStatic.NewNone());
642  agentGift->SetItem(1, PyStatic.NewNone());
643  agentGift->SetItem(2, extra);
644  giftList->AddItem(agentGift);
645  */
646  objectiveData->SetItemString("agentGift", giftList);
647 
648  PyList* normList = new PyList(); // this is list of tuple(3) typeID, quantity, extra
649  if (offer.rewardISK) {
650  PyDict* extra = new PyDict(); // 'extra' is either specificItemID or blueprint data.
651  //extra->SetItemString("specificItemID", PyStatic.NewNone());
652  //extra->SetItemString("blueprintInfo", PyStatic.NewNone());
653  PyTuple* normalRewards = new PyTuple(3);
654  normalRewards->SetItem(0, new PyInt(itemTypeCredits));
655  normalRewards->SetItem(1, new PyInt(offer.rewardISK));
656  normalRewards->SetItem(2, extra);
657  normList->AddItem(normalRewards);
658  }
659  if (offer.rewardItemID) {
660  PyDict* extra = new PyDict(); // 'extra' is either specificItemID or blueprint data.
661  //extra->SetItemString("specificItemID", PyStatic.NewNone());
662  //extra->SetItemString("blueprintInfo", PyStatic.NewNone());
663  PyTuple* normalRewards = new PyTuple(3);
664  normalRewards->SetItem(0, new PyInt(offer.rewardItemID));
665  normalRewards->SetItem(1, new PyInt(offer.rewardItemQty));
666  normalRewards->SetItem(2, extra);
667  normList->AddItem(normalRewards);
668  }
669  objectiveData->SetItemString("normalRewards", normList);
670 
671  PyList* collateralList = new PyList(); // this is list of tuple(3) typeID, quantity, extra
672  /*
673  PyDict* extra = new PyDict(); // 'extra' is either specificItemID or blueprint data.
674  extra->SetItemString("specificItemID", PyStatic.NewNone());
675  extra->SetItemString("blueprintInfo", PyStatic.NewNone());
676  PyTuple* collateral = new PyTuple(3);
677  collateral->SetItem(0, PyStatic.NewNone());
678  collateral->SetItem(1, PyStatic.NewNone());
679  collateral->SetItem(2, extra);
680  */
681  objectiveData->SetItemString("collateral", collateralList);
682 
683  PyList* bonusList = new PyList(); // this is list of tuple(4) timeRemaining, typeID, quantity, extra
684  if (offer.bonusTime > 0) {
685  PyDict* extra = new PyDict(); // 'extra' is either specificItemID or blueprint data.
686  //extra->SetItemString("specificItemID", PyStatic.NewNone());
687  //extra->SetItemString("blueprintInfo", PyStatic.NewNone());
688  PyTuple* bonusRewards = new PyTuple(4);
689  if (offer.dateAccepted > 0) {
690  bonusRewards->SetItem(0, new PyLong(offer.bonusTime - (offer.dateAccepted - offer.dateIssued) * EvE::Time::Minute)); // bonus time - elapsed time * minutes
691  } else {
692  bonusRewards->SetItem(0, new PyLong(offer.bonusTime * EvE::Time::Minute)); // bonus time * minutes
693  }
694  bonusRewards->SetItem(1, new PyInt(itemTypeCredits)); // bonus is *usually* isk. for now, we'll keep it as isk (easier)
695  bonusRewards->SetItem(2, new PyInt(offer.rewardISK *2));
696  bonusRewards->SetItem(3, extra);
697  bonusList->AddItem(bonusRewards);
698  }
699  // bonusList can be multiple items, usualy only item or isk for time bonus
700  if (false/*bonus2*/) {
701  PyDict* extra = new PyDict(); // 'extra' is either specificItemID or blueprint data.
702  //extra->SetItemString("specificItemID", PyStatic.NewNone());
703  //extra->SetItemString("blueprintInfo", PyStatic.NewNone());
704  PyTuple* bonusRewards2 = new PyTuple(4);
705  bonusRewards2->SetItem(0, new PyLong(12000000000)); //20m
706  bonusRewards2->SetItem(1, new PyInt(itemTypeTrit));
707  bonusRewards2->SetItem(2, new PyInt(offer.rewardISK));
708  bonusRewards2->SetItem(3, extra);
709  bonusList->AddItem(bonusRewards2);
710  }
711  objectiveData->SetItemString("bonusRewards", bonusList);
712  /* for collateral and rewards, as follows...
713  typeID, quantity, extra in objectiveData['normalRewards']
714  typeID, quantity, extra in objectiveData['collateral']
715  typeID, quantity, extra in objectiveData['agentGift']
716  or
717  timeRemaining, typeID, quantity, extra in objectiveData['bonusRewards']
718 
719  specificItemID = extra.get('specificItemID', 0)
720  blueprintInfo = extra.get('blueprintInfo', None)
721  */
722 
723  objectiveData->SetItemString("objectives", GetMissionObjectives(pClient, offer));
724  PyList* dunList = new PyList(); // this is a list of dunData dicts
725  /*
726  PyDict* dunData = new PyDict();
727  dunData->SetItemString("dungeonID", new PyInt(1000));
728  dunData->SetItemString("completionStatus", new PyInt(Dungeon::Status::Started));
729  dunData->SetItemString("optional", new PyInt());
730  dunData->SetItemString("briefingMessage", new PyInt());
731  dunData->SetItemString("objectiveCompleted", new PyBool(false));
732  dunData->SetItemString("ownerID", new PyInt(m_agent->GetID()));
733  dunData->SetItemString("shipRestrictions", new PyInt(0)); // 0=normal 1=special with link to *something else*
734  dunData->SetItemString("location", m_agent->GetLocationWrap());
735  */
736  objectiveData->SetItemString("dungeons", dunList);
737  /* dunData data....
738  * dungeonID
739  * completionStatus
740  * optional
741  * briefingMessage
742  * objectiveCompleted
743  * ownerID
744  * location
745  location['locationID']
746  location['locationType']
747  location['solarsystemID']
748  location['coords']
749  location['agentID']
750  ?location['referringAgentID']
751  ?location['shipTypeID']
752  * shipRestrictions 0=normal 1=special with link to *something else*
753  */
754 
755  if (is_log_enabled(AGENT__RSP_DUMP)) {
756  _log(AGENT__RSP_DUMP, "AgentBound::Handle_GetMissionObjectiveInfo() RSP:" );
757  objectiveData->Dump(AGENT__RSP_DUMP, " ");
758  }
759 
760  return objectiveData;
761 }
762 
764 {
765  // set mission objectiveData based on mission type.
766  PyDict* dropoffLocation = new PyDict();
767  if (sDataMgr.IsStation(offer.destinationID)) {
768  dropoffLocation->SetItemString("typeID", new PyInt(offer.destinationTypeID) );
769  dropoffLocation->SetItemString("locationID", new PyInt(offer.destinationID) );
770  dropoffLocation->SetItemString("solarsystemID", new PyInt(offer.destinationSystemID) );
771  } else {
772  dropoffLocation->SetItemString("shipTypeID", new PyInt(offer.destinationTypeID) );
773  dropoffLocation->SetItemString("agentID", new PyInt(offer.destinationOwnerID) );
774  // get agent in space location and set here
775  PyTuple* coords = new PyTuple(3);
776  coords->SetItem(0, new PyFloat(0)); //x
777  coords->SetItem(1, new PyFloat(0)); //y
778  coords->SetItem(2, new PyFloat(0)); //z
779  dropoffLocation->SetItemString("coords", coords);
780  dropoffLocation->SetItemString("referringAgentID", new PyInt(offer.agentID) );
781  }
782 
783  PyTuple* objectives = new PyTuple(1);
784  switch (offer.typeID) {
786  case Mission::Type::Courier: {
787  PyDict* pickupLocation = new PyDict();
788  pickupLocation->SetItemString("typeID", new PyInt(m_agent->GetLocTypeID()) );
789  pickupLocation->SetItemString("locationID", new PyInt(offer.originID) );
790  pickupLocation->SetItemString("solarsystemID", new PyInt(offer.originSystemID) );
791  PyDict* cargo = new PyDict();
792  cargo->SetItemString("hasCargo", new PyBool(pClient->ContainsTypeQty(offer.courierTypeID, offer.courierAmount)));
793  cargo->SetItemString("typeID", new PyInt(offer.courierTypeID));
794  cargo->SetItemString("quantity", new PyInt(offer.courierAmount));
795  cargo->SetItemString("volume", new PyFloat(offer.courierItemVolume * offer.courierAmount)); // calculated shipment volume. *this is direct to window*
796  PyTuple* objData = new PyTuple(5);
797  objData->SetItem(0, new PyInt(offer.originOwnerID));
798  objData->SetItem(1, pickupLocation/*m_agent->GetLocationWrap()*/);
799  objData->SetItem(2, new PyInt(offer.destinationOwnerID));
800  objData->SetItem(3, dropoffLocation/*m_agent->GetLocationWrap()*/);
801  objData->SetItem(4, cargo);
802  PyTuple* objType = new PyTuple(2); // this is list of tuple(2) objType, objData
803  objType->SetItem(0, new PyString("transport"));
804  objType->SetItem(1, objData);
805  objectives->SetItem(0, objType);
806  } break;
808  case Mission::Type::Mining: {
809  PyDict* cargo = new PyDict();
810  cargo->SetItemString("hasCargo", new PyBool(pClient->ContainsTypeQty(offer.courierTypeID, offer.courierAmount)));
811  cargo->SetItemString("typeID", new PyInt(offer.courierTypeID));
812  cargo->SetItemString("quantity", new PyInt(offer.courierAmount));
813  cargo->SetItemString("volume", new PyFloat(offer.courierItemVolume * offer.courierAmount)); // calculated shipment volume. *this is direct to window*
814  PyTuple* objData = new PyTuple(3);
815  objData->SetItem(0, new PyInt(offer.destinationOwnerID));
816  objData->SetItem(1, dropoffLocation/*m_agent->GetLocationWrap()*/);
817  objData->SetItem(2, cargo);
818  PyTuple* objType = new PyTuple(2); // this is list of tuple(2) objType, objData
819  objType->SetItem(0, new PyString("fetch"));
820  objType->SetItem(1, objData);
821  objectives->SetItem(0, objType);
822  } break;
824  case Mission::Type::Arc:
827  case Mission::Type::Data:
831  objectives->SetItem(0, PyStatic.NewNone());
832  } break;
833  }
834 
835  return objectives;
836 
837  /* objectives data...
838  if objType == 'agent': -- report to agent
839  agentID, agentLocation = objData
840  agentLocation['locationID']
841  agentLocation['locationType']
842  agentLocation['solarsystemID']
843  if not in station
844  agentLocation['coords']
845  agentLocation['agentID']
846  ?agentLocation['referringAgentID']
847  ?agentLocation['shipTypeID']
848 
849  elif objType == 'transport': -- courier and trade missions
850  pickupOwnerID, pickupLocation, dropoffOwnerID, dropoffLocation, cargo = objData
851  pickupLocation['locationID']
852  pickupLocation['locationType']
853  pickupLocation['solarsystemID']
854  dropoffLocation['locationID']
855  dropoffLocation['locationType']
856  dropoffLocation['solarsystemID']
857  if not in station
858  dropoffLocation['coords']
859  dropoffLocation['agentID']
860  ?dropoffLocation['referringAgentID']
861  ?dropoffLocation['shipTypeID']
862  cargo['hasCargo']
863  cargo['typeID']
864  cargo['volume']
865  cargo['quantity']
866 
867  elif objType == 'fetch': -- encounter and mining missions
868  dropoffOwnerID, dropoffLocation, cargo = objData
869  dropoffLocation['locationID']
870  dropoffLocation['locationType']
871  dropoffLocation['solarsystemID']
872  if not in station
873  dropoffLocation['coords']
874  dropoffLocation['agentID']
875  ?dropoffLocation['referringAgentID']
876  ?dropoffLocation['shipTypeID']
877  cargo['hasCargo']
878  cargo['typeID']
879  cargo['volume']
880  cargo['quantity']
881  */
882 }
883 
884 
889 PyResult AgentBound::Handle_GetDungeonShipRestrictions(PyCallArgs &call) {
890  //restrictions = self.GetAgentMoniker(agentID).GetDungeonShipRestrictions(dungeonID)
891  _log(AGENT__DUMP, "AgentBound::Handle_GetDungeonShipRestrictions() - size= %u", call.tuple->size() );
892  call.Dump(AGENT__DUMP);
893 
894  return nullptr;
895 }
896 
897 PyResult AgentBound::Handle_RemoveOfferFromJournal(PyCallArgs &call) {
898  //called on rclick in journal to "remove offer"
899  //self.GetAgentMoniker(agentID).RemoveOfferFromJournal()
900  _log(AGENT__DUMP, "AgentBound::Handle_RemoveOfferFromJournal() - size= %u", call.tuple->size() );
901  call.Dump(AGENT__DUMP);
902 
903  return nullptr;
904 }
905 
906 PyResult AgentBound::Handle_GetOfferJournalInfo(PyCallArgs &call) {
907  //html = self.GetAgentMoniker(agentID).GetOfferJournalInfo()
908  _log(AGENT__DUMP, "AgentBound::Handle_GetOfferJournalInfo() - size= %u", call.tuple->size() );
909  call.Dump(AGENT__DUMP);
910 
911  return nullptr;
912 }
913 
914 PyResult AgentBound::Handle_GetEntryPoint(PyCallArgs &call) {
915  //entryPoint = sm.StartService('agents').GetAgentMoniker(bookmark.agentID).GetEntryPoint()
916  _log(AGENT__DUMP, "AgentBound::Handle_GetEntryPoint() - size= %u", call.tuple->size() );
917  call.Dump(AGENT__DUMP);
918 
919  return nullptr;
920 }
921 
922 PyResult AgentBound::Handle_GotoLocation(PyCallArgs &call) {
923  //sm.StartService('agents').GetAgentMoniker(bookmark.agentID).GotoLocation(bookmark.locationType, bookmark.locationNumber, referringAgentID)
924  _log(AGENT__DUMP, "AgentBound::Handle_GotoLocation() - size= %u", call.tuple->size() );
925  call.Dump(AGENT__DUMP);
926 
927  return nullptr;
928 }
929 
930 PyResult AgentBound::Handle_WarpToLocation(PyCallArgs &call) {
931  //sm.StartService('agents').GetAgentMoniker(bookmark.agentID).WarpToLocation(bookmark.locationType, bookmark.locationNumber, warpRange, fleet, referringAgentID)
932  _log(AGENT__DUMP, "AgentBound::Handle_WarpToLocation() - size= %u", call.tuple->size() );
933  call.Dump(AGENT__DUMP);
934 
935  return nullptr;
936 }
static float GetStanding(uint32 fromID, uint32 toID)
Definition: StandingDB.cpp:142
uint32 GetFactionID()
Definition: Agent.h:42
Dispatcher *const m_dispatch
unsigned __int8 uint8
Definition: eve-compat.h:46
double dateAccepted
Definition: EVE_Missions.h:60
uint16 missionID
Definition: EVE_Missions.h:34
void SendErrorMsg(const char *fmt,...)
Definition: Client.cpp:2719
#define _log(type, fmt,...)
Definition: logsys.h:124
Python string.
Definition: PyRep.h:430
uint32 agentID
Definition: EVE_Missions.h:42
Python's dictionary.
Definition: PyRep.h:719
uint32 GetStandingsRsp(uint32 charID)
Definition: Agent.cpp:547
size_t size() const
Definition: PyRep.h:591
double dateIssued
Definition: EVE_Missions.h:59
PyObject * GetInfoServiceDetails()
Definition: Agent.cpp:290
float EffectiveQuality(int8 AgentQuality, uint8 NegotiationSkillLevel, float AgentPersonalStanding)
Definition: EvEMath.cpp:150
bool empty() const
Definition: PyRep.h:592
uint32 GetDeclineRsp(uint32 charID)
Definition: Agent.cpp:490
uint16 destinationTypeID
Definition: EVE_Missions.h:40
uint32 bonusISK
Definition: EVE_Missions.h:47
PyRep * Clone() const
Clones object.
Definition: PyRep.cpp:617
bool IsMissionComplete(MissionOffer &data)
Definition: Client.cpp:1764
Python floating point number.
Definition: PyRep.h:292
bool IsLocator()
Definition: Agent.h:31
int32 GetCharacterID() const
Definition: Client.h:113
float courierItemVolume
Definition: EVE_Missions.h:57
PyDict * GetMissionObjectiveInfo(Client *pClient, MissionOffer &offer)
Definition: AgentBound.cpp:605
uint32 characterID
Definition: EVE_Missions.h:45
static uint32 IntegerValueU32(PyRep *pRep)
Definition: PyRep.cpp:134
std::string name
Definition: EVE_Missions.h:62
uint32 GetStationID()
Definition: Agent.h:40
CharacterRef GetChar() const
Definition: Client.h:164
Python tuple.
Definition: PyRep.h:567
void MakeOffer(uint32 charID, MissionOffer &offer)
Definition: Agent.cpp:63
void Dump(FILE *into, const char *pfx) const
Dumps object to file.
Definition: PyRep.cpp:84
bool ContainsTypeQty(uint16 typeID, uint32 qty) const
Definition: Client.cpp:1744
bool HasMission(uint32 charID)
Definition: Agent.cpp:149
Agent * m_agent
Definition: AgentBound.h:52
void AddItem(PyRep *i)
Definition: PyRep.h:701
void RemoveMissionItem(uint16 typeID, uint32 qty)
Definition: Client.cpp:1711
uint16 rewardItemQty
Definition: EVE_Missions.h:37
bool IsResearch()
Definition: Agent.h:32
* args
Python boolean.
Definition: PyRep.h:323
#define is_log_enabled(type)
Definition: logsys.h:78
uint32 originSystemID
Definition: EVE_Missions.h:50
uint32 destinationSystemID
Definition: EVE_Missions.h:53
uint32 briefingID
Definition: EVE_Missions.h:43
uint32 dungeonLocationID
Definition: EVE_Missions.h:54
uint16 courierTypeID
Definition: EVE_Missions.h:38
Definition: Agent.h:21
void SetItem(size_t index, PyRep *object)
Stores Python object.
Definition: PyRep.h:610
uint16 bonusTime
Definition: EVE_Missions.h:33
static void TranserFunds(uint32 fromID, uint32 toID, double amount, std::string reason="", uint8 entryTypeID=Journal::EntryType::Undefined, uint32 referenceID=0, uint16 fromKey=Account::KeyType::Cash, uint16 toKey=Account::KeyType::Cash, Client *pClient=nullptr)
Python integer.
Definition: PyRep.h:231
uint32 GetID()
Definition: Agent.h:37
void UpdateStandings(Client *pClient, uint8 eventID, bool important=false)
Definition: Agent.cpp:562
#define PyStatic
Definition: PyRep.h:1209
X * get() const
Definition: RefPtr.h:213
double expiryTime
Definition: EVE_Missions.h:58
double dateCompleted
Definition: EVE_Missions.h:61
const char * GetName() const
Definition: Client.h:94
#define sMissionDataMgr
uint32 rewardISK
Definition: EVE_Missions.h:46
Client *const client
Definition: PyCallable.h:49
#define PyCallable_REG_CALL(c, m)
Definition: PyServiceCD.h:78
Definition: Client.h:66
bool CanUseAgent(Client *pClient)
Definition: Agent.cpp:743
uint16 rewardItemID
Definition: EVE_Missions.h:36
uint32 GetCompleteRsp(uint32 charID)
Definition: Agent.cpp:512
bool remoteOfferable
Definition: EVE_Missions.h:28
uint32 GetLoyaltyPoints(uint32 corpID)
Definition: Client.cpp:1704
double GetFileTimeNow()
Definition: utils_time.cpp:84
uint32 destinationOwnerID
Definition: EVE_Missions.h:52
void GetOffer(uint32 charID, MissionOffer &offer)
Definition: Agent.cpp:167
PyTuple * GetMissionObjectives(Client *pClient, MissionOffer &offer)
Definition: AgentBound.cpp:763
PyDict * GetLocationWrap()
Definition: Agent.cpp:231
float GetStandingBonus(float fromStanding, uint32 fromFactionID, uint8 ConnectionsSkillLevel, uint8 DiplomacySkillLevel, uint8 CriminalConnectionsSkillLevel)
Definition: EvEMath.cpp:180
void DeleteOffer(uint32 charID)
Definition: Agent.cpp:217
void Dump(LogType type) const
Definition: PyCallable.cpp:81
int8 GetSkillLevel(uint16 skillTypeID, bool zeroForNotInjected=true) const
Definition: Character.cpp:575
float EffectiveStanding(float YourStanding, double standingBonus)
Definition: EvEMath.cpp:155
int8 GetQuality()
Definition: Agent.h:35
uint32 dungeonSolarSystemID
Definition: EVE_Missions.h:55
#define sItemFactory
Definition: ItemFactory.h:165
uint32 GetAcceptRsp(uint32 charID)
Definition: Agent.cpp:468
uint8 GetLevel()
Definition: Agent.h:34
void SendMissionUpdate(Client *pClient, std::string action)
Definition: Agent.cpp:696
uint16 courierAmount
Definition: EVE_Missions.h:39
uint32 GetLocTypeID()
Definition: Agent.h:41
bool remoteCompletable
Definition: EVE_Missions.h:29
uint32 destinationID
Definition: EVE_Missions.h:51
void UpdateOffer(uint32 charID, MissionOffer &offer)
Definition: Agent.cpp:195
uint32 GetCorpID()
Definition: Agent.h:38
uint32 originID
Definition: EVE_Missions.h:48
Python list.
Definition: PyRep.h:639
uint32 itemID() const
Definition: InventoryItem.h:98
void SetItemString(const char *key, PyRep *value)
SetItemString adds or sets a database entry.
Definition: PyRep.h:812
PyList * bookmarks
Definition: EVE_Missions.h:63
uint32 originOwnerID
Definition: EVE_Missions.h:49
const char * GetName() const
Definition: PyBoundObject.h:44
Python long integer.
Definition: PyRep.h:261
PyTuple * tuple
Definition: PyCallable.h:50
#define sDataMgr