5 ms·
byond does alot of things differently then most programming languages. They are always hailed as a failing, but its not. ss13 wouldn't exist if byond was a com
by MrStonedOne 5y ago
byond does alot of things differently then most programming languages.
They are always hailed as a failing, but its not. ss13 wouldn't exist if byond was a competent programming language.
Half the features wouldn't get coded if class members had visibility/security levels (public/private), or had to be well written interface defined frameworks, or if types were enforced or required to be specified.
Lacking all of the fluff of modern programming languages allowed it to appeal to a wider base of contributors, a fair amount who got their start in programming by contributing to ss13.
Non-visualized programming languages also have issues that make game dev hard, that byond can sidestep. byond uses a single-thread:multiple-stacks framework that treats soft blocks (sleep, network/file io, client involved commands) specially and allows you to detach your call stack at an arbitrary point when a softblock happens allowing for easier programming of performant code.
So if i have code for airlocks to start the close animation, sleep for the duration of the close animation, then mark the airlock as dense and the tile its on as an airblocker, I can easily make code to handle closing all doors in a list of doors without making each wait thru the animation of the close block the caller, while still allowing for the blocking of the caller when thats what i want.
The curse is real, but its not insurmountable.
- beaconstudios 5y agoThe execution flow you describe is similar to JS' event loop and (I think, I'm not very experienced at C#) C#'s async/await functionality. It's a godsend in JS for exactly the reasons you describe. I haven't written any Dream code so I can't / wasn't speaking to the language design itself, and I got started in php and actually mostly like it for its design and accessibility so I wouldn't be the guy to shit on the language. I'm just aware that the platform is kinda crashy and non performant.
- MrStonedOne 5y ago> The execution flow you describe is similar to JS' event loop yes, in mechanic, the biggest benefit is you can get it via a control statement so its as easy as typing a keyword and an additional indentation block, ie, you can do it mid function and the function level vars just get copied over, or you can mark the entire function as non-blocking and the stack detaches at the first sleep, but at the non-blocking function, even if the sleep is 10 calls deep from that function. All without the caller of the non-blocking function needing to do anything (the biggest difference from c#'s async/await). You can even define this on a base function and all 50 million overrides can be trusted to not block the caller.