I had done the excavator below.
https://didisoftwares.ddns.net/9/index.html
And now I decided to make some other models in my free time.
https://didisoftwares.ddns.net/11/index.html
Will it work on cell phones?
I had done the excavator below.
https://didisoftwares.ddns.net/9/index.html
And now I decided to make some other models in my free time.
https://didisoftwares.ddns.net/11/index.html
Will it work on cell phones?
damn that sim feels super real. very nice.
I dig it!
Your choice of controls does not appear to be suitable for phones.
While, on my Android phone, I can rotate and zoom in/out with touches maybe you could consider something as trivial as this (not really sure if this would apply to your physics library if you are using one):
onpointerdown
and onpointerup
events and set the corresponding variable, similar to this:
<button title="Move -X" id="btn_move_nx" onpointerdown="move_nx = true;" onpointerup="move_nx = false;">W</button>
if (move_nx === true) object.position.x -= 0.05;
This is just a trivial example but maybe the idea behind it might help your examples work even better on mobile devices.
Maybe check the code of one of my viewers to see what I did for detecting mobile devices, which would be variable isMobile
.
Mobile detection could help you hide or show those buttons if necessary.
Just so you could visualize my suggestion better, the buttons layout could be similar to this Showroom legend on the bottom of the page, the link to which you can find posted by @funny in this topic.
You would have to use the actual buttons to make it work.
Also, since you already have a code for when the keyboard buttons are pressed then maybe just reuse that code for buttons on the screen.
It really looked good, I’m going to use this or something similar.