Cyber Game Engine
- 18 Devlogs
- 57 Total hours
Tiny 3d game engine made in python and pygame
Tiny 3d game engine made in python and pygame
Final touchups before demo ship!!!
You can now give the option to make some NPCs pushable. NPCs now have wall collision and player collision is reworked so you dont “stick” on walls anymore.
Ive added a a few things like “dynamic” lighting and html documentation. Ive added some keyboard controls to the engine like moving the map with wasd. I changed some buttons around a tad and the gun works and sends NPCs a message (only one right now is die, but more flexibility soon). A demo ship might be coming soon maybe.
Today is the day I realized I had to lock in in order to get the stuff I want. So, I have done quite a bit in that case like: The floor darkness is fixed, NPCs can be pickup items (kinda, only the gun is supported), very basic tool/weapon support, shooting with the gun and having it detect NPCs, starting the documentation page, lots of stuff behind the scenes like moving the map around with WASD, and a measuring tool for the map. The only problem (that bothers me because there is a lot of problems) Im having right now is the fps tanks when there is flooring. I tried to optimize it but that led nowhere. So you can disable flooring in the settings.
I have added some stuff that is major. I have added FLOORS!!!!!! Using the same type of code for the walls but a little different, we can get ourselves some floors. I also added a toggle to swap between adding floors and walls (that W button) and you can see the floors behind the walls in the grid. The floors are slightly optimized to disappear if they are far too. They also support darkness. NPCs also got some stuff done too. they can move toward the player (and phase through walls) and there can be multiple NPCs.
I honestly dont remember what I did the other day except that I made the npc disappear behind walls and some y pos stuff with the npc
I have not been working on these projects in a while because I found out that Terraria exists but today I have spent many hours working on both projects. Things I have done today: I finally started working on the NPC `s (It works, and I had to look WAY back to my old raycaster on scratch to figure it out lol), More stuff with the scripts (for the npc), Doom like hand (that bobs when you move), Done a alternative way to test the game your making without future problems (hopefully), Object/NPC panel (buttons dont work yet),Still under 1.44mb :) . Things I am going to do: Finish NPC, Fix some problems with the IDE, NPC Waypoints (Inspired by NZ:P), Audio scripting (so you can call when a sound should be played), Maybe NPC collision, Weapons/Tools support, Possible flooring/ceiling and more of the 3rd dimension instead of the raycaster feel (this is not a raycaster), Ingame guis, Win function, Keep this below 1.44mb, try to figure out how to use the formatting stuff on this website to make this look good. More development stuff here (might need to be updated): https://cybrock9000.github.io/CyberWolfGames/engine.html
I HAVE FIGGURED IT OUT!!! I HAVE MADE THE RENDERING FAST!!! Turns out I was checking every step that the ray moves (which is about 250) for 20 rays (5000 checks) for each wall (if its 10 walls, that is 50000 checks) which is very hardware expensive. I solved it by just doing one check per ray by firing the ray and checking it once (for those same stats above with this new method, it is 200 checks WHICH IS HUGE!!!). And that means that the is near no limit on how long the rays are. And now the games the engine makes are a smooth 60fps (uncapped is roughly 175-200fps) and before with the same map and settings it was 7-30fps. The engine will default the ray count to 30 with a ray dist of 500. I have also started working on the .cy script (top right pic) to make life easier doing coding for the engine to make your game. Right now it only looks for player.cy but I will have it load all in the scripts folder. The IDE that I am working on for this now can load and save files, it loads what words to be in color by loading a .json file, and you can scroll. My next steps are to work on the scripts and figure out objects/sprites (2d objects in a 3d world, look up Wolfenstein 3D to see what I mean). I also need to update my website to include documentation on how to use this engine (https://cybrock9000.github.io/CyberWolfGames/index.html). I would like to also polish up the engine too by making it more satisfying in some areas and also add button mappings to the map grid. With all that said, I am really happy on where this is going and I am still happy to say that this is still under 1.44mb :). -Cy
So its been a while since my last devlog and I have done not that much (I was busy and burned out), so Im going to talk. I have created a custom code editor that just handles the basics so far. Like: Writing stuff, multi line stuff, custom color pallets for fun and saving. This new IDE will help program in the custom programing language (when I get to that point). I need to figure out how to make the 3d rendering faster because right now it runs on an average 17-30fps (with no cap) when its near some walls. I am happy if it stayed at 30, but sometimes it drops to 7. Im thinking on executing this by some way of multithreading/multiprocessing or find a more optimized way to do the raycasting (which just checks to see if you are looking at a wall). One of the things that I am really stuck on though is putting the 2d sprites/objects/npcs into a 3d world. I have an idea on how to do it but putting it into code is tough. But even though I have a lot to do, Its still under 1.44mb
I have been working offline quite a bit and done quite a bit:
I wont be posting that much because of my internet being out but i am still working on both projects :)
I`ve done some stuff the past couple days:
if you are interested in pics and vids please look here: https://cybrock9000.github.io/CyberWolfGames/engineDev.html
today I had a lot of free time that I spent working on this project, here is what I have done:
*screen smoothly scales to correct size instead of instantly being set to that size
if you are interested in this project more, I suggest looking at my website to see cool pics and vids: https://cybrock9000.github.io/CyberWolfGames/engineDev.html
Today and yesterday i was a little busy but I did get stuff done:
*Starting to do the script logic for the user to make custom events and other cool things
*possibly faster rendering (haven’t fully tested)
*still under 1.44mb
*mouse inversion option for scrolling the scripts
*lots of backend stuff
If you would like to see the whole development process with videos and pics, the link is here: https://cybrock9000.github.io/CyberWolfGames/engineDev.html
The things I have added to my game engine today:
I have fixed the map grid cursor and implemented drawing walls.
I made it possible to change the wall color in editor
Changeable map grid cursor speed
Other little tweaks
Things I still need to do:
If you want to see more pictures and videos, please look here: https://cybrock9000.github.io/CyberWolfGames/engineDev.html
I have gotten a lot of stuff done today: worked a lot on the map grid, wall occlusion using raycasting, being able to turn the project into a exe, and some QOL tweaks! If you want to see more pictures and videos, please look here: https://cybrock9000.github.io/CyberWolfGames/engineDev.html
little look at the progress right now. I have added some settings and other buttons functionality’s. I fixed the map grid to properly show the map and added zooming to the map grid. I am planning to fix the way the 3d renderer renders walls eventually. If you want to see more pics and vids, please visit here: https://cybrock9000.github.io/CyberWolfGames/engineDev.html
worked on the little viewport that shows a 2d version of the map with accurate wall sizes and colors. and added controls to move the map and zoom in and out
3d rendering of 2 walls