HNHacker News
TopNewBestAskShowJobs

adamdusty

514 karma · joined January 21, 2021

submissionscomments
adamdusty··on Data-oriented design or why you might shoot yourself in the foot with OOP (2009)
My comment has nothing to do with implementation. We're talking about ECS in the context of DoD so I'm not sure what relevance being data-oriented by default has. It seems like you're just confusing the concepts of ECS, DoD, and composition.

Your entire post on ECS is, "If you don't use DoD with ECS than you're not using DoD". Well yeah.. obviously? If you implement an ECS and then use it without data-oriented structures, then yes obviously you don't have data-oriented design.

You're creating a strawman. You're saying if you take ECS, remove the idea of storing components independently of entities, and pass them in an inefficient manner to systems, then you don't have DoD. ECS isn't inherently DoD, literally nothing is. Arrays aren't inherently cache friendly. There's nothing stopping you from making a language that allocates data randomly throughout reserved memory and every array element points to each location. No one is arguing ECS is inherently DoD, but it is a good design to facilitate DoD.

> For example we might want to do damage to another entity entirely.

Add a damaged component to the entity to damage. Consume damage component in a system.

> Or we might want to look up the properties of the piece of ground we're stood on

Use a position component on the entity standing on the ground. Consume the position in a system and look at the properties of the terrain map at that position. Even simpler for grid based maps.

> We're also ignoring interacting with other components or the world and how that might work

You interact with other components by defining interactions in systems based on those components.

You've created an ECS in a way that doesn't take advantage of any of the benefits, and complaining that all you're left with is the disadvantages.

adamdusty··on Data-oriented design or why you might shoot yourself in the foot with OOP (2009)
Sure ECS is object oriented in the same way C99 is. Yeah, technically you are building up some OOP functionality, the same way you emulate constructors and instance methods in C by making functions to init data structures and functions that take references to a struct to modify it's data. That doesn't make C object oriented.

In ECS you are decoupling data from behavior, which is basically the entire paradigm of languages like rust and go. You could argue that by defining systems in a way that they run on certain components you are defining behavior and data in one, but I think that's a stretch.

It clearly differs from OOP when I have 2 entities with components that have overlapping and non-overlapping systems. If e1 has components c1 and c2, and e2 has components c2 and c3, and c1 and c2 are used in system s1 while c2 and c3 are used in system s2, I don't see how you would model that with OOP without adding data to classes that don't need it. In OOP both e1 and e2 would need all the logic from s1 and s2, or needlessly specialized versions of s1 and s2. Which would be solved via inheritance (either class based or interface based).

In ECS your data exists in an array of components and any part of your program can operate on any component however it wants. I've never needed message passing for anything I've worked on.

That's not to mention that the main benefits of ECS have nothing to do with language paradigm. ECS main advantage is cache coherency and easier parallelism.

adamdusty··on Goodbye C++, Hello C
The author lists GLFW, stb_image, and ImGui as dependencies for their renderer written in C. Those are the same exact dependencies you would use to write a renderer in C++. Maybe you would add glm because you don't want write matrix math operations, but the author will have to do that in C anyway. I don't see how dependencies are an advantage for C.
adamdusty··on New Records Show the NYPD’s Favored Punishment: Less Vacation Time
Most people don't know how the police operate. Growing up, my stepfather was a police officer, and I have no idea how they operate. Other than the big stories of officers getting off with essentially murdering people, I don't think people are too dialed in to law enforcement.
adamdusty··on Microsoft is bringing Android apps to Windows 11
They had to partner with Amazon or no one. Amazon already has an android marketplace, and there's no way Google, who has a "competing" OS, is going to facilitate users using apps on windows. Google especially isn't going to combine the play store with the microsoft store and let MS call it the microsoft store.
adamdusty··on Microsoft is bringing Android apps to Windows 11
Not sure what that guy is talking about, but some people are frustrated that WSL2 is basically a linux VM, and F# has been little more than an experimental playground for .net features. I don't care about either project, but these are the complaints I hear the most.
adamdusty··on California will pay off all past due rent
If your mom tells you and your brother to clean the house, bathe the dogs, wash the cars, and repaint the living room, and you do all of it while your brother is sick, you wouldn't feel slightly upset if she paid his rent and you got nothing? Most people don't want all those people to be homeless, but it does feel punishing that other people are having their way paid for while contributing less.
adamdusty··on Stride Game Engine
I can't stand this mentality, but here is a list of reasons:

* ECS is built in, not tacked on (unity DOTS)

* Also supports unity/ue actor model style

* Gives you complete control over rendering, access to opengl/vulkan/d3d12 context

