2.0 Alpha 13 bug: Random returning < null > (Solved it myself in reply) #2061
Replies: 2 comments 1 reply
-
Okay I just managed to fix it. Line 59 in event_variable.gd: Change from "1,3,4: the_value = dialogic.VAR.get_variable(str(value))" to "1,3,4,5: the_value = dialogic.VAR.get_variable(str(value))" The random number generation was tied to 5, but it wasn't actually able to "match" to 5. Not familiar with GDScript so apologies for any incorrect terminology there, I figured it out through deduction haha. |
Beta Was this translation helpful? Give feedback.
-
Hey thanks for this report and even finding the fix. I will make sure to include this asap. Btw, next time for stuff like this feel free to open actual Issues instead of discussions. Also if you find other stuff or have questions emilios discord is the best place to chat/ask. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I was advised to make a dedicated thread for this issue after mentioning it in a previous thread.
So, I did a totally fresh install on Alpha 13 after losing a project utilizing Alpha 12, I know it's definitely not an update problem or anything. It's always possible it's a local issue but with a totally fresh install it's unlikely. I also have the latest version of Godot (4.2.1)
When I try to set an expression to a random value, it returns null.
Easy way to recreate it:
When you run it, you'll get the error message: Dialogic: Set Variable event failed because one value wasn't a float! [0, < null >]
(Using breakpoints on the relevant lines will also reveal the value is null but I don't feel like finding which lines that is again)
Alpha 12 does not have this problem (which also rules out my copy of Godot itself), I reinstalled it just to test that lol, I used the exact same steps there with no problem.
If anyone figures out a fix please let me know! I'll also share if I figure it out because I am tinkering with it myself, but I'm pretty new to Godot (I've used Unity and Unreal Engine before this) so my hopes aren't high.
Beta Was this translation helpful? Give feedback.
All reactions