Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

[EO 2.x, 3.x w/e] Simple but sexy Hotbar fix


Conscientia
 Share

Recommended Posts

Yo bros, didn't really introduce myself coming back to this community after so long, but I'll just leave this little tutorial here while I silently sneak around your weird projects and coding, trying to find my way.

**HOTBAR FIX**

_All client side._

So, we want to change the way icons position when we move them. At the moment, you drag stuff from their respective top left corner, that's just not ok. So to change that we do this, with built-in variables of course, since this stuff has been around for a couple of years…

____________________________________________________________________________

Anyway, **DO THIS**:

Find:

```

With frmMain.picTempInv

.Top = y + picInventory.Top

.Left = x + picInventory.Left

.Visible = True

.ZOrder (0)

End With
```
Change to:

```
With frmMain.picTempInv

.Top = y + picInventory.Top - CurY

.Left = x + picInventory.Left - CurX

.Visible = True

.ZOrder (0)

End With
```

Find:

```
With frmMain.picTempSpell

.Top = y + frmMain.picSpells.Top

.Left = x + frmMain.picSpells.Left

.Visible = True

.ZOrder (0)

End With
```
Change to:

```
With frmMain.picTempSpell

.Top = y + frmMain.picSpells.Top - CurY

.Left = x + frmMain.picSpells.Left - CurX

.Visible = True

.ZOrder (0)

End With
```

Now your cursor will in a sexy way (somewhat) align itself with the center of the icon you are dragging, simple!
Link to comment
Share on other sites

> Variable not defined
>
> .top = y + picInventory.top - CurY
>
> use eo 2.0

Not sure if the CurY variable is in EO 2.0 but you can just replace it with "-16" and it should work as well lol

Edit: OR you can be engine-correct and use```
.top = y + picInventory.top - Int(PIC_X / 2)
```
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...