Skip to content

Commit d813b24

Browse files
author
Jo Jaquinta
committed
Death toggle made sticky.
1 parent 70f27f9 commit d813b24

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

app/routes.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ def chargen():
1919
upp_string=character.upp_string, age=character.age, status=character.status,
2020
career=character.career, rank_name=character.rank_name, terms=character.terms,
2121
credits=character.cash, possessions=character.possessions_string,
22-
skills=character.skill_string)
22+
skills=character.skill_string,
23+
deathDefault=death)
2324
if request.args.get('generate') == 'Generate':
2425
return redirect(url_for('chargen', Death=death))
2526
else:

app/templates/index.html

+5
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,13 @@ <h2>Cepheus Light Character Generator</h2>
1010
{{possessions}}<br><br>
1111
{{skills}}<br><br>
1212
<form action="">
13+
{% if deathDefault %}
14+
<input type="radio" name="Death" value="Death" checked="checked"><span>Death enabled</span><br/>
15+
<input type="radio" name="Death" value="Life"><span>Death disabled</span><br><br>
16+
{% else %}
1317
<input type="radio" name="Death" value="Death"><span>Death enabled</span><br/>
1418
<input type="radio" name="Death" value="Life" checked="checked"><span>Death disabled</span><br><br>
19+
{% endif %}
1520
<input type="submit" name="generate" value="Generate">
1621
</form><br>
1722
</form> </body>

0 commit comments

Comments
 (0)