[DiscordArchive] Hi, is there any script or anything i can add into my wow repack that will enable me to look through
[DiscordArchive] Hi, is there any script or anything i can add into my wow repack that will enable me to look through
Archived author: Wonderwhy • Posted: 2023-10-11T08:51:41.656000+00:00
Original source
I only found morph addon for new versions but not for wotlk 3.3.5a
Archived author: Wonderwhy • Posted: 2023-10-11T09:10:28.509000+00:00
Original source
And also, is there any way to check / upload scripted events ? You know like if i do a quest npcs comes and will say something etc
Archived author: Foe • Posted: 2023-10-11T11:53:54.551000+00:00
Original source
Our code probably wouldn't be drop in compatible, but the concept is relatively simple and you just need a few variables
- parentWidth, this is the width of the parent frame, not the scroll child
- parentHeight, same as above, but height
- childCenterX, childCenterY, these are the current center x and y coordinates of your scroll child relative to the parent frame
- xOffset, parentWidth/2
- yOffset, parentHeight/2
- topLeftX = childCenterX - xOffset
- topLeftY = childCenterY - yOffset
- bottomRightX = childCenterX + xOffset
- bottomRightY = childCenterY + yOffset
Then you just check on update if a node x, y is within the top and bottom coordinates
Archived author: Foe • Posted: 2023-10-11T11:55:34.585000+00:00
Original source
You might want to add some padding to xOffset and yOffset so you don't have popping in some cases
Archived author: Foe • Posted: 2023-10-11T11:57:32.518000+00:00
Original source
```Lua
function isNodeWithinView(nodeX, nodeY, topLeftX, topLeftY, bottomRightX, bottomRightY)
return nodeX >= topLeftX and nodeX <= bottomRightX and nodeY >= topLeftY and nodeY <= bottomRightY
end```
Archived author: Foe • Posted: 2023-10-11T11:58:15.217000+00:00
Original source
So on scroll child update, iterate over your nodes, check their coordinates and if they now are within view set them to shown
Archived author: Rymercyble • Posted: 2023-10-11T12:24:26.121000+00:00
Original source
i meant it from even higher up in logic in frame itself i was trying to do roughly this
```lua
local talentWindow = CreateFrame("Frame", "TalentWindow", UIParent)
local nodeWindow = CreateFrame("Frame", "NodeWindow", talentWindow)
local scrollFrame = CreateFrame("ScrollFrame", nil, nodeWindow)
--- this is actual frame that contains tree itself
local innerFrame = CreateFrame("Frame", nil, scrollFrame)
```
then i got bunch of events for zooming and moving and i was trying to contain tree frame within boundaries of window such that if tree frame edge woud reach edge of window while moving it it would stop it so u cant reveal window background or move it outside of view
i was trying to calculate if any edge or corner of tree frame is within window and stop it but i dont know if this is reasonable approach i dont even know if whole scroll frame approach is good and on top of that i dont know if i just dont understand how wow frames and coordinates work but like scroll frame was starting at 180,106 which is completely out of my talent window and then i had many weird issues connected to that together with relative size caused by zooming and it was completely broken
Archived author: Foe • Posted: 2023-10-11T12:26:35.903000+00:00
Original source
https://wowpedia.fandom.com/wiki/UIOBJECT_ScrollFrame
Use FauxScrollFrame instead of normal ScrollFrame
[Embed: UIOBJECT ScrollFrame]
ScrollFrame (inherits from Frame) may be customized to vertically or horizontally scroll other widgets.
The logic and textures to operate the ScrollFrame may be inherited from a template:
UIPanelScrollFrameCodeTemplate - The logic for vertial scrolling without any textures. {, }
UIPanelScrollFrameTemplate - Adds vertical scroll bar textures b...
https://wowpedia.fandom.com/wiki/UIOBJECT_ScrollFrame
Archived author: Foe • Posted: 2023-10-11T12:29:00.523000+00:00
Original source
https://wowpedia.fandom.com/wiki/Making_...meTemplate
[Embed: Making a scrollable list using FauxScrollFrameTemplate]
This HOWTO describes how to create a list view using the FauxScrollFrameTemplate FrameXML class. An alternative is to simply create a Slider object of your own, but there is no HOWTO on that at the moment. Using CreateFrame() to create the list items dynamically may also be a good idea.
https://wowpedia.fandom.com/wiki/Making_...meTemplate
Archived author: Rymercyble • Posted: 2023-10-11T12:30:50.730000+00:00
Original source
should i take it literally ? because it says that its scrollable not draggable