61
61
* 1000
62
62
)
63
63
64
+ BROKEN_OVERFLOW_TYPES = {"cider" , "large_net" , "palmer" }
65
+
64
66
65
67
def cache_path_for (** kwargs ) -> str :
66
68
buf = io .StringIO ()
@@ -96,8 +98,10 @@ class ItemDrops:
96
98
explores : int = 0
97
99
lemonades : int = 0
98
100
ciders : int = 0
101
+ palmers : int = 0
99
102
fishes : int = 0
100
103
nets : int = 0
104
+ large_nets : int = 0
101
105
harvests : int = 0
102
106
drops : int = 0
103
107
@@ -107,8 +111,10 @@ class LocationDrops:
107
111
explores : int = 0
108
112
lemonades : int = 0
109
113
ciders : int = 0
114
+ palmers : int = 0
110
115
fishes : int = 0
111
116
nets : int = 0
117
+ large_nets : int = 0
112
118
harvests : int = 0
113
119
drops : int = 0
114
120
items : dict [str , ItemDrops ] = attrs .Factory (lambda : defaultdict (ItemDrops ))
@@ -119,8 +125,10 @@ class Drops:
119
125
explores : int = 0
120
126
lemonades : int = 0
121
127
ciders : int = 0
128
+ palmers : int = 0
122
129
fishes : int = 0
123
130
nets : int = 0
131
+ large_nets : int = 0
124
132
harvests : int = 0
125
133
drops : int = 0
126
134
locations : dict [str , LocationDrops ] = attrs .Factory (
@@ -179,12 +187,22 @@ def count_sources(
179
187
# This is kind of wrong for global and location stats since not all explores count
180
188
# for all items but it's more correct than not.
181
189
drops .explores += row ["results" ].get ("explores" , row ["results" ]["stamina" ])
190
+ elif row ["type" ] == "palmer" :
191
+ drops .palmers += 1
192
+ if lemonade_fake_explores_location is not None :
193
+ drops .explores += round (
194
+ (1 / BASE_DROP_RATES [lemonade_fake_explores_location ]) * 500
195
+ )
182
196
elif row ["type" ] == "fish" :
183
197
drops .fishes += 1
184
198
elif row ["type" ] == "net" :
185
199
drops .nets += 1
186
200
if nets_fake_fishes :
187
201
drops .fishes += sum (it .get ("quantity" , 1 ) for it in row ["results" ]["items" ])
202
+ elif row ["type" ] == "large_net" :
203
+ drops .large_nets += 1
204
+ if nets_fake_fishes :
205
+ drops .fishes += 400
188
206
elif row ["type" ] == "harvestall" :
189
207
# We already checked that only mono-seed logs are considered.
190
208
drops .harvests += len (row ["results" ]["crops" ])
@@ -194,8 +212,10 @@ def compile_drops(
194
212
explore : bool = False ,
195
213
lemonade : bool = False ,
196
214
cider : bool = False ,
215
+ palmer : bool = False ,
197
216
fish : bool = False ,
198
217
net : bool = False ,
218
+ large_net : bool = False ,
199
219
harvest : bool = False ,
200
220
since : int = 0 ,
201
221
iron_depot : bool = False ,
@@ -208,8 +228,10 @@ def compile_drops(
208
228
e = explore ,
209
229
l = lemonade ,
210
230
c = cider ,
231
+ p = palmer ,
211
232
f = fish ,
212
233
n = net ,
234
+ m = large_net ,
213
235
h = harvest ,
214
236
s = since ,
215
237
i = iron_depot ,
@@ -246,10 +268,14 @@ def compile_drops(
246
268
types .add ("lemonade" )
247
269
if cider :
248
270
types .add ("cider" )
271
+ if palmer :
272
+ types .add ("palmer" )
249
273
if fish :
250
274
types .add ("fish" )
251
275
if net :
252
276
types .add ("net" )
277
+ if large_net :
278
+ types .add ("large_net" )
253
279
if harvest :
254
280
types .add ("harvestall" )
255
281
explores = Drops ()
@@ -273,7 +299,7 @@ def compile_drops(
273
299
# Ignore out-of-bounds drops. This allows accounting for stuff like drop
274
300
# rates changing substantially by manually resetting firstDropped.
275
301
continue
276
- if row ["type" ] == "cider" and item ["item" ] in overflow_items :
302
+ if row ["type" ] in BROKEN_OVERFLOW_TYPES and item ["item" ] in overflow_items :
277
303
# Cider overflow always reports 0 drops so any item that overflows during
278
304
# a cider has to be ignored.
279
305
continue
@@ -317,7 +343,7 @@ def compile_drops(
317
343
if row ["ts" ] not in when_items_dropped [(item , location_name )]:
318
344
# Item couldn't drop, this doesn't count.
319
345
continue
320
- if row ["type" ] == "cider" and item in overflow_items :
346
+ if row ["type" ] in BROKEN_OVERFLOW_TYPES and item in overflow_items :
321
347
# Cider overflow always reports 0 drops so any item that overflows during
322
348
# a cider has to be ignored.
323
349
continue
0 commit comments