Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Snowflake singleplayer implementation #57

Open
wants to merge 48 commits into
base: singleplayer
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 45 commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
84cf927
Bump redis from 5.0.7 to 5.0.8
dependabot[bot] Jul 30, 2024
90764dc
Merge pull request #47 from Lekuruu/dependabot/pip/redis-5.0.8
Lekuruu Jul 30, 2024
37b8418
Bump sqlalchemy from 2.0.31 to 2.0.32
dependabot[bot] Aug 6, 2024
b9873a8
Merge pull request #48 from Lekuruu/dependabot/pip/sqlalchemy-2.0.32
Lekuruu Aug 6, 2024
e304c01
Bump twisted from 24.3.0 to 24.7.0
dependabot[bot] Aug 12, 2024
29c633a
Merge pull request #49 from Lekuruu/dependabot/pip/twisted-24.7.0
Lekuruu Aug 12, 2024
fdd1af7
Fix `tile_range` logic for tusk
Lekuruu Aug 19, 2024
0945cc3
Merge pull request #50 from Lekuruu/tile-range-fix
Lekuruu Aug 19, 2024
ee35124
Bump sqlalchemy from 2.0.32 to 2.0.33
dependabot[bot] Sep 4, 2024
822523e
Merge pull request #51 from Lekuruu/dependabot/pip/sqlalchemy-2.0.33
Lekuruu Sep 4, 2024
1c6c1ee
Bump sqlalchemy from 2.0.33 to 2.0.35
dependabot[bot] Sep 17, 2024
047cae1
Merge pull request #53 from Lekuruu/dependabot/pip/sqlalchemy-2.0.35
Lekuruu Sep 17, 2024
92c3c4a
Refactor session parameter in database repositories
Lekuruu Sep 17, 2024
88bcb03
Add card data property
Lekuruu Sep 17, 2024
8b67f31
Cleanup imports
Lekuruu Sep 17, 2024
fd1c8fa
Add `do_later` method to game objects
Lekuruu Sep 17, 2024
0edef36
Fix sprite resets
Lekuruu Sep 17, 2024
42c9e9a
Bots
Walinski Oct 1, 2024
5fafb89
Tusk Fix
Walinski Oct 1, 2024
01f0eb9
Tusk
Walinski Oct 1, 2024
8151c6d
Healing Bug
Walinski Oct 1, 2024
29ebcf5
CJ Snow Bots More
Walinski Oct 1, 2024
40b74fc
Edited Health Threshold
Walinski Oct 1, 2024
6c7930d
Fixed Ranges
Walinski Oct 1, 2024
e3c43e9
Fixed Ranges
Walinski Oct 1, 2024
eb03030
Fixed Ranges
Walinski Oct 1, 2024
a5bfe0c
Ninja Ranges
Walinski Oct 1, 2024
e243418
Ninja Ranges
Walinski Oct 1, 2024
67c64d4
FINAL
Walinski Oct 1, 2024
d5564e3
Bump redis from 5.0.3 to 5.0.4
dependabot[bot] Apr 24, 2024
96aba3f
Remove unused `get_debug_players` function
Lekuruu May 5, 2024
1e064f1
Implement matchmaking timeout
Lekuruu May 5, 2024
7e9ff02
Refactor matchmaking timeout todo
Lekuruu Apr 2, 2024
7ed7c50
Implement matchmaking timeout
Lekuruu May 5, 2024
47ba602
Add `PenguinAI` class
Lekuruu Apr 2, 2024
b5bf9c2
Fix rebase with main branch
Lekuruu Jul 25, 2024
d1b62b4
Refactor `reactor.callLater` delays
Lekuruu Jul 25, 2024
30859b5
Add `confirm_move` function
Lekuruu Jul 25, 2024
f863664
Implement action functions, based on element of ninja
Lekuruu Jul 25, 2024
283f289
Refactor session parameter in database repositories
Lekuruu Sep 17, 2024
98bf9dc
Cleanup imports
Lekuruu Sep 17, 2024
6ee8cfb
Bots
Walinski Oct 1, 2024
851db72
Merge remote-tracking branch 'origin/singleplayer' into pr/Walinski/57
Lekuruu Oct 1, 2024
37f5f51
Add `is_bot` check to prevent event timeouts
Lekuruu Oct 1, 2024
3841586
First general code overhaul
Lekuruu Oct 1, 2024
118a139
Change usage of `update_attack_position` function
Lekuruu Oct 1, 2024
cd36179
More refactoring & cleanup
Lekuruu Oct 1, 2024
98e1471
Change tusk hp values back
Lekuruu Oct 11, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Snowflake
# Snowflake Singleplayer Edition

A game server for the Club Penguin minigame "Card-Jitsu Snow", made to be compatible with [Houdini](https://github.com/solero/houdini).

Expand All @@ -24,6 +24,7 @@ Please view [this file](https://github.com/Lekuruu/snowflake/blob/main/SETUP.md)
- [x] Attacks
- [x] Healing
- [x] Reviving
- [x] AI Ninjas
- [x] Enemies
- [x] Movement
- [x] Attacks
Expand Down Expand Up @@ -59,4 +60,4 @@ Please view [this file](https://github.com/Lekuruu/snowflake/blob/main/SETUP.md)

![image](https://raw.githubusercontent.com/Lekuruu/snowflake/main/.github/screenshots/gameplay3.png)

![image](https://raw.githubusercontent.com/Lekuruu/snowflake/main/.github/screenshots/gameplay4.png)
![image](https://raw.githubusercontent.com/Lekuruu/snowflake/main/.github/screenshots/gameplay4.png)
5 changes: 4 additions & 1 deletion app/data/repositories/cards.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,11 @@ def fetch_all(session: Session | None = None) -> List[Card]:

@session_wrapper
def fetch_by_element(element: str, session: Session | None = None) -> List[Card]:
# Query to fetch all unique cards of the given element
return session.query(Card) \
.filter(Card.element == element) \
.filter(Card.power_id > 0) \
.distinct(Card.id) \
.all()

@session_wrapper
Expand Down Expand Up @@ -86,4 +89,4 @@ def fetch_power_card_count(
.filter(PenguinCard.penguin_id == penguin_id) \
.filter(Card.element == element) \
.filter(Card.power_id > 0) \
.scalar() or 0
.scalar() or 0
Loading