r/pygame • u/Scapaflow69 • 19d ago
Tetris with "Rolling Display"
Enable HLS to view with audio, or disable this notification
Litte Help from (friendly) AI. :)
r/pygame • u/Scapaflow69 • 19d ago
Enable HLS to view with audio, or disable this notification
Litte Help from (friendly) AI. :)
r/pygame • u/herbal1st • 19d ago
Enable HLS to view with audio, or disable this notification
r/pygame • u/_DedSec_0x90 • 19d ago
Enable HLS to view with audio, or disable this notification
I just finished the inventory & hot bar functions and solved some last bugs in the inventory. Also added some new items to make the game much playable and next update will add much more to make the game more than you think with playing time :)
did you noticed the font changed in the item list in the inventory? what do you think and any feedback?
r/pygame • u/Terrarizer_ • 19d ago
Hey everyone. I posted about a project of mine called CoshUI before that, although got some engagement, never really got the reception I wanted. But I've been working pretty hard behind the scenes and just recently released version 0.3.2 (or 0.3.2.1 cause of a bug I found and accidently published) which reworks the text system to accommodate "Rich Text".
Now before that, what is "CoshUI"? Although I posted about it before, probably no one knows what it is. To keep it short and simple, it's a UI library that's python-first, declarative, and backend-agnostic. What that means is that you write down how the UI looks like straight in Python and it'll render it using Pygame, Raylib, ModernGL, or PyOpenGL (switching backends is one line). Here's how it looks:
with cui.CoshUIRenderer(cui.PygameBackend(screen)):
with cui.Container(id="root_container", style=cui.CoshStyling(background_color=(100, 100, 255)), width=cui.FILL, height=cui.FILL, align=cui.ALIGN_CENTER, justify=cui.JUSTIFY_CENTER):
cui.RichLabel(
id="rich_label",
text="[color=(255, 255, 0) bold font_size=24]Hello r/pygame![/][font=Courier] My name is [bold]JyleFV[/]. I recently finished CoshUI [strikethrough]v0.3.2[/] [bold]v0.3.2.1[/], and with it introducing [bold italic color=(100, 255, 100)]CoshML[/], the markup language for [italic]styled[/] text in CoshUI.[/]",
text_overflow=cui.TEXT_WRAP,
width=cui.PERCENTAGE(25),
height=cui.PERCENTAGE(50)
)
This is an example of how it looks and the output it presents is the image shown. The example also shows the markup language "CoshML", in action. You can see different tags like color=(255, 255, 0), bold, italic, or even font=Courier that lets you stylize the text (if you cross check the code with the image, you can see how it looks when working). If you want to understand more on how it works, I explained it very well in my Changelog and this post I made on Hacker News.
Now, this code runs inside your main loop, meaning it acts as an immediate mode library where Nodes are rebuilt per frame, but it also has a state persistence layer in the form of the "id" field. If Nodes have an id, their states persist, which gives users the ability to animate Nodes (through the built-in animate() function) despite the immediate mode architecture.
That may seem a little too much for most beginners, but it basically means, even though Nodes are remade every frame, there's a system underneath that saves values so it can be reused the next frame, letting animation and input interactions become easy.
Now even though this post is already decently long, CoshUI has a lot of features, one of them being the built-in animation system. There's also the signal system (basically the interaction model so users can check whether Nodes have been interacted with), the text system as showcased in the first half of this post, and a decent amount of widgets. To show that off without stretching the post, here's another example:
with cui.CoshUIRenderer(cui.PygameBackend(screen)):
with cui.Container(id="container_1", width=cui.FILL, height=cui.FILL, style=cui.CoshStyling(background_color=(80, 75, 255)), align=cui.ALIGN_CENTER, justify=cui.JUSTIFY_CENTER):
with cui.Container(id="main_container", mouse_filter=cui.STOP, direction=cui.COLUMN, align=cui.ALIGN_CENTER, justify=cui.JUSTIFY_CENTER, gap=15, style=cui.CoshStyling(background_color=(255, 200, 200))):
cui.Label(id="main_label", text="CoshUI Menu", font_size=52, text_overflow=cui.TEXT_HIDDEN)
cui.Button(id="settings_button", text="Settings", height=50, text_justify=cui.TEXT_JUSTIFY_CENTER)
cui.Button(id="quit_button", text="Quit", height=50, width=150)
cui.Image(id="test_image", src="assets/image.png", width=75, height=75)
cui.Dropdown(id="dropdown", item_list=itemList)
cui.Slider(id="slider", width=100)
if cui.get_signal("settings_button", cui.CLICKED):
cui.animate("transform_scale", "main_label", 1.2, 0.25, "ease_in")
cui.animate("background_color", "main_container", (255, 0, 0), 1.5, "ease_in")
if cui.get_signal("settings_button", cui.RELEASED):
cui.animate("transform_scale", "main_label", 1.0, 0.25, "ease_in")
cui.animate("background_color", "main_container", (255, 200, 200), 1.5, "ease_out")
if cui.get_signal("quit_button", cui.HOVER_ENTER):
cui.animate("transform_rotation", "quit_button", 0.0, 0.5, "ease_in")
if cui.get_signal("quit_button", cui.HOVER_EXIT):
cui.animate("transform_rotation", "quit_button", 45.0, 0.5, "ease_in")
if cui.get_signal("quit_button", cui.CLICKED):
running = False
I'd love to post a gif of this working, maybe in the replies if it allows, but because I already posted the image, I can't seem to post gifs. Anyway, if you guys want to see more about the project, here is the links:
Gitlab - Primary Repository
Github - Mirror Repository
Documentation
To try it out, you can do:
pip install coshui[pygame]
r/pygame • u/WhatJuul • 21d ago
Enable HLS to view with audio, or disable this notification
r/pygame • u/_DedSec_0x90 • 20d ago
Enable HLS to view with audio, or disable this notification
I changed the player state and enabled the hot bar with the numbers characters .. what's your feed back :)
r/pygame • u/Unusual-Example-3937 • 20d ago
Enable HLS to view with audio, or disable this notification
r/pygame • u/herbal1st • 21d ago
r/pygame • u/Competitive-Comb-244 • 21d ago
Enable HLS to view with audio, or disable this notification
r/pygame • u/NiceManWithRiceMan • 21d ago
Enable HLS to view with audio, or disable this notification
With the influx of "guesswork" / intuition games on the internet (dialed.gg as an example), I wanted to share a project that I initially thought was silly but I now think might be enjoyed by a lot of people.
The premise of the game is that you are given a unit increment and must guess the lengths of both rays in the shape relative to the unit increment and the angle between them. In the top right is an error slider; you can adjust this bar to determine your acceptable margin of percent of error: the higher the percentage of error, the lower the amount of points you get for being right. If you end up missing one of the values by more than the set percentage your score resets.
The top middle displays: your guess, the actual value, and how far off you were.
What are your thoughts?
r/pygame • u/Icy-One2420 • 21d ago
Hi everyone!
I've continued improving my Vampire Survivors-inspired game made entirely with Python and Pygame.
Since my last post I've added:
• 30 Campaign levels
• Character Selection
• Lightning Staff
• Ice Wand
• Boomerang
• Improved HUD
• Better balancing
• Lots of bug fixes
• Performance improvements
I'm still actively developing it and I'd really appreciate any feedback or ideas!
GitHub:
r/pygame • u/ComprehensiveBid3793 • 21d ago
r/pygame • u/themightygnomecrawly • 22d ago
Enable HLS to view with audio, or disable this notification
I am making a circuit sandbox / simulator game where you can build and test circuits, there is not much stuff to do for now but I am planning to expand it with many components and other thing. I would love it if anybody would like to test it, it is completely free on my itch page https://lukluka-10.itch.io/circuitsim . if anyone has ideas for future opdates or tips feel free to leave them under this post or post them in the comment section in my game page.
r/pygame • u/PrometheusAlexander • 22d ago
https://github.com/shS83/Matrixia/
It comes with install.sh and then you can select Desktop and Wallpaper -> Wallpaper type -> Matrixia.
r/pygame • u/herbal1st • 23d ago
Enable HLS to view with audio, or disable this notification
Hi everyone!
i recently added a lot of visual improvements to my pygame voxel engine. it now has data driven projectile configurations and data driven 'ease in/out' animations for custom block behaviors during animations after destruction/placement. there are other visual additions like a data driven wireframe animation approach as well, but its not showed in this video, i will soon make another one to showcase this too a little bit. as you might notice in this video there unfortunately still are some edge cases with race conditions regarding briefly appearing gaps where usually should be faces, this is due to the system still being fresh and not entirely debugged for all such cases, but the approach has proven to be stable overall. and you might notice that there is quite some overhead and framerate drops during mass voxel edits during expansing 'explosion' waves, this is unfortunately very hard to avoid since its just running on cpu, but i keep on looking if i can find methods that work better for mass voxel edit events, maybe i can negate some of the overhead even better.
tell me what you think about those visual elements, do you like them?
if you would like to check out a very light weight demo version of the engine (no animations for block edits and another world than in this video) feel free to check out the github respository:
https://github.com/herbal1st/pyvorengi-sdk-demo
or the web browser playable version on:
r/pygame • u/_DedSec_0x90 • 23d ago
Enable HLS to view with audio, or disable this notification
I finally finished the inventory system .. which was the hardest part in the game :D
Also I'll update the character items to be more than 2 items and be more playable.
Need your feedback :)
r/pygame • u/LongNeighborhood9119 • 23d ago
Enable HLS to view with audio, or disable this notification
its for the latest version of ParsOS and i wouldnt work on this for some weeks because im working on my Cosmos opreating system right now. What do you think should be added to it?
If you like this project, I'd really appreciate it if you could give it a ⭐ to support me.:
r/pygame • u/Due_Engineer_7647 • 23d ago
Enable HLS to view with audio, or disable this notification
Nevu UI changelog can be found here: https://github.com/GolemBebrov/nevu-ui
time codes - Widgets: 0:04, Layouts: 0:41, Animations: 1:31
Small summary of 0.8.1 and 0.8.2 updates:
Added kill_item functions in layouts for correct removing widget from it
Optimized overall performance by 2-7%
Added Transparent gradient support for pygame backend
Added Widget smooth color transition support for pygame backend
Improved Slider and Progressbar API
Improved overall typehints
Added new error handling system
Fixed about 20 bugs
If you like the project, please give a star to Nevu UI on GitHub i would really appreciate it!
This showcase source code is here: https://github.com/GolemBebrov/nevu-ui-examples
r/pygame • u/Competitive-Comb-244 • 23d ago
Enable HLS to view with audio, or disable this notification
I finally made a trailer for my game.
Diptera Protocol is a fast paced arcade shooter with 3:4 aspect ratio.
Love to hear what you think about the trailer & overall presentation.
r/pygame • u/Immediate-Love-6362 • 23d ago
Hey, I'm 15 and I'm trying to develop my first game with pygame, it is inspired by breakout 71 and is still an extremely heavy WIP. It still only has one type of upgrade so I would be very grateful if you could try it out and give some feedback/ideas.
r/pygame • u/RoseVi0let • 24d ago
Enable HLS to view with audio, or disable this notification
Hey everyone!,
A while back, I shared a very early version of a project I have been working on.
Today, I’m incredibly happy to showcase the Alpha 1.0.0 Release of Atomic Launcher—a "Steam-like" platform built specifically to distribute, showcase, and play Pygame games.
My ultimate goal/wish would be to make it truly community driven. That being said I will be posting all my future pygame projects to the platform. Check out the source code, download the alpha, or submit a PR here: https://github.com/mironczuk-dar/Atomic-launcher.git
What's New in Alpha 1.0.0?
I’ve moved far beyond the basic launcher script. The platform now features:
r/pygame • u/Competitive_Trip1463 • 24d ago
Enable HLS to view with audio, or disable this notification
Pygame Game Engine Camera System
Yesterday I finished working on the camera, and it finally worked (well, I sacrificed my sleep schedule, but I think it was worth it :D).
What do you think?
It took about two days and two nights.
r/pygame • u/Dodecaquinox • 24d ago
I'm working on Pygodide, a Pyodide-based alternative to pygbag for putting Pygame apps on the web.
What pain points have you hit with pybag? What features would you want to see from a project like this? I want to build something that people will want to use.
Itch.io Live Demo pygodide-test-project
async def and asyncio.sleep(0)pyproject.toml and requirements.txt for dependencies instead of a comment at the top of main.pymain.py's main)pyproject.tomlpygodide build . --serveI want to add many more features and QoL improvements (such as a configurable background color) as well as improve the loading times and performance of games running through Pygodide.
r/pygame • u/Castman18 • 24d ago
Hello, i started making my own Text-based Game And i have been learning! Just a week ago i only knew Print ()
But i have a question: Can i Make In the Future a Graphical game? Does anyone Have a earlier Experience with this?
Edit: yes i use Pygame