Ideas Lab

Real problems people complain about online, pulled every morning and scored out of 100. Build, validate, or skip. How scoring works

Ideas
4,145
BUILD
689
Sources
8
Last sync
59m ago
4,145 ideas

Obfuscate GDScript in production export

### Describe the project you are working on Any project which can be released publicly where the developer might not want to have their code or structure implementation easily stolen. ### Describe the problem or limitation you are having in your project Currently Godot [supports encryption of the exported files](https://docs.godotengine.org/en/stable/development/compiling/compiling_with_script_encryption_key.html) (if you use a custom build of the export templates) However this is not really good enough. Almost every successful engine will at some point have a decompiler for the exported assets. (see [ILSpy](https://github.com/icsharpcode/ILSpy)). In-fact, due to the open source nature of Godot, I think it would be relatively simple to write a script-dumper, that uses the encryption to first de-crypt the files and then just dump them to some output folder once they've been loaded into memory. Many others have also been worried about this issue, quite often with those issues being closed when the discussion goes more towards DRM or encryption. ### ❗️ This is not a discussion about DRM or Encryption ❗️ https://github.com/godotengine/godot/issues/39115 https://github.com/godotengine/godot/issues/24716 https://github.com/godotengine/godot/issues/19790 ### Describe the feature / enhancement and how it helps to overcome the problem or limitation When exporting to production, exported GDscript files can be obfuscated with the names mangled. In this case, adding encryption would add a layer of security, and if someone does decide to extract the files from the pck, they are left with an unintelligible mess of obfuscated code. This additional security would put godot at the top end of protecting game assets, and likely bring users to our community. ### Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams An example implementation [can be found here](https://github.com/javascript-obfuscator/javasc

GitHub4y agoToolDev

62FL score
0Sign in to vote

Expose a zero allocation API to Godot C# bindings

### Describe the project you are working on Godot C# bindings ### Describe the problem or limitation you are having in your project For the past weeks, I've been discussing with several Unity users intending to move to Godot C# regarding dealing with the C# garbage collector. The most common complaint I hear from users is that, in Unity, allocations can trigger unexpected GC spikes into the game. In Godot, we target to make all of the high performance APIs (those that intended to be called every frame) not allocate any memory, so theoretically the GC should not be a problem. Additionally, Godot starting from 4.0, uses the Microsoft CoreCLR version of .net, which also supposedly has a better garbage collector than Unity. But in all, after several discussions with Unity users, neither is enough reassurance for them, and they would really feel safer if Godot exposed a zero allocation API. ### Describe the feature / enhancement and how it helps to overcome the problem or limitation The idea of this proposal is that Godot exposes zero allocation versions of many functions in the C# API, that users can use if they desire. Technically, this could be done from the binding generator itself, without breaking compatibility, and without doing any modification to Godot itself. ### Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams **WARNING** I am not familiar with C#, so take this as pseudocode. Imagine you have two functions exposed as to C#: ```C# void MyClass.SetArray( Vector2[] array); Vector2[] MyClass.GetArray(); ``` This works and is pretty and intuitive. However, it has two problems: * GC is allocated on return * Memory is copied to Godot native formats every time there is a call. The idea is to add NoAlloc versions, which can be generated directly by the binder automatically when required: ```C# void MyClass.SetArrayNoAlloc( Godot.Collections.PackedVector2Array array); void MyCl

GitHub3y agoToolAI

84FL score
0Sign in to vote