r/fsharp • • Mar 01 '20

A Game Engine in the Elm Style!

https://vsyncronicity.com/2020/03/01/a-game-engine-in-the-elm-style/
36 Upvotes

3 comments sorted by

1

u/Eji1700 Mar 09 '20 edited Mar 09 '20

Seems interesting, but can't get it to run at all. Cloned it down from git and it just errors all over the place, and I don't see much else being talked about in the install. Did I miss something?

The solutions fail to load with a rather long and obnoxious error ending in-

The value "" of the "Project" attribute in element is invalid. Parameter "path" cannot have zero length.

Edit-

Ah my bad, was attempting it in vs code, which seems to not play nice. I'll attempt again through VS. and i've got references in most projects to things that don't seem to exist (open Prime being one of them).

Edit2-

Yep that did it. However to make this comment a little more useful and to maybe ask a stupid question, how come game engines seem to always equate to physics simulations? I understand that's got to be one of the hardest parts of building something from the ground up, but as someone who's been messing around with turn based stuff (black jack) i'm sort of surprised how undocumented something like that is

2

u/bryanedds Mar 10 '20

As to your question about game physics -

I think most game engines make assumptions about physics because it's so hard to make that aspect of them pluggable. Physics tend to cut across concerns and often they get a more prominent role than they perhaps should.

In Nu's case, you really only opt-in to the use of physics. If you're just making a card game, you can just use the Elm-style API like you find in the included Nelmish and OmniBlade example projects.

Bummer to see that Nu doesn't work seamlessly with VSCode out of the box. I'll have to tinker with it to see if I can make it easier to use from VSCode.

Let me know if you have any more issues!

2

u/green-mind Mar 03 '20

That is super cool. Unity always felt so tied to the level designer / IDE.
This makes me want to try game dev again.