Skip to content

Commit 442cc2c

Browse files
committed
Event Tab
- Added first version of the event tab - Few minor var name changes
1 parent 0455d61 commit 442cc2c

File tree

4 files changed

+308
-3
lines changed

4 files changed

+308
-3
lines changed

HObj.cs

+79
Original file line numberDiff line numberDiff line change
@@ -478,4 +478,83 @@ public override void Update(HMail mail)
478478
}
479479
}
480480
}
481+
482+
class HEvent : HObj
483+
{
484+
protected int _messageId = 0;
485+
public int MessageID
486+
{
487+
get { return _messageId; }
488+
}
489+
490+
protected string _subject = "-";
491+
public string Subject
492+
{
493+
get { return _subject; }
494+
}
495+
496+
public HEvent(HMail mail)
497+
{
498+
_id = HHelper.ToID(mail.SenderID);
499+
Update(mail);
500+
}
501+
502+
public override void Update(HMail mail)
503+
{
504+
//if (HMail.IsOfficerTenFour(mail.MailBytes) && DateTime.Compare(_lastUpdated, mail.DateTime) < 0)
505+
//{
506+
base.Update(mail);
507+
508+
// String working vars.
509+
int subStart, subEnd;
510+
string[] tempArray;
511+
512+
_messageId = mail.MessageID;
513+
_subject = mail.Subject;
514+
//if (mail.MessageType == 0x05) // MSG_CityIntelligenceReport
515+
//{
516+
// ?
517+
//}
518+
//else if (mail.MessageType == 0x12) // MSG_ShipLogFinal
519+
//{
520+
// ?
521+
//}
522+
//else if (mail.MessageType == 0x13) // MSG_Government
523+
//{
524+
// ?
525+
//}
526+
//else if (mail.MessageType == 0x16) // MSG_OfficerDeath
527+
//{
528+
// ?
529+
//}
530+
//else if (mail.MessageType == 0x17) // MSG_CityFinalDecayReport
531+
//{
532+
// ?
533+
//}
534+
//else if (mail.MessageType == 0x18) // MSG_DiplomaticMessage
535+
//{
536+
// ?
537+
//}
538+
539+
// AttentionCodes
540+
if (false) // Nothing yet!
541+
_attentionCode = (byte)(_attentionCode | 0x01); // 0b00000001
542+
if (false) // Nothing yet!
543+
_attentionCode = (byte)(_attentionCode | 0x03); // 0b00000010
544+
if (false) // Nothing yet!
545+
_attentionCode = (byte)(_attentionCode | 0x04); // 0b00000100
546+
if (false) // Nothing yet!
547+
_attentionCode = (byte)(_attentionCode | 0x08); // 0b00001000
548+
if (false) // Nothing yet!
549+
_attentionCode = (byte)(_attentionCode | 0x10); // 0b00010000
550+
if (false) // Nothing yet!
551+
_attentionCode = (byte)(_attentionCode | 0x20); // 0b00100000
552+
if (false) // Nothing yet!
553+
_attentionCode = (byte)(_attentionCode | 0x40); // 0b01000000
554+
if (false) // Nothing yet!
555+
_attentionCode = (byte)(_attentionCode | 0x80); // 0b10000000
556+
557+
//}
558+
}
559+
}
481560
}

Main.Designer.cs

+159-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)