ID:1764887
 
(See the best response by Multiverse7.)
I would like to disable the hotbar. I just want my game to display as the DMF suggests it should display.

I've seen that you can define the interface from scratch again using scripting but that's not what I want. My interface is already complex enough that replicating it in text only is not an option.

As a side note, the Hotbar also takes up room in the iframe which squishes my interface to fit it in. Just... Whyyy?

I need to get rid of this thing ASAP. I know you spent lots of time on it Lummox but I just don't need it.
So far, the webclient controls are not very cooperative. However, I figured out how to forcibly remove the hotbar at runtime.

Calling this should do it:
Edit: This one is better:
winset(src, null, {"command=".skin document.getElementsByClassName(\\"byond_hotbar_bar\\")\[0\].remove()&\
byond.skin.attach(document.getElementsByClassName(\\"byond_hotbar_contents\\")\[0\],\\"pane\\").winset(\\{ size:\\"0x0\\" \\})""}
)

What this does is it removes the byond_hotbar_bar div, converts the byond_hotbar_contents div into a pane control, then calls the new control's winset() function to reset the size, so it takes up the whole area.

Let me know if you can find a better way to do this. I wonder if the hotbar itself not having an id or being a real skin control could be some kind of bug, since that's why it can't be disabled by just using an ordinary winset() call.
Didn't work for me, am I doing it right? Also you're dam right, why is this so hard to turn off?

mob/Player
Login()
if(client.connection != "seeker")
winset(usr, null, {"command=".skin hotbar.children\[0\].remove()&\
byond.skin.attach(hotbar.children\[0\],\\"pane\\").winset(\\{ size:\\"0x0\\" \\})""}
)
Best response
The id of the main hotbar element isn't always the same, so in your case it just wasn't finding it.

Here is a much improved, and hopefully working solution:
client
New()
..()
if(connection == "web")
winset(src, null, {"command=".skin document.getElementsByClassName(\\"byond_hotbar_bar\\")\[0\].remove()&\
byond.skin.attach(document.getElementsByClassName(\\"byond_hotbar_contents\\")\[0\],\\"pane\\").winset(\\{ size:\\"0x0\\" \\})""}
)
Wow thanks, that worked. The hotbar is still there for a moment before it disappears but that'll just have to do for now.

Thanks again man, that's awesome.
In response to Zecronious
I'm glad it's working. If you still see the hotbar for a moment, then that's probably due to the fact that the server is telling the webclient what to do, or it could just be the complexity of your interface. In my testing it seems to vanish almost instantly.
Actually, you can probably do this much simpler by removing the hotbar control outright instead of just removing its HTML components. (That said, I'm not 100% positive I accounted for "undocking", but if I didn't I can fix it.)

The command to run in JS would be:

byond(':hotbar').remove()

It's worth trying; if removal isn't working right then that's something I can address. I also would like is-visible to have a similar effect.

I'd like to add some customization so the hotbar can be suppressed more easily for authors who want to avoid it entirely.
So how do I use that? Also, thanks that would be amazing if it just had an is-visible. I'm used to that.
That'd be called via a .skin command like the current examples.
In response to Lummox JR
Mm, I don't understand the current examples. I copy pasted them.
All those examples are doing is sending a command via winset. The command starts with ".skin", and what comes after it is pure JavaScript.
In response to Lummox JR
Yes, I don't know Javascript though. =/
In response to Lummox JR
Unfortunately, calling this will remove the entire game, not just the hotbar:
winset(src, null, {"command=".skin byond(':hotbar').remove()""})

I tried removing the "hotbar" control at first, but I found out that in interfaces that include the hotbar, the hotbar's contents div is like some kind of pane that includes the contents of the rest of the game.

The hotbar is overriding all the other divs in the DOM tree, which certainly isn't what I would expect from that kind of control. It should be contained within one of the existing panes, so that removing it doesn't uproot the contents of the entire iframe.
I just need to modify the hotbar removal behavior. Shouldn't be a problem.