EQ2Emulator Development forum.
Moderator: Team Members
-
John Adams
- Retired
- Posts: 9684
- Joined: Thu Jul 26, 2007 6:27 am
- EQ2Emu Server: EQ2Emulator Test Center
- Characters: John
- Location: Arizona
-
Contact:
Post
by John Adams » Tue Nov 28, 2017 1:34 pm
I can’t believe it’s been so long I have to ask questions
Can a server admin “lock” a hotbar so the player can’t change the items? Say I want hotbar1 to always be 12 specific things, unchangeable.
I know the Lock stuff is generally client side... so maybe it’s not possible without a custom UI.
-
tyrbo
- Team Member
- Posts: 271
- Joined: Thu Feb 18, 2016 12:33 pm
Post
by tyrbo » Tue Nov 28, 2017 4:30 pm
Looking at the code, I think the server just maintains the saved hotbar state, and the client looks like it maintains it's own internal state. So when you move something on your hotbar, it sends a packet to the server to update it server-side. The server doesn't send anything back in response.
You could try hooking into the incoming client packet (OP_QuickbarUpdateMsg), and whenever someone updates the hotbar you're interested in, ignore the change and re-send the hotbars.
I'm not sure if the client will even take the hotbar packet again. It's only sent once (from what I can see), so that might not even work.
-
John Adams
- Retired
- Posts: 9684
- Joined: Thu Jul 26, 2007 6:27 am
- EQ2Emu Server: EQ2Emulator Test Center
- Characters: John
- Location: Arizona
-
Contact:
Post
by John Adams » Wed Nov 29, 2017 8:40 am
Right on, thanks for the reply. I kinda figured it was client-side, mostly. I imagine it could be handled (maybe) via a custom UI, but in the 14 years of EQ2 I have enjoyed, I have never been brave enough to handle customizing a UI
It's probably not as hard as I predict, I just lack the attention span to learn heh.
-
tyrbo
- Team Member
- Posts: 271
- Joined: Thu Feb 18, 2016 12:33 pm
Post
by tyrbo » Wed Nov 29, 2017 11:18 am
Well, like I said, it might be possible. If you can just re-send the initial hotbar packet, you could set the hotbar to whatever you want any time you want.
Come to think of it, it surely accepts that packet (or some similar one, at least), because you used to be able to possess your pet and it would replace your entire hotbar with their abilities.
For an easy test, you could wire up the /test command to call ClientPacketFunctions::SendQuickBarInit with your client. You could log in, open your SQL editor and change your hotbars in the database. Calling the /test command would then (hopefully) update your hotbars to reflect the change you made in the database.
-
Cynnar
- Project Leader
- Posts: 738
- Joined: Sat Sep 27, 2014 1:22 am
- EQ2Emu Server: Eq2emulator
- Characters: Vlash
Veinlash
Taragak
Cynnar
Post
by Cynnar » Wed Nov 29, 2017 8:09 pm
Customizing the UI isn't bad once you start messing around with it. The editor that is in the install folder of the game is a buggy mess. I have learned to do my editing in notepad++ and use the editor for viewing, and an initial creating something.
It has been some time since I have messed with the UI, so I will need to look at it again this weekend to refresh my memory if you want to go that route.
[ 01000011 01111001 01101110 01101110 01100001 01110010 ]
Follow on:
Twitter Facebook
Contact me:
PM Discord chat email
Hardware: the parts of a computer that can be kicked
-
tyrbo
- Team Member
- Posts: 271
- Joined: Thu Feb 18, 2016 12:33 pm
Post
by tyrbo » Wed Nov 29, 2017 8:16 pm
The only issue with relying on a UI mod is enforcing it. If that's not super important, then it might be a good fit.
-
Cynnar
- Project Leader
- Posts: 738
- Joined: Sat Sep 27, 2014 1:22 am
- EQ2Emu Server: Eq2emulator
- Characters: Vlash
Veinlash
Taragak
Cynnar
Post
by Cynnar » Wed Nov 29, 2017 9:44 pm
That is true. It would be hard to force someone to use a custom UI. Even if it's added in with some other changes, a person could disable it with a little poking around.
[ 01000011 01111001 01101110 01101110 01100001 01110010 ]
Follow on:
Twitter Facebook
Contact me:
PM Discord chat email
Hardware: the parts of a computer that can be kicked
Who is online
Users browsing this forum: No registered users and 0 guests