4 ms·
Games, particularly ones written with engines like Unity, actually look a lot like websites in this respect. You have a core engine written in C++ that runs the
by csande17 6y ago
Games, particularly ones written with engines like Unity, actually look a lot like websites in this respect. You have a core engine written in C++ that runs the event loop and draws things on the screen and stuff, but all the actual game logic is written in an interpreted language.
- josephg 6y ago> but all the actual game logic is written in an interpreted language. I was listening to a talk by Jonathan Blow the other day where he was saying using interpreted languages (like lua) inside a game engine isn't considered good practice anymore. And indeed, in unity most games write all their logic in C# - which unity somehow compiles down to native code.
- tomduncalf 6y agoUnity specifically uses C# as the language for your logic, but it gets compiled to auto generated C++ code when you export (if you export to iOS you can take a look at the generated source). Of course games do sometimes make use of languages like Lua for scripting behaviour, I’m not sure if these usually remain interpreted or get compiled.