|
| 1 | +--- |
| 2 | +title: "GSoC '25 Week 5 Update by Krish Pandya" |
| 3 | +excerpt: "Animations, Toolbars, and a Playable Game" |
| 4 | +category: "DEVELOPER NEWS" |
| 5 | +date: "2025-07-05" |
| 6 | +slug: "2025-07-05-gsoc-25-mostlyk-week05" |
| 7 | +author: "@/constants/MarkdownFiles/authors/krish-pandya.md" |
| 8 | +tags: "gsoc25,sugarlabs,week05,mostlyk" |
| 9 | +image: "assets/Images/GSOC.png" |
| 10 | +--- |
| 11 | + |
| 12 | +# Week 5: Animations, Toolbars, and a Playable Game |
| 13 | + |
| 14 | +**Project:** [GTK4 Exploration](https://summerofcode.withgoogle.com/programs/2025/projects/rsHsYZKy) |
| 15 | + |
| 16 | +**Mentors:** [Walter Bender](https://github.com/walterbender), [Ibiam Chihurumnaya Ibiam](https://github.com/chimosky), [Juan Pablo Ugarte](https://github.com/xjuan) |
| 17 | + |
| 18 | +**Reporting Period:** June 22, 2025 – June 28, 2025 |
| 19 | + |
| 20 | +--- |
| 21 | + |
| 22 | +## Travel and Context |
| 23 | + |
| 24 | +This week started with an 8-hour flight from Hyderabad to Diu ( my hometown ) between Sunday and Monday. |
| 25 | +And _YES_ , I am home, sweet home. It was fun working on animations , toolbars and the game. |
| 26 | + |
| 27 | + |
| 28 | +## Animations and Toolbars |
| 29 | + |
| 30 | +So as discussed and sneak peeked in last week, first part was finishing the toolbar integration and that was done! I also added animations.py. |
| 31 | +I have always been a big fan of animations, my first addition to my [PKMS Site](https://pkms.vercel.app/) ( Personal Knowledge Management System ) was a handcrafted and personal documentation of Manim which a python animation library. |
| 32 | + |
| 33 | +Now it has a lot of things but it started as a manim documentation. |
| 34 | + |
| 35 | +### Animations |
| 36 | + |
| 37 | +Added a few clean effects: |
| 38 | + |
| 39 | +- `fade-in` and `fade-out` |
| 40 | +- `color` transitions |
| 41 | +- `scale-down` |
| 42 | + |
| 43 | + |
| 44 | +### Toolbars |
| 45 | + |
| 46 | +Features include and tested in example: |
| 47 | + |
| 48 | +- Full range of buttons: open, save, undo, redo, cut, copy, paste |
| 49 | +- Multi-select toggles, zoom controls, view modes |
| 50 | +- Toolbuttons ( This requires palette somehow so will be updated next week. Sorry for the wait! ) |
| 51 | +- And because of that if someone wants to play the game, you would have to wait till next week for the palette finish and the ToolButton addition in library. |
| 52 | + |
| 53 | + |
| 54 | +## Why Not HelloWorld Yet? |
| 55 | + |
| 56 | +The actual HelloWorld example has more dependencies than just graphics. It needs: |
| 57 | + |
| 58 | +- `widgets.py` |
| 59 | +which further needs: |
| 60 | + - `RadioButton`, `ToolButton`, `ToolBarButton`, `PaletteMenuBox` etc. |
| 61 | + - A bunch of internal glue that isn't finalized yet |
| 62 | + |
| 63 | +A good HelloWorld will take a few more weeks to land, realistically. |
| 64 | +It requires almost all graphics-related components working in unison. Instead of rushing a half-baked HelloWorld, I decided to make something fun using what I already have. |
| 65 | + |
| 66 | + |
| 67 | +## The Game: Super Ball Dodge |
| 68 | + |
| 69 | +<iframe width="560" height="315" src="https://www.youtube.com/embed/B517C_LTCns?si=u4zGfRp0yEJca8_O" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe> |
| 70 | + |
| 71 | +So I built a game. It's simple, but fully interactive, and it uses the toolkit as it currently exists ( well it uses ToolButton which is half baked, so you would be able to play it by next week, can watch the video to see what it is though! ). |
| 72 | + |
| 73 | +### Game Mechanics |
| 74 | + |
| 75 | +- Use `WASD`, arrow keys, or toolbar buttons to move |
| 76 | +- Press `P` to pause, `R` to restart |
| 77 | +- Touch the red ball and you lose |
| 78 | +- Hitting walls increases your speed and randomizes your color |
| 79 | +- Max speed is capped to keep it playable |
| 80 | + |
| 81 | +This game is both a stress test and a fun break. It's a good way to validate rendering, event handling, animation, and user interaction at once. |
| 82 | +Also it kind of stands like a hello world alternative for now before everything is done in unison and final decisions are made. |
| 83 | + |
| 84 | + |
| 85 | +## Summary of Progress |
| 86 | + |
| 87 | +- Built and finalized core animations |
| 88 | +- Integrated and tested full-featured toolbar |
| 89 | +- Added working event bindings and accelerators |
| 90 | +- Created Super Ball Dodge as a game/activity testbed |
| 91 | + |
| 92 | +--- |
| 93 | + |
| 94 | +## Next Steps |
| 95 | + |
| 96 | +- Refactor window tests (they're not up to standard yet) |
| 97 | +- Finalize and commit `widgets.py`, `ToolButton`, and all of `pallete` stuff. |
| 98 | +- Start building the actual HelloWorld once widget infra is stable |
| 99 | + |
| 100 | +--- |
| 101 | + |
| 102 | +## Links |
| 103 | + |
| 104 | +- [Project Page](https://summerofcode.withgoogle.com/programs/2025/projects/rsHsYZKy) |
| 105 | +- [Toolkit Repo (Python)](https://github.com/MostlyKIGuess/sugar-toolkit-gtk4-py) |
| 106 | +- [sugar-ext (C bindings)](https://github.com/sugarlabs/sugar-ext) |
| 107 | +- [Game Demo Video](https://youtu.be/B517C_LTCns) |
| 108 | + |
| 109 | + |
| 110 | +## Closing Thoughts |
| 111 | + |
| 112 | +It's funny how animations were the thing that got me into this headspace of _I GOTTA DO SOMETHING DYNAMIC_ , and I have always loved geometry and maths. And I got to introduce and do something related to that this week and this game was the result of what came out this week and I am glad I got to do it. |
| 113 | + |
| 114 | +Until next week, |
| 115 | +Krish! |
| 116 | +(P.S. If you couldn’t tell already , I love hiding pop culture references and breaking the fourth wall in these posts. So yes, you, yup, you alright, the reader.... enjoy.) |
0 commit comments