MatejSloboda / Dijkstra_map_for_Godot

MIT License
77 stars 13 forks source link

No Interface for HTML5? #118

Open Sunnigen opened 1 year ago

Sunnigen commented 1 year ago

Running the HTML5 exported project has run into an issue. When bringing up developer tools on either Chrome or Microsoft Edge I get the following:

ERROR: Interface does not have a library for the current platform.
at: init_library (modules/gdnative/nativescript/nativescript.cpp:1479) - Condition "lib_path.length() == 0" is true.
SCRIPT ERROR: Attempt to call function 'new' in base 'NativeScript' on a null instance.
at: GameScreen._reset_dungeon (res://GameScreen.gdc:130) - Attempt to call function 'new' in base 'NativeScript' on a null instance.

The GameScreen._reset_dungeon() issue at line 130 is this following code:

dijkstra_map = DijkstraMap.new()

Then, I also tried the HTML5 export without my code: Minimum Working Example

Just from the Visualisation.tscn demo, I get the same errors as above on both Chrome and Edge.

From the picture attached below when I make a selection from the visualizer dialog box, neither the cost map nor the direction map updates. I'm not sure why it can't. I was able to successfully export onto desktop and play around with the visualizer.

Also, I noticed after downloading from AssetLib, this module doesn't appear in the plugins for me to toggle?

Tested on:

How to reproduce:

  1. Create new project and create a parent node
  2. Download via AssetLib and attach visualisation.tscn as child node
  3. Download HTML5 template & run
  4. select either "cost map" or "direction map" in dialog box
  5. Open developer tools

issue

astrale-sharp commented 1 year ago

Hey!

The rust binding don't support exporting an html project so far, if I'm not mistaken it will change either in gd extension (the rust bindings for godot4.x) or when Godot solve that problem/implement that feature themselves -- nothing we can do I'm afraid!


From: Sunnigen @.> Sent: Monday, November 21, 2022 9:35:48 AM To: MatejSloboda/Dijkstra_map_for_Godot @.> Cc: Subscribed @.***> Subject: [MatejSloboda/Dijkstra_map_for_Godot] No Interface for HTML5? (Issue #118)

Exporting project to HTML5 leads to issues. From the picture, it looks like the "web" cannot recognize DijkstraMap.new(). I'm not sure why it can't. I was able to successfully export onto desktop.

Also, I noticed after downloading from AssetLib, this module doesn't appear in the plugins for me to toggle?

Minimum Working Examplehttps://github.com/Sunnigen/godot_dijkstra_test

Tested on:

How to reproduce:

  1. Create new project and create a parent node
  2. Download via AssetLib and attach visualisation.tscn as child node
  3. Download HTML5 template & run
  4. select either "cost map" or "direction map" in dialog box
  5. Open developer tools

[issue]https://user-images.githubusercontent.com/27396065/203002421-ec8a5461-98f5-4416-a8eb-f2179bcbeede.PNG

— Reply to this email directly, view it on GitHubhttps://github.com/MatejSloboda/Dijkstra_map_for_Godot/issues/118, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AMZTDKRL6SHRDEJMCO7VGKTWJMX6JANCNFSM6AAAAAASGMCKIE. You are receiving this because you are subscribed to this thread.Message ID: @.***>

astrale-sharp commented 1 year ago

Oh my bad they totally do support it but it's a bit of a pain, got it working on one of my project, see godot rust book for details and ask them or me if you can't get it working

if someone is interested in bringing support for this go ahead