Scene Loading issues with needle

Sorry for bothering you all again though I’m having issues with loading scenes with needle engine in unity. I have a 3d model of an arrow with a box collider and button component on it. When I build and run in unity the model works fine for loading the next scene; however, it doesn’t seem to work in the needle engine tab specifically.

Original Post on Discord

by user 841751666960760944

Hello there – we have an experimental AI bot :robot: that might be able to help you with your question. Would you like to try this out?

Hi, can you clarify a bit?

  • play mode in unity game window works?
  • what is the needle engine tab? Do you mean the browser?
  • what does not work? which method does the button call to load another scene and/or what messages or console logs do you get in the browser?
  • Yes
  • Yes, when u click play on the needle engine exporter, the tab it shows you previewing the website
  • I have a 3d model with a box collider and a button component on it, it’s supposed to go to the next scene when clicked
  • I’m using Unity Scene Management’s LoadNextScene method, it works fine in the editor when i do build and run though in needle engine port tab it doesn’t work.

by user 841751666960760944

My code for reference

by user 841751666960760944

works fine with build and run as stated before but yeah

by user 841751666960760944

You show C# code here but Needle Engine doesnt export C# to typescript (logic) automatically. You have to write that code in typescript for it to work. Needle Engine Scripting | Needle Engine Documentation

To load a scene you can also use our SceneSwitcher component and call a method on it using your button so for this you dont need to write any code manually

Ah okay thanks

by user 841751666960760944

I’ll give it a shot

by user 841751666960760944

so i don’t need the button at all correct? There seems to be a Use Swipe boolean on the Scene Switcher component which i assume will do the heavy lifting in scrolling to switch scenes

by user 841751666960760944

You can either use the button to call one of the sceneswitcher methods (e.g. select with the index of the scene to load) or you can use the swipe or url parameter functionality (wasd and arrow keys can also be enabled) - depends on what you need

thank you Marcel for all your support

by user 841751666960760944

I’m actually using needle engine for a competition which will happen soon and I’ll definitely let you know how it goes

by user 841751666960760944

What kind of competition is it if I may ask? Good luck :crossed_fingers:

TSA (technology students association) Webmaster category competition

by user 841751666960760944

last year i got first place with a unity game but this year I wanted to switch it up a little and do the website creation category

by user 841751666960760944

hopefully i can pull off first place again

by user 841751666960760944

really quickly, the scrolling and keyboard strategy for switching scenes doesn’t seem to be working on the export page, you mind checking my component really fast.
image.png

by user 841751666960760944

i have this attached to my Needle Engine Export Info object

by user 841751666960760944