-
Notifications
You must be signed in to change notification settings - Fork 85
/
PlayerObject.idl
2112 lines (1593 loc) · 47.9 KB
/
PlayerObject.idl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/*
Copyright <SWGEmu>
See file COPYING for copying conditions.*/
package server.zone.objects.player;
import engine.log.Logger;
import engine.service.proto.BaseMessage;
import engine.service.proto.BasePacket;
import engine.util.u3d.Vector3;
import server.zone.objects.building.BuildingObject;
import server.zone.objects.creature.CreatureObject;
include server.zone.objects.creature.ai.AiAgent;
import server.zone.objects.intangible.IntangibleObject;
import server.zone.objects.player.events.PlayerDisconnectEvent;
import server.zone.objects.player.events.PlayerRecoveryEvent;
import server.zone.objects.player.events.ForceRegenerationEvent;
import server.zone.objects.player.events.PvpTefRemovalTask;
import server.zone.objects.scene.SceneObject;
import server.zone.objects.structure.StructureObject;
import server.zone.objects.waypoint.WaypointObject;
import server.zone.objects.ship.ShipObject;
include templates.SharedObjectTemplate;
import server.zone.ZoneClientSession;
import server.login.account.Account;
include system.lang.ref.Reference;
import system.util.SortedVector;
import system.util.Vector;
import system.util.VectorMap;
import system.util.SynchronizedSortedVector;
include system.lang.Time;
include server.login.account.GalaxyAccountInfo;
include server.zone.objects.draftschematic.DraftSchematic;
include server.zone.objects.player.badges.Badges;
include server.zone.objects.player.sui.SuiBox;
include server.zone.objects.player.ValidatedPosition;
include server.zone.objects.player.variables.Ability;
include server.zone.objects.player.variables.AbilityList;
include server.zone.objects.player.variables.FactionStandingList;
include server.zone.objects.player.variables.FriendList;
include server.zone.objects.player.variables.FrsData;
include server.zone.objects.player.variables.IgnoreList;
include server.zone.objects.player.variables.SchematicList;
include server.zone.objects.player.variables.WaypointList;
include server.zone.objects.player.variables.PlayerQuestData;
include server.zone.objects.player.variables.SpaceLaunchPoint;
include server.zone.objects.scene.variables.DeltaVector;
include server.zone.objects.scene.variables.DeltaVectorMap;
include server.zone.objects.scene.variables.DeltaBitArray;
include server.zone.objects.transaction.TransactionLog;
include server.zone.objects.player.PlayerBitmasks;
@json
class PlayerObject extends IntangibleObject {
protected int playerLogLevel;
@dereferenced
protected PlayerBitmasks playerBitmask;
protected string title;
protected string savedTerrainName;
protected unsigned long savedParentID;
@dereferenced
protected Badges badges;
protected int birthDate;
protected int forcePower;
protected int forcePowerMax;
protected int foodFilling;
protected int foodFillingMax;
protected int drinkFilling;
protected int drinkFillingMax;
protected int reactionFines;
protected transient GalaxyAccountInfo galaxyAccountInfo;
protected transient Account account;
protected transient int countMaxCov;
@dereferenced
protected Time reactionFineTimestamp; // Timestamp of when player was given a fine
@dereferenced
protected Time reactionFineMailTimestamp; // Timestamp of last mail sent regarding fine being due
protected string starterProfession;
protected string bankLocation;
protected boolean teleporting;
protected boolean onLoadScreen;
protected boolean forcedTransform;
protected boolean muted;
protected string mutedReason;
protected int tosVersionAccepted;
@dereferenced
protected SortedVector<unsigned long> ownedStructures;
@dereferenced
protected SortedVector<unsigned long> ownedVendors;
protected byte maximumLots;
protected int jediState;
protected unsigned int adminLevel;
protected int priviledgeFlag;
protected byte languageID;
@dereferenced
protected VectorMap<string, int> xpTypeCapList;
@dereferenced
protected VectorMap<unsigned int, string> commandMessageStrings;
@dereferenced
protected DeltaVectorMap<string, int> experienceList;
@dereferenced
protected FrsData frsData;
@dereferenced
protected WaypointList waypointList;
@dereferenced
protected AbilityList abilityList;
@dereferenced
protected FriendList friendList;
@dereferenced
protected IgnoreList ignoreList;
@dereferenced
protected FactionStandingList factionStandingList;
@dereferenced
protected SchematicList schematicList;
@dereferenced
protected Vector<unsigned int> incapacitationTimes;
protected unsigned int suiBoxNextID;
@dereferenced
protected VectorMap<unsigned int, SuiBox> suiBoxes;
@dereferenced
protected SortedVector<unsigned int> chatRooms;
@dereferenced
protected SortedVector<unsigned int> ownedChatRooms;
@dereferenced
protected transient SynchronizedSortedVector<CreatureObject> duelList;
@dereferenced
protected Vector<unsigned long> victimList;
protected unsigned long declaredResidence;
protected unsigned long cloningFacility;
protected boolean isPlayerCloning;
@dereferenced
protected SortedVector<unsigned long> persistentMessages;
protected unicode biography; //char biography
@dereferenced
protected SortedVector<string> consentList;
//npc conversation
protected string lastNpcConvoMessage;
protected string lastNpcConvo;
@dereferenced
protected Vector<string> lastNpcConvoOptions; //Deprecate. Conversation could also be a session.
protected unsigned long conversatingObject; //If conversation is a session, then this would be stored on the session.
// Jedi Trainers.
@local
@dereferenced
protected Vector3 trainerCoordinates;
@local
@dereferenced
protected Vector3 lastLogoutWorldPosition;
protected string trainerZoneName;
@dereferenced
protected transient Reference<PlayerDisconnectEvent> disconnectEvent;
@dereferenced
protected transient Reference<PlayerRecoveryEvent> recoveryEvent;
@dereferenced
protected transient Reference<ForceRegenerationEvent> forceRegenerationEvent;
@dereferenced
protected Time logoutTimeStamp;
protected int onlineStatus;
protected int skillPoints; //TODO: This could be encapsulated in the skill list.
protected int pvpRating;
@dereferenced
protected Time lastPvpRatingUpdate; // Timestamp of when last time player received a pvp rating change
@dereferenced
protected Vector<byte> hologrindProfessions;
protected unsigned int clientLastMovementStamp;
@dereferenced
protected Time serverLastMovementStamp;
@dereferenced
protected ValidatedPosition lastValidatedPosition;
protected unsigned int accountID;
@dereferenced
protected VectorMap<string, string> screenPlayData;
@dereferenced
protected SortedVector<string> permissionGroups;
protected unsigned long performanceBuffTarget;
protected boolean debugOutput;
protected float visibility;
@dereferenced
protected Time lastVisibilityUpdateTimestamp;
@dereferenced
protected Time lastBhPvpCombatActionTimestamp;
@dereferenced
protected Time lastGcwPvpCombatActionTimestamp;
@dereferenced
protected Time lastCrackdownGcwCombatActionTimestamp;
@dereferenced
protected Time lastPvpAreaCombatActionTimestamp;
protected unsigned int crackdownFactionTefCrc;
@dereferenced
protected transient Reference<PvpTefRemovalTask> pvpTefTask;
@dereferenced
protected Time lastDigestion;
@dereferenced
protected SortedVector<AiAgent> activePets;
@dereferenced
protected DeltaBitArray activeQuests;
@dereferenced
protected DeltaBitArray completedQuests;
protected string installedHoloEmote;
protected int holoEmoteUseCount;
protected string spouseName;
@dereferenced
protected VectorMap<unsigned int, string> chosenVeteranRewards; // milestone, templateFile
@dereferenced
protected SortedVector<unsigned long> currentEventPerks;
@weakReference
protected transient SceneObject currentClientPathWaypoint;
@dereferenced
protected SpaceLaunchPoint launchPoint;
/**
* the key is the quest.hashCode()
*/
@dereferenced
@rawTemplate(value = "uint32, PlayerQuestData")
protected DeltaVectorMap playerQuestsData;
protected unsigned long miliSecsPlayed;
protected unsigned long miliSecsSession;
protected unsigned long sessionStatsMiliSecs;
protected transient long sessionStatsLastCredits;
protected transient int sessionStatsLastSkillPoints;
protected transient unsigned long sessionStatsActivityXP;
protected transient unsigned long sessionStatsActivityMovement;
protected transient unsigned long sessionStatsTotalMovement;
protected transient unsigned long sessionStatsTotalCredits;
protected transient string sessionStatsIPAddress;
public static final int ONLINE = 1;
public static final int OFFLINE = 2;
public static final int LINKDEAD = 3;
public static final int LOGGINGOUT = 5;
public static final int PVP_RATING_FLOOR = 500;
public static final unsigned long PVP_RESET_TIME = 259200000; // 3 days
public PlayerObject() {
playerLogLevel = 4; // INFO
commandMessageStrings.setNoDuplicateInsertPlan();
bankLocation = "";
teleporting = false;
onLoadScreen = false;
forcedTransform = false;
muted = false;
mutedReason = "";
debugOutput = false;
suiBoxNextID = 0;
savedParentID = 0;
declaredResidence = 0;
cloningFacility = 0;
isPlayerCloning = false;
skillPoints = 0;
conversatingObject = 0;
birthDate = 0;
forcePower = 0;
forcePowerMax = 0;
jediState = 0;
pvpRating = 1200;
trainerZoneName = "";
duelList.setNoDuplicateInsertPlan();
persistentMessages.setNoDuplicateInsertPlan();
consentList.setNoDuplicateInsertPlan();
activePets.setNoDuplicateInsertPlan();
chosenVeteranRewards.setNoDuplicateInsertPlan();
accountID = 0;
clientLastMovementStamp = 0;
maximumLots = 10;
adminLevel = 0;
priviledgeFlag = 0;
languageID = 0;
onlineStatus = OFFLINE;
performanceBuffTarget = 0;
visibility = 0;
lastVisibilityUpdateTimestamp.updateToCurrentTime();
lastBhPvpCombatActionTimestamp.updateToCurrentTime();
lastGcwPvpCombatActionTimestamp.updateToCurrentTime();
lastCrackdownGcwCombatActionTimestamp.updateToCurrentTime();
lastPvpAreaCombatActionTimestamp.updateToCurrentTime();
crackdownFactionTefCrc = 0;
lastDigestion.updateToCurrentTime();
installedHoloEmote = "";
holoEmoteUseCount = 0;
spouseName = "";
foodFilling = 0;
foodFillingMax = 0;
drinkFilling = 0;
drinkFillingMax = 0;
reactionFines = 0;
lastPvpRatingUpdate.updateToCurrentTime();
tosVersionAccepted = 0;
miliSecsPlayed = 0;
Logger.setLoggingName("PlayerObjectBase");
}
public void finalize() {
}
@dirty
@nativeStub
@local
public native PlayerObject asPlayerObject();
public void setLogLevel(int newLevel) {
playerLogLevel = newLevel;
}
@read
public int getLogLevel() {
return playerLogLevel;
}
@read
public int getCountMaxCov() {
return countMaxCov;
}
public void setCountMaxCov(int newMaxCov) {
countMaxCov = newMaxCov;
}
public void setClientPathWaypoint(SceneObject obj) {
currentClientPathWaypoint = obj;
}
public native void initializeAccount();
/**
* Gets called when this objects is loaded from database
* @pre { this locked }
* @post { this locked }
*/
public native void notifyLoadFromDatabase();
public native void unload();
@dirty
public native int calculateBhReward();
@local
public native void loadTemplateData(SharedObjectTemplate templateData);
public native void initializeTransientMembers();
@dirty
public native void sendBaselinesTo(SceneObject player);
@dirty
@local
public native void sendMessage(BasePacket msg);
public synchronized void addOwnedStructure(StructureObject obj) {
if (!obj)
return;
ownedStructures.put(obj.getObjectID());
}
public synchronized void removeOwnedStructure(StructureObject obj) {
if (!obj)
return;
ownedStructures.drop(obj.getObjectID());
if(obj.getObjectID() == getDeclaredResidence())
setDeclaredResidence(null);
}
@read
public int getAcceptedTOSVersion() {
return tosVersionAccepted;
}
public void setAcceptedTOSVersion(int version) {
tosVersionAccepted = version;
}
@dirty
public native void checkAndShowTOS();
public native void createHelperDroid();
@dirty
public synchronized int getTotalOwnedStructureCount() {
return ownedStructures.size();
}
@dirty
public synchronized boolean isOwnedStructure(StructureObject obj) {
if (!obj)
return false;
return ownedStructures.contains(obj.getObjectID());
}
@dirty
public synchronized unsigned long getOwnedStructure(int i) {
return ownedStructures.get(i);
}
@dirty
public native int getLotsRemaining();
@dirty
public synchronized boolean hasLotsRemaining(int lots) {
return lots <= getLotsRemaining();
}
public native void notifySceneReady();
public native void checkPendingMessages();
/**
* Adds experience of a type to the player's experience pool.
* @pre { this is locked }
* @post { this is locked }
* @param xpType The string value for the type of experience to add.
* @param xp The value of experience to add.
* @param notifyClient Boolean to determing whether the client should receive a delta packet for the experience gain.
* @return returns total experience awarded
*/
@local
public native int addExperience(@dereferenced TransactionLog trx, final string xpType, int xp, boolean notifyClient = true);
/**
* Removes experience of a type from the player's experience pool.
* @pre { this is locked }
* @post { this is locked }
* @param xpType The string value for the type of experience to remove.
* @param notifyClient Boolean to determing whether the client should receive a delta packet for the experience loss.
*/
@local
public native void removeExperience(@dereferenced TransactionLog trx, final string xpType, boolean notifyClient = true);
/**
* Checks if the player has capped the experience type.
* @param xpType The string value for the type of experience to check.
* @return true if experience is capped, false otherwise.
*/
@read
public native boolean hasCappedExperience(final string xpType);
/**
* Adds waypoint object to waypointList
* @pre { this is locked }
* @post { this is locked, waypoint object is in the list }
* @param waypoint waypoint object to add
* @param checkName determines whether to remove existing Waypoint with equal customName
* @param notifyClient determines whether to update the client with the changes
*/
public native void addWaypoint(WaypointObject waypoint, boolean checkName, boolean notifyClient = true);
public native void setWaypoint(WaypointObject waypoint, boolean notifyClient = true);
/**
* Adds a new waypoint with the specified coordinates
* @pre { this is locked }
* @post { this is locked, waypoint object is in the list }
* @param planet planet where waypoint will be created
* @param positionX waypoint position X
* @param positionY waypoint position Y
* @param notifyClient determines whether to update the client with the changes
*/
@local
public native WaypointObject addWaypoint(final string planet, float positionX, float positionY, boolean notifyClient = true);
/**
* Removes a waypoint from this player
* @pre { this is locked }
* @post { this is locked, waypoint list doesnt contain the specified waypoint }
* @param waypointID waypoint object id to remove
* @param notifyClient determines whether to update the client with the changes
* @param destroy determines whether to remove the waypoint from the database
*/
public native void removeWaypoint(unsigned long waypointID, boolean notifyClient = true, boolean destroy = true);
/**
* Updates the client with a waypoint change
* @pre { this is locked }
* @post { this is locked }
* @param waypointID waypoint object id to update
*/
public native void updateWaypoint(unsigned long waypointID);
/**
* Removes a waypoint of a special type from this player
* @pre { this is locked }
* @post { this is locked, waypoint list doesnt contain a waypoint of the special type }
* @param specialTypeID id of special type to remove
* @param notifyClient determines whether to update the client with the changes
*/
public native void removeWaypointBySpecialType(int specialTypeID, boolean notifyClient = true);
/**
* Gets the first waypoint of a special type from this player
* @param specialTypeID id of special type to find
*/
@read
public native WaypointObject getWaypointBySpecialType(int specialTypeID);
@read
public native WaypointObject getSurveyWaypoint();
@read
public boolean hasWaypoint(unsigned long objectID) {
return waypointList.contains(objectID);
}
@read
public WaypointObject getWaypointAt(float x, float y, string planet) {
return waypointList.getWaypointAt(x, y, planet);
}
@read
@local
public void insertWaypointListToMessage(BaseMessage msg) {
waypointList.insertToMessage(msg);
}
@read
public int getWaypointListSize() {
return waypointList.size();
}
@read
public WaypointObject getWaypoint(int index) {
return waypointList.getValueAt(index);
}
/**
* Adds new abilities commands to player
* @pre { this is locked }
* @post { this is locked }
* @param abilities Vector of abilities to add
* @param notifyClient determines whether to update the client with the changes
*/
@local
public native void addAbilities(@dereferenced Vector<Ability> abilities, boolean notifyClient = true);
@local
public native void addAbility(Ability ability, boolean notifyClient = true);
/**
* Removes certifications from player
* @pre { this is locked }
* @post { this is locked }
* @param skills Vector of skills to add
* @param notifyClient determines whether to update the client with the changes
*/
@local
public native void removeAbilities(@dereferenced Vector<Ability> abilities, boolean notifyClient = true);
@local
public native void removeAbility(Ability ability, boolean notifyClient = true);
@local
public native boolean addSchematics(@dereferenced Vector<DraftSchematic> schematics, boolean notifyClient = true);
@local
public native void removeSchematics(@dereferenced Vector<DraftSchematic> schematics, boolean notifyClient = true);
@local
public native boolean addRewardedSchematic(DraftSchematic schematic, short type, int quantity = 1, boolean notifyClient = true);
@local
public native void removeRewardedSchematic(DraftSchematic schematic, boolean notifyClient = true);
@local
public native void decreaseSchematicUseCount(DraftSchematic schematic);
//@local
//public native void addSchematic(DraftSchematic schematic, boolean notifyClient = true);
//@local
//public native void removeSchematic(DraftSchematic schematic, boolean notifyClient = true);
/**
* Sets the specified language id
* @pre { }
* @post { }
* @param language language id to set
* @param notifyClient determines whether to update the client with the changes
*/
public native void setLanguageID(byte language, boolean notifyClient = true);
/**
* Adds a friend to the friend list
* @pre { this is locked}
* @post { this is locked }
* @param name friends name
* @param notifyClient determines whether to update the client with the changes
*/
public native void addFriend(final string name, boolean notifyClient = true);
/**
* Removes the specified friend from the friend list
* @pre { this is locked }
* @post { this is locked}
* @param name friend name to remove
* @param notifyClient determines whether to update the client with the changes
*/
public native void removeFriend(final string name, boolean notifyClient = true);
//Used when a character is renamed
public native void removeAllReverseFriends(final string oldName);
/**
* Adds a player to the ignore list
* @pre { this is locked}
* @post { this is locked }
* @param name player name
* @param notifyClient determines whether to update the client with the changes
*/
public native void addIgnore(final string name, boolean notifyClient = true);
/**
* Removes the specified player from the ignore list
* @pre { this is locked }
* @post { this is locked}
* @param name player name to remove
* @param notifyClient determines whether to update the client with the changes
*/
public native void removeIgnore(final string name, boolean notifyClient = true);
public native void setTitle(final string characterTitle, boolean notifyClient = true);
public native void setFoodFilling(int newValue, boolean notifyClient = true);
public native void setDrinkFilling(int newValue, boolean notifyClient = true);
/**
* Adds the amount of faction points to the faction point list.
* @pre { this locked }
* @post { this locked }
* @param factionName The string key for the faction the faction points are to be added.
* @param amount The float amount of faction points to add.
*/
public native void increaseFactionStanding(final string factionName, float amount);
public native void giveCoaBonus(final string factionName, float amount, float currentStanding);
public native void decreaseFactionStanding(final string factionName, float amount);
public native void setFactionStanding(final string factionName, float amount);
@read
public native float getFactionStanding(final string factionName);
public void setScreenPlayData(final string screenPlay, final string variable, final string data) {
screenPlayData.put(screenPlay + "_" + variable, data);
}
public void deleteScreenPlayData(final string screenPlay, final string variable) {
screenPlayData.drop(screenPlay + "_" + variable);
}
@read
public string getScreenPlayData(final string screenPlay, final string variable) {
return screenPlayData.get(screenPlay + "_" + variable);
}
public native void clearScreenPlayData(final string screenPlay);
public native void activateRecovery();
public native void activateForcePowerRegen();
public native void doRecovery(int latency);
public native void disconnect(boolean closeClient, boolean doLock);
public native void reload(ZoneClientSession client);
public native void setOffline();
public native void setLinkDead(boolean isSafeLogout = false);
public native void setOnline();
public native void setLoggingOut();
public native void activateJournalQuest(unsigned int questCrc, boolean notifyClient = true);
public native void completeJournalQuest(unsigned int questCrc, boolean notifyClient = true);
public native void clearJournalQuest(unsigned int questCrc, boolean notifyClient = true);
public native void activateJournalQuestTask(unsigned int questCrc, int taskNum, boolean notifyClient = true);
public native void completeJournalQuestTask(unsigned int questCrc, int taskNum, boolean notifyClient = true);
public native void clearJournalQuestTask(unsigned int questCrc, int taskNum, boolean notifyClient = true);
public native boolean isJournalQuestActive(unsigned int questCrc);
public native boolean isJournalQuestComplete(unsigned int questCrc);
public native boolean isJournalQuestTaskActive(unsigned int questCrc, int taskNum);
public native boolean isJournalQuestTaskComplete(unsigned int questCrc, int taskNum);
/**
* Sends a badges response message
* @pre { }
* @post { }
* @param player CreatureObject to receive badges response message
*/
public native void sendBadgesResponseTo(CreatureObject player);
public native void logout(boolean doLock);
public native void setJediState(int state, boolean notifyClient = true);
public native void setActiveQuestsBit(int bitIndex, byte value, boolean notifyClient = true);
public void clearActiveQuestsBit(int bitIndex, boolean notifyClient = true) {
setActiveQuestsBit(bitIndex, (byte)0, notifyClient);
}
@dirty
public native boolean canActivateQuest(int questID);
public native void activateQuest(int questID);
@read
public boolean hasActiveQuestBitSet(int bitIndex) {
return activeQuests.getBitValue(bitIndex);
}
@read
public boolean hasCompletedQuestsBitSet(int bitIndex) {
return completedQuests.getBitValue(bitIndex);
}
public native void setCompletedQuestsBit(int bitIndex, byte value, boolean notifyClient = true);
public void clearCompletedQuestsBit(int bitIndex, boolean notifyClient = true) {
setCompletedQuestsBit(bitIndex, (byte)0, notifyClient);
}
public native void completeQuest(int questID);
@dereferenced
@local
@read
public native PlayerQuestData getQuestData(unsigned int questCrc);
@read
public boolean hasQuestData(unsigned int questCrc) {
return playerQuestsData.contains(questCrc);
}
@local
public native void setPlayerQuestData(unsigned int questCrc, @dereferenced PlayerQuestData data, boolean notifyClient = true);
@local
public native void clearPlayerQuestData(unsigned int questCrc, boolean notifyClient = true);
/**
* Gets the faction point list.
*/
@local
@dirty
public FactionStandingList getFactionStandingList() {
return factionStandingList;
}
//NPC Conversation Methods
public void setLastNpcConvStr(final string conv) {
lastNpcConvo = conv;
}
public void setLastNpcConvMessStr(final string mess) {
lastNpcConvoMessage = mess;
}
@read
public string getLastNpcConvStr() {
return lastNpcConvo;
}
@read
public string getLastNpcConvMessStr() {
return lastNpcConvoMessage;
}
@read
public string getLastNpcConvOption(int idx) {
return lastNpcConvoOptions.get(idx);
}
public void addLastNpcConvOptions(final string option) {
lastNpcConvoOptions.add(option);
}
@read
public int countLastNpcConvOptions() {
return lastNpcConvoOptions.size();
}
public void clearLastNpcConvOptions() {
lastNpcConvoOptions.removeAll();
}
public void setConversatingObject(SceneObject creature) {
if (!creature)
conversatingObject = 0;
else
conversatingObject = creature.getObjectID();
}
@read
public unsigned long getConversatingObject() {
return conversatingObject;
}
@local
public native void setTrainerCoordinates(@dereferenced final Vector3 trainer);
@local
@dereferenced
@read
public native Vector3 getJediTrainerCoordinates();
public void setTrainerZoneName(string zoneName) {
trainerZoneName = zoneName;
}
@read
public string getTrainerZoneName() {
return trainerZoneName;
}
@local
@dirty
public SortedVector<unsigned long> getPersistentMessages() {
return persistentMessages;
}
public void addPersistentMessage(unsigned long id) {
persistentMessages.put(id);
}
public void dropPersistentMessage(unsigned long id) {
persistentMessages.drop(id);
}
/**
* Unloads all the spawned objects from the datapad control devices
*/
public native void unloadSpawnedChildren(boolean petsOnly = false);
public void addToConsentList(final string name) {
consentList.put(name);
}
@read
public boolean hasInConsentList(final string name) {
return consentList.contains(name);
}
public void removeFromConsentList(final string name) {
consentList.drop(name);
}
@read
public string getConsentName(int i) {
return consentList.get(i);
}
@read
public int getConsentListSize() {
return consentList.size();
}
@read
public int getReactionFines() {
return reactionFines;
}
@read