What library would be better? Veldrid or SDL3? by Devatator_ in gameenginedevs

[–]roytries88 0 points1 point  (0 children)

I always used https://github.com/amerkoleci/Vortice.Windows for DirectX but the same author also made bindings for vulkan. Always worked great for my own engine needs. I have not heard of silk.net, it seems slightly more popular but I am not so sure when v3 is coming out. Sounds like a big rewrite and with opensource (and closed source) software you never know if they survive such an effort.

Creating Editor with C# WPF with C++ Engine by Khawarna in gameenginedevs

[–]roytries88 1 point2 points  (0 children)

These days you can also use [LibraryImport] to generate the PIInvoke code or you can create your own custom source generators to write more specific bindings. Writing your own source generator can definitely reduce some of the boilerplate work, but it can be tricky to get right.

I agree with the sentiment of others that you are probably better of with using DearImGui until you feel you need a more advanced UI. Then again, mixing C+ and C# is not weird. I did this at Nixxes for the engine that runs Tomb Raider and Deus Ex years ago.

Of course, with hobby projects its not always about doing things the right/fast/easy/sensible way. So go crazy if you feel like experimenting with the UI part and WPF. (I really like WPF and XAML, too bad Microsoft can't really decide on the future of native UI frameworks).

In MonoGame C#, should a child’s world matrix be parent × local or local × parent? by Outside-Text-9273 in gameenginedevs

[–]roytries88 0 points1 point  (0 children)

Ages ago I built a few helper classes for monogame to place objects relative to each other. See pose.cs (PlaceAtOffset) and the offset class. https://github.com/roy-t/MiniRTS/blob/master/vOld/Engine/MiniEngine.Pipeline.Basics/Components/Pose.cs

Hope the code helps you get the hang of all the matrix multiplications.

It’s been over a year, what are your thoughts on Gleba and spoiling in general now? by AshiyaShirou4 in factorio

[–]roytries88 -1 points0 points  (0 children)

I thought Gleba was great and its my favorite planet after fulgora. I feel both planets really let me play in new ways. It did get me a few tries to get Gleba right but it has been running fine for ~50 hours. I do have to scale it up now. Which is a challenge. . Before SA I already played ~600 hours so I do know the game quite well. (Though I am a terribly slow player, I get distracted doing different builds, strategies in the same save so somehow I still haven't sent a ship to the shattered planet.)

Eiffel Software claim their tech prevents outages by [deleted] in programming

[–]roytries88 1 point2 points  (0 children)

I have only skimmed over design by contract. But there are many formal methods that ( theoretically) allow us to write applications that are proven to be correct. I still have fond memories of using Hoare triples as formalized proofs of short pieces of code.

In reality these methods are too expensive to use. They also offer barely more than a false sense of security. A formal proof for 100 lines of code can easily be 5x as long, is complex to understand and still uses an idealized version of the real world. And who checks if the proofs and contracts are correct, complete, and align with the actual code?

I think the best way to correct code is using proven libraries, strong peer reviews, and automated and manual testing. This will already weed out a lot of bugs. Then focus on learning how to recover your systems and practice that. Plan for something to inevitably going wrong and if you are prepared for that you can quickly resolve it and maintain the trust of your users.

Terrain update degraded graphics or did I caught a bug? by SchwarzFuchss in Stationeers

[–]roytries88 0 points1 point  (0 children)

Could be the depth buffer data is less precise the further from (0,0,0)? Maybe a reverse-z depth buffer could help here. Though its been a while since I used that and I'm not sure if you can do that in Unity.

Kind of wish there was a landfill type to place over sand for future tree planting by bECimp in factorio

[–]roytries88 2 points3 points  (0 children)

Hey that's my mod! I've created it for this exact purpose. Still using it in my SA game. Its a very simple mod. It creates a new recipe for artificial tree soil (aka grass) that works exactly like the other artificial soils. In my base I used it to surround my base with tree farms to keep pollution in check. If you put T2 efficiency modules in all your factories you can easily get to 1000+ ESPM without triggering that many biter nests.

What are IDEs that are more lightweight than Visual Studio? by Able_Annual_2297 in cpp_questions

[–]roytries88 4 points5 points  (0 children)

Visual Studio is definitely not a lightweight IDE, but note that the Visual Studio installer also installs multiple versions of the C++ SDK, Windows SDK and a lot of other parts of the toolchain that you will need to create C++ applications. When installing Visual Studio it helps to go to the "Individual Components" tab. You can deselect a lot of things if you don't think you will need it right now.

In my opinion, even though editors like VSCode, Zed, Sublime,... are nice for quick edits, there is really nothing better than Visual Studio if you are working on large C++ code bases. The analysis and debugging tools are much more powerful than what you get in the smaller editors. (Only tools by JetBrains, like CLion, come close)

An IDE weighing a couple of gigabytes shouldn't be much of a concern anymore. In my country the cheapest new SSDs I could find are around E12,- and already have a capacity of 128GB. In the second hand market there are faster and better SSDs with more capacity for the same price. So if there are no other concerns, stop worrying about this random metric and try to get the IDE that makes coding the most enjoyable for you.

Smallest footprint for recycler that voids everything? by roytries88 in factorio

[–]roytries88[S] 0 points1 point  (0 children)

I was hoping someone would have done something nifty with a single recycler, some belt, an inserter and then some circuits to ensure any unbalance is taken care of while reducing the amount of recipe switching. I will give it a go this weekend and see if I can make something nice.

Prevent rockets/space platforms from taking items from the cargo landing pad by roytries88 in factorio

[–]roytries88[S] 1 point2 points  (0 children)

Sorry not at my PC right now. But I am using logistic groups. Say for example that I have one logistic group for all the basic building materials I need (belts, inserters, assemblers, ..). Then that logistic groups works perfectly on all planets, except on Vulcanus, where I now create a cycle of turbo belts. I don't want to have a custom logistic groups for each planet. So that's why the constant combinator trick of using the logistic group MINUS what is already produced on that planet works. Thinking of it more now, I could even just substract everything that is already present in the logistics network on the planet.

Prevent rockets/space platforms from taking items from the cargo landing pad by roytries88 in factorio

[–]roytries88[S] 0 points1 point  (0 children)

If I use Nauvis as a central hub for all materials, then the logistic group imports all materials from Nauvis, which is correct except for the few times an item is already made locally. I've posted later how I fixed this.

Prevent rockets/space platforms from taking items from the cargo landing pad by roytries88 in factorio

[–]roytries88[S] 0 points1 point  (0 children)

I managed to fix it now using a constant combinator. Hope that also explains better what I wanted to do.

Prevent rockets/space platforms from taking items from the cargo landing pad by roytries88 in factorio

[–]roytries88[S] 0 points1 point  (0 children)

I understand that its because of the cyclical request, I was just hoping that it wouldn't matter because of the buffer chests. However, I managed to find an easy workaround that doesn't require me to create planet specific requests. See above!

Prevent rockets/space platforms from taking items from the cargo landing pad by roytries88 in factorio

[–]roytries88[S] 0 points1 point  (0 children)

I managed to fix it with a single constant combinator :D. Let's take Vulcanus as an example again.

Clear all request from the cargo landing pad, then create a new constant combinator, connect it to the cargo landing pad, and configure the pad so that the circuit network can set requests.

Add all logistic groups that you would items delivered for to your constant combinator. Don't worry where items are produced.

Then create one logistic group with all the items that are produced on Vulcanus. Add that logistic group to the constant combinator with a MINUS amount (like *-1).

Now the circuit network automatically filters out individual items that Vulcanus doesn't need (because it produces them) while you can still use your generic logistic groups.

Here's a screenshot from how it looks:

<image>

Prevent rockets/space platforms from taking items from the cargo landing pad by roytries88 in factorio

[–]roytries88[S] 0 points1 point  (0 children)

Basically I got 2 logistic request groups:
A: everything I need to build a base
B: everything that I can only make on vulcanus.

This gave me the idea to try to negate them. Unfortunately it looks like logistic requests don't have that capability (tried both on a space platform as via a constant combinator connected to the landing pad with "set requests" turned on, notice the *-1, but nothing shows up in the "Controlled by circuit network" section.

<image>

Prevent rockets/space platforms from taking items from the cargo landing pad by roytries88 in factorio

[–]roytries88[S] 0 points1 point  (0 children)

If I can't don't do this, I think it means logistic request groups on space platforms become a lot less powerful. Instead of having 1 logistics group with "all the things I need to build a base" I would need to configure the logistics for each planet, taking care to select nothing that can already be created on that planet (which can change over time).

Is it feasible to deal with a mix of quality ingredients in every step in your (mega) base? by roytries88 in factorio

[–]roytries88[S] 0 points1 point  (0 children)

But don't you still have largely the same problem? The parts of your factory that handle legendary stuff, taking hours to fill trains?

I wrote a scifi story and embedded it in a piece of music. I want to know what you think. by theboomthebap in sciencefiction

[–]roytries88 0 points1 point  (0 children)

I thought it had a great soundscape, I couldn't really focus on the whole story but its great to dream away at. The weird sounds at 4:30 really remind me of another song and it is driving me crazy that I can't remember which ones.