[Server] Hellgrave Exodus (TFS 1.4)

Hellgrave Exodus [Server] Hellgrave Exodus (TFS 1.4) v2.5.2

Sin permiso para descargar

Archer32

Miembro
LV
1
 
Awards
4
Is bug? Or is something goofed on my end?
I cannot trade player?
Right click item -> Trade with -> Click player
Cursor shows up bugged (crosshair) and cannot click anything or play, need to shut down and bring back up.. not sure if this is client bug or server bug.. I haven't changed anything regarding trading.. just happen to try it
 

Archer32

Miembro
LV
1
 
Awards
4
Can't edit my post, but figured it out was the mousegrabberrelease.. I actually did make a change not knowing it messed with the use and trade actions.... lol
 

Alex

Miembro del equipo
Webdesigner
LV
58
 
Awards
38
Can't edit my post, but figured it out was the mousegrabberrelease.. I actually did make a change not knowing it messed with the use and trade actions.... lol
Hello , I think is client but never I find how to fix this as is first time i work on otclient , so its mousegrab ? I Will Check it thanks you.
 

Archer32

Miembro
LV
1
 
Awards
4
Hello , I think is client but never I find how to fix this as is first time i work on otclient , so its mousegrab ? I Will Check it thanks you.
Hey Alex,

Hopefully this gives you some insight..
Código Lua:
function onMouseGrabberRelease(self, mousePosition, mouseButton)
  if mouseButton ~= MouseLeftButton then return false end

  local clickedWidget = gameRootPanel:recursiveGetChildByPos(mousePosition, false)
 
  if not clickedWidget then
    resetInteraction()  -- Resets any ongoing actions
    return false
  end
 
  if selectedType == 'use' then
    onUseWith(clickedWidget, mousePosition)
    resetInteraction()
    return true
  end

  if selectedType == 'trade' then
    onTradeWith(clickedWidget, mousePosition)
    resetInteraction()
    return true
  end

  resetInteraction()
  return false
end

function resetInteraction()
selectedThing = nil
selectedType = nil
selectedSubtype = nil
g_mouse.popCursor('target') -- Reverts any cursor changes made during interaction
mouseGrabberWidget:ungrabMouse() -- Ensures the mouse is not bound to any widget
gameMapPanel:blockNextMouseRelease(true) -- Prevents accidental clicks from carrying over
end



I have not tested this exact code because I have some custom features in my mousegrabber but that should do the trick
I am not the best coder, could hopefully give you some information though
 
Última edición por un moderador:

Alex

Miembro del equipo
Webdesigner
LV
58
 
Awards
38
Hey Alex,

Hopefully this gives you some insight..
Código Lua:
function onMouseGrabberRelease(self, mousePosition, mouseButton)
  if mouseButton ~= MouseLeftButton then return false end

  local clickedWidget = gameRootPanel:recursiveGetChildByPos(mousePosition, false)
 
  if not clickedWidget then
    resetInteraction()  -- Resets any ongoing actions
    return false
  end
 
  if selectedType == 'use' then
    onUseWith(clickedWidget, mousePosition)
    resetInteraction()
    return true
  end

  if selectedType == 'trade' then
    onTradeWith(clickedWidget, mousePosition)
    resetInteraction()
    return true
  end

  resetInteraction()
  return false
end

function resetInteraction()
selectedThing = nil
selectedType = nil
selectedSubtype = nil
g_mouse.popCursor('target') -- Reverts any cursor changes made during interaction
mouseGrabberWidget:ungrabMouse() -- Ensures the mouse is not bound to any widget
gameMapPanel:blockNextMouseRelease(true) -- Prevents accidental clicks from carrying over
end



I have not tested this exact code because I have some custom features in my mousegrabber but that should do the trick
I am not the best coder, could hopefully give you some information though

I Tried, seems do the trick, but idk how to 'bug' the mouse i never had this problem ^^
 
Arriba