terraria-cpp2il-methodrecon v1.4.4.9
Terraria mobile dump, with reconstructed method body. Dump with CallAnalysis: https://infinitynichto.github.io/terraria-cpp2il
Loading...
Searching...
No Matches
AchievementsHelper.cs
Go to the documentation of this file.
1using System;
5
7{
8 // Token: 0x020009A4 RID: 2468
9 public class AchievementsHelper
10 {
11 // Token: 0x14000056 RID: 86
12 // (add) Token: 0x06004905 RID: 18693 RVA: 0x0026100C File Offset: 0x0025F20C
13 // (remove) Token: 0x06004906 RID: 18694 RVA: 0x00261024 File Offset: 0x0025F224
15 {
17 add
18 {
20 if (@delegate != null)
21 {
22 }
23 }
25 remove
26 {
28 if (@delegate != null)
29 {
30 }
31 }
32 }
33
34 // Token: 0x14000057 RID: 87
35 // (add) Token: 0x06004907 RID: 18695 RVA: 0x0026103C File Offset: 0x0025F23C
36 // (remove) Token: 0x06004908 RID: 18696 RVA: 0x00261054 File Offset: 0x0025F254
38 {
40 add
41 {
43 if (@delegate != null)
44 {
45 }
46 }
48 remove
49 {
51 if (@delegate != null)
52 {
53 }
54 }
55 }
56
57 // Token: 0x14000058 RID: 88
58 // (add) Token: 0x06004909 RID: 18697 RVA: 0x0026106C File Offset: 0x0025F26C
59 // (remove) Token: 0x0600490A RID: 18698 RVA: 0x00261084 File Offset: 0x0025F284
61 {
63 add
64 {
66 if (@delegate != null)
67 {
68 }
69 }
71 remove
72 {
74 if (@delegate != null)
75 {
76 }
77 }
78 }
79
80 // Token: 0x14000059 RID: 89
81 // (add) Token: 0x0600490B RID: 18699 RVA: 0x0026109C File Offset: 0x0025F29C
82 // (remove) Token: 0x0600490C RID: 18700 RVA: 0x002610B4 File Offset: 0x0025F2B4
84 {
86 add
87 {
89 if (@delegate != null)
90 {
91 }
92 }
94 remove
95 {
97 if (@delegate != null)
98 {
99 }
100 }
101 }
102
103 // Token: 0x1400005A RID: 90
104 // (add) Token: 0x0600490D RID: 18701 RVA: 0x002610CC File Offset: 0x0025F2CC
105 // (remove) Token: 0x0600490E RID: 18702 RVA: 0x002610E4 File Offset: 0x0025F2E4
107 {
109 add
110 {
112 if (@delegate != null)
113 {
114 }
115 }
117 remove
118 {
120 if (@delegate != null)
121 {
122 }
123 }
124 }
125
126 // Token: 0x1700084A RID: 2122
127 // (get) Token: 0x0600490F RID: 18703 RVA: 0x000021DB File Offset: 0x000003DB
128 // (set) Token: 0x06004910 RID: 18704 RVA: 0x002610FC File Offset: 0x0025F2FC
129 public static bool CurrentlyMining
130 {
131 get
132 {
133 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
134 }
135 set
136 {
137 }
138 }
139
140 // Token: 0x06004911 RID: 18705 RVA: 0x0026110C File Offset: 0x0025F30C
141 public static void NotifyTileDestroyed(Player player, ushort tile)
142 {
143 if (!true)
144 {
145 }
146 bool gameMenu = Main.gameMenu;
147 }
148
149 // Token: 0x06004912 RID: 18706 RVA: 0x00261128 File Offset: 0x0025F328
150 public static void NotifyItemPickup(Player player, Item item)
151 {
152 int netID = item.netID;
153 int stack = item.stack;
154 int netID2 = item.netID;
156 }
157
158 // Token: 0x06004913 RID: 18707 RVA: 0x00261154 File Offset: 0x0025F354
159 public static void NotifyItemPickup(Player player, Item item, int customStack)
160 {
161 int netID = item.netID;
162 int netID2 = item.netID;
164 }
165
166 // Token: 0x06004914 RID: 18708 RVA: 0x00261178 File Offset: 0x0025F378
167 public static void NotifyItemCraft(Recipe recipe)
168 {
169 int myPlayer = Main.myPlayer;
170 Item createItem = recipe.createItem;
171 int netID = createItem.netID;
172 int stack = createItem.stack;
173 Item createItem2 = recipe.createItem;
174 bool flag = AchievementsHelper.IsMetalBar(createItem2.type);
175 if (createItem2 == null)
176 {
177 }
178 int myPlayer2 = Main.myPlayer;
179 if (createItem == null)
180 {
181 }
182 LocalUser localUser;
183 uint totalBarsCrafted;
184 if (localUser != null)
185 {
190 if (totalBarsCrafted != 0U)
191 {
192 }
193 return;
194 }
195 if (recipe.requiredTile == null)
196 {
197 }
198 int myPlayer3 = Main.myPlayer;
199 if (totalBarsCrafted == 0U)
200 {
201 }
204 if (localUser2 != null)
205 {
207 totalAnvilCrafting = persistentUserData2.TotalAnvilCrafting;
210 if (totalAnvilCrafting != 0U)
211 {
212 }
213 return;
214 }
215 if (recipe.requiredTile == null)
216 {
217 }
218 int myPlayer4 = Main.myPlayer;
219 if (totalAnvilCrafting == 0U)
220 {
221 }
222 }
223
224 // Token: 0x06004915 RID: 18709 RVA: 0x00261254 File Offset: 0x0025F454
225 public static void Initialize()
226 {
227 }
228
229 // Token: 0x06004916 RID: 18710 RVA: 0x00261264 File Offset: 0x0025F464
230 internal static void OnPlayerEnteredWorld(Player player)
231 {
232 Item[] inventory = player.inventory;
233 int type = inventory.type;
234 int stack = inventory.stack;
235 }
236
237 // Token: 0x06004917 RID: 18711 RVA: 0x002615C8 File Offset: 0x0025F7C8
238 public static void NotifyNPCKilled(NPC npc)
239 {
240 int num = 1;
241 if (num == 0)
242 {
243 }
245 bool[] playerInteraction = npc.playerInteraction;
246 if (num == 0)
247 {
248 }
249 int myPlayer = Main.myPlayer;
250 if (num != 0)
251 {
252 if (num == 0)
253 {
254 }
255 int myPlayer2 = Main.myPlayer;
256 int netID = npc.netID;
257 }
259 if (playerInteraction2 != null)
260 {
261 int netID2 = npc.netID;
262 if (playerInteraction2 == null)
263 {
264 }
265 }
266 }
267
268 // Token: 0x06004918 RID: 18712 RVA: 0x00261630 File Offset: 0x0025F830
275
276 // Token: 0x06004919 RID: 18713 RVA: 0x00261654 File Offset: 0x0025F854
277 public static void NotifyProgressionEvent(int eventID)
278 {
279 if (!true)
280 {
281 }
282 bool netHost = Main.NetHost;
283 }
284
285 // Token: 0x0600491A RID: 18714 RVA: 0x0026167C File Offset: 0x0025F87C
286 public static void HandleOnEquip(Player player, Item item, int context)
287 {
288 }
289
290 // Token: 0x0600491B RID: 18715 RVA: 0x00261754 File Offset: 0x0025F954
291 public static void HandleSpecialEvent(Player player, int eventID)
292 {
293 int num = 1;
294 int whoAmI = player.whoAmI;
295 if (num == 0)
296 {
297 }
298 int myPlayer = Main.myPlayer;
299 }
300
301 // Token: 0x0600491C RID: 18716 RVA: 0x00261894 File Offset: 0x0025FA94
302 public static void HandleNurseService(int coinsSpent)
303 {
304 if (!true)
305 {
306 }
307 if (Main.Achievements.GetCondition("FREQUENT_FLYER", "Pay") != null)
308 {
309 }
310 }
311
312 // Token: 0x0600491D RID: 18717 RVA: 0x002618C4 File Offset: 0x0025FAC4
313 public static void HandleAnglerService()
314 {
315 if (!true)
316 {
317 }
318 AchievementCondition condition = Main.Achievements.GetCondition("SERVANT_IN_TRAINING", "Finish");
319 if (Main.Achievements.GetCondition("GOOD_LITTLE_SLAVE", "Finish") != null)
320 {
321 }
322 if (Main.Achievements.GetCondition("TROUT_MONKEY", "Finish") != null)
323 {
324 }
325 if (Main.Achievements.GetCondition("FAST_AND_FISHIOUS", "Finish") != null)
326 {
327 }
328 if (Main.Achievements.GetCondition("SUPREME_HELPER_MINION", "Finish") != null)
329 {
330 }
331 }
332
333 // Token: 0x0600491E RID: 18718 RVA: 0x00261954 File Offset: 0x0025FB54
334 public static void HandleRunning(Player player, float pixelsMoved)
335 {
336 if (!true)
337 {
338 }
339 AchievementCondition condition = Main.Achievements.GetCondition("MARATHON_MEDALIST", "Move");
340 if (condition != null)
341 {
342 }
343 if (condition._isCompleted)
344 {
346 return;
347 }
348 }
349
350 // Token: 0x0600491F RID: 18719 RVA: 0x0026199C File Offset: 0x0025FB9C
351 public static void HandleMining()
352 {
353 if (!true)
354 {
355 }
356 if (Main.Achievements.GetCondition("BULLDOZER", "Pick") != null)
357 {
358 }
359 }
360
361 // Token: 0x06004920 RID: 18720 RVA: 0x002619CC File Offset: 0x0025FBCC
362 public static void CheckMechaMayhem(int justKilled = -1)
363 {
364 }
365
366 // Token: 0x06004921 RID: 18721 RVA: 0x00261A54 File Offset: 0x0025FC54
367 private static bool IsMetalBar(int itemType)
368 {
369 }
370
371 // Token: 0x06004922 RID: 18722 RVA: 0x00261A64 File Offset: 0x0025FC64
373 {
374 }
375
376 // Token: 0x0400842E RID: 33838
379
380 // Token: 0x0400842F RID: 33839
383
384 // Token: 0x04008430 RID: 33840
387
388 // Token: 0x04008431 RID: 33841
391
392 // Token: 0x04008432 RID: 33842
395
396 // Token: 0x04008433 RID: 33843
397 private static bool _isMining;
398
399 // Token: 0x04008434 RID: 33844
400 private static bool mayhemOK;
401
402 // Token: 0x04008435 RID: 33845
403 private static bool mayhem1down;
404
405 // Token: 0x04008436 RID: 33846
406 private static bool mayhem2down;
407
408 // Token: 0x04008437 RID: 33847
409 private static bool mayhem3down;
410
411 // Token: 0x020009A5 RID: 2469
412 public sealed class ItemPickupEvent : MulticastDelegate
413 {
414 // Token: 0x06004923 RID: 18723 RVA: 0x00261A78 File Offset: 0x0025FC78
415 public ItemPickupEvent(object @object, IntPtr method)
416 {
418 this.m_target = @object;
420 this.method_code = this;
421 }
422
423 // Token: 0x06004924 RID: 18724 RVA: 0x00261AD8 File Offset: 0x0025FCD8
424 public void Invoke(Player player, short itemId, int count)
425 {
428 IntPtr method = this.method;
429 }
430
431 // Token: 0x06004925 RID: 18725 RVA: 0x000021DB File Offset: 0x000003DB
432 public IAsyncResult BeginInvoke(Player player, short itemId, int count, AsyncCallback callback, object @object)
433 {
434 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
435 }
436
437 // Token: 0x06004926 RID: 18726 RVA: 0x00261AFC File Offset: 0x0025FCFC
438 public void EndInvoke(IAsyncResult result)
439 {
440 }
441 }
442
443 // Token: 0x020009A6 RID: 2470
444 public sealed class ItemCraftEvent : MulticastDelegate
445 {
446 // Token: 0x06004927 RID: 18727 RVA: 0x00261B0C File Offset: 0x0025FD0C
447 public ItemCraftEvent(object @object, IntPtr method)
448 {
451 }
452
453 // Token: 0x06004928 RID: 18728 RVA: 0x00261B5C File Offset: 0x0025FD5C
454 public void Invoke(Player player, short itemId, int count)
455 {
458 IntPtr method = this.method;
459 }
460
461 // Token: 0x06004929 RID: 18729 RVA: 0x000021DB File Offset: 0x000003DB
462 public IAsyncResult BeginInvoke(Player player, short itemId, int count, AsyncCallback callback, object @object)
463 {
464 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
465 }
466
467 // Token: 0x0600492A RID: 18730 RVA: 0x00261B80 File Offset: 0x0025FD80
468 public void EndInvoke(IAsyncResult result)
469 {
470 }
471 }
472
473 // Token: 0x020009A7 RID: 2471
475 {
476 // Token: 0x0600492B RID: 18731 RVA: 0x00261B90 File Offset: 0x0025FD90
477 public TileDestroyedEvent(object @object, IntPtr method)
478 {
480 this.m_target = @object;
482 this.method_code = this;
483 }
484
485 // Token: 0x0600492C RID: 18732 RVA: 0x00261BF0 File Offset: 0x0025FDF0
486 public void Invoke(Player player, ushort tileId)
487 {
490 IntPtr method = this.method;
491 }
492
493 // Token: 0x0600492D RID: 18733 RVA: 0x000021DB File Offset: 0x000003DB
494 public IAsyncResult BeginInvoke(Player player, ushort tileId, AsyncCallback callback, object @object)
495 {
496 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
497 }
498
499 // Token: 0x0600492E RID: 18734 RVA: 0x00261C14 File Offset: 0x0025FE14
500 public void EndInvoke(IAsyncResult result)
501 {
502 }
503 }
504
505 // Token: 0x020009A8 RID: 2472
506 public sealed class NPCKilledEvent : MulticastDelegate
507 {
508 // Token: 0x0600492F RID: 18735 RVA: 0x00261C24 File Offset: 0x0025FE24
509 public NPCKilledEvent(object @object, IntPtr method)
510 {
512 this.m_target = @object;
514 this.method_code = this;
515 }
516
517 // Token: 0x06004930 RID: 18736 RVA: 0x00261C84 File Offset: 0x0025FE84
518 public void Invoke(Player player, short npcId)
519 {
522 IntPtr method = this.method;
523 }
524
525 // Token: 0x06004931 RID: 18737 RVA: 0x000021DB File Offset: 0x000003DB
526 public IAsyncResult BeginInvoke(Player player, short npcId, AsyncCallback callback, object @object)
527 {
528 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
529 }
530
531 // Token: 0x06004932 RID: 18738 RVA: 0x00261CA8 File Offset: 0x0025FEA8
532 public void EndInvoke(IAsyncResult result)
533 {
534 }
535 }
536
537 // Token: 0x020009A9 RID: 2473
539 {
540 // Token: 0x06004933 RID: 18739 RVA: 0x00261CB8 File Offset: 0x0025FEB8
541 public ProgressionEventEvent(object @object, IntPtr method)
542 {
544 this.m_target = @object;
546 this.method_code = this;
547 }
548
549 // Token: 0x06004934 RID: 18740 RVA: 0x00261D0C File Offset: 0x0025FF0C
550 public void Invoke(int eventID)
551 {
554 IntPtr method = this.method;
555 }
556
557 // Token: 0x06004935 RID: 18741 RVA: 0x000021DB File Offset: 0x000003DB
558 public IAsyncResult BeginInvoke(int eventID, AsyncCallback callback, object @object)
559 {
560 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
561 }
562
563 // Token: 0x06004936 RID: 18742 RVA: 0x00261D30 File Offset: 0x0025FF30
564 public void EndInvoke(IAsyncResult result)
565 {
566 }
567 }
568 }
569}
class f__AnonymousType0<< Count > j__TPar
PersistentUserData PersistentUserData
Definition LocalUser.cs:223
IPlatformAwardNotifier PlatformAwards
Definition LocalUser.cs:220
static eSlimeKillStatistics GetSlimeStatIDFromNetID(int netID)
static void NoteItemPickedUpForPlayer(Player player, int itemID)
static void NoteTriggerForPlayer(Player player, eTrigger triggerType)
static void NoteSlimeDefeatedForPlayer(Player player, eSlimeKillStatistics slimeID)
IntPtr method_code
Definition Delegate.cs:386
IntPtr invoke_impl
Definition Delegate.cs:371
AchievementCondition GetCondition(string achievementName, string conditionName)
IAsyncResult BeginInvoke(Player player, short itemId, int count, AsyncCallback callback, object @object)
IAsyncResult BeginInvoke(Player player, short itemId, int count, AsyncCallback callback, object @object)
IAsyncResult BeginInvoke(Player player, short npcId, AsyncCallback callback, object @object)
IAsyncResult BeginInvoke(int eventID, AsyncCallback callback, object @object)
IAsyncResult BeginInvoke(Player player, ushort tileId, AsyncCallback callback, object @object)
static AchievementsHelper.TileDestroyedEvent OnTileDestroyed
static AchievementsHelper.ProgressionEventEvent OnProgressionEvent
static AchievementsHelper.ItemCraftEvent OnItemCraft
static void HandleSpecialEvent(Player player, int eventID)
static AchievementsHelper.ItemPickupEvent OnItemPickup
static void HandleRunning(Player player, float pixelsMoved)
static void NotifyItemPickup(Player player, Item item)
static void HandleOnEquip(Player player, Item item, int context)
static AchievementsHelper.NPCKilledEvent OnNPCKilled
static void NotifyNPCKilledDirect(Player player, int npcNetID)
static void NotifyTileDestroyed(Player player, ushort tile)
static void NotifyItemPickup(Player player, Item item, int customStack)
static bool LogicClient
Definition Main.cs:5513
static AchievementManager Achievements
Definition Main.cs:4221
static bool NetHost
Definition Main.cs:5544
static int myPlayer
Definition Main.cs:2337
static bool gameMenu
Definition Main.cs:2673
bool[] playerInteraction
Definition NPC.cs:11141
int netID
Definition NPC.cs:11510
Item[] inventory
Definition Player.cs:21263
int[] requiredTile
Definition Recipe.cs:1029
static LocalUser FindLocalUserByPlayer(Player player)
eSlimeKillStatistics
eTrigger
Definition eTrigger.cs:5