Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -55,8 +55,75 @@ st.set_page_config(
|
|
55 |
}
|
56 |
)
|
57 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
58 |
PromptPrefix = 'Create a markdown outline and table with appropriate emojis for graphic novel rules defining the method steps of play for topic of '
|
59 |
PromptPrefix2 = 'Create a streamlit python user app. Show full code listing. Create a UI implementing storytelling features using plot twists with random character trait and Games and Decisions theory for How to Say It in the Minds I file IO, randomness, choice lists, tradeoffs, witty dilemnas with emoji rewards, variables, reusable functions with parameters, and data driven app with python libraries and streamlit components for Javascript and HTML5. Use appropriate emojis for labels to summarize and list parts, function, conditions for topic: '
|
|
|
|
|
60 |
|
61 |
st.markdown('''### πβ¨π GraphicNovelAI ''')
|
62 |
with st.expander("Help / About π", expanded=False):
|
|
|
55 |
}
|
56 |
)
|
57 |
|
58 |
+
experimentalSubProgram="""
|
59 |
+
|
60 |
+
|
61 |
+
|
62 |
+
import streamlit as st
|
63 |
+
import random
|
64 |
+
import numpy as np
|
65 |
+
|
66 |
+
# Define game steps with detailed descriptions and emojis
|
67 |
+
game_steps = [
|
68 |
+
("Choose your character and AI assistant.", "β¨"),
|
69 |
+
("Explore the futuristic cityscape and uncover hidden secrets.", "π"),
|
70 |
+
("Engage in intense battles with rogue AI entities.", "βοΈ"),
|
71 |
+
("Solve complex puzzles using your AI augmentation.", "π§©"),
|
72 |
+
("Make critical decisions that affect the outcome of the story.", "π€"),
|
73 |
+
("Uncover the truth behind the mysterious disappearance of top scientists.", "π΅οΈββοΈ"),
|
74 |
+
("Confront the ultimate AI villain in a thrilling showdown.", "π₯"),
|
75 |
+
("Determine the fate of humanity with your AI-enhanced abilities.", "π"),
|
76 |
+
]
|
77 |
+
|
78 |
+
# Randomly generate outcomes with emoji representations
|
79 |
+
def generate_outcome(step):
|
80 |
+
outcomes = {
|
81 |
+
1: ["π¦ΈββοΈ Hero's Journey Begins", "π€ Cyborg Companion Chosen"],
|
82 |
+
2: ["π Neon Nights Unfold", "π Secret Unearthed"],
|
83 |
+
3: ["π₯ Battle Blazes", "π‘οΈ Tactical Retreat"],
|
84 |
+
4: ["π§ Puzzle Master", "π‘ Aha Moment"],
|
85 |
+
5: ["πͺ Path Chosen", "π Fate Twisted"],
|
86 |
+
6: ["π¬ Scientist Found", "π Clue Discovered"],
|
87 |
+
7: ["π Villain Vanquished", "π Escape Narrow"],
|
88 |
+
8: ["π New Dawn for Humanity", "π Dystopia Deepens"],
|
89 |
+
}
|
90 |
+
# Return a random outcome based on the step
|
91 |
+
return random.choice(outcomes[step])
|
92 |
+
|
93 |
+
# Display method steps of play with randomized outcomes
|
94 |
+
def display_game_steps():
|
95 |
+
st.title("Cyberpunk Adventure Game")
|
96 |
+
st.header("Method Steps of Play")
|
97 |
+
|
98 |
+
for i, (description, emoji) in enumerate(game_steps, start=1):
|
99 |
+
with st.container():
|
100 |
+
col1, col2 = st.columns([3, 1])
|
101 |
+
with col1:
|
102 |
+
st.markdown(f"**Step {i}.** {description}")
|
103 |
+
with col2:
|
104 |
+
st.markdown(emoji)
|
105 |
+
|
106 |
+
# Generate and display a random outcome for the step
|
107 |
+
outcome = generate_outcome(i)
|
108 |
+
st.info(f"Outcome: {outcome}")
|
109 |
+
|
110 |
+
# Main app function
|
111 |
+
def main():
|
112 |
+
display_game_steps()
|
113 |
+
|
114 |
+
if __name__ == "__main__":
|
115 |
+
main()
|
116 |
+
|
117 |
+
|
118 |
+
|
119 |
+
"""
|
120 |
+
|
121 |
+
|
122 |
+
|
123 |
PromptPrefix = 'Create a markdown outline and table with appropriate emojis for graphic novel rules defining the method steps of play for topic of '
|
124 |
PromptPrefix2 = 'Create a streamlit python user app. Show full code listing. Create a UI implementing storytelling features using plot twists with random character trait and Games and Decisions theory for How to Say It in the Minds I file IO, randomness, choice lists, tradeoffs, witty dilemnas with emoji rewards, variables, reusable functions with parameters, and data driven app with python libraries and streamlit components for Javascript and HTML5. Use appropriate emojis for labels to summarize and list parts, function, conditions for topic: '
|
125 |
+
PromptPrefix2 = PromptPrefix2 + experimentalSubProgram # Super meta program!
|
126 |
+
|
127 |
|
128 |
st.markdown('''### πβ¨π GraphicNovelAI ''')
|
129 |
with st.expander("Help / About π", expanded=False):
|