Shader edition/gedg/ Wiki: https://igwiki.lyci.de/wiki//gedg/_-_Game_and_Engine_Dev_GeneralIRC: irc.rizon.net #/g/gedgProgress Day: https://rentry.org/gedg-jams/gedg/ Compendium: https://rentry.org/gedg/agdg/: >>>/vg/agdgGraphics Debugger: https://renderdoc.org/Requesting Help-Problem Description: Clearly explain your issue, providing context and relevant background information.-Relevant Code or Content: If applicable, include relevant code, configuration, or content related to your question. Use code tags.(Actual) Previous: >>106658977
Interface re-ordering, stacking, focus/unfocus
>>106843272wow your UI looks good>>106843063and really cool menu too.Good stuff Ygg, you get my gold star for the week
>>106843272Looks very nice.
Attempting to convert all the collision code from float to double again.
you will never be a video game
>wake up>work all day on game development>get off work>start working on my own game>go sleep>repeat
>spend all day trying to find out why all the meshes in a model arent translated correctly>realize i didnt give them a slot in the descriptor tablemfw
>>106845588living the dream
>>106845588Why the FUCCCwith a triple capital care you sad about that
>>106845683that's him being happy
How do you guys handle materials and such? My current plan is:>Material Pipelines which are just wrappers around Vulkan pipelines, stuff like Material_Opaque, Material_Translucent, etc. with each one having its own constants struct (and possibly others)>Material Instances (or just Materials) which contain a handle to the pipeline etc and an instance of that constants struct with per-instance data>you just do Material_Pipeline.make_instance and pass your constants struct instance etc and get back the instance
Is Java the best choice if I'm building a game with 2d tile based graphics that uses multiple OS windows at the same time and don't want to have to waste time writing custom GUI code? I've researched all the different alternatives like SDL and they all seemed to be designed to work with the game being confined to one window. Will I run into any performance issues with Java 2d graphics APIs if I'm only targeting modern PCs?
>>106847127Just use C/C++ with the win32 api, and use the default windows API for handling user interface. Even Java or C# might work because I think they do support Win32
>>106847265I don't want this to be restricted to one platform. I want it to run on Linux, Mac OS, and Windows out of the box without having to do any extra porting work.
>>106847127Im not sure but couldnt you do something like this with wxwidgets and C++? I think wxwidgets is able to expose a GL context for rendering.
>>106847279Would it be fine if the entire game is in a one big window but inside that window you can have sub windows like transport tycoon?
>>106847127Python is another option. If you can do a bullet hell then you should be fine for most cases?
>>106847503Lol. Add me to the thread enemy hitlist too.
>>106847279>I want it to run on Linux, Mac OS, and Windows out of the box without having to do any extra porting work.stupid goal
>>106847127What makes you think SDL is not suitable for multi window applications? Genuine question, I have never worked with SDL and am using GLFW for window creation which has a lot less features than SDL, and with it creating more than one window is trivial. I can't imagine SDL being much different.
>>106847503Add me to the list too. I'm a transgirl dev.
>>106846088assuming they all use the same vertex format and only differ in textures and some constants, then i handle them all in the same rendering pipeline. I predefine all the materials to use and put the textures in a big array on the gpu (the bindless approach).During rendering I pass an index along with the instance to tell it which texture to use
IHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYIHATEUNITYbloated piece of shit why does it fucking exist if only godot was a good engine then i wouldnt be forced to use this piece of shit fukcingh software
>>106847127Pretty sure you can have multiple windows with SDL. And you definitely can with Qt, which also has some helpers to give you an opengl context that draws into a canvas you can use alongside the other widgets.Or, with Dear Imgui you can have multiple sub-windows that draw inside your main window, kind of like old MDI programs.
>>106848752fuck this im restarting the project from scratch and building my own engine from JS and if anyone has a problem with it they can kiss my ass. And if any script kiddie decides to cyber rape me then I guess I'll have to keep cyber vaseline on standby
Fixing float imprecision issues again. Hopefully for the last time.
legitimately considering making a coomer game rn
Starting to wonder if I should just mod existing games instead of essentially making clones of themAll the games I want to make would just be clones
>>106849708easy money until visa and mastercard comes knocking
the keyboard can sample any node audio you put in it
>>106848633Yeah sounds like we have more or less the same setup then. Seems to be the best way to go about it.
I hit a terrible dead end. I'm very upset. I think I'm going to leave this for tomorrow.>>106850806Very good looking UI. I'd like to see this webm with sound.
>>106851632thanks, I have the little video at least lolhttps://www.youtube.com/shorts/YaY0S9UnU2k
I spent time working on enemy distance targeting and added and check that compares distances between enemies and the player and always targets the closest one as the first. It also has a max distance float that may tag actors but wont add to the array of targets if beyond the float threshold.
>>106851857That's nice, but it's not enginedev is it.
>>106852109No but while I am a ue5 shitter the uhh other places to discuss this specific stuff is not going to happen.
>>106847279if you wanted your code to run on mobile, your only sane choice is html.I say that, because nobody gives a single shit about apple or linux. The number of mobile users is massive, and gen alpha prefers all games being on their phones.
>>106843063I'm officially burned out. It's joever.
Considering some gamers are having an exodus from windows to linux rn, I think I'm gonna target linux (along with windows)However, linux support for unity or unreal, at least the editors, is shit, so I guess I'm gonna enginedev
>>106852805that's a bold statement when the steam hardware survey says 95% of users are using windows, and linux grew by 0.04% this month, and a pretty large chunk of those users are on a steamdeck (not a usable PC, closer to a phone OS than windows handheld's, not trying to say that windows handhelds are better, but if you plugged it to a monitor + keyboard and mouse, you could do everything a PC can do).Also the next steam index seems to be a VR headset.
>>106853387i think we're at the start of it where the growth is not strong enough yet to be noticeable in the numbers to such a large degree yet. there's just much more output from people looking away from windows to other alternatives.could be a good idea to consider linux as a primary target early now, and not try to port a few months or years into development later when the numbers are clearer.
>>106853491you're retarded
>>106853491I've used linux for years coping that it's good for programming (windows 7 until 2019, tried linux until 2022, now I just use windows 11 without updates), but I can't really make a list of reasons for why linux is better for gaming or programming.At the very best, I think using linux is a flex, and it's comfy when it works. But in terms of actually saving me time, linux is a huge waste of time (especially when you can still make portable code on windows, you could use WSL if you wanted to save SSD space instead of a dual boot).There are like 40 things I need to fix on a fresh windows install to make it useful, but that's nothing compared to the autism that C/C++ has for you, especially when it comes to making portable code (and I feel like the #1 reason someone engine dev's is because of autistic languages like C/C++, if you use JS or C#, it's basically the same language as Unity or Godot, while no language support C/C++ as a first class language, unreal doesn't count BTW).
>>106852805>I'm gonna target linuxWhy do people think porting a game to another platform is some big thing that only elites can do?
>>106853954>Rad Games (from Epic) is porting their entire tool chain to linux>RadDebugger is coming to linux>Valve is working hard to solve the distro problem>We have a professional gaming handheld running linux This is all cope?
>>106854513The only thing that matters is "% of people playing games on Linux"
>>106854518>The only thing that matters is "% of people playing games on Linux"So you know better than the people making decision at Valve, Epic, Rad, etc
>>106854535Appeal to authority is a pathetic argument bro
>>106854560Read it again.
>>106854603You're appealing to authority, yes, it's patheticUntil people are actually using Linux to play games it's meaningless
>>106854609Read it again.
>>106854560>>106854609It's a simple yes or no question, do you know better than people working at Valve, Epic, or Rad?
>>106854686On some things, yeahBut that's not even relevant, they're trying to push Linux adoption, that doesn't mean it's going to work
>>106854698>On some things, yeahThat's not the point. Do you know more than the people making decisions at Valve, Epic, Rad or stuff "relevant" to Linux as an alternative to windows?
>>106854815>or*on
>>106854815Not neccessarily, but they're pushing for adoption, adoption is not yet hereUntil adoption is here there's no reason to even think about it
>>106854842>but they're pushing for adoption, adoption isWrong, they are actively working to make Linux better for adoption. None of them are saying, bro just switch to Linux. Each of them is working on a specific problem and iterating on solutions. >Epic/Rad is focusing on the developer environment>Valve is focusing on OS level services
>>106854958Ok, so what? The point remains
Live.
>>106852535>if you wanted your code to run on mobile, your only sane choice is htmlIt's the same thing as running on wasm.You can compile to native and just have onclick and keydown and draw buffer and UI stuff like that abstracted to app language
>>106852535>a game in html...a website?
instanced sdf drawing bumptotal polygon death soon
I added a pool it make everything so smoothhttps://github.com/SpaghettiCodeMasterThe/Godot-quadtree-terrain/tree/main
>>106856403It's not sane because debugging wasm is not fun and supporting both a native and wasm toolchain is not sane (it is fun, if you want a challenge).I personally think UI is a big issue for games, and C++ does not have many options that work well with a mobile UI, how does imgui work on touch screens?
>>106858000Sounds awesome. Need to see a .webm of this.
>>106843063>43594rune-server name?
>>106858031I see cracks at the lod transition!
>>106852805win32 is the only stable api. Target that and make sure your game runs with proton and it will work better on linux thatn 99% of games with native linux builds. Even valve can't manage to keep there old linux builds working.
>>106858000Impressive, very nice.Lets see a complex mesh.
>>106858000>sdflike this is ray marched ?
>>106847127>Is Java the best choice if...No
>>106858567in the future we will all be using linux because windows has gotten so bad but all the software will actually run on wine with dxvk because open source autists just could not agree for the life of them on a single sane API and a stable ABI for doing basic desktop stuff that any graphical application would want to do. glibc developers will still go "hurrrrrr not my problem WONTFIX/INVALID" any time they make a breaking change and it will still be used by SkibidiRizzlerOS (modded arch linux) so companies will just invest a lot into wine and make their own libc for it to have a sane deployment environment irrespective of whatever distro autism the user's machine has.
>>106858092nothing special at all.but it runs perfectly smooth on my many years old gpu which is good enough for now.focusing on rigidbody dynamics and sdf collision check.>>106858641yes but instanced with depth test between so it's not a big union which would be way too slow.>>106858619>Meshno such thing. but i'm gonna try more complicated shapes and more bodies soon.
>>106858907Awesome.
>>106858805I honestly would love to have my phone as a OS, and I just plug it into a dock when I need a PC, and I can get calls on my PC.the closest thing to getting calls on your PC ATM is by using the windows phone link, there are handheld PC's and laptops with sim card trays, but it's ONLY for internet, no SMS or calling.just a few changes to android or IOS, and honestly, it could run 99% of all desktop apps and even dev tools (even right now it could, with winlator or mobox, but it should be part of the OS, and the filesystem needs to be opened up).
>>106859154The issue is a modern pocketable x86, we have mainline ARM actually. PMOS, droidian, SFOS are all mainline. If you still needed apps you can use use waydroid. Otherwise you can patch your own together from debos-builder recipe, or raw debian with ofono and no hw acceleration. Thats pretty much the landscape.
>>106859282I don't know what you are saying, but I looked at waydroid and it turns out that someone was able to put cellular into it. So I guess it's possible to get a phone in a VM container on linux.The problem however is that the mini-pcie LTE adapter costs $70 (with messaging, I assume GMS is for voice and GPRS is for texting and 2.5g), and I bet 5g is just proprietary and exists only as raw chips since nobody wrote drivers in x86, and of course this would not fit into a pocket, and I have not looked into how ISP services behave when you put a sim card into something exotic like that, and I would hope that the data is usable by the host PC if the internet went out (... maybe you can use windows + WSL + phone link?).https://forums.quectel.com/t/android-ril-and-gnss-driver-for-android-13-on-x86-64/31970
What math do I need to know to render isometric tiles with different elevations like in simcity or transport tycoon? Any code examples of this kind of thing?
>>106852805>Considering some gamers are having an exodus from windows to linux rnLmao never change Linux fags
>>106859870there is ancient code scattered around the internet, but unity has gotten so good that you could find a shader that just makes everything look retro, and just make everything 3D, and then you wont need to worry about animating 8 directions of a car, you could have smooth rotations (the secret is that you need to find the right pixel resolution that makes the models look the best with the outline shader and just upscale it when you zoom into it, a good example is VRchat Neo Worlds, which is 3d turned into isometric), and then you can add another shader for drawing outlines hidden behind walls since you can rotate (you can make cliffs, because sim city can't display cliffs without blocking stuff, which is annoying, so you don't need to write the code for special anti-cliff map editing if you wanted to real time editing).The easy way with unity is a height map and paint it with tiles (it would look kind of like shit), and then you could make it complicated if you want cliffs and tile set rules so that water has a smooth edge around the coast, and smooth sand/grass transitions. You could also try a voxel approach, lots of examples of that.Obvious this requires a lot of engine dev code inside of a game engine that you would normally avoid doing all of that in. So it's not trivial, not a lot of examples, but it is generally worth it at the end.
>>106859870Just multiplication and division
>>106860048I think getting something like that to work on Unity could be just as much work as just getting it to work on SDL2.
>>106860357It isn't because in unity that's like copy pasting code from 3 projects, and maybe paying for a plugin. I think someone with zero programming experience could figure it out by brute forcing through all the build errors.No need to reinvent the wheel for isometric when there are examples that exist to be copied.
>>106858547I will close the crack, I get the neighbor heightmap and interpolate
>>106859870I don't think it's code if you just use the same tile heights for the height right? Colliders take care of the rest?
>>106860048>but unity has gotten so good that you could find a shader that just makes everything look retro, and just make everything 3D, and then you wont need to worry about animating 8 directions of a car, you could have smooth rotationsliterally soul vs soulless as thinking
>>106859870>What math do I need to knowBasically none. Just draw a bunch of terrain pieces, then paste them together in the right order.
I know this isn't really the place to ask about this, but there isn't a thread on /v/ up like this.I need an idea for the story of my game without just ripping off an idea from it's inspiration wholesale. (maybe need is a strong word)It's a procedurally generated first person dungeon crawling RPG in a similar style to Daggerfall or Arena. I'm just looking for a story justification for giving the player character a call to adventure, and give them a reason to travel all across the world doing dungeons.Arena had the idea that you need to assemble the eight pieces of the Staff of Chaos in order to defeat Jagar Tharn and save Emperor Uriel Septim. An idea taken pretty blatantly from Legend of Zelda now that I spell it out like that.But yeah, I just want to know if anyone else has some fun ideas they want to put out there. Like I said, it's procedurally generated, and very low fidelity in terms of graphics, so it can't rely too much on in-game events or pre-placed set pieces.
>>106863203why would i give you my 3 billion dollar ideas for free?
>>106863210because I'll put your post number in the credits.
>>106863203Collecting the eight golden sticks and fulfill your destiny by assembling the mighty golden faggot.
>>106858000>instanced sdf drawing bumpcan you explain in detail? I did a sdf modeller but paused it because performance sucked when using over 100 shapes. Mostly read from a buffer and had a index to terminate the loop and different shapes/color ids which were all generated at runtime, using cone tracing it lagged a lot on standard igpu hardware so I stopped working on it.
>>106864060This only works if you have many SDFs that you want to draw as objects in a scene but they are indepenent shapes not part of a common csg tree.The main benefit you can get then is instead of doing a min over all shapes per pixel, just do the one shape's SDF within a screen space bounding box.Write the ray hit depth to gl_FragDepth and the depth test will make sure your overlaps are correct which looks the same as doing a min or union over all per pixel.
>>106858567ironic considering linux as a kernel has a stable API/ABI
>>106865904The kernel ABI is stable, glibc mostly is, but the things you need to build a GUI program are not. X11 is deprecated and being removed from distros, Gtk and Qt both experience breaking version churn every few years, pulseaudio is being replaced by pipewire, et cetera.Unmodified source for 20 year old Linux GUIs will almost certainly not work today, but likely will on Windows.
>>106865942>>106865904>>106865222>>106864060Is vibecoding worth it
Anyone using KTX2? Why are there no decent libraries for it? I'll write my own simple importer but still, does Khronos want people to use it or not? >libktxBloated mess of C and C++, like 25 files. Just give me a single C header for God's sake.
If I posted the C++ code for my spatial hasher, could anyone tell me what's wrong with it? It usually says there are no colliding objects, even when there are. It's also REALLY slow when in debug mode, although release mode works fine.
>>106867294post it and ill at least take a look
>>106867504Thank you.https://hastebin.com/share/ejehewaxoj.cppI think the problem might be with the getID() function. It gets the four corner buckets, but if the object is large enough to span multiple buckets, it won't get any of the ones inbetween. It sometimes also adds objects into buckets that are far away for some reason.
>>106867577well it looks like, in getCollideObjects you have some code i dont think compiles, the for (int id : getID(object)) should be something like for (auto [id, cells] : getID(object))and for getID, youd need to loop between min and max by however many times the width/height of the object fits in that range. also i think you need to do some clamping to make sure you dont get some silent "out of bounds" errorsworry about the speed after it is correct