That was originally the goal with Icon.mimic(coreGuiName) (e.g. Icon.mimic("Chat")) although that’s unfortunately not possible anymore due to further restrictions within the core and chat main scripts.
I’ve seen games like “Outlaster” do it though, and I’m fairly certain they use TopbarPlus v1 or v2 due to the fact that their core gui icons all have TopbarPlus styled captions, including the chat icon.
I think I’ve come pretty close to creating an icon that mimics the chat button, however it only works when selecting, not deselecting. Here’s what I have so far:
When I do this, it works almost perfectly, except for the fact that it makes the default chat icon appear in the topbar every time the icon is selected, and it disappears when deselected:
We’re only supporting overflows for left and right set icons for the time-being due to additional complexities involved with mid-set icons.
A solution for you instead: check the clients screen size with ViewportSize, then if their X size is below a certain value, create an icon and set a dropdown with all your other icons.
local screenSize = ...
local icon1 = Icon.new()
local icon2 = Icon.new()
local icon3 = Icon.new()
if screenSize.X < DESIRED_AMOUNT then
local dropdownIcon = Icon.new()
dropdownIcon:setDropdown({icon1, icon2, icon3})
end
Apologies, by ‘impossible’ I should have said ‘impossible to mimic the chat icon perfectly while preserving the default chat menus without forking and creating your own’.
You’re welcome to use the code we originally wrote for the Chat Mimic Icon:
As far as I’m aware though (with the recent removal of key chat events) you won’t be able to mimic it perfectly unless you create your own chat menu or a fork of the core chat.
I want to make a button that hides 2 of the icons (top bar icons).
I guess its kind of a frame but since its a topbar icon I dont know if its possible.
When I say topbar icon, I mean I made an icon out of this module, and I want to make a button that hides 2 of the icons, so players can decide if to view them.