I’m creating a simulation/ program where students can connect different atoms together to start a chemical reaction, thus creating a compound. EX: combining hydrogen and oxygen atoms to get water.
The basic UI of the program will consist of 2 main panels. On the right side will be a small, slim panel which will serve as an element bank. The left side will be the student’s workspace. What I’d like is for students to be able to drag and drop elements from the ‘element bank’ panel, and into their workspace so that they could connect them to form compounds.
I have already implemented the drag and drop feature. What I’d like is to be able to to drag elements (they’re just spheres) from the panel on the left, in to the main workspace, and allow students to work with them in a 3D environment.
I’ve ran into the following issues:
When I drag and drop an element into the control area, I can’t interact with it in a 3D manner. Unless I include it in between the cam.begin & cam.end section. The issue with that is that it takes away from the drag and drop functionality and arises other issues.
Secondly, I’m not sure if I’m using the set control area function correctly because I can still use the mouse inputs to interact with the 3D space, even if my mouse is outside the 3D environment.
Is there anyway I can set the camera to always rotate about the center of the control area. I’ve tried achieving this using the .setOrientation, but it hasn’t been working.
Lastly, is there any way I can alter the default controls to Easy Cam. I’d like for left click to do nothing, scroll wheel to zoom, and right click to rotate.
Thank you for listening. Any advice would be greatly appreciated. I’ll upload my code (It’s not much, aside from the standard stuff its 40-50 lines tops).