a51b75 No.15154579
"Reminder that next Demo Day is August 8th
Resources
>>>/agdg/
>>>/vm/
>#8/agdg/ via irc.rizon.net
>Dev resources: http://8agdg.wikidot.com/resources
Links
>Wiki: http://8agdg.wikidot.com/
>Beginner's guide: >>>/agdg/29080
>Previous thread: >>15118977
>Sister thread: >>>/vg/27335
Announcements
>Next demo day is scheduled for August 8th. You DO have a game, right anon?
>Please contribute to the wiki if you can
092aad No.15154618
Blender model+animation import
55108b No.15154628
Newbie game dev here, I will make a simple game and upload it as soon as possible. I want to make game, I don't care how bad it will be. I just want to make game.
e58c21 No.15154696
>>15154628
Just make an Arkanoid clone or something to get the groove.
a74c06 No.15154801
>>15154628
>>15154696
I would advice against making it for android, add basic controls and see how it goes, remember, design gameplay first, then the art.
ba478c No.15154813
YouTube embed. Click thumbnail to play.
>>15154628
I honestly don't think this is a good idea. Make the game shit, sure, but at least fill it with enough stuff that you'll get to experience all the necessary steps of gamemaking while you work on it. From concept, to prototyping, to art and music.
Vid related
bb46c5 No.15154904
Editor's getting there. Last big things are making selected object parameter editing work with undo/redo history, multiple selections at once and picking a tile in texture atlas for things like walls and sector surfaces.
caa8af No.15154907
>>15154628
Do a Snake clone
043657 No.15155026
Is it possible to import a skeleton into Godot and then animate it or do I have to do the animations in blender, then import them?
a792b6 No.15155033
>>15154618
is this minecraft?
ba478c No.15155037
>>15155026
Why would you ever want to animate in godot, an engine that has nothing to do with animation when you can do it in a program built from the ground up to do it?
I mean I guess you could look into procedural animations.
a74c06 No.15155039
>>15155026
Unless Godot has the tools for that I don't think so, what are you trying to do? does your model have a unique skeleton? you could use Mixamo's auto rigger and get some free animations.
caa8af No.15155055
ba478c No.15155096
YouTube embed. Click thumbnail to play.
I added iTween to my project in Unity but I'm unsure how to create visual paths with it
Anyone know how to get this to work?
Do I have to download vid related separately? The files are 8 fucking years old
043657 No.15155267
>>15155037
>Why would you ever want to animate in godot, an engine that has nothing to do with animation when you can do it in a program built from the ground up to do it?
Good point.
To answer your question it's just personal preference. importing/ exporting things to various programs always seemed messy to me. I like to keep everything in one place.
Godot does have an animation node and seudo 2D bones so I thought it would have 3d bones to.
9db1af No.15155291
>>15155267
You could theoretically animate 3D bones by keyframing bone transformations, but there's no visual editor yet. Much better to animate in a modeling program and import.
6d0164 No.15155383
Shit I'm always late for posting my progress. Reposting just one video.
>>15154904
That's cool man. I did something similar a few years ago. Looks strikingly similar. Good luck.
a74c06 No.15155392
>>15155366
So, what kind of game is the "notShinobu Simulator" ?
6d0164 No.15155399
>>15155392
Not really a game it's just a fuck around sort of simulator. Basically a tamagochi is what I'm aiming for. There are things to do and actual games within like chopsticks but really it's more of a chill out sim. I'd like to eventually add things to explore with her and what not.
b97940 No.15155430
Just whipped these up today, 8 tris a piece. This in total is 1000 tris + 2 for the ground.
Been looking into limitations of the PS1, N64 and Saturn, and after looking at what Spyro could get away with, using these over sprited foliage while still fitting within those limitations wouldn't be out of the question. The stage is a flower garden, so the extra detail is worth it, I think, and the actual stage geometry doesn't have to be too complex.
0726a5 No.15155434
>>15155399
Can you at some point explore her ?
6d0164 No.15155487
1e1230 No.15155608
I'm beginning to think that the portal clipping tutorial I am using only accounts for a map where all of the polygons are facing inwards and none of them face outwards into a void. The code keeps failing everywhere and the test program doesn't have this case in it. So I am wondering… but I just might have some other bugs in my code that is causing all of these errors to happen.
c4c368 No.15155662
>>15155608
So what's considered a "portal"? I'm taking it to believe it's some kind of depth window, and not like Portal portals
62801f No.15155742
>>15155608
what the FUCK are you trying to do?
6fe0c1 No.15155753
YouTube embed. Click thumbnail to play.
>>15155662
Nah, they are actual portal portals. Watch embed related.
>>15155742
Lurk moar.
4c583b No.15155763
Teleports behind you
NO, WAIT, TOO FAR BEHIND YOU
1e1230 No.15155768
>>15155753
>>15155742
A portal is a polygon that represents the border between two leaves, where a leaf is a convex hull of polygons that make up the leaves of a BSP tree. By building a set of portals I can calculate a PVS.
See:
https://www.cs.utah.edu/~jsnider/SeniorProj/BSP/default.htm
4c583b No.15155771
>>15155383
Neat stuff as always shinobro
c4c368 No.15155820
>>15155768
Is this technique used in modern engines as well, or are you using it to emulate older style games?
1e1230 No.15155922
>>15155820
It's not used in modern engines. The engine I am making is an old-style engine.
4707e9 No.15156268
GDScript or Mono for Godot?
453e41 No.15156294
Why are skeleton animations such a huge pain in the dick?
6a0edb No.15156329
>>15156294
If you're coming from traditional animation, believe me then I say the annoyance of having to micromanage bones is made up for via the computer handling interpolation between keyframes
abfb75 No.15156337
>>15155608
> and none of them face outwards into a void.
Logically you'd cull those in a preprocessing step since they'd never be seen.
85fc6d No.15156391
>>15155820
It's a method for culling polygons/tris. It could be used in a modern engine. What does that even mean? City of Heroes used it. Many games from 1995-2005 used it. It could be used in modern engines. If it is or not I don't know. Culling the total set of tris to render is always an issue. How to organize and cull the total set is an ongoing area of research. Portals are a reasonable way to cull interiors.
453e41 No.15156422
>>15156329
I can translate the bones fine I just can't get the skin to bind to them.
092aad No.15156565
>>15155033
No this is aggy daggy. I'm making a hacky slashy. The block terrain is just there as it is way easier to work with than polygon/bsp's, and the model is something I quickly threw together for testing. I have no intention of recreating the box-character style from Minecraft.
>>15155608
Aren't portals in BSP's just walls like any other? (Except that they render the room behind them instead of a texture of course.) I'm pretty sure if you have them sticking out of the room partially you're violating the principle of convex rooms.
>>15156368
Delicious octahedrons.
>>15156422
Where are you having the problem? In your modeling tools? Or are you trying to write code to import a model?
0eebd0 No.15156634
>want to make a tactical shooter
>That would actually take artistic talent to model, animate and design maps/scenarios
Fuck that. I'll just make a roguelite
9be841 No.15156906
>>15156634
lel. maybe learn those skills then?
653239 No.15156939
YouTube embed. Click thumbnail to play.
>>15156634
Your levels can be square grids and your characters their hitboxes if the gameplay is good. Find a minimalist artstyle that fits and people will praise you for it.
ba478c No.15156968
Anyone have any idea why my skeleton looks like pic 1 in blender, but then when I import it into unity and change the "Animation Type" to "Humanoid" the legs break and become one single bone?
6d0164 No.15156988
>>15156939
You are missing hip bones. Hip bones connect the thighs to the spine. You do not have any.
9a970c No.15156995
>>15156968
I don't think it's turning the leg bones into a single bone, I think it's not detecting the leg bones correctly and making an existing bone appear larger.
>>15156988 is a good suggestion. You shouldn't have those dotted line relationships between bones I forget what they're called exactly you should have actual bones there. Not just the hip, but connecting the arms to the spine as well.
And if it's not auto-detecting correctly in Unity you should be able to manually assign the right bones to the right body parts.
62801f No.15157008
YouTube embed. Click thumbnail to play.
>>15156906
I'm the vulkan engine fag. My primary goal is making a physics engine and employing it simply while also making a game I want to play. The whole point of me making a physics engine is because with sufficient physics you can naturally invent create a world that looks good (e.g. ray casting lighting/shadows).
There's a lot of repetitive elements in the roguelite I envision while a tactical shooter requires a hell of a lot more general gamedev/artistic skills.
>>15156939
Not simple hitboxes. Regardless of the game, I want to make everything decomposable. Characters (possibly different monsters/things) will have bones that articulate with flesh surrounding. I really liked the low-poly meshes someone posted in the previous thread. I'm currently wondering if I could make a game that's graphically basic (like an old fear game) but squeezes as much physics performance out of the engine. Think of a modern game that looks like FEAR except you can turn everything into dust (like vid related). Doing this well would be incredible but to accomplish it is bit idealistic, especially since good tactical shooters require a great deal of work in their level design which is stuff I just don't want to focus on right now.
I'm just being a dumb cunt though with all of this though since I only just implemented a sampler into my engine >>15156299
caa8af No.15157062
>>15156268
I think a component of Mono calls home., so GDScript.
The next version of Godot will have optional typing for GDScript.
ba478c No.15157154
>>15156995
>>15156988
Isn't this a hip bone?
(in blue)
ba478c No.15157165
>>15156995
>>15156988
Oh shit nevermind the thing isn't there in the original rig
sorry
453e41 No.15157255
>>15156565
>Where are you having the problem? In your modeling tools? Or are you trying to write code to import a model?
I'm using an importer that imports GLTF models.
The problem is GLTF is basically trying to be a universal format that is bloated and confusing as shit. There's tons of duplicated data and redundant references. Also it can say NON-JOINT nodes are a child of a joint. So if you're building out a skeleton you can have your joint point to random garbage as a child. I'm honestly thinking about switching formats. I only picked up this garbage because it's been made by the group who made OpenGL, is FOSS and has a blender exporter.
1e1230 No.15157301
>>15156565
BSP does not normally generate with portals, you have to create those after the compilation. It's not a violation to have them sticking out of a room partially since the leaf that that portal is attached too represents a space that stretches out from it's polygon into an infinite void. It's fine for my intents and purposes (but obviously not generating the way it should be…)
092aad No.15157353
>>15157255
>The problem is GLTF is basically trying to be a universal format that is bloated and confusing as shit.
So basically, the same as every other model format.
>I'm honestly thinking about switching formats. I only picked up this garbage because it's been made by the group who made OpenGL, is FOSS and has a blender exporter.
Why not Collada? It's also managed by Khronos, but it's a lot older. I don't know what it misses in features, but it has plenty of tutorials and libraries out there to help you with getting it set up. If you google "OpenGL Skeletal Animation", you'll find a whole bunch of tutorials using Assimp to import a model file, which also supports it. It's what I use.
>>15157301
Sorry, I'm fucking up my terminology and confusing BSP's with PVS's.
453e41 No.15157371
>>15157353
>So basically, the same as every other model format.
Obj is perfect, but it doesn't support animations. I don't know why nobody there wasn't an extension of it to do this.
>Collanda
That popped up a ton when I was trying to figure out problems with GLTF. I think theres a ton of overlap between the two. Apparently the blender exporter is broken though, at least according to this godot article.
https://godotengine.org/article/we-should-all-use-gltf-20-export-3d-assets-game-engines
From what I've read, it seems to have GLTF's problems and then some.
092aad No.15157453
>>15157371
>Obj is perfect, but it doesn't support animations. I don't know why nobody there wasn't an extension of it to do this.
That's where the problem lies. Making a model format that is just the raw vertex + element data in text format is trivial. But the moment you introduce all the complexity that animation brings the shitshow of different approaches to the same problem starts.
>Apparently the blender exporter is broken though
The blender exporter definitely has issues. For one, it doesn't support shape keys. But you can easily fix that by telling blender to simply generate in-between keyframes for you. Alternatively, people made their own exporters for blender that don't suffer those issues.
But, all in all, it does actually export a model with working animation, as you can see here >>15154618
Even if a model format is broken, I'd rather use a broken model format with a compile-able working example that has no problem importing my blender model & its animations than actually use a good model format for which there is no such thing.
453e41 No.15157635
>>15157453
>That's where the problem lies. Making a model format that is just the raw vertex + element data in text format is trivial. But the moment you introduce all the complexity that animation brings the shitshow of different approaches to the same problem starts.
I don't know if I buy that. OBJ did one thing and it did one thing well. It held mesh data. All these animation formats are trying to do 20 different things, and they're shit at all of them.
>Even if a model format is broken, I'd rather use a broken model format with a compile-able working example that has no problem importing my blender model & its animations than actually use a good model format for which there is no such thing.
Right now I'm just worried about switching over and hitting the same dead end and wasting a ton of time. Although, GLTF is still in it's infancy so maybe it's the one with more issues.
ba478c No.15157682
Unity refuses to accept my model as Humanoid no matter how many fucking times its changed and despite all the bones being there, so fuck it, I'm going to try to get IK working with the generic skeleton.
First of all, quick question, can I have IK on a generic rig WHILE also using simple animations? Most of the tutorials don't even touch on this at all so I can't find an answer.
I found this https://docs.unity3d.com/ScriptReference/Animator.SetLookAtWeight.html
A bunch of tutorials point to this being what actually makes things move.
Now what I'm wondering is, is this just for humanoid rigs? If not, how does unity know which part of my model is his Head, Eyes, etc?
Lastly, does anyone have any worthwhile tutorials for IK? This is the most extensive one I've found (https://www.alanzucconi.com/2017/04/17/procedural-animations/) but of course it does not talk about using IK+animations at all.
ac2ba0 No.15157685
>>15157682
>using unity
Well there's your problem.
fda723 No.15157763
>>15157685
Unity is, unfortunately, the most feasible engine to actually make game in
ba478c No.15157784
>>15157763
Don't respond to bad bait and shitposts
fda723 No.15157792
>>15157784
>bad bait and shitposts
It could be either, but there's a lot of schizoids here who actually believe that using an established engine is wrong.
b9f0c7 No.15157799
Do you ever just feel like a dummy?
>tfw get confused about how 8K textures can fit in VRAM because 8K textures are obviously 8GB
>Oh wait… They're 8MB
This is the second time the sheer size of gigabytes has stumped my mental midget mind.
ac2ba0 No.15157800
>>15157763
As opposed to making your own engine? I doubt it. If you're going to put in the effort to make your own game you might as well make it truly your own.
>>15157792
You're not going to make anything that stands if you walk the worn paths.
e9b81f No.15157812
>>15157799
I'm pretty sure an 8k texture would be more like 250mb in memory.
62801f No.15157820
>>15157800
Are you lazy? Why not design your own computing architecture to run your game on so you can program you game in assembly?
fda723 No.15157824
>>15157800
Nevermind, this is bad bait.
ac2ba0 No.15157827
>>15157820
Working on making Ternary a thing so we can eventually get to matrix-levels of code density. If you want to make AI a reality then you need to copy the human neural network as closely as possible and nerve cells certainly do not work on a binary level.
>>15157824
>le ebin your argument is just bait :^)
e9b81f No.15157830
>>15157820
>not hardwiring your game directly into the circuits of your own computer
You can't even call yourself a gamedev
fda723 No.15157833
>>15157799
>an 8K texture is only 8 MB
>64 million pixels are stored in 1 million bytes
except for some rare occasions (like the gamecube) textures are stored completely uncompressed, so it'd be a lot more
092aad No.15157838
>>15157799
>>15157812
RGBA 8K textures are 256MiB.
1e1230 No.15157840
>>15157833
GPU's have had hardware texture compression since 1999 and it has only become better and more prevalent since then. If any game is using 8k textures, it is probably using that compression to save VRAM.
b9f0c7 No.15157841
>>15157812
>>15157833
Oh right yeah.
4-channel 8K would be 256MB
4-channel 4K would be 64MB
Are there any good places to view differences between 1K, 2K, 4K, 8K textures in a game??
85fc6d No.15157846
>>15157255
I've been using directX (.x) files and 3d studio max files (.3ds) exported from Blender, then into AssImp converter which writes out my own binary file format. I haven't found any other Blender exporters that have worked quite right with animations, UVs, & normals.
I tried Collada a few years ago and it didn't work correctly, producing really bad meshes. Maybe it's better now.
I'm interested to hear how your work with GLTF goes. I was looking at it too, but .3ds files are working for me so I haven't spent that much time on it.
fda723 No.15157849
>>15157840
>GPU's have had hardware texture compression since 1999
Which consumer GPUs specifically?
1e1230 No.15157871
>>15157849
The first consumer card to support it was the Savage3D in 1998, and it was supported by the MeTaL graphics API developed by Savage for it's cards. Unreal Tournament even offers special high resolution textures that require the texture compression.
https://www.youtube.com/watch?v=1B1SSdSAhqY
https://www.youtube.com/watch?v=DfjZkL5m4P4
Texture compression is a hardware feature in basically every modern graphics card now, it's a standard feature and better compression formats are supported. So, it's not new at all and essentially every single GPU made in the last 10 years should have some kind of texture compression.
62801f No.15157885
>>15157871
Is this a feature that has to be activated or would graphics libraries use it natively?
Just wondering because it probably slightly impacts performance.
1e1230 No.15157895
>>15157885
You have to activate it and explicitly use it, you can even store textures on the disk in compressed GPU formats, for example. If you're using a high level API above OpenGL or something it could in theory compress the textures internally for some extra space saving. (but this wouldn't allow for the same optimizations).
fda723 No.15157914
>>15157871
Alright, that card in 1999 had it, but I'm still not convinced that hardware compression is commonplace now. I'm sure it can be performed on the hardware.
092aad No.15157937
453e41 No.15158022
>>15157846
>I'm interested to hear how your work with GLTF goes.
I'm probably going to switch. I've been banging my head trying to get skins to work for almost a month now. Everytime I lookup the issues I get Collada mixed in, because the two are so similar. GLTF 2.0 is basically looking like Collada 3.0 to me.
fda723 No.15158035
>>15157937
Yes, texture compression can easily be performed on any modren programmable graphics card, but that's different than hardware support. we're just being pedantic at this point anyway
c4c368 No.15158055
>>15157792
>Calling anons schizos
>While supporting using engines that fund the Jew
I'm on to you Rabbi Schlomo
fda723 No.15158079
>>15158055
>Calling anons schizos
The reason I call them that is because they can't separate their own thoughts from anyone else. People aggressively shitting on using engines invariably use reasons that only apply to them, without actually considering anyone else's thoughts or goals. This is different than shitting on the engines themselves, which I do all the time
453e41 No.15158124
>>15158055
Notice how he turns unity bashing into general engine usage bashing. Dudes a master of D&C.
fda723 No.15158157
>>15158124
>Notice how he turns unity bashing into general engine usage bashing
Enginefags really enjoy solving problems that have been solved and thoroughly documented. In current year + XX , the only real merit to choosing an engine for the rest of us is whether you can actually get shit done with it.
453e41 No.15158166
>>15158157
>Having bait this weak after being outed
fda723 No.15158189
>>15158166
>bait
>being outed
I make almost no money off of Unity and it's all from assets (which unity takes a large cut of)
e9b81f No.15158200
If you haven't made a game yourself, then you can't tell other people that their engine choice or dev methods are wrong.
453e41 No.15158221
>>15158189
>Trying to divert attention from his blatant D&C with how much he gets paid to shill
Easiest filter of my life. I'll keep an eye out for you in future threads.
fda723 No.15158240
>>15158221
no one can accuse me of doing anything for free
ba478c No.15158247
>>15158240
>>15158221
>>15158189
>>15158166
You guys want to maybe stop shitposting in /agdg/? This petty argument is fucking worthless and has already devolved into namecalling.
453e41 No.15158255
>>15158247
The only argument I'm having is he's trying to D&C the thread, which is why I filtered him and will do so in the future.
fda723 No.15158271
>>15158255
You still haven't explained what I'm supposedly trying to conquer. Nodevs who build their own engines?
015d92 No.15158282
>>15158200
I made pong once. Now I can shit all over your work and you just forfeited your only way of deflecting it.
c4c368 No.15158292
>>15158200
>If you haven't operated a restaurant and cooked a burger for someone, you can't call their food bad
fda723 No.15158298
>>15158292
More like
>If you haven't operated a restaurant, you can't tell someone the best way to operate a restaurant
ba478c No.15158302
>>15158292
Did you even read the post
You can criticize the game, not the engine.
By your metaphore it would be like going to a restaurant and saying they're preparing lasagna wrong
e9b81f No.15158307
>>15158282
Since we're on cooking allegories, you made a sandwich and now are telling chefs how to cook.
453e41 No.15158311
>>15158200
>>15158282
>>15158292
>>15158302
>>15158307
>The ultimate win-an-argument card in /agdg/ is "Where is your game"
>100% of the time the other person will have nothing to show for it
>Because the people who actually make games aren't arguing about semantics
b4f3bb No.15158441
>msdn is fucked
>all functions have multiple parameters with no information
>look at previous versions of the docs
>the shitty search doesn't show the functions im looking for
I have never truly hated Microsoft until this day.
a51b75 No.15158480
>>15158441
If you're even bothering with MSDN I assume you're using C#. What are you trying to look up? Since they own GitHub now, it's actually a great spot to peek at their source code, even if it's kinda bloaty https://github.com/Microsoft/referencesource/tree/master/mscorlib/system
Also, I know the previous version of MSDN, if you clicked on a class name or something, it would take you to a generic lander page for that object, and then you'd have to click class members to actually see shit
e9b81f No.15158498
>>15158480
Anyone who makes their own engine and doesn't have some kind of clairvoyance will definitely need MSDN.
a51b75 No.15158504
http://archive.is/kVG4B
Oh hey so this is interesting. Just a little weekly writeup by the Factorio devs, but they look at a few different sprite handling techniques
a51b75 No.15158528
>>15158498
I use VS 2010 C# Express Edition or whatever the fuck its called. I like it because you can hit F12 and jump to any object definition, and even if its compiled source, you can still view the header and attached docs (if any). See pic related.
Very rarely do I need to refer to the MSDN or source, since in most cases, things are pretty self-explanatory, but you do enter those weird corner cases on how to do things
fda723 No.15158561
Is the (microsoft) standard of having gigantic walls of comments actually good practice?
b4f3bb No.15158564
>>15158480
I'm using C/C++ and am trying to look up SetDIBits and GetDIBits. I don't use C# at all, sorry anon.
b4f3bb No.15158567
>>15158561
It's used for documentation. They probably have a program that looks in the source files and uploads the struct and function definitions and the comments to msdn.
a51b75 No.15158587
>>15158561
>>15158567
The Microsoft® best practices™ is to either inline XML comments above every single public-facing field for every object, or else point the compiler to an XML document to include with the binary file. Obviously, this bloats the source, but if you're making an engine/API, the separate attached file may be a good idea if you're pedantic.
Either way, self-documenting code that actually works is a good thing to aim for
fda723 No.15158595
>look over MSDN's C# code
>find contracts
So it's like Debug.Assert, but can also do static analysis when compiling? Guess there's no reason not to use it.
ceb144 No.15158597
>>15158561
Having good comments in a reliable place (ideally in the headers) is never a bad idea.
a51b75 No.15158705
Okay so here's a gameplay question that's not related to my current project, but one I'll have a few games from now (I want to just mull it over for some time, while working on somsething)
So I want it to be a dungeon crawler, party of four maximum with a first person perspective, like those old games, and grid based. Combat would be simple and round based, but I'd want to have a gambit system like FF12 for assigning basic AI.
My problem is how can I set a "timer" of sorts where it makes the players periodically return to town? I feel that having a good cycle between killing monsters and resting is ideal, so they don't clear half the dungeon heal, run down, and do it again.
>Stat timers (HP/MP); once they run out you're dead or can't make good headway. Warriors can keep going though
>Artificial timers (oxygen/food/morale/corruption); arbitrary and difficult to design around, it's a timer for the sake of it and doesn't integrate well with mechanics
The one thing I wanted to do though was have 3 different ways of affecting MP for abilities: straight regeneration, reduction in MP costs, and having a large pool. That way you can itemize and build different ways, which would affect how you can do certain things, which I think would be cool. But then, if you have regeneration in MP you can stay down indefinitely.
So I was thinking of having a THIRD resource, energy, which can't be replaced until you rest in town, and only decreases by using special abilities (or certain very rare monsters). If your energy is depleted, you can only attack or move. Thus, energy would be a long term thing for abilities, while MP would be short term.
I think I'm okay with it up to this point, but here's where I want your advice: If I let players buy food/rations, at the cost of increasing their weight (thus delaying their turn order in combat), but let them rest outside of combat to restore their energy (and a fraction of HP), do you think it would break this system?
>Want to stay out longer, so buy food
>But now I'm slower in fights
>But as I rest to recover, food is consumed so my weight goes down, so now I'm faster
e34213 No.15158715
>>15158564
I haven't used SetDIBits or GetDIBits but I have successfully done software rendering with StretchDIBits, maybe you should look at that. You can see an example of how to use it in Phillip Buck's "Handmade Quake" series.
>>15158035
>>15157914
If you don't know about this resource, here is a list of the cards that support some kind of texture compression and comply with the most basic GL_ARB_texture_compression OpenGL extension from 2000.
http://feedback.wildfiregames.com/report/opengl/feature/GL_ARB_texture_compression
And here is the extension in question:
http://feedback.wildfiregames.com/report/opengl/feature/GL_EXT_texture_compression_s3tc
If you look at the full list you can see there are 19 diffrent extensions that have "texture_compression" in the name, with varying levels of support. However ARB texture compression and S3TC texture compression are both at 99%.
http://feedback.wildfiregames.com/report/opengl/
ba478c No.15158726
>>15158705
If this is for mobile, those guys really do not care about slightly grindy mechanics.
I would personally do cooldowns, but allow players to create teams with different characters that are part of their guild.
This is essentially the Darkest Dungeon system, but it works extremely well not only gameplaywise but it also allows the player to get REALLY attached to their characters. If you want to go a mile more add some nice customization options and you'll get plenty of people addicted as long as the dungeoning is fun.
a51b75 No.15158736
>>15158726
My only real experience with crawlers is pic related, which I want day want to make a clone/successor of, but I'll keep that in mind, thanks. No mobile, PC only
ba478c No.15158737
>>15158705
Forgot to answer your actual question.
I think food/rations/weight mechanics are really really annoying. Honestly the only game I've played where they are not a massive ballache is New Vegas Hardcore mode because it's extremely easy to break if you know the game well.
But since you're planning for people to buy rations you will not be able to actually make them, so that might create a lot of annoyance.
b4f3bb No.15158744
>>15158715
>I haven't used SetDIBits or GetDIBits but I have successfully done software rendering with StretchDIBits, maybe you should look at that. You can see an example of how to use it in Phillip Buck's "Handmade Quake" series.
Yeah, thats what I ended up using. I already knew how to do use that from Handmade Hero.
a51b75 No.15158837
>>15158737
>But since you're planning for people to buy rations you will not be able to actually make them, so that might create a lot of annoyance.
Not necessarily. I know it's an annoying thing, but I don't want a player to clear the dungeon in one go, but just throwing strong things at them to waste their resources feels cheap as well; they should be able to control the rate they use resources, but still have a finite limit before they can return. I feel like this creates a rhythm to the game flow
But also, depending on how I implement it, I could eg have a Ranger or Survivalist class/ability that lets them create food from plants or monster parts maybe. Not sure how I want it to feel though, since it's still a very distant project. I think the whole issue with hunger mechanics is that they are added in as an afterthought and there's no design space to interact with them.
a51b75 No.15158843
>>15158837
Also, since it's a round based combat (think FF), weight would just end up making the slowest character go last, while your thieves and such get their first strikes in
b581e2 No.15158938
what math subjects do I need to know before getting started with programming? I don't know anything besides some 1st grader bullshit to be honest and I have to use a calculator for that..
someone give me a list and i'll get started on it
I assumed algebra (equations) so i'm learning that first
b97940 No.15158956
>>15158938
Trig.
You can probably survive without it for 2d, but I've had to use it numerous times before. For 3D, you're probably fucked without trig.
e9b81f No.15158961
>>15158938
That depends on what you wanna make and what tools you'll use. Anything with rotation or more than 8 directions and you'll probably need trigonometry, but classic games often don't rotate anything. Engines solve many problems for you and if you don't need anything fancier then that's that. 3D is obviously a lot harder in many ways than 2D.
c1c1ad No.15158971
>>15158938
The benefit of programming is that you don't have to do the math yourself, you have to know how to instruct the PC to do the math for you. Like other anons mentioned, trigonometry is pretty damn useful, but you'll also want to know vectors to some degree. You don't need to know how to make them when using an engine, but you do need to know how to use them.
Aside from that, it's very much more about being able to identify what problem you are trying to solve rather than actually solving the problem, you can find a lot of solutions to problems online.
a51b75 No.15158977
>>15158938
Simple curves, rates of change, and linear algebra have been very useful for me, but I'm somewhere between making a game and engine
ba478c No.15158980
>>15158938
Unless you get into engine devving you're probably not gonna need that much math honestly. Unless you want to get really autistic with stat calculation, but even then most of the formulas that the Final Fantasy games used are online so you can probably get the idea on how to make them work.
Trig is a must if you want to get any complex movement working, useful mostly if you work in 3D.
But really the best thing to learn to program is plain old logic.
>I'm here
>I need to get here
>What's the best route to take
b4f3bb No.15158991
>>15158938
I was literally just listening to HH where he mentions this.
https://hooktube.com/watch?v=_4vnV2Eng7M&t=5477
ba478c No.15159399
>>15159353
You really ought to use probuilder to shape your environments before making them in blender, those stairs are going to be a bitch to navigate even without the bug to travel to PUs
4c583b No.15159412
>>15159399
upper floors will not render if you are not on them
6d0164 No.15159415
>>15157682
Anon no stop being retarded. There is documentation with the bone hierarchy that you need to use in the docs. https://blogs.unity3d.com/2014/05/26/mecanim-humanoids/
Stop being retarded. The reason why Unity has a bad name is because morons are either lazy or retarded and end up doing things a different unintended way without fully knowing what they are doing. You are about to embark on a path that will make your deving 10x harder.
>>15158200
I've been an enginefag for 2D and 3D and made games for companies before. That doesn't make me any better. Unity is a good engine. Hell I prefer it over UE4 but there are lots of bad devs that use it that have no idea how game engines work. The best skill to have for indie deving is resourcefulness. If you know how to Google fu, all your problems are solved. If you are lazy even a teeny bit, you've already failed which is the majority of 8/v/ (and gamedevs on the internet) because they are all mostly college or high school kids.
8358de No.15159428
>>15159399
naw
just fix the controller or geometry
ba478c No.15159450
>>15159412
That's not really the problem here
be023a No.15159551
>tfw you implement a class between between a header file and a source file, with default parameters and a member initialization list, and compile it successfully for the first time
9a970c No.15159559
>>15159551
It little victories like this that make me happy I read these threads.
Good job anon.
0b3dd7 No.15159574
Hi all,
I'm using the learn opengl tutorial here: https://learnopengl.com/
I'm using the source code from one of the parts, and attempting to get it to compile without using the provided cmake/generated make files.
It compiles correctly without errors, but when I execute the binary, the screen's background is colored correctly, but no primitives are drawn or textured.
Any ideas on what to do here? I know that the code works correctly when compiled with the provided make file, so I don't think the source code is the issue, but how could it compile and result in very different runtime behavior?
0b3dd7 No.15159577
>>15157008
how many lines are you up to?
0b3dd7 No.15159604
>>15159574
okay, nevermind, I fixed it. Still don't know what was the issue, but at least it's over.
a991ef No.15159622
>have game idea when i was like 12
>always wanted to make it but didn't know
>slowly learned how
>didn't have the drive to do it
>spent years and years refining the plans but never doing it
>think it's unique enough since it doesn't fit in any existing genres that no one else will ever make it
>suddenly find a game that is literally exactly my idea
a51b75 No.15159644
Okay so this is how I think my minecarts will look in use. I made the color coded tracks an overlay (not shown), and created a loading and unloading zone for the carts, which I hope make sense
4c583b No.15159661
98e6c4 No.15159707
I'd like to make a game in rpg maker. I know it's not the best but for now I really want to just make progress on something and it works for what I am making right now. I have VX Ace. Are there any recommended tutorials or things I should look into? My original idea before I scaled back had two battle systems although I don't see any good example of games that do that. I don't mind limiting it to just one but if anyone has any examples of that in VX Ace project let me know.
9a970c No.15159755
456431 No.15159775
>>15159707
>>15159755
Bouncing off of that, I thought RPG Maker was hated due to the many, many games that use default art assets and do nothing new with the combat systems?
Assuming you could get a decent artist on board with something that looks interesting, is it worth it? Or does the engine itself limit you to make the same turn-based combat every-other game has, so you can't do your own shit?
be023a No.15159804
98e6c4 No.15159815
>>15159775
I think rpg maker is hated for a lot of things including the rtp assets. Although from what I hear VX Ace seems to
need extra work for some battle stuff that was easy in 2k3. I don't know specifics though since I just started looking.
I am planning to get custom art but this is mostly just a game for some close friends since it's mostly in jokes.
>>15159755
>Anon Googles so you don't have to
I can google I was mostly just looking for what other anons have used and found helpful. Thanks anon I will look through these
b3b049 No.15159817
>>15159707
>>15159755
>>15159775
RPG Maker was designed for creating a very specific kind of game, and fucking sucks at anything even slightly outside its intended use. If you stick with it, you'll waste more time struggling with its quirks than you would have if you'd just picked up a general purpose 2D engine and made an RPG with that instead.
653239 No.15159819
>>15157008
That sounds cool, I'm just saying >>15156634 doesn't need to have a AAA (or even what passes for "indie" today) presentation to make the game he wants. Everyone likes to daydream and imagine a game looking a certain way in their heads, but if your idea is solid it would still work even with ASCII graphics or 3D boxes.
>>15157849
https://en.wikipedia.org/wiki/Direct3D#Direct3D_6.0
>Direct3D 6.0 also included support for features that had been licensed by Microsoft from specific hardware vendors for inclusion in the API, in exchange for the time-to-market advantage to the licensing vendor. S3 texture compression support was one such feature, renamed as DXTC for purposes of inclusion in the API. Another was TriTech's proprietary bump mapping technique. Microsoft included these features in DirectX, then added them to the requirements needed for drivers to get a Windows logo to encourage broad adoption of the features in other vendors' hardware.
It's been almost 20 years since then. DXTC (once again renamed BC1-3 in D3D10+) is ubiquitous on PC hardware.
>>15157885
If you are using compressed textures, you will want to compress them offline and store them as .dxt's, because they will look better and load faster than if you compressed them at runtime.
Compressed textures actually improve performance, because texture sampling is bottlenecked by GPU memory bandwidth, and texture decompression is "free." Every byte saved is another byte the texture sampling hardware doesn't have to wait for, and the most common DXT formats use a quarter of the memory of an uncompressed RGBA8 texture.
Compressed textures have compression artifacts that make them look worse compared to an uncompressed texture of the same size. OTOH because compressed textures take up a quarter of the space, you can double the texture resolution in both directions for "free" and get more detail up close.
>>15158705
Have you considered using a literal timer? Something like a day-night cycle where powerful enemies appear at night that force you to return to safety. This would add to the tension of spelunking and provide an opportunity to flesh out your setting. Or you could combine it with your "energy" system for a fatigue system, causing characters to perform worse the longer they go without proper rest.
456431 No.15159838
>>15159817
Thanks.
Any advice on the engine?
Any advice on where to find people to do the sprites/models? It'd be paid of course.
d6620b No.15159839
>>15159707
RPGmaker is great if you're making OFF or 7th Stand User and you need a battle system to be functional out of the box but not the main draw of the game or Yume Nikki where you don't use it at all. If you really want to set up RPG combat that's going to be different from what RPGmaker does then it's easier to build it from scratch in a 2D engine like Gamemaker, Love2D or Godot 2D than it is to take RPGmaker apart and rebuild the combat - that's why Shut Up and Jam Gaiden ended up switching to Gamemaker though they started in RPGmaker.
456431 No.15159854
>>15159839
IIRC, Game Maker asks for a license if you sell anything. That still true?
And while Godot doesn't, there was some drama with a language they used or some BS? All I remember is they (allegedly) caved to someone bad or cliquey. In either case I didn't like Godots tutorials because it was like
> Hey this works! We won't tell you why it works right now though. Onto the next bit!
98e6c4 No.15159860
>>15159817
> If you stick with it, you'll waste more time struggling with its quirks than you would have if you'd just picked up a general purpose 2D engine and made an RPG with that instead.
I agree but I don't really plan on sticking with it for more then one game. I've been procrastinating for years and I feel like if I just make anything at this point it will be progress.
>>15159839
At this point I'm locked into rpg maker but like I said I don't really mind using one battle system since it's not far off from what I wanted to do anyway. I probably will go with game maker or godot after this.
b3b049 No.15159881
>>15159838
I used MV instead of VX MV is supposedly the most customizable of all the RPG Maker engines because it's a fucking JavaScript web application, but modifying it still sucks balls, and my experience is basically what >>15159839 said: the default combat system werks but trying to modify the default behaviour is a pain in the ass, much harder than implementing your own combat system from scratch in another engine. Any experience you gain in RPG Maker will be very specific workarounds for retarded design decisions and won't carry over to other engines, which the developers use to entrap their customer base instead of actually improving the fucking engine.
453e41 No.15159905
I think all my greivences with GLTF was caused simply because the inverseBindMatrices are out of order for some retarded ass reason.
d6620b No.15159907
>>15159854
Yeah, gamemaker has a license so I'm not really sure what the draw of it is when there are pretty good free alternatives out there. Haven't heard anything like that about Godot, though.
62801f No.15160438
>want everything to be perfect and documented
>want to start seeing shit on screen
I'M BEING TORN APART
a51b75 No.15160452
>>15160438
>When you dislike [feature] of current engine/framework so you make your own
It's always hell
62801f No.15160478
HookTube embed. Click on thumbnail to play.
>>15160452
It will all be worth it. I'm sure of it!
b68e46 No.15160507
>>15159353
Nibba, you best be planning to pull the camera closer while in an interior.
a51b75 No.15160543
Speaking of things that are worth it, I just need to finish off the corners and my redone tracks should be all finished
a51b75 No.15161188
Also made a few custom icons for stuff that minecarts can carry (keys, gems, rocks, and bombs, once I figure out how they should look)
730205 No.15161272
>>15159353
just scale the environment up a bit
also for the love of dog, please bake the lighting
092aad No.15161408
>>15158715
> http://feedback.wildfiregames.com/report/opengl/
>s3tc has 99% support
>anistrophic texture filtering has only 98%
Well I sure didn't expect that.
bb46c5 No.15161757
Got texture setting roughly done but I was too lazy to make a scrollable window, so for now you just click through tiles pulled from the texture atlas. Walls inherit their parent sector's default wall textures unless you change them and can reset them back. Got some other simple stuff done like deleting entities/vertices/walls, which all work with undo/redo.
>>15155383
Thanks. That's a lot of neat features, how long did you work on the editor/engine? I think I vaguely remember it but didn't know it was yours.
>>15161188
>those keys and gems
You were the anon working on the Boulderdash-like game right? You better keep at this one.
a51b75 No.15161770
>>15161757
Yup, I am. The minecarts are a bit of an afterthought, but it's one of the items that should make my clone a little more unique, I hope
e58c21 No.15161774
>>15160478
Why even bother with Hooktube now since all it does is embed youtube?
b53fce No.15161784
>>15161757
cool shit
what are you making exactly?
ba478c No.15161803
>>15159415
I mean I devved up until now with a generic Skeleton and I never had any problems.
c1c1ad No.15161832
>>15161784
Pretty sure it's this guy http://8agdg.wikidot.com/fps-arpg-hybrid
>>15161774
To not give youtube any views or revenue, especially now that they were big enough assholes to force hooktube to gimp itself?
c1c1ad No.15161835
>>15161774
>>15161832
Nevermind, the hooktube thing, just woke up and didn't get the news yet
bb46c5 No.15161858
>>15161770
Oh these carts are for that game?
>>15161784
Original plan was Hexen meets Diablo but that probably doesn't explain current intention too well anymore and I've meandered about a lot. If you saw February's demo day thread, I had an online multiplayer demo.
>>15161832
Yeah that's me, I should really update the wiki page.
abfb75 No.15162168
>>15158938
>what math subjects do I need to know before getting started with programming?
In general, not really more than + - * /. That said, algebra can be useful for reducing expressions, which sometimes lets you realize that you've been overcomplicating things in the first place. It can help you keep your code clean.
Some specific problems do require math, e.g. if you want to make a physics engine you obviously need to understand the math behind the physics, and even if you're using someone elses engine, understanding the math lets you use it more effectively, and troubleshoot stuff easier too. If you're going to be doing 3D games, learning linear algebra can be pretty useful, especially for enemy behavior.
>>15159622
Steal their ideas, observe their missteps and make yours even better.
a792b6 No.15162170
>>15159551
if you had just used D you wouldn't have to worry about header hell
c1c1ad No.15162316
>>15162170
There's no such thing you fucking pajeet
a792b6 No.15162823
>>15162316
>he doesn't know about how fucking bad the C preprocessor bogs down compile time
>that's before C++ bloat
It shows that you haven't worked on a large project where compile time gets worse and worse the more you pull in. Even C++ is considering adding modules to an upcoming standard because they know how much of an ancient kludge their system is. However, even in C and C++ you can get a speedup by using a faster preprocessor such as warp, which is written by the creator of D.
c5e7cd No.15163152
How taxing is the usage of Unity's tag system? I want to check whether a colliding object belongs to a certain group and I'm wondering whether it's better to make a separate script with an int variable, that'll need to be accessed through GetComponent or just use the tags, despite them requiring to use a string to be accessed.
ba478c No.15163161
>>15163152
Here's a tip I wish I could've learned when I started using unity.
Instead of using tags, use different layers, and make certain layers interact with certain others. This way you don't have to do it via script and you don't need to manage random tags or strings.
(this also works with filtering out certain colliders for raycasts and spherecasts)
c1c1ad No.15163223
>>15162823
I've worked on plenty big projects before, except we had proper code standards which included various rules to keep compile times down plus an in-house compiler because every big gamedev company wants their own The Best Shit™. Except that has nothing to do with header hell anyway, that term is purely used by either retards who don't know how to manage headers efficiently or lazy faggots. And it has even less to do with the post you originally quoted, which was just an anon being happy about his new code compiling.
c5e7cd No.15163361
>>15163161
The problem is, I can't turn off the interactions between these different groups I think. To be clear what trying to do, I'm using trigger colliders for an AI to know if player or another npc is in their sight range. I though I could use layer collision matrix to to set which characters the AI will react to, but the matrix allows only for 2 possible states (react somehow and ignore) and I need 3 (ally, enemy, ignore. Also there's a problem that "sight" triggers trigger each other when they overlap.
a51b75 No.15163382
>>15161858
>Oh these carts are for that game?
That's right. My main inspiration is from a game called SubTerra. A lot of how I approach things are modeled after how they do things, sort of as an homage/spiritual successor, and partly so I can refer to how objects should behave. Incidentally, I found like 4-5 bugs in the original game (from 2003) that never got patched because I kept poking around so specifically.
Anyways, they don't really have a similar minecart object, so it actually is something new I made. The simple version is that if it always follows the tracks if it can, preferring to go straight, then left, then right, then stopping if it can't move or turn. When it stops it dumps its cargo into the next tile, if possible. Otherwise, it follows the filter color branches, and tries to load/unload objects at the colored zones if it can.
At least that's the plan. Most of my code is just engine-tier stuff; I tend to chip away at a generic feature, abstract it into the engine, and otherwise work on art assets while I grow my codebase
ba478c No.15163416
>>15163361
Ah I see.
Tags are probably fine for that then, but it would probably still be good if you deactivated collisions with all other things that can't be ally, enemy or ignore.
I mean I doubt it would have that much effect on the optimization at all either way, but you might as well do it.
a792b6 No.15164016
>>15163223
>recompiling the header for every file that uses it
Yes, this is completely fine.
c1c1ad No.15164093
>>15164016
>not precompiling any header that is used in many files
Yes, you're completely retarded.
85fc6d No.15164431
>>15162823
Well here is a data point. I have a 26k lines of code project in 55 C++ files and 44 header files. I'm using Qt's nmake with a mingw64 version to build (multi-threaded). It takes ~ 55 seconds to build from clean. I'm not using any precompiled headers. My header situation is kind of a mess. Every library I'm using is statically linked. Exception handling is disabled. I don't think that's too bad, or slows me down. When I'm working I'm usually only recompile 2-3 source files so compile time is < 10 seconds.
I suppose if you're a guess-and-check style programmer, don't know how to manage headers (include everything everywhere, "just to be sure"), and don't know how to use a debugger.. yes, it could be a problem.
a51b75 No.15164831
So this is more or less how my sprite sheet for tracks will look. It might be able to rearrange it to fit 384x256, rather than 512x256, but that doesn't really matter.
This goes back to the thing I was doing with building a texture atlas during the last few weeks. Do you think it makes more sense to copy the entire texture as-is to a supertexture via a blit, or should I look at the list of texture coordinates that's provided and only copy things that are used? In this case, stuff from one sheet could end up very fragmented, but it would also mean better distribution of used space
fda723 No.15164842
>>15164831
You really don't need to do any of that.
a51b75 No.15164855
>>15164842
I kinda have to, since SFML doesn't provide any sprite sorting out of the box… Being able to batch my textures and group draw calls by that or depth is going to be very helpful
fda723 No.15164967
>>15164855
What language are you using?
fb389c No.15165237
>>15164093
>have to use implementation specific features to not compile the same shit over and over again
Headers sure aren't an archaic paradigm. You really got me there.
a51b75 No.15165265
fda723 No.15165269
>>15165265
I was afraid you were using Java
62801f No.15165296
Okay. NOW I get why people use C++. Not having complex data structures is quite annoying.
So I've implemented a way to import obj models and then map each vertex to an index to repeat vertices, thereby saving memory. Unfortunately, I'm an idiot who needs to go and study data structures now so I can implement some kind of hash table to do this instead of just looping through millions of things.
62801f No.15165341
>>15165296
Also, I'm willing to take any advice on how to do this more efficiently. I can barely find any info on this so I assume it's something that OpenGL probably does behind the scenes?
a51b75 No.15165369
>>15165296
This is called vertex indexing and I believe it's fairly low level. Even if it's not provided you can make do with a pair of arrays yourself, one for the vertices and one for the indices, in sets of 3
0b3dd7 No.15165506
>>15165296
>implement a hash table
surely the c++ standard library has one
also isn't an array sufficient?
4707e9 No.15165541
>>15165296
>why people use C++
Wait until you figure out why people use Java.
62801f No.15165578
>>15165506
It would be trivial if I just had to take into account an array of vertices and find unique ones. The issue is that I'm basically looking at two arrays representing the index to vertex position data and index to texture coordinates. I need to hash (not necessary but probably most efficient) these two together in order to find what is unique then fill the vertex buffer with only unique values.
The index buffer then has to reference each of those vertices in the vertex buffer in correct order.
a51b75 No.15165585
>>15165541
Because they're part pooinloo?
62801f No.15165587
>>15165506
>>15165578
and I'm using C.
C++ has all those types.
a51b75 No.15165618
>>15165578
Well you might be naive and think that a cube only has 8 vertices, but that's wrong. Each face needs its own normal data per vertex set, and if you want to avoid having a texture wrap/bleed around an edge, you need to set distinct texture coordinates too. Thus, it makes way more sense to render a cube as a set of 24 vertices (6 faces x 4 vertices per face) - some vertices will have the same position and that's fine, but they'll differ by their texture coordinates.
So you load your model or whatever, and make a Vertex[] with 24 elements. You want to draw this front face of the cube then you make a UInt16[], an index array of shorts, to define which vertices to use in the draw call. With pic related, this would result in the following array:
>0, 1, 8,
>8, 10, 1,
>2, 11, 7,
>2, 3, 11,
>5, 4, 9,
>5, 9, 6,
Usually there is an call that does something like Window.Draw(vertex, indices, index, count, primitiveType), and you'd just feed the data into that. This has been my experience with both XNA and SFML, which used DirectX and OpenGL respectively. I don't know how accurate it is in your case, but that has been my experience with what you're trying to do.
e34213 No.15165627
>>15155608
I tried to figure out what is going on, I walked through the algorithm on paper and it worked correctly and produced the right polygons, so I know now that it's not a bug in the algorithm or anything but the code.. so I should figure out how I can step through the code in a more detailed way so that it can be fixed. I think when I can correctly generate portals for a rect-prisim map then it will make more sense what is wrong.
>>15165296
I see you finished all the tutorials- that's pretty good going. I'm not as fast as that, but I'm confused about your post. think that you have made some kind of mistake in your understanding of how this works.
So, when you have an OBJ, the vertex data is formatted like this:
v 0.016636 0.031388 -0.015639
v 0.017866 0.035529 -0.013326
v 0.009451 0.033436 -0.014545
And to draw the faces, the face data is formatted like this:
f 42 41 995
f 1347 1140 1346
f 1040 1497 477
When I write f X1 X2 X3, I am describing a triangle made up of the vertices X1, X2, and X3. So if I have an array of vertices then my faces
will be drawn like so:
glBegin(GL_TRIANGLES);
for(uint32_t i = 0; i < face_array_size; i++){
glVertex3fv( vertex_array[ face_array[i] + 1 ] );
}
glEnd();
It's not a hash table or anything, its an array access. You should have everything already if you are using OBJ. Maybe this can help a little, I don't know.
a51b75 No.15165726
Oh hey I have an important question.
So if I ask SFML what Texture.MaximumSize is, it returns 16384x16384 (based on my graphics card). If I create an Image object of that size (raw pixel data on the CPU), it lags for a sec then consumes 1,024mb of RAM memory. The debugger also says it throws a memory out of range exception.
However, if I create a Texture object of that size, it does so instantly, and no RAM use is listed - since it exists entirely on the graphics card. Thus, I'm wondering if I can check the amount of graphics memory my game is using, since Task Manager doesn't seem to list it.
62801f No.15165736
>>15165627
Here's the tutorial I'm following. Notice how he uses an unordered map in the last section?
https://vulkan-tutorial.com/Loading_models
The issue is each face has a vertex index AND a texture coordinate index (and a normal map index). These are just plain, ordered arrays. I need to be able to find out when a combination of the vertex index and texture coordinate index are unique and then only record these in the vertex buffer and reference them in the indices buffer that I pass to the graphics pipeline.
It would be trivial to do this if I only had to deal with the vertex indices and not both texture/vertex indices.
e34213 No.15165775
>>15165736
I see how it is now, sorry if my response was a kind of dumb tangent on stuff you knew already.
Still it's not terribly difficult, just hash the data and allocate an array of buckets, then use it to index into that array (remember to have a pointer to an expanding array or linked list for each bucket just in case there are collisions unrelated to identical vertices), and store the unique vertices with the indices (just count up on collisions that are real). Then dump all the unique vertices and indices into a new file (with your own custom format) that just lists off the vertex data (with texture coords and normal maps, of course), and then the indices. That way you can do this before runtime so it doesn't actually matter how fast this table is.
85fc6d No.15165790
>>15164831
Can you fit everything in one texture atlas? That would be ideal if you can do it. If not I guess you could swap them around the minimize texture binds, if you're not using bindless textures.
>>15165341
There are stand-alone tools that will index your verts from an imported model and output an OBJ file. OBJ can include vertex indices along with the actual vert data. If you want to do this yourself though and index your model.. maybe just copy to new array and only add unique vertices to the new array, of course also building the index list as you go. Might as well calculate the tangent and bitangent of each tri as you go if you don't already have it in the OBJ file. If you want sharp or blended normals you will need to insert extra vertices so that you can have different normals at the same spatial position - much the same issue as >>15165618 mentioned with respect to unique texture coordinates.
>>15165736
oh, Vulkan has separate index for texture and normal index? that's pretty nice. All my info is OpenGL related so ignore everything above.
a51b75 No.15165803
>>15165726
Hey so, I realized it literally does not matter.
>Create 1024 textures of 8192x8192 in size
>This is 274,877,906,944 raw bytes of data, or 262,144 mb at most
>My graphics card has 4 gb memory, my toaster from a decade ago still has 1 gb or more, since it runs Win 7 just fine
>260mb is a huge amount of texture memory, but it's only a fraction of the GPU, and I will at most use maybe a dozen textures of half that size
It's like pissing in the ocean, jesus
a51b75 No.15165805
>>15165790
See >>15165803
Since my toaster supports 8192, I want to support 4096 textures at minimum, and if I can go bigger than that, great. That should avoid alienating any hardware through my optimizations. I'm just dumbfounded, how do modern games end up so fucking bloated? I went out of my way to shit up my gpu just now and didn't even come close.
85fc6d No.15165815
it's pretty relaxing modelling pastries. It feels right to have the Barbie Detective game CDs next to the cigs and the burner track phones in blister packs. The total scene is up to 281k tris now. What's a reasonable limit? I expect about 40% of total scene tris to make it through to the draw calls. All my shaders are very simple - mostly just basic lighting and diffuse texture map. a few have low-res normal and height maps.
>>15165805
It's kind of incredible, isn't it? I think big games use many hi-res textures per object: normal maps, displacement maps, tangents, light maps,various masks for dirt and grime, diffuse texture, etc etc.
62801f No.15165819
>>15165775
Thanks. That's precisely what I plan to do. I'm just a bit unfamiliar with hashing/linked lists but I'll figure it out.
>>15165790
It's quite interesting. When I don't repeat vertices, it takes 0.0006 per refresh but with repeat vertices it takes 0.0003. I wondering if this will carry on to improve performance greatly in the future.
a51b75 No.15165826
>>15165819
>I wondering if this will carry on to improve performance greatly in the future.
Based on what, your stuff you write, or improvements to Vulkan?
62801f No.15165834
>>15165826
I mean that I'm unfamiliar with OpenGL. I imagine there's probably some complex system for indexing vertices/texture coords so I don't know whether vulkan has significant performance gains or what.
9a970c No.15166027
>>15165815
>Mega Pies
>cupcakes
>regular cakes
>donuts
>potatoes
>no pies
I feel cheated. Is Mega Pies the brand name for a pastry warmer or something?
6bc02e No.15166047
>small loaves of bread (rustic)
>unappealing muffin color coordination
>donuts that seem to go off into infinity
>two cakes
>MEGA PIES
>no actual pies
7/11 it's okay.
I think you wanted to keep it below 50k drawn tris to support low-end machines in 2010. Pretty sure you won't be murdering anyone with 281k.
Maybe find someone with a toaster to play your thing once you hit a decent enough milestone.
fda723 No.15166143
>>15165815
>all those perfectly laid out and spaced donuts
Where do you go to get your donuts?
6d0164 No.15166447
>>15165815
>The total scene is up to 281k tris now
That's a little high for an unfinished scene with no player models. You s>>15161757
hould try simplifying groups of donuts. But if you really want to have detail for each donut for whatever reason, make each donut 400 or so triangles. You wanna aim for at most 1M triangles in the scene.
>>15161757
>how long did you work on the editor/engine?
2-3 or so years with the game included.
c1c1ad No.15166482
>>15165237
>oh noes I have to think about my code when programming
And thus you fall into the lazy faggot camp instead of the too retarded camp. Better make everything dynamically typed since having to think about implementation specific variable types over and over again is a hassle. And add a garbage collector because having to think about my memory is a hassle and archaic. Wait, why am I suddenly using java? Why is my home in India?
abfb75 No.15166498
>>15166482
Who are you quoting?
c1c1ad No.15166515
>>15166498
<greentext is only for quoting
Alright, I'll use the more appropriately named one next time.
caa8af No.15166792
>>15166498
>Who are you quoting?
go back to
>>>/cuckchan/
85fc6d No.15166816
>>15166027
you're right, I need some pies.
>potatoes
wow my bread model needs some work.
I think the steak house restaurant across the street is owned by a nice eastern European couple. they win the county fair pie bake contest every year. they bake extra bread and pastries and sells them in the convenience store.
>>15166143
can't figure out how to do random jitter with blender array modifier. I'll move & rotate them by hand before exporting.
>>15166447
Thanks. my donuts are in the 300-400 range. they'll be using glDrawElementsInstanced() so not too worried about the # of donuts. I was going to have a stack near the coffee maker too.
I'm also considering using Armory (mentioned by an anon a few threads ago). It has some rough edges but rendering performance seems pretty good. Only problem is I've never used Haxe to program before. I'm struggling to find good examples of game code written in Haxe too. anyone have some examples?
85fc6d No.15166827
>>15166447
OK, I understand now. I think you mean grouping donuts into single object and deleting the hidden faces. That makes sense, I should do that, and also with some of my other object groups. thanks
a792b6 No.15166965
>>15166482
>slippery slope
>calls me pajeet again
okay
009775 No.15167003
>>15166482
>Wait, why am I suddenly using java? Why is my home in India?
6fe0c1 No.15167168
>>15166965
Not much of a slippery slope if half his "prediction" (garbage collection) is already true
D is as much of a shitty meme language as Rust tbh
Sage for lanuagewars. JLMG.
ba478c No.15167172
Right so I'm rotating my character's head with this
Vector3 lookAtTarget = target.position - head.position;
head.forward += lookAtTarget;
This causes the head to rotate towards the target point I set.
The only problem is that doing both this or changing head.rotation also stops the normal animation movement from happening.
Adding the head to an empty GameObject and rotating that breaks all the animations, so I can't do that.
Anyone got any other solutions?
617013 No.15167193
can anyone here tell me how GPU computation works and whether or not it's applicable for ULTIMATE PARALLELISM of voxelshit? I made a knockoff autismcraft and i wanna see how tiny i can go. im up to 2 million voxels per chunk and the terrain generation is starting to get too slow for me so i thought maybe i can use the graphics card
thanks in advance lads
6bc02e No.15167207
>>15167172
Maybe have the animation have a reference toward the "desired look direction", so it can smooth into and out of it, keeping its usual movements around said desired direction.
I guess that depends on how your animation works. If it takes a parameter every frame, you could just feed it that look direction, if not, it's going to need to read it in from somewhere.
16c02d No.15167408
Still working on those skeletons
85fc6d No.15167526
>>15167408
looks pretty fun already. going to have a skellie "reverse" mode so you can blast hobbits?
092aad No.15167557
>>15167193
Basically, GPU's can't branch.
If your workloads don't require branching, it's fantastic. If they do, assume that for every branch, the computational cost requires you to go through BOTH branches. It goes without saying recursion is impossible too.
2cadf1 No.15167644
>>15167557
Can they use iteration such as while loops, or is it better to think of it as a giant calculator to manage basic FLOPs?
fda723 No.15167689
>>15167644
>is it better to think of it as a giant calculator to manage basic FLOPs
sure dude, think of it like redstones in minecraft
092aad No.15167794
>>15167644
To dive into more exact details:
GPU's have a fuckton of shader cores, which are grouped together in compute units.
The compute units can branch. The shader cores, however, cannot. Meaning that the branching has to be 100% consist amongst all shader cores. This is also referred to as "dynamically uniform".
This means that any meaningful control flow has to be 100% predictable amongst a large group of instances, which often defeats the entire purpose of computation.
So to answer your question, you're allowed to do this:uniform int loops; // global variable, consistent per draw call
void main() {
for(int i = 0; i<loops; i++) { // amount of loops is dynamically uniform in this compute unit
// do actions
}
// write results for this shader core
}
But if you do this, you get undefined behaviour:in int loops; // per-shader core variable
void main() {
for(int i = 0; i<loops; i++) { // amount of loops is not uniform, so the amount of loops the compute unit chooses is the amount of loops that actually happen
// do actions
}
// write results for this shader core
}
If you've looked at a bunch of shaders, you would notice that some of them DO have if statements in them. These are resolved by having the compute unit step through BOTH branches. That means that if you want branches to be efficient, you should keep them as small as possible.
I think it's more meaningful to use CPU multithreading for huge voxel worlds though. GPU's are literally only good for brute-force straightforward work. CPU's on the other hand have tons of pipelining magic and, most importantly, their ability to branch allows them to utilize complex data structures. If you want extremely high resolution voxel worlds, then data structures like octrees are almost guaranteed to be way more efficient, especially if you have your typical minecraft world where almost half the blocks are air, and the other half is dirt or stone.
092aad No.15167891
>>15167644
>>15167794
To summarize: If/else branches will cause both of them to be executed. Loops must be consistent in the entire branch. And to add: code recursion (functions calling themselves) are entirely impossible.
Additionally, if your shader accesses remote resources (this means textures or shader storage buffer objects, but NOT uniforms themselves) then which resources they access must be dynamically uniform. So you're not allowed to attach an index to indicate which resource you want to pick out of a uniform array.
092aad No.15167895
>>15167891
>Loops must be consistent in the entire branch.
*in the entire compute unit
fug
c5e7cd No.15167950
>>15167172
If you parent head joint to the empty game object at run time in Start(), instead of in edit mode it seems not to break anything.
433398 No.15167959
>>15167172
look into IK
unity has a built in implementation of it if you're using a humanoid rig
otherwise the way it usually works is like this:
have 1 animated skeleton that you never modify and isn't visible
have another skeleton that copies the positions/rotations of the bones in the animated skeleton + IK calculations, and has a renderer
62801f No.15168667
Really starting to wonder if C is worth it over C++ for my game engine, lads.
I'm using it because
1. I'm hoping that the nature of C will translate better to DoD later
2. I believe thr robust documentation of C and it's simpler nature means I could eventually understand it in its entirety whereas C++ is far more complex.
3. I'm worried about any unseen overhead brought in by C++
4. Some older engines (like Id tech's) that I want to study are written in C
5. I want the engine to be as accessible as possible
6. My ego wants to stay low-level and never trade performance for what's easier (despite this trade-off not being rational)
BUT
1. Vulkan (or OpenGL) are implemented in a way that translates better to OOP. C++ is obviously more capable in handling objects, even just by allowing inheritance.
2. There is overhead in C++ but I'm starting to think that in time-criticial parts of code, this won't be relevant
3. The use of C++ is much more prevalent in any guides/tutorials for graphics programming
4. I could basically just use C with C++ classes which may possibly improve readibility but is it worth it to betray the C standard?
5. Most people are going to be used to OOP so I'm worried about people being turned off by pure C for future support
6. Plenty of very good libraries related to OpenGL/Vulkan (like GLM) are made for C++
092aad No.15168882
>>15168667
>1. Vulkan (or OpenGL) are implemented in a way that translates better to OOP. C++ is obviously more capable in handling objects, even just by allowing inheritance.
OpenGL/Vulkan translates better to C than C++. They're C API's after all. However, if you want to write game objects with inheritance, C++ will obviously be a better choice.
>2. There is overhead in C++ but I'm starting to think that in time-criticial parts of code, this won't be relevant
Correct. If you're not doing anything retarded in your engine it'll run on a potato anyway. Besides, there's nothing stopping you from rewriting the critical parts in C or even assembly. Or just release the game a few years later when the average computer is faster.
>3. The use of C++ is much more prevalent in any guides/tutorials for graphics programming
If you can't read and understand different programming languages, then maybe you should reconsider programming your own engine for the moment.
>4. I could basically just use C with C++ classes which may possibly improve readibility but is it worth it to betray the C standard?
I recommend against mixing C and C++, purely because the style of code is different.
C is focused to do exactly what you tell it to. It wants you to explicitly say what you want to do, and never does anything more. If you allocate an object, you have to also free that object.
C++ on the otherhand has a ton of code that it'll tend to run behind your back, even taking care of some garbage collection in the process. If you create a vector, then that also incurs allocations. But when the vector falls off the stack or the object owning the vector is deleted, the vector is also cleaned up for you.
Mixing the two means that you'll be writing more explicit code in some parts (C), whilst relying on very implicit behavior in others (C++), which makes it harder to read.
Note that you can always use two language separately. You can write most of the engine in C, produce C++ bindings for it and build all the game play code on top of it in C++. Whether that's good for your engine is something you'll have to decide for yourself. Plan out how you want to break up your engine into smaller parts, and ask yourself what parts would even benefit from OOP at all. Depending on the game you want to make, that can be a lot or even absolutely nothing.
>5. Most people are going to be used to OOP so I'm worried about people being turned off by pure C for future support
You're going to be engine-devving. If you think you can avoid god objects without introducing a unmaintainable amount of smaller objects then you're very wrong.
>6. Plenty of very good libraries related to OpenGL/Vulkan (like GLM) are made for C++
There's also plenty of C libraries to replace those. Or you can port a C++ library or write your own replacement.
tl;dr if you have to ask then you're not good enough at programming for it to matter. Use a language you like, shoot yourself in the foot and learn from your mistakes. By the time you have a half-decent engine going, you'll be proficient in both anyway purely because of the amount of material you'll have to go through.
a51b75 No.15168903
>>15168882
>C++ on the otherhand has a ton of code that it'll tend to run behind your back, even taking care of some garbage collection in the process
Okay, now explain why people give C# shit for doing that and C++ gets a pass
6fe0c1 No.15168937
>>15168903
Because the things that do it are also things you shouldn't be using for gamedev anyway.
092aad No.15168967
>>15168903
Because of the way garbage collection occurs.
C++ only does garbage collection when:
>When the object falls off the stack
>When an object containing the (to be garbage collected object) gets deleted
In other words, doing this:obj* o = new obj(vars);
Causes a memory leak.
You still have to manually clean it up by manually deleting the object as such:delete o;
Simply put, C++ does garbage collection for you, but only in specific places. If you want one of these places to not trigger garbage collection, you're shit outta fucking luck. It gets freed, every time, because fuck you.
C#, on the other hand, does a complete garbage collection every once in a while. The way is does this is by:
>Pause all threads
>Traverse every single object that is global or on the stack, and marking it and it's children (recursively) as used
>After this, every object that isn't marked as used is no longer used, so delete them
>Resume all threads
Of course, stopping your program periodically and traversing literally every instantiated object is expensive, and often causes a frame to take many times longer than the other ones, resulting in a quite poor gameplay experience.
The garbage collection that C# (and Java) uses is amazing for enterprise programs, since you don't have to garbage collect at all! It's just expensive to do, and is guaranteed to cause a laggspike in large applications. This is considered sub-optimal for vidya, which is why everyone shits on it.
C++, on the other hand, garbage collects some objects for you, but not everything. You still have to manually manage a bunch of stuff. It's just a bit less than C, which is convenient. It's not really garbage collection in the complete sense like C#, but it's got performance in that it doesn't have to do a bunch of other shit.
tl;dr C++ garbage collection is free but incomplete whilst C# is complete but causes laggspikes which are really bad for vidya
3d4338 No.15168978
YouTube embed. Click thumbnail to play.
>>15154904
>>15155383
Reminds me of some vintage stuff.
a51b75 No.15169013
>>15168967
>The garbage collection that C# (and Java) uses is amazing for enterprise programs, since you don't have to garbage collect at all! It's just expensive to do, and is guaranteed to cause a laggspike in large applications. This is considered sub-optimal for vidya, which is why everyone shits on it.
I'll assume that it doesn't traverse every object, since you could probably optimize references and the object graph as things are created and collected.
However, your post doesn't go into detail about how C#'s GC also promotes certain objects that are long-lived. Essentially, if an object survives one or two GC's, that object and its entire graph get promoted to higher levels that almost never get collected (but eventually still will if they are eligible for collection)
092aad No.15169056
>>15169013
>However, your post doesn't go into detail about how C#'s GC also promotes certain objects that are long-lived.
Because I don't know nor give a shit how which C# implementation optimizes what. I don't program in C#.
I'm just responding with what the difference in theoretical garbage collection approach is and why people hate on C#'s approach. If you were expecting to engage in some asinine discussion about muh perf then you're shit outta luck. Go profile your code instead.
62801f No.15169134
>>15168882
The purpose of making this engine is as a learning experience.
I've realized that I need to take a step back and go through a few more books. I'm just worried about the future. I can't see any jobs in C that aren't embedded systems/electrical engineering related. I'm getting a dual degree in IT CS / Applied Maths. Maybe the work I do now will some day translate to systems programming or processor optimization. I don't know where you find a career in that except in Shenzhen.
6fe0c1 No.15169155
>>15169134
Gamedev jobs always look for C++, but the C++ they'll have you write will pretty much be C anyway. Saying you mainly work with C but know C++ as well might actually be more likely to get you a job than the other way around, even though it's not what they ask for in job offerings.
092aad No.15169182
>>15169134
If you're doing it to pad your resume, then you should ask yourself what job you exactly want and learn the skills required for that.
For software engineering in general, you're best off learning the skills required to manage development. Things like version control, automated builds, testing, managing roadmap, stuff like that.
If you want to do gamedev, it's either C flavored C++ as >>15169155 says, or C# because your employer wants you to work in Unity. Anything else means you'd be working in mobile/web. The above mentioned software engineering skills are theoretically useful, but the standards of the gaming industry are so low, it probably wont even register as useful to most studios.
62801f No.15169255
>>15169155
>>15169182
Okay. I'll stick to learning the ins and outs of C and work on my engine sparingly as I acquire the relevant skills.
453e41 No.15169307
>>15169255
Pro-tip: When managing memory, write your own allocators. Instead of using Malloc everywhere, you should malloc a giant pool of memory, or several pools, all at once then when you want memory grab from this pool of memory.
Malloc is slower than cache misses.This wasn't something I knew when I tried DOD and it's going to take me forever to fix.
b3b049 No.15169315
>interested in Go for its CSP-style concurrency
>GC turns me off from using it for gamedev
>Plan 9 from Bell Labs has http://man.cat-v.org/plan_9/2/thread but making vidya for Plan 9/9front means no one will play it
e89cd5 No.15169399
Am I missing something or is the Character Controller in Unity unusable garbage?
At this rate I'll have to write my own implementation. But I find it hard to believe something so basic would be this broken in Unity.
e34213 No.15169809
>>15168667
>>15169134
OpenGL and Vulkan programs have "Objects" but not OOP. This is because none of the objects in these systems actually have any agency, and are operated on by procedures. I wouldn't worry about other programmers not using your engine because it isn't in C++ (you can link C++ code to C so what is the issue?).
Really what makes me think is, when C can become a burden, for example having to learn how to write a hash table when C++ has one built in, what is better? It's the same thing with GLM. You can write all your math functions yourself, it really isn't difficult and you should know how all of that math works anyway. But it's obviously less of a burden to just use GLM instead. Really if you are making this to challenge yourself, isn't the burden that you have from not having the STL or GLM the purpose of using C? You wouldn't be challenged in this way if you used C++.
453e41 No.15169853
>>15169809
The STL is riddle with performance flaws. For example: The hash maps you mentioned group key and value together which rapes cache.
e34213 No.15170022
>>15169853
I'm not saying that you can't write a better hash table or a better version of any of those data structures for the task at hand. That's part of the performance difference between C and C++, after all.
e34213 No.15170244
>>15169315
It's just a casual filter. Anyone who cares, will play. It's not so unreasonable, I had to burn a CD to play all of Terry's games on TempleOS - I've got plan 9 front on my computer too already, so it's not a problem for people who can put in the time and set it up to boot with LILO or whatever
85fc6d No.15170422
>>15169809
There are good C libraries for hash maps of all kinds. C++ comes with some OK data containers (in the STL) but you can get similar for C just not built into a standard library.
I've heard GLM isn't all that great for performance BTW. The MIT license Sony SIMD math library is probably better although not for beginners. GLM's advantage is that it looks and works very much like GLSL math functions so it is very easy and comfortable to use. Honestly though I haven't tried to use basic SIMD techniques like processing std:array's of GLM matrices & vectors in batches to compare to Sony's library, so I don't have direct data either way on actual performance.
I disagree, OpenGL doesn't have "objects". It has a State which controls rendering behaviour and it provides C functions to operate on data that you provide and to manipulate the graphics hardware. It also copies/creates new data but it always returns handles to you - it's your program's responsibility to manage the new data, track and remove it as you deem necessary. The functions and data are very loosely bound (not at all really), and no constructors/destructors for the GL handles to that data.
e34213 No.15170442
>>15170422
I am really just using the words that khronos uses to describe certain things in OpenGL, for example textures are an "object" in this system and as such are referred too as objects, you can see here:
https://www.khronos.org/registry/OpenGL/extensions/EXT/EXT_texture_object.txt
In this way resources like textures, etc, are called "objects" by the standards and so when I say in OpenGL you have objects that you operate on, it's really just saying you write procedures to operate on resources like textures and VBO's. Really I agree with you that the objects don't satisfy the requirements of OOP, but I don't think that it's wrong to call them objects still, just not in regard to what an object is in OOP.
6d0164 No.15171002
Some bathroom modelling progress.
>>15169399
You should always write your character controllers in Unity. It only exists as legacy and nobody actually uses it anymore.
3891ea No.15171149
how do I get this good
and how do I not fuck it up with horrendous shaders
b581e2 No.15171160
bbcd11 No.15171230
>>15171149
Study anatomy including bone and muscle structure, save references, look at drawing guides because the general idea is the same while the tools are not, realize that art is subjective and that you must realize what your standards are in order to meet them. Set goals, get good.
Also what >>15171158 said.
ba478c No.15171243
>>15167950
You beautiful bastard that works
ba478c No.15171280
>>15171149
You ever wonder how it is to be able to make your own really high quality jerk off material?
Like surely at some point you just give up going after real women and dedicate yourself just to improving how much you can jerk off with your own creations
bb46c5 No.15171311
Got the new map format loading yesterday, next to fix some things for concave sectors then to get back onto culling and rendering stuff. Now that I'm using depth tests instead of manually setting stencils based on portals and needing to determine draw order it feels like I should probably just cull and draw things at a room level basis rather at a sector level since the triangle count will be so low. This entire test room is only ~1800 vertices for example.
bbcd11 No.15171369
>>15171280
The amount of time and effort put into it dissuades you from being attracted. All you see when you look at it are the steps you took to make it, not the finished result.
4c583b No.15171624
>>15161272
can the sun move and have baked lighting?
4c583b No.15171629
>>15169399
>Am I missing something or is the Character Controller in Unity unusable garbage?
>At this rate I'll have to write my own implementation
welcome to the club
ba478c No.15171967
>>15171002
>>15169399
I don't even think they have a proper download for it anymore honestly
7d35dd No.15172385
>SFML
>write sprite ECS using sf::Sprite
>runs like molasses with 6000 sprites
>decide to do some tests
>1 FPS drawing a sprite 1M times from memory
>7-9 FPS creating a VertexArray of 4M vertices every frame
>24-50 FPS drawing a VertexArray of 4M vertices from memory
c5e7cd No.15172398
>>15171280
It's like when you have a fancy for some meal, so you decide to cook it, but you have to constantly take a bite of your work in progress as you go. You can't cook without consuming at the same time. Eventually, you'll become full and lose appetite long before you're done with preparing the actual meal.
ba478c No.15172483
>>15172398
/agdg/ metaphors are always on point
0ed09e No.15172562
>>15172398
Except when you know how to cook it, you don't need to taste test it. There are plenty of people who can make and enjoy their own meals.
c5e7cd No.15172717
>>15172562
My analogy has some holes. While cooking, you can put off the consumption of your work until you're done, you can't do it while creating visual work, like a drawing or a 3d model. The creation and consumption are simultaneous, unless you can create with closed eyes. Now that I think about it, cooking seems to be more like gamedev, because you could make a game without taste testing it.
0ed09e No.15172929
>>15172717
Well even then, whenever I listen to my music or look at my art I find myself enjoying it as I would someone else's music/art. So it doesn't seem too unlikely to me that there are people who "enjoy" their work.
7d35dd No.15173011
>>15172929
If you give it a few months it'll look like someone else's music/art.
a51b75 No.15173018
>>15172717
>/v/ using a food/cooking metaphor
>Has some flaws
You don't say
e7e024 No.15173024
>>15172398
>>15171369
I don't know, you faggots. pretty sure shinobudev enjoyed making these>>15171369
ba478c No.15173041
b1b85e No.15173045
>>15173024
I certainly hope he's cleaned up those vagina and anus animations by now. They don't just open up on their own as the dick gets near.
6fe0c1 No.15173047
>>15172717
>because you could make a game without taste testing it
>write all your code without compiling
>theoretically finish your game
>hit compile
>despair as the error counter approaches infinity
4707e9 No.15173080
>>15173024
This is what Ton Roosendaal has in mind as he works on blender.
62fdd5 No.15173082
>>15172717
>because you could make a game without taste testing it.
<Not doing QA
Disturbing
2c8456 No.15173192
Has anyone here either attempted to or successfully kickstarted/crowdfunded a project without getting stuck with a project that never ends?
e33696 No.15173198
Hey /agdg/ can you make me a sandwich?
67bab2 No.15173209
>>15173198
Give me 12 months, and I should have a sandwich engine made.
a51b75 No.15173210
>>15173198
Sure, let me just reimplement the universe first
4587da No.15173306
>>15171149
Where is this from?
84bc80 No.15173331
Does anyone happen to know of a primer on rigging characters with props? It's remarkably difficult to rig a sword slash using the whole body while also keeping the arc straight and the blade edge in the direction of travel.
ba478c No.15173635
>>15173331
There's really no need to keep the sword straight, the more cartoony the better.
9a970c No.15173759
>>15173331
Use real life as reference. I'm not saying you have to copy real life 1 to 1, but understanding how people move and exaggerating from there will give a better end result than not using real life.
You can look into HEMA, in particular saber fighting as that is done with one hand. You don't have to go full HEMA and make all of your sword swings historically accurate but seeing how certain body movements translate into certain sword movements is helpful.
Also pick up a stick and film yourself swinging it. You are the only person who ever has to see these videos so go all out and try your best to swing the sword how your character would swing the sword. Walt Disney would often film actors acting out scenes and use that as reference for his animations.
ba478c No.15173783
Anyone ever had to slerp a quaternion so that it would only rotate in a specific direction?
Tips or ideas on how to do it in unity?
ddf711 No.15173822
653239 No.15173833
>>15173024
lmao
does anyone have the webms from when he redesigned her tits recently
4587da No.15173864
84bc80 No.15173927
>>15173759
>>15173635
I appreciate the advice, but I'm more after info regarding the rigging process itself. For example, the position of the tip of the sword of my character is dependent on 7 bones (hand, lower arm, upper arm, shoulder, chest, spine, and torso. If I was to go about animating them via forward kinematics, even a slight adjustment of one of the body or shoulder bones would create a large shift in the position of the sword tip, thereby making it nigh impossible to animate a nice smooth swing arc without having to animate each and every bone at every frame by hand. I would like to do inverse kinematic animating, but I'm not sure how you would go about creating a 7 bone IK chain. Would it end up having 6 different pull targets? I'm not sure how well the product would turn out either as animating in IK tends to lead to slidey motions.
Ultimately for that previous animation, I ended up using a method that chained the IK hand bone to a spline curve, but this method takes a long time to get right and it still has issues with the torso, spine, and shoulder not being very consistent with the arm.
9a970c No.15174047
>>15173927
I can't say what the industry standard is, but the way I've done it in the past is used IK for the arms and legs, then used FK for the rest of the body. I've never used a spline curve, just a lot of time and elbow grease, checking frequently to make sure everything looks right and fixing stuff when it doesn't.
c1b7ab No.15174080
>>15171311
How do you store these maps ?
6d0164 No.15174088
>>15173024
Well that's embarrassing.
>>15173833
Just check out the thread on the agdg board.
>>15173045
Oh you bet your ass there will be a remake. The body has gone through so much since I went full retard and made those animations. That work is 6 months old. Whenever I get around to sexy time there will be a revamp for the lower body mesh as I've learned a bit of anatomy and deformations. Won't be for a while though, focusing on normal features.
b1b85e No.15174159
>>15174088
Great, that's good to hear that you're steadily improving, your dedication is an inspiration to us all and I was slightly worried that you would think those were good enough and leave it as is. So it scared me a bit thinking that your dedication was slipping
4c583b No.15174242
Finished the new terrain, remade the entire terrain mesh using my brother's terrain system, it is made to allow procedural generation of props and objects based on the terrain type/biome, so filling the map will be much easier later on
Now i will remake some of the collision meshes of the buildings so they stop fucking the character collider in the ass
Then we will work on the character movement, adding sprint, wall jumping and swimming, it would be functional for the 8/8 demoday, but won't be much to do other than walk around and explore the city
653239 No.15174286
>>15174088
I forgot /agdg/ existed.
a51b75 No.15174769
>Finish work
>I feel like working really hard on my game today!
>Set up my environment again and write a dozen lines of boilerplate
>Have a nap
>4 hours later wake up in time for bed for my morning shift
We're all gonna make it lads
7d35dd No.15174814
>>15174769
>decide I'm going to rewrite everything even though I've barely even started again
Also any advice for retards on data structures for culling renderable entities and collision detection? I am aware of the existence of quadtrees, kd trees, bvh but not sure how to implement these.
653239 No.15174862
>>15174814
Depends on what kind of game you're making.
c5e7cd No.15174868
What is better? Infographic for clarity, because I probably explain it like shit.
>a lot of scripts with Update() reference another script to get a variable
>a lot ofscripts have variable inside them and use it in an Update()
6d0164 No.15175214
>>15174868
I dont' know what the context is. It depends entirely and if you are just trying to optimize stuff right now without measuring anything or having any sense of where the bottleneck is, you are wasting time.
>>15174242
What's the polycount for everything?
3891ea No.15175266
>>15173306
>from?
one sakuramochiJP.
https://twitter.com/sakuramochiJP
The face remind me or revolution 60 but that body is 10/10
4587da No.15175315
>>15174868
The second one sure looks a lot more error prone. Do you need this for something or is that a general question?
Speaking of Update(), here is something that may be related to your question: https://blogs.unity3d.com/2015/12/23/1k-update-calls//monobehavior-calls-optimization/
>>15175266
Great stuff. Will that model be used in a game?
057f3f No.15175449
Head IK is working, but sometimes the head rotates the wrong side and I've got no fucking clue how to stop it from doing that
3891ea No.15175784
>>15175315
>Will that model be used in a game?
No idea. I don't speak moon and the guy tweets so much that I can't really reach many of his earlier projects or the reason he's working on this stuff. The character looks like something for a fighting game, that's for sure. Still, might just be his personalized waifu.
he also made this qt
http://sakuramochijp.web.fc2.com/unity/seraphina.html
and other 5000poly models, which are gone from his website and only remain as screens
4c583b No.15176108
>>15175214
547724 triangles on the entire city, but its static geometry, it runs at 70+ fps even without LOD models
The terrain editor doesn't count polygons yet, i will compile the mesh later and check on Unity
dd6d6f No.15176217
>>15176108
got any occlusion culling going?
4c583b No.15176369
>>15176217
Not yet, unless my brother activated it, but we will use it
fda723 No.15176509
>>15176369
What's your backup plan for if your game commercially fail?
4c583b No.15176602
>>15176509
Get a job and keep improving it until it stops failing
This game will succeed at some point, the niche is still not being supplied by any other game
b97940 No.15177036
If my game utilizes OpenGL, what's the newest version I can go with while still supporting potatoes? I remember anons mentioning certain versions of 2, 2.1 I believe.
How different are they, compared to OpenGL 3 and up?
2dcc49 No.15177066
>>15177036
Go with version 1. Stick with fixed function. Everything after 2 is a meme and depricated by Vulkan.
b3b049 No.15177101
>>15177036
Probably 2.1, depending on your definition of potato maybe 3.x too.
b97940 No.15177137
>>15177101
Ideally, I'd like to support computers as old as possible, for curiosity if anything. Since the game will be largely styled after PS1-era games, I don't really need anything too fancy.
The big issue is that I don't have enough experience to know what's really reasonable. I have a couple potatoes with 64mb of video memory on hand, and if I could, I'd love to run it on those, once again, out of curiosity if anything.
>>15177066
Any good sources on 1? Just looking around for tutorials and the like, most are for 3 and up, though I did find this one for 1.
http://www.glprogramming.com/red/
b3b049 No.15177153
>>15177137
In that case, OpenGL 1.x should be good enough. If you're targetting modern toasters, you'll gain more performance through using Vulkan and newer OpenGL versions wisely.
b97940 No.15177190
>>15177153
That's something to keep in mind, damn. Most of the playerbase will probably use modern-ish hardware at the least. Would OpenGL 2 be an adequate tradeoff, or is the performance enhancement limited to 3 and up?
Is the performance difference really that big, also?
092aad No.15177248
>>15177036
Depends on how potato the potato is.
In terms of meaningful versions, consider the major number and highest minor variant. So 1.5, 2.1, 3.3 and 4.7. Each major version indicates new features being introduced that require new hardware:
>2: shaders
>3: deferred rendering (render-to-texture, feedback buffer)
>4: tessellation
Ask yourself what features you want to support first. 3.3 is often a favorite since it's the first version that standardized a lot of nonsense, but 2.1 is fine too as it allows you to customize the shader pipeline. 3.3 is mostly interesting as it allows you to do deferred rendering, making multiple lights and shadows significantly cheaper.
You probably don't need tessellation, so 4.x can be tossed out the window.
If you want to know what supports what, simply visit wikipedia:
https://en.wikipedia.org/wiki/List_of_AMD_graphics_processing_units
https://en.wikipedia.org/wiki/List_of_Nvidia_graphics_processing_units
https://en.wikipedia.org/wiki/List_of_Intel_graphics_processing_units
To summarize, 3.3 is supported on dedicated cards that are a decade old, whilst 2.1 is also supported on integrated that is a decade old. That should be a good enough target, because trying to support systems older than that means you are either dealing with ancient hardware running modern operating systems with shit performance, or hardware running ancient operating systems that will require you to do a lot more work to make your software actually run proficiently.
That last bit is especially awful, since it means you usually end up having to write separate code for different operating systems. And if you're doing that, then you can also consider using different OpenGL versions for different systems, and then your initial question is no longer relevant.
>>15177190
If your OpenGL 2.1 game can run at acceptable framerates on 2.1 hardware, then you don't need to worry about 3.x hardware being able to render it efficiently.
b97940 No.15177313
>>15177248
A really great summary, anon, and thank you. I'll have to read up a bit more on the individual features, though it seems like 2.1 is the version to go with right now, unless I find that it's really lacking something I'd need.
Thanks a whole bunch, again. No idea what you like, so have this sleepy loli as thanks.
c5e7cd No.15177424
>>15175214
>context
I'm trying to make an AI script. Some of their behaviors are based on character attributes, like attack range. For example, it check whether the targeted enemy is in range on every frame to either punch him or change the state of the AI to pursue the enemy. That's why I'm wondering if it's more efficient for the script to get it from another script that contains various info about the character on every frame or have it kept in a variable inside, where it's updated only when something like changing equipment happens.
>without measuring anything or having any sense of where the bottleneck is, you are wasting time
I'm trying to trail and error this shit. So far it just works but I don't really believe I'll get it right this time so it's a learning experience to see what works.
>>15175315
>link
Very informative, thanks.
As I wrote above, I have particular use for this. But I'm also curious in more general sense for the future.
b3b049 No.15177791
>look through the XBill/XLennart codebase after noticing the insanely low locked framerate
>it's a C++ program ported to C
>everything is hardcoded in the worst way
>every sprite is an individual X11 pixmap/bitmap
>the entire game is a horrible abuse of gtk+/motif/xaw tools meant for designing GUIs
This isn't yandev-tier "everything is a string comparison nestled within six million if statements" but I'm still horrified.
033373 No.15177849
0b3dd7 No.15177893
Looking to make a small 3d multiplayer katamari demacy style game. Recommendations for physics engines?
5d3424 No.15177980
i'm not really sure what's going on
i'm back to raytracing again for assembly party and everything is slow and broken
b53fce No.15177983
>spend hours with MSYS2/mingw-w64 breaking and trying to reinstall it on two computers because Avast has false positives.
>set up build system to automatically download and compile the required dependencies for my C++ project during MSYS2 fuckery.
>work around limitations in git to privately download the submodules from my dev server
>commit all build system files with inconsistent line-endings and end up spending a day or two intermittingly fixing that and preventing it from occurring ever again
>finally fix it and MSYS2 breaks yet again
7c43cb No.15178177
>Toaster took 3 hours to install Unity
>10 minutes to open a blank 3D Unity project
>Rare stutters from just moving the scene camera around
How fucked am I?
b53fce No.15178200
>>15178177
Jesus, what kind of awful computer do you have?
I bet a $150 computer will get you more performance than you have right now. Or it's a driver issue.
abfb75 No.15178201
>>15178177
TBH get SDL and make a pixelated platformer instead.
6e406b No.15178212
>>15178177
What do you expect, nigger? Fucking pong on unity requires a NASA supercomputer. If you want to live the toaster life, you gotta learn the art of optimization. Unity? Get outta here. I bet even Game Maker would push your computer to its limits.
a51b75 No.15178224
>>15178212
>Pic related
>Game is under 40 kb
057f3f No.15178243
>>15178224
Nigger that's not a toaster.
Your pc is just fucked.
Pic related is mine and I can run a high poly 3D game with physics no problem.
>>15178212
>(1)
classic
b3b049 No.15178279
>>15178243
I misread v2 as x2 for a moment and assumed you were the uneven RAM anon with dual Xeons.
a51b75 No.15178298
>>15178243
>Your PC isn't a toaster
I know, that was the joke, that I'm making such a simple game on decent hardware
>It's just fucked
Wait what?
057f3f No.15178311
>>15178298
I confused you for the anon saying his game wasn't running
Sorry
7c43cb No.15178315
>>15178200
A laptop with 4 gigs of RAM and an AMD A10 APU. I think there's a bunch of shit running in the background that's slowing it down. But I got this laptop for free and it's better than my desktop (an old office desktop I got from the local high school for $20 because they were phasing them out)
>>15178224
>Phenom CPU
>12GB RAM
>300 series AMD GPU
>Toaster
I kek'd
b3b049 No.15178365
>>15178315
Try shutting off some background programs and running it again. If you get the same results and Godot doesn't fare any better, either take >>15178201 's advice or go for some older freetard engines like Irrlicht, Panda3D, and the id Tech family.
7c43cb No.15178371
>>15178365
Yeah, I'm going to try Godot and see how that goes for me. I hear that if you can't get 3D to work in Godot. Then there's no point in trying
4c583b No.15178401
Added a bit more terrain near the city, im satisfied with the terrain for now, some spots will be cool places to make your house/farm
4587da No.15178417
>>15176602
>>15178401
What game are you making? Can I find it on the wiki?
4c583b No.15178426
4c583b No.15178431
I need to update the wiki, just noticed my page still describes the demo i made instead of the fullgame
a51b75 No.15178735
Okay so A button memes aside, if I poll input and only do one check per frame, then that means an input can't be simultaneously pressed and then released at the same time on the same frame, right?
Asking because pic related is how I'm going to handle replays
>Game runs at 60 fps
>Update logic is set up so that 60 ticks = one tile of movement, maybe faster
>Ticks is converted into an int16 and encoded with a byte (pic related), for a total of 24 bits per player input
>Ticks acts as a timestamp for when to toggle the input, and it's designed to even wrap around - replays will only break if the player is idle for chunks of 18 minutes at a time
85fc6d No.15178842
>>15171002
Really nice models and detail! I like the windows and the detail work on the bathtub feet.
b97940 No.15178854
Ready for early access, boys.
e89cd5 No.15178959
>>15178177
I used to sometimes get extreme stuttering where Unity's editor ran at 60 fps but freezed for a moment every second, while the exported game exe ran flawlessly. Once when it did this, I disconnected my laptop from the internet, and the editor instantly became smooth as butter. Then the moment I went online again, the stuttering came back. I suspect what happened is that I had a shitty connection, which slowed down all the phoning home Unity does.
I think it's unlikely you have the same problem, but going offline is a thing you can try.
a553de No.15179364
>>15178735
Yes.
This doesn't really apply to replays, but it might be worth considering what would happen if someone pressed and released or released and pressed a button within the same frame. Whether to switch for one frame and back, or to drop input entirely. You'll have to consult your polling or whatever feeds data into the thing you're polling.>>>15174814
a51b75 No.15179447
>>15179364
I have 4 directions of movement and two modifiers (interact with adjacent tile but dont move into it, and use item). The modifiers don't really matter but the direction does. I'll probably just have an arbitrary thing that reads the first direction of the flag and then ignores the other inputs.
a51b75 No.15179489
>Wow what the fuck why does C# pad my output with 2 bytes per byte I write
>Is this endianness?
>Why is it 6 bytes per button press?
< Oh right I'm retarded, each button press has a corresponding release so each press event is 3+3, four times
730205 No.15179790
>>15178177
i'm using a 6 year old laptop not meant for vidya and unity still works like a charm for me, jesus man what decade are you from
0b2a77 No.15179804
http://picosong.com/wfENW/
I want to add a greaser boss now. In the lore something more artistically and technologically close to the 1950s doesn't occur for another thirty years though.
fda723 No.15181376
>google anything on performance
>every top answer is "don't worry about it and just fix it if it becomes a problem"
this software dev mentality is fucking cancerous, now I need to find a book that tells me exactly how the compiler implements something to gauge the performance. It's not just this, every question has only answers that's a slight variation of this. I just don't want to build an entire system using a language feature many times a frame without having some idea of what it's translating to.
>how many ounces of water does this hold/
>I dunno lol just fill it until its full
b4f3bb No.15181416
HookTube embed. Click on thumbnail to play.
>>15181376
I don't know what those people said, but premature optimisation is the biggest killer of progress. As for your compiler question, here is a good talk.
fda723 No.15181421
>>15181416
>but premature optimisation is the biggest killer of progress
You're just shitting out slogans at me.
>here is a good talk
That has absolutely nothing to do with what I was saying, though. Why did you link it?
abfb75 No.15181439
>>15181416
>I don't know what those people said, but premature optimisation is the biggest killer of progress.
Unfortunately this also gets used as an excuse to write shit code.
For that matter it's a bullshit statement in itself because it says nothing about were to draw the line, just that there is such a thing as premature optimization. It's so vague a statement infact that it's not falsifiable.
b4f3bb No.15181482
HookTube embed. Click on thumbnail to play.
>>15181421
Maybe I misunderstood your question, but if you want to write performant code, then you should know what the compiler is doing so you don't waste your time. Things like passing pointers to functions may be good or bad depending on the size of the struct and other factors.
There are many profiling tools out there you can use like Nsight, or you can write your own (or both).
>>15181439
>Unfortunately this also gets used as an excuse to write shit code
Maybe, but it's even dumber to try and optimise as you write. It's like writing a book but you always edit a paragraph right after you write it instead of redrafting like usual. Bad programmers being bad programmers doesn't dismiss a common practice, unless that practice makes programmers bad.
>it says nothing about were to draw the line
The line is when you know what systems interact with that code. You should know with your project. Let's say you have model loading code, there's no point optimising it until you know how many models you're going to have in a scene. If you're still at the low level, stop worrying about it and get shit done.
fda723 No.15181495
>>15181482
>Maybe, but it's even dumber to try and optimise as you write.
I'm starting to think you're an NPC who can only through out vaguely related remarks and thinks that's discussion.
b4f3bb No.15181507
File: 96f40de3ae289e0⋯.png (Spoiler Image, 179.09 KB, 790x859, 790:859, 62fd3305483a8735e93c60357e….png)

>>15181495
Excellent conversation
fda723 No.15181520
>>15181507
There's no conversation being had. You're just throwing out a giant stream of consciousness that only consists of things you've been heard, verbatim, from other people.
b4f3bb No.15181523
>>15181520
So are you going to refute it or what?
fda723 No.15181530
>>15181523
What do you want to to refute? You managed to pump out all of that bullshit despite having no idea what I was specifically referring to, including random youtube talks and barely relevant analogies. None of which you'd have pulled out if you had the ability to make your own points.
b4f3bb No.15181538
>>15181530
Okay, so am I wrong or not? Why don't you say why as well.
fda723 No.15181562
>>15181538
Fuck it, I'll give it a shot even though you're just a slogan dispensing machine. I'm calling your bullshit what it is because it's completely unrelated to anything I said, and you just used it an excuse to throw out a few slogans that have been pounded into your head. I'm working on the foundation that everything else will build off of. It needs to be fast, packed tightly in memory, and cannot generate garbage. And I need to verify that using relatively new language features doesn't screw with this, because rewriting it will be much, much more time consuming when everything relies on it.
a553de No.15181579
>>15181376
It's a vague bullshit statement, but it does cover at least some valid points.
Say you decide to use a specific kind of architecture. As you continue working, you find out that it's going to be orders of magnitude too slow and difficult to expand in the specific direction you've deemed best.
So, you spend some time optimizing. If your optimization isn't trivial and getting you massive results (by way of having done things wrong before), you've probably got a problem that cannot be fixed with just optimization. You might need to pick a new architecture and fundamentally change how you process your data, and with that, most of your ad hoc optimizations might go to waste or just end up being toward what becomes a complete non-issue.
I think "don't optimize without measuring" is a much better thing to go by. Just profile every now and then and see what can be done about the nastiest spikes. 30% of CPU time going into one function call might be a spike, or it might just be the heaviest function in your program. Maybe it's something stupid and you can knock it down by a few orders of magnitude. If you're getting 95% in one spot and simple methods don't work, you might need more sweeping changes.
>>15181376
Optimizing compilers are a dark art that can sometimes mangle together ungodly messes that just do the right thing tens of times faster than should be possible, but might fail with much simpler detection of unnecessary calculations.
The general advice seems to be to try and build your system so it'd be as easy as possible to change from the suspect feature to a different implementation, but if you're talking language features, those tend to be more fundamental. This is especially bad in languages like C# and Java, where these days even most low-level documentation suggests blindly trusting the default implementation of whatever standard libraries are available.
Did you have anything specific in mind? Maybe you could make your own benchmarks to see if it's a completely pointless endeavor.
b4f3bb No.15181584
>>15181562
Finally, you did something. Well done, I'm proud of you. You could have just said that to begin with.
fda723 No.15181595
>>15181584
You're the cancer I was complaining about, of course I'm going to treat you with contempt
b3d885 No.15181768
>>15181376
>>15181416
>>15181482
>muh premature optimization meme
It has some validity in that doing weird micro-optimizations early on is a bad idea, but shitters use it as an excuse to shit out awful code and messily "optimize" it later. Keep performance in mind with your initial design (DoD makes this much easier, as does having a good idea of your target hardware and shit like how many enemies you'll have onscreen at once) and save the smaller tweaks for later.
e9b81f No.15181779
Nothing wrong with doing early optimizations if you can do it fairly easily, and it won't reduce the flexibility of the code more than you're sure you can afford.
4c583b No.15181818
Should i make collision meshes for the buildings in blender like i did the buildings or there is something else better? My brother told me to use probuilder, what are the benefits over importing a blender mesh?
abfb75 No.15181855
>>15181482
>Bad programmers being bad programmers doesn't dismiss a common practice,
Right but the whole topic was people spewing that particular line in contexts where it's not warranted because of its vagueness.
a792b6 No.15182146
>>15181376
>I need to find a book that tells me exactly how the compiler implements something to gauge the performance.
You can profile to gauge performance and you can read the generated code to see what it's doing. If you optimize without reading assembly and profiling you're stumbling around in the dark hoping to trip over the right thing.
fda723 No.15182162
>>15182146
>you can read the generated code to see what it's doing.
Which I did. At least you're not quoting a "top 100 coding tips" list on pajeet exchange.
a792b6 No.15182170
>>15182162
Then if you want to know how the compiler is implemented it's open source retard. :^)
fda723 No.15182181
>>15182170
Which, again, has absolutely nothing to do with my original complaint. You aren't even the good type of autist.
a792b6 No.15182416
>>15182181
>google something and complain about retards instead of looking into yourself
You're not autistic enough.
fda723 No.15182422
>>15182416
Alright, you've got to be baiting, no one can be that fucking illiterate.
7d1212 No.15182557
>>15181376
Its not cancerous its a fact. But what you are talking about is of a different subject matter than optimization. If you want to know how something works, that's a different subject entirely. You are not optimizing, you are learning to set the groundwork to maybe optimize later. With your own metaphor: Im filling a bucket with a liquid.
How fast does it fill and what shape is the bucket? ← this is not optimizing its just learning.
Optimizing would be like: lets create a maze of connected straws to feed water to the bucket.
The real pajeets are the type of programmers that implement the most complex quadtrees/kd trees/etc because they think their program needs to handle as many fucking million objects to be performant. No restrictions, no end to ambition, just integrate infinity in O(n) and implement the structure that handles as many objects. If you've never measured or had any sense of context, you've already wasted time and code. You don't learn this until after college and work in an actual project with specific requirements.
85fc6d No.15182578
>>15181818
holly shit check those digits
interested in answer to your question too. right now I'm building simple boxes and convex hulls by hand for my Bullet3D collision objects. An automated tool would be nice.
fda723 No.15182709
>>15182557
>The real pajeets are the type of programmers that implement the most complex quadtrees/kd trees/etc because they think their program needs to handle as many fucking million objects to be performant
No, that's not at all what a pajeet is.
7d1212 No.15182955
>>15182709
Yes it is. Its a sign of an amateur coder. Context is always better than bruteforce when designing anything. Optimize only when needed. It's not bad programming, its genuinely an accepted statement.
057f3f No.15182980
I started looking into procedural generation stuff and stumbled upon this.
https://gist.github.com/selfsame/e7ff11205c316888977f9cac04fe4035
There's a direct port to Unity, so I've been working on that.
Lower in the page it mentions Symmetry types with this explanation
>Note that the tiles have the same symmetry type as their assigned letters (or, in other words, actions of the dihedral group D4 are isomorphic for tiles and their corresponding letters). With this system it's enough to enumerate pairs of adjacent tiles only up to symmetry, which makes lists of adjacencies for tilesets with many symmetrical tiles (even the summer tileset, despite drawings not being symmetrical the system considers such tiles to be symmetrical) several times shorter.
Can anyone translate this to more simple terms? I have no idea what it means, I'm a simpleton from the countryside
fda723 No.15182985
>>15182955
>Yes it is.
No, it's not. There's absolutely no connotation to pajeet that includes "spends too much time engineering fast and scalable solutions". You're just an idiot who thinks words can mean whatever he wants them to.
9a970c No.15183008
>>15182980
It doesn't say that anywhere on that page you linked.
057f3f No.15183031
b3d885 No.15183047
>>15182980
>>15183031
>See how the floor has the same kind as its own ABCs (or, in other words, actions of the up angle daycare four Ds are similar but different granddads for floors and their ABCs). With this computer it's okay to list mommies and daddies of floors side by side only up to same sides, which makes lists of side by sides for floorsets with many side by side floors (even the summer floorset, despite crayons not being side by side the computer thinks such floors to be side by side) a couple clocks more kiddish.
057f3f No.15183099
>>15183047
good effort
way worse
I need some better /agdg/ metaphors
7d1212 No.15183127
>>15182985
No. I've genuinely worked on projects unlike your dumbass asking for compiler help on 8ch. Scalable solutions are great. But there is no point in achieving it if you don't use it. It should be made for necessity and not just on a whim. Reason why people spew the premature optimization is because 9/10 times its people who do it merely because they think its faster. Many times its overkill and harms performance from just the more overhead. That's why context and measuring is important. Git good son.
9a970c No.15183195
>>15182980
>>15183031
Alright, let me try to translate.
Each tile corresponds to a letter.
Each letter has a specific kind of symmetry.
Take the letter X. You can rotate it 90 degrees, and it's the same. You can mirror it vertically or horizontally, and it's the same.
>Note that the tiles have the same symmetry type as their assigned letters (or, in other words, actions of the dihedral group D4 are isomorphic for tiles and their corresponding letters)
That's saying "you see the kind of symmetry in those letters, that same symmetry exists in the tiles". So the tile that corresponds to X can be rotated 90 degrees or mirrored horizontally and vertically and it's the same, just like the letter X.
Now take the letter I and mirror it across the Y axis and it's the same, mirror it across the X axis and it's the same, but if you rotate it 90 degrees it's something different. The same can be said for the tile it corresponds to.
>With this system it's enough to enumerate pairs of adjacent tiles only up to symmetry,
Because some of the tiles can go through various transformations and become new tiles, we only need to mention the original tiles, we don't need to include the tiles post-transformation. With the I tile, we only need the I tile, we don't need the I tile rotated 90 degrees, or the I tile mirrored over the Y axis.
>which makes lists of adjacencies for tilesets with many symmetrical tiles several times shorter.
Because we can do this with the tiles we don't have to store all of the rotated and mirrored tiles, making the list of tiles we need to store and worry about a lot smaller.
057f3f No.15183223
>>15183195
So
>X can be mirrored and rotated
>I can be mirrored on both X and Y
>T can only be mirrored in Y (?)
>L can be rotated (?)
9a970c No.15183288
>>15183223
It's not giving limits on their rotation mirroring, it's saying that the specific properties of symmetry that exist in the letters also exist in the corresponding tiles.
I can be mirrored on both X and Y and the tile is the same. Rotation is allowed, you just get a new tile. This new tile is useful because you just have to store the I tile, not both the I tile and the rotated I tile.
057f3f No.15183350
>>15183288
Okay but then what kind of symmetry does L have? It can't be flipped on any axis.
fda723 No.15183397
>>15183127
>No. I've genuinely worked on projects
I've "genuinely worked on projects" and I seriously doubt you have anything useful to say. If you did, you already would have.
9a970c No.15183409
>>15183350
I'm not saying that the tiles are all symmetrical, I'm saying that the symmetry that exists or doesn't exist in the letters exists or doesn't exist in the same way in the tiles.
Just like when you mirror the letter L on either axis the result doesn't look like the letter L, when you mirror the L tile the result doesn't look like the L tile. That's the entire point, because you can mirror and rotate tiles to get new tiles, you don't need to store all the mirrored or rotated versions of tiles.
7d1212 No.15183687
>>15183397
Try replying with an actual argument. Maybe you'll get what you are looking for.
453e41 No.15183731
>>15183687
>Look at who this post is talking to
>Its the dude I filtered way earlier in the thread
Oddly satisfying.
218ee8 No.15184642
>>15181416
That's nonsense. Noone is suggesting to do little bitshifting tricks before you even benchmark your program.
If you don't plan out your program in advance to handle data optional and structure it all correctly, you're going to end up with an inefficient program where the bottleneck ls you're measuring aren't even relevant because your entire program runs like shit.
433398 No.15185418
i'm retarded and can't into matrices
how do i get UVs in a unity shader to always scroll in a direction that local to the mesh rotation?
i can get it to scroll along world pos and uv coords, but neither is exactly what i want
e9b81f No.15186343
Are there any decent guides to reading font files?
I can't make sense of the "specifications", they talk about tables and all kinds of shit that the file may contain, but they're really vague about how to start actually reading the file.
453e41 No.15186497
>Trying to do animations
>Follow formula for animations and skinning EXACTLY
>Shit is fucked
>Try using a sample model with 2 fucking bones
>Realize matrix multiplications in GLM are done BACKWARDS
>Flip everything around
>It looks like it almost works except the sample model is at a 45 degree angle
>Try with my original model
>it's all fucked up
This shit has been delaying me for so fucking long
28ee7f No.15186702
I'm been thinking of choosing what programming language i want to learn. I've been learning python and i heard great things about C++.
Are there any good programming languages for me to use when i am making a game. the idea of a game i've been wanting to make was a metroidvania. pic related was a great game and i feel pretty inspired right now
057f3f No.15186738
>>15186702
If you don't know any programming at all you might as well use an engine, after that it's essentially just about seeing what language that engine uses and learn that.
There's not a particular language that's better for certain types of games.
abfb75 No.15186743
>>15186702
It's not really important which one you start with. They all have their advantages but you can pretty easily learn a new one once you get a solid grasp on one, so just stick with whatever you start with until you git gud.
Python is probably sufficient for what you want. Look up pysfml when you get a handle on it.
9a970c No.15186767
>>15186702
If you're just starting out you would be better off choosing a game engine and learning the programming language of that engine. If you are already familiar with python you could look into Godot, or you could learn C# for Unity 2D.
28ee7f No.15186788
>>15186779
But thank you for the suggestion anons. I think I will start with Godot because the familiarity of python and the fact that it is open source
e9b81f No.15186791
>>15186779
You can't really say that one is "better" than the other, they have different reasons for existing.
Making things with C++ requires a lot more work on your part and is more difficult, but it also allows for much greater performance than Python ever could. There's also more libraries and things that you can interface with using C++.
057f3f No.15186795
>>15186779
Python's pretty trash, I wouldn't make a full game by hardcoding with it
b4f3bb No.15186808
>>15186702
Just learn C. It's C++ with 99% of the good things and 1% of the bad things. It's the original high level language (although it's not high level at all by today's standards).
28ee7f No.15186814
>>15186791
>>15186795
>>15186808
I'll consider that as well anons. I feel motivated due to the self improvement I've been doing. Meditation every day, exercising got me a lot more energy to really dedicate myself to learning how to gamedev. thank you anons. you guys are great
b3d885 No.15186818
>>15186767
>Unity 2D
aka "rendering a 2D plane with our 3D renderer totally won't have any performance overhead"
>>15186795
Which is why >>15186743 suggesting pysfml is probably a bad idea unless it uses C++ for performance-critical stuff like Pygame.
28ee7f No.15186824
>>15186818
wait why is python bad anyway. i thought it was a good programming language to start out with. quick rundown??
b3d885 No.15186854
>>15186824
And it is a decent starting language, the issue is that it's not particularly fast and performance is very important to vidya. It's fast enough to use as a game's scripting language if critical parts of the engine are written in C or C++ (such as Godot and its "I can't believe it's not Python" scripting language or LÖVE and Lua), but if you tried writing an entire game from scratch using Python it would be unnecessarily slow.
Don't let this bother you too much. Pick up something like Godot for now and maybe learn C or C++ on the side in case you want to optimize certain scripts beyond Python/GDScript's limitations, but for 99% of game scripting stuff languages like Python and Lua are okay.
abfb75 No.15186855
>>15186824
It has its drawbacks. It certainly runs slower than C++, by at least an order of magnitude, and it's not statically typechecked (or checked very much at all) in advance, so e.g. a typo that could have been caught by the compiler in C++ wont rear its head until you actually try to run that part of he code. This makes it increasingly annoying to work with as your program grows.
Also, I don't really think it deserves its reputation for being "easy." It pretty forgiving when it comes to syntax and usually does something sensible (e.g. converting int to bool inside an if() statement instead of throwing an autistic fit like java) and has some convenient syntactic sugar, but it also lets you write dumb bugs that would have been caught in other languages, which is not great for people learning on their own.
6fe0c1 No.15186857
>>15186824
Python is "good to start with" because it's relatively simple and for some reason clicks in non-programmers' brains more easily, for instance for artists.
It's also slow, has a bunch of features programmers tend to dislike (such as var and whitespace-based blocks instead of using { }), and since it doesn't compile there's also no compiler to catch certain mistakes when compiling instead of after 15 minutes of running.
a51b75 No.15186863
>>15186824
The core things of programming are interchangeable anyways. Things like logic, branching, iteration, are more or less identical between languages (though some have minor gotchas, the fundamentals are the same).
Like anon said, for a moderate-sized game, the core parts of the game should be in a lightweight language (eg the graphics). Python (and other interpreted languages) shouldn't be doing any logic, only function calls, or what have you.
a51b75 No.15186882
*teleports behind u*
*makes new thread*
Pssh, nothing personnel kid
>>15186873
>>15186873
>>15186873
>>15186873
>>15186873
28ee7f No.15186883
>>15186854
>>15186855
>>15186857
>>15186863
thanks for the info anons. Honestly i was way more confused about what programming language to do but you guys have way more experience than i do.
Also would it be a good idea to start with passion projects early on or should i start small like a pong clone, a rogue-like clone. Im just blatantly new to programming
abfb75 No.15186912
>>15186883
Start with some small ones, tbh. Or do them along the way. It can be pretty demoralizing anyway to work on something for years without finishing anything, and a lot of people end up starting over entirely because they learn things along the way that makes them feel like they've been heading down a dead end. Actually finishing stuff gives you a feel for how things work together, and helps give you an idea of whether your passion project is actually feasible.
e9b81f No.15186927
>>15186883
I think it's ok to start with whatever game you want to make. You're not going to finish it, but the only way to learn to make your dream project™ is to start working on your dream project. The experience you'll gain from making Pong isn't really that different from the experience you gain from working on features of any other game, in fact it's more likely to be different than similar.
9a970c No.15186942
>>15186814
Learn C in addition to C++, preferably before. C++ is C with a bunch of stuff added to it. As a result C++ is bigger, more complex, and more difficult to learn in it's entirety. C++ also has objects and is built around OOP, whereas C is not. Using OOP in games without very strict discipline is a bad idea, so learning how to program without it entirely is useful especially when you are starting out.
C also does less memory management for you, which gives you more opportunities to mess up but also teaches you important lessons on how your computer actually works with data. Knowing this is core to optimizing your games.
Once you have a good base in C you can start learning about the features that C++ adds and decide for yourself if you want or need them. If you don't then you can stick with C, if you do then you can move over to C++ and use everything you learned in C. It's up to you.
4e2616 No.15188676
>>15186497
I got animation working with a custom exporter and I still don't know how it works.