Live data from Hacker News

Porting 58k lines of D and C++ to Jai

yet-another-blog.com

61–70 of 264 posts

Re: Porting 58k lines of D and C++ to Jai

#61
post #39

Earlier quoted context omitted.

It’s hard to find any material on Jai. It seems to be a “better C”. Isn’t that what D / Zig try to do? What’s the advantage?

I think that Jai / Zig / Odin all started around the same time. D is closer to C++ than C, in my opinion. I suspect that Jai was an inspiration for Zig and Odin. Many developers in gamedev circles are still using C or orthodox C++ (C++ without most of the bullshit) but are frustrated by many features and gaps. Short compilation time is one of the big goals, as it is crucial for fast iteration. The goal is simply to h…

Right that makes sense.

I’m curious if the gaming industry will switch languages, it feels like with the current game engines that it’s heavily entrenched in C and C++. Feels like something like Carbon has the best chance to break in.

Re: Porting 58k lines of D and C++ to Jai

#62
post #50

This person might as well said that he is not planning to finish his game. Screwing around with tooling and languages seems to be a common pitfall to not finishing a game. Why not just use the best ecosystem like Unreal/Unity and get the game out of the door fast?

> Why not just use the best ecosystem like Unreal/Unity laughable. absolutely laughable. I'm not even talking about politics of using an engine versus writing one; unity and unreal are complex tools with their own problems. if you value what you are producing, and if you value quality and you want your game to be just the way you want it, Unity and Unreal will fight you just as hard as D or C++ have been for the blog…

Could you give an examples of a game that used a custom game engines that couldn’t achieve what they wanted in Unreal or Unity?

Edit: The only style I would think would be infinite/strange geometry, like Manifold garden (great game!). But, it’s Unity.

Re: Porting 58k lines of D and C++ to Jai

#63
post #48
post #41

Earlier quoted context omitted.

While I agree with most of your points, I am not sure what this has to do with the parent you're replying to. The one part I disagree with is: > A lot of these things do find some modest niche to survive in. But none really take over the world as originally forecast by the hype wave. One of Blow's critique of C++ is specifically that it's trying to be the everything language. Jai's goal is to be for video game develo…

It's false, he never said that it was only for games.

But the decisions made are going to be for the benefit of game development first, and everything else secondarily.

Re: Porting 58k lines of D and C++ to Jai

#64
post #8

I don’t understand how this language is planning on ever seeing adoption when it’s been restricted from open use since it’s inception. Seems like vaporware.

Maybe it's a marketing thing. Creating a perception of exclusivity. Making Jai the Maserati and Gucci of programming languages. That's ridiculous but seeing the odd level of interest in this language that almost nobody can use means maybe it's working.

It's "do I have bandwidth to deal with all the feature requests?" thing for now.

Re: Porting 58k lines of D and C++ to Jai

#65

Earlier quoted context omitted.

I think Jonathan Blow's main goal is to make his dream game programming language so that he can be happier while developing all of his future games. Widespread adoption by others is only a secondary concern. He also doesn't want to push it out to the general public until he feels it's ready, and wants to take the time to get it right first.

Jonathan Blow is a skilled craftsman with stuff like this and he knows he's going to get a bunch of Opinions About His Language from people who think they have a complete superset of his knowlege, and he is making his language without involving those people in any way.

No post body was provided.

Re: Porting 58k lines of D and C++ to Jai

#66
post #50

This person might as well said that he is not planning to finish his game. Screwing around with tooling and languages seems to be a common pitfall to not finishing a game. Why not just use the best ecosystem like Unreal/Unity and get the game out of the door fast?

> Why not just use the best ecosystem like Unreal/Unity laughable. absolutely laughable. I'm not even talking about politics of using an engine versus writing one; unity and unreal are complex tools with their own problems. if you value what you are producing, and if you value quality and you want your game to be just the way you want it, Unity and Unreal will fight you just as hard as D or C++ have been for the blog…

> laughable. absolutely laughable.

It’s really not laughable.

I’ve made games with off-the-shelf engines and I’ve made games using just code and libraries. Sometimes not even libraries.

The main concern here is that you have a limited amount of time to work on your game. Some people try to sidestep this concern by saying that they’ll “spend as much time as it takes” or something like that, but since these projects often fail due to attrition, I’m skeptical.

Engines like Unity and Unreal have plenty of constraints and they fight you, but you don’t have to fight them unless you have powerful, immovable, inflexible opinions about how the game code should be implemented. Otherwise, these engines give you a surprising amount of freedom. This freedom is not apparent to casual users of the engines and it’s not apparent if you read forums explaining how these engines are used.

> They are definitely not a pure win for someone making a game.

Sure. Not a pure win. In some sense, however, time is interchangeable with time. By choosing an engine like Unity or Unreal, you save some time in some areas of the project, and that time can be reinvested in other parts of your project. You end up with a higher-quality game in the same amount of time, in typical scenarios. Or you end up with a similar-quality game in a smaller amount of time, in typical scenarios.

Re: Porting 58k lines of D and C++ to Jai

#67

I wrote an extremely hard and complex program in which I had to use c++ metaprogramming throughout. Not my decision. I do not understand why you could possibly need more metaprogramming than C++ provides. This is a problematic feature to begin with. Not worthless but not worth much. The debugging was difficult. Many problems show up buried in literally thousands of compiler error messages.

C++ started with templates as a type polymorphism mechanisms.

Then it was shown to be turing complete so people started using it as such.

The over time it started getting more and more things constexpr such that it's easier to execute during compile time (because it's turing complete).

Jai just made the decision that everything is constexpr by default.

And the answer to your question is that it's easier to do in Jai (in theory) than C++.

Re: Porting 58k lines of D and C++ to Jai

#68

Earlier quoted context omitted.

Over the past decade, I watched HN's and Reddit's hype waves cycle through server-side JavaScript, Golang, Haskell, and now Rust. With plenty of secondary favorites in the mix like Julia, Nim, Zig, etc. A lot of these things do find some modest niche to survive in. But none really take over the world as originally forecast by the hype wave. Ultimately, you either enjoy tinkering with programming languages for persona…

Javascript absolutely took its position. Speaking of those waves, where did Ruby and RoR go? Seems completely dead on HN whereas 'back in the day' it was top most talked thing. LISP would be a guest of honor - always there, never here.

Ruby/RoR values form over function. Over the past few (five or so?) years, as teams went through the transition from aggressive feature development to devoting more effort to maintenance and operations, they realized that relying on conventions as a guiding principle has a substantial cost burden that you don't pay when prefer rigor and specification.

Re: Porting 58k lines of D and C++ to Jai

#69
post #15

Earlier quoted context omitted.

> Supports x86 architecture only No native macOS then? > No virtual functions > Jai is less dogmatic okay

> No native macOS then? Or Pi, or iOS, or practically all Android hardware… Kind of a non-starter IMO. Maybe this was marginally acceptable when the language started in '14 but it becomes less so every year.

Blow is designing and implementing a language for making video games, and in particular, for making Thekla’s video games (Jon’s game company). Blow does not make mobile games, nor does he make small, retro-style games that would typically be run on a Pi. His concerns are modern Windows gaming PC’s and the big three consoles. While Jai is Turing-complete and is ‘general-purpose’, the implementation serves Blow’s needs first and fioremost, so the chosen targets make sense in light of that.

Re: Porting 58k lines of D and C++ to Jai

#70

I wrote an extremely hard and complex program in which I had to use c++ metaprogramming throughout. Not my decision. I do not understand why you could possibly need more metaprogramming than C++ provides. This is a problematic feature to begin with. Not worthless but not worth much. The debugging was difficult. Many problems show up buried in literally thousands of compiler error messages.

That's the issue with C++ metaprogramming. It's so unwieldy and complex that the benefits are difficult to see and the occasions to be worthwhile limited. When the language has better (i.e. simpler) facilities for meta-programming like D, it will open big venues where it makes sense to use it. It is like programming object oriented in C, it is possible to do but so unwieldy and requiring discipline and verbose boiler plate that there's rarely an occasion where it would be interesting to use. While it is much easier to do in C++ or D or Java (etc.) as they provide the abstractions that makes it useable. C++'s meta-programming facilities are not good enough.
Post reply on HN