* Built in scene streaming (stream objects in and out as needed, similar to UE5 terrain chunking

* Fully built in C#, runs on .NET 5 (xplat), and uses the latest version of C#. I don't know which version unity is stuck on

* The "engine" is just a tool, you can use stride as a framework and make a code-only project (my personal reason for using it when I do)

* MIT license

* Aysnc scripting capabilities

* Technically supports dev on linux (code-only)

* FOSS

* On top of all that it was developed by Silicon Studios, a company that actually makes money off of real-time rendering

adamdusty··on FDA Moves to Ban All Menthol Cigarettes and Flavored Cigars
I'm not going to argue for or against the ban, but tobacco companies specifically targeted african-americans to use them and the civil rights movement to defend industry policy.

Mexicans like tequila because it's made from agave which is easy to grow in the desert. Mexicans have loved tequila since before europeans even landed in mexico.

adamdusty··on Ask HN: Did a team building exercise ever work for you?
In my experience, team building exercises just help you get more comfortable with your co-workers, regardless of whether or not each individual recognizes that it's happening.
adamdusty··on Show HN: I made a simulator for personal finance
>Please don't use HN primarily for promotion. It's ok to post your own stuff occasionally, but the primary use of the site should be for curiosity.

Posting the same site twice in 2 weeks seems more than "occasional", and in my opinion, crosses the line from "look what I made" to self promotion.

adamdusty··on Just Be Rich
He's using "protestant" as an adjective of zealotry, not as an adjective of the people themselves.
adamdusty··on Facebook's 'Clear History' Tool Doesn't Clear Shit (2020)
They didn't plant a GPS tracker, you bought it and use it for navigation, messaging, and social media.
adamdusty··on All C++20 core language features with examples
Rust is so far from taking over c++, you could bury your head, my head, and everyone else's head in the sand and we'd still be waiting.
adamdusty··on A curated list of .NET performance resources
And on the other hand, Bing is running on the first preview version of .NET 6.

MS is a big company, they aren't going to immediately migrate everything just like Google didn't migrate every single project to Go when they were heading it.

adamdusty··on Only Google is really allowed to crawl the web
They want you to pay them to "research" google's web crawling monopoly. It's really just a donation, but they don't frame it like that. Probably more credible than using a crowd funding website, because it sounds like their pushing for actual legislation.

> Meet with legislators and regulators to present our findings as well as the mock legislation and regulations. We can’t expect that we can publish this website or a PDF and then sit back while governments just all start moving ahead on their own. Part of the process is meeting with legislators and regulators and taking the time helping them understand why regulating Google in this way is so important. Showing up and answering legislators’ questions is how we got cited in the Congressional Antitrust report and we intend to keep doing what’s worked so far.

adamdusty··on PinePhone – Beta Edition Linux SmartPhone Preorder
Its a phone you can purchase from their website that they will send to you. The purchasing process is exactly the same as buying a galaxy s21. If companies could just say "this is an unfinished product" to get around mandatory warranties, everyone would do it. PinePhone should not be exempt because they are selling what they call a beta product.
adamdusty··on SvelteKit Is in Public Beta
Isn't that exactly what's happening? Svelte is a library and SvelteKit is a framework built on top of it? I think.
adamdusty··on Small, cheap spy satellites mean there’s no hiding place
Google turns up nothing on anything from that quote.
adamdusty··on ZGC – What's new in JDK 16
After some research I couldn't really find much of an answer.

The thing about GC is you either don't care at all, or you don't want it at all. There's rarely a case where you know how many GC cycles you can handle in a certain period. Web dev, GC all you want. Games can handle GC but its likely you'll need to be cognitive of memory use. Embedded stuff doesn't have enough memory to utilize a GC.

I'm sure why GC languages get so much hate. I do a lot with C# and the runtime gives a few options for controlling allocations and accessing memory, so I can usually get it to be fast enough.

adamdusty··on A curated list of .NET performance resources
Sure, but comparing to python is disingenuous. Python3 was a complete break from Python2. The first version of .net core (5ish? years ago) broke the standard library down to only libs that work cross platform.

Is there anything in .NET 5 you're missing from .net 4.x?

adamdusty··on A curated list of .NET performance resources
This[0] guy claims to work at a shop that uses C# for HFT. This[1] comment chain from a post about Java HFT has users claiming to use C# for HFT.

[0]: https://www.youtube.com/watch?v=ug_UC4lxMr8 [1]: https://news.ycombinator.com/item?id=24896616

adamdusty··on Java 16
What fancy features won't we understand?

I think some things about functional programming make code feel cleaner, but I don't like it enough to use F# or Haskell.

adamdusty··on How I make graphics for retro systems and retro-styled games
There is a madden modding community at footballidiot.com/forum

Might be the place to start. Madden 08 is the biggest target as far as I know, but someone there might be able to point you in the right direction.

adamdusty··on Checked C
Python has at least 3 relatively popular implementations that I know of.
adamdusty··on Epic Games steps up Apple fight with EU antitrust complaint
You're right about steam. Monopoly isn't the right word.

Steam is the only one on that list that takes 30% that I know of. MS store went through a period where they would pay you to put your app there.

adamdusty··on Nvidia announces mining GPUs, cuts the hash rate of RTX-3060 in half
Then get literally any other Nvidia card?
adamdusty··on Epic Games steps up Apple fight with EU antitrust complaint
I wouldn't consider amazon prime a physical good or service.
adamdusty··on Epic Games steps up Apple fight with EU antitrust complaint
I figured you were right, so I just signed up for prime.. through the app, and it didn't use the play store payment system, so Google isn't taking a cut.

Again, I have no idea what is possible on the Apple version, but I have subscriptions on other apps that go through the play store payment system. I'm not an expert on app store policies for payments, but I don't use any other apps that have subscription payment that don't go through the play store. I have a LastPass subscription which I purchased through their website, specifically because you have to go through the play store if you get it through the app.

adamdusty··on Epic Games steps up Apple fight with EU antitrust complaint
Nobody is going to not put their app on the apple app store. Look at steam for example. Almost every game on steam can be purchased somewhere else, like icth.io or the game's website. 30% is industry standard among monopolistic players (Google play store, Apple app store, Steam). There are many other storefronts that take less of a cut, and don't require IAP to go through a specific payment system that the platform also owns. FDroid, MS Store, Epic Store, Galaxy Store, GOG, the list goes on.
← PreviousPage 5 of 6Next →