[DiscordArchive] Would the dump not show we're in the Lua stack?
[DiscordArchive] Would the dump not show we're in the Lua stack?
Archived author: stoneharry • Posted: 2024-03-10T00:19:10.433000+00:00
Original source
I know most people don't read doc, but a 'common misconceptions' type page could go a long way here. The main pitfalls I've seen in general WoW emu Lua scripts is global state pollution and storing unsafe pointers.
Archived author: Foe • Posted: 2024-03-10T00:20:24.921000+00:00
Original source
Yeah. Global state pollution is thankfully not that big of an issue now with multiple states, but eh
Archived author: stoneharry • Posted: 2024-03-10T00:22:21.773000+00:00
Original source
I won't keep banging on about it, but I do feel like some of these problems are not feasible to be 100% safe against and trying to put in countermeasures could annoy good citizens of the framework more than it helps. Let's solve the problems that actually are proven problems.
Archived author: Rochet2 • Posted: 2024-03-10T00:30:19.648000+00:00
Original source
On the use after free issue, the system in place now has been working well, does not require core edits, but is not perfect.
The system using shared_ptr that was mentioned would in my mind plug the remaining issues with using deleted memory, but it requires some core edits to add variables in all exposed classes.
Archived author: Rochet2 • Posted: 2024-03-10T00:30:21.390000+00:00
Original source
Apart from memory safety, there may be some implementation details that lead to crashes when operating with TC.
I have seen many events cause crashes if one accesses some specific data during that event. Here is an example https://github.com/ElunaLuaEngine/Eluna/issues/342
Archived author: Foe • Posted: 2024-03-10T00:32:56.491000+00:00
Original source
Yeah, I'm not really sure how we could prevent order issues like that efficiently