Autoload variables nil in XCode Project

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By hassny

My project builds and works fine in godot however when running in xcode it seems my global script/autoload is non-existant as none of its methods/variables return any value. The following is the error I receive:

e[1;35mSCRIPT ERROR: _on_TextureButton_pressed: e[0me[1mInvalid set index ‘game_mode’ (on base: ‘Nil’).