Spaces:
Runtime error
Runtime error
minor update
Browse files
app.py
CHANGED
@@ -173,7 +173,7 @@ st.header(f'HeroPlan Explorer')
|
|
173 |
st.write('Powered by Heroplan.io : Thanks E&P community for continually update hero data.')
|
174 |
|
175 |
df = pd.read_csv('heroes_ep.csv')
|
176 |
-
st.write(f'### Updated:
|
177 |
|
178 |
df_extra = pd.read_csv("heroes_ep_extra.csv")
|
179 |
all_name_extra = sorted(list(df_extra['name'].values))
|
@@ -223,6 +223,8 @@ if genre == ':rainbow[Heroes Explorer]':
|
|
223 |
attack_option = st.text_input(label="Attack:", value="0")
|
224 |
health_option = st.text_input(label="Health:", value="0")
|
225 |
|
|
|
|
|
226 |
total_dot_option = st.text_input(label="Total DoT Damage:", value="0")
|
227 |
dot_per_turn_option = st.text_input(label="DoT Damage Per Turn:", value="0")
|
228 |
with col3:
|
@@ -274,6 +276,10 @@ if genre == ':rainbow[Heroes Explorer]':
|
|
274 |
dot_per_turn_option = int(dot_per_turn_option)
|
275 |
idx_all.append(filter_by_1col_num(df, 'dot_damage_per_turn', dot_per_turn_option, oper_flag="ge"))
|
276 |
|
|
|
|
|
|
|
|
|
277 |
if special_type_option != '':
|
278 |
idx_all.append(filter_by_1col(df, 'types', special_type_option, exact_flag=False))
|
279 |
|
@@ -313,10 +319,16 @@ elif genre == "Team Simulation":
|
|
313 |
st.write(f'Class: {df_hero["class"].values[0]}')
|
314 |
st.write(f'Types: {df_hero["types"].values[0]}')
|
315 |
|
|
|
|
|
316 |
nheroes_choice_list = [2,3,4,5]
|
317 |
nheroes_choice = st.selectbox(label='Number of Heroes:', options=nheroes_choice_list, index=len(nheroes_choice_list)-1)
|
318 |
-
|
319 |
-
|
|
|
|
|
|
|
|
|
320 |
df_hero_list = []
|
321 |
total_power = 0
|
322 |
for ii in range(nheroes_choice):
|
@@ -325,8 +337,9 @@ elif genre == "Team Simulation":
|
|
325 |
write_short_description(df_hero_list[-1])
|
326 |
total_power += df_hero_list[ii]['power'].values[0]
|
327 |
|
328 |
-
|
329 |
-
|
|
|
330 |
|
331 |
df_hero_all5 = pd.concat(df_hero_list)
|
332 |
|
@@ -359,4 +372,4 @@ else:
|
|
359 |
lb_choice = st.selectbox(label='Limit Break:', options=lb_list, index=0)
|
360 |
|
361 |
df_ret = return_hero_stat(df_extra, name_choice, lb_choice=lb_choice, costume_choice=costume_choice)
|
362 |
-
display_heroes_from_df(df_ret,display_cols=df_ret.columns[:-2]) # display all except special-skill text
|
|
|
173 |
st.write('Powered by Heroplan.io : Thanks E&P community for continually update hero data.')
|
174 |
|
175 |
df = pd.read_csv('heroes_ep.csv')
|
176 |
+
st.write(f'### Updated: December 9, 2023 -- Total heroes in HeroPlan database = {len(df)} (including Toon Costume3)')
|
177 |
|
178 |
df_extra = pd.read_csv("heroes_ep_extra.csv")
|
179 |
all_name_extra = sorted(list(df_extra['name'].values))
|
|
|
223 |
attack_option = st.text_input(label="Attack:", value="0")
|
224 |
health_option = st.text_input(label="Health:", value="0")
|
225 |
|
226 |
+
max_percent_option = st.text_input(label="Max % in Special Skill:", value="0")
|
227 |
+
|
228 |
total_dot_option = st.text_input(label="Total DoT Damage:", value="0")
|
229 |
dot_per_turn_option = st.text_input(label="DoT Damage Per Turn:", value="0")
|
230 |
with col3:
|
|
|
276 |
dot_per_turn_option = int(dot_per_turn_option)
|
277 |
idx_all.append(filter_by_1col_num(df, 'dot_damage_per_turn', dot_per_turn_option, oper_flag="ge"))
|
278 |
|
279 |
+
if max_percent_option != "0":
|
280 |
+
max_percent_option = int(max_percent_option)
|
281 |
+
idx_all.append(filter_by_1col_num(df, 'max_special_percent', max_percent_option, oper_flag="ge"))
|
282 |
+
|
283 |
if special_type_option != '':
|
284 |
idx_all.append(filter_by_1col(df, 'types', special_type_option, exact_flag=False))
|
285 |
|
|
|
319 |
st.write(f'Class: {df_hero["class"].values[0]}')
|
320 |
st.write(f'Types: {df_hero["types"].values[0]}')
|
321 |
|
322 |
+
note_flag = st.checkbox("Displayt Notepad", value=False)
|
323 |
+
|
324 |
nheroes_choice_list = [2,3,4,5]
|
325 |
nheroes_choice = st.selectbox(label='Number of Heroes:', options=nheroes_choice_list, index=len(nheroes_choice_list)-1)
|
326 |
+
|
327 |
+
additional_col = 0
|
328 |
+
if note_flag:
|
329 |
+
additional_col = 1
|
330 |
+
|
331 |
+
col_list = st.columns(nheroes_choice+additional_col)
|
332 |
df_hero_list = []
|
333 |
total_power = 0
|
334 |
for ii in range(nheroes_choice):
|
|
|
337 |
write_short_description(df_hero_list[-1])
|
338 |
total_power += df_hero_list[ii]['power'].values[0]
|
339 |
|
340 |
+
if note_flag:
|
341 |
+
with col_list[-1]:
|
342 |
+
txt = st.text_area("Write your note about team synergy", max_chars=1000, height = 480)
|
343 |
|
344 |
df_hero_all5 = pd.concat(df_hero_list)
|
345 |
|
|
|
372 |
lb_choice = st.selectbox(label='Limit Break:', options=lb_list, index=0)
|
373 |
|
374 |
df_ret = return_hero_stat(df_extra, name_choice, lb_choice=lb_choice, costume_choice=costume_choice)
|
375 |
+
display_heroes_from_df(df_ret,display_cols=df_ret.columns[:-2]) # display all except special-skill text
|