-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #34 from xrandox/CT_Revamp_Dev
v2.0 Release Version
- Loading branch information
Showing
226 changed files
with
10,287 additions
and
6,637 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file removed
BIN
-12.1 KB
TehsTrails/Data/TehsTrails/PoFHPTrails/CrystalOasisGriffonTrail.trl
Binary file not shown.
Binary file not shown.
Binary file removed
BIN
-17.1 KB
TehsTrails/Data/TehsTrails/PoFHPTrails/DesertHighlandsGriffonTrail.trl
Binary file not shown.
Binary file removed
BIN
-7.58 KB
TehsTrails/Data/TehsTrails/PoFHPTrails/DesertHighlandsRaptorTrail.trl
Binary file not shown.
Binary file not shown.
Binary file removed
BIN
-6.22 KB
TehsTrails/Data/TehsTrails/PoFHPTrails/ElonRiverlandsRaptorTrail.trl
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed
BIN
-7.23 KB
TehsTrails/Data/TehsTrails/PoFHPTrails/TheDesolationRaptorTrail.trl
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
-- Constants | ||
local MOUNT_IDS = { | ||
["beetle"] = 2213302, | ||
["jackal"] = 2179789, | ||
["raptor"] = 2179792, | ||
["skimmer"] = 2179791, | ||
["skyscale"] = 2141699, | ||
["springer"] = 2179790, | ||
["griffon"] = 1824207 | ||
} | ||
|
||
local PARENT_CATEGORIES = { "tt.mc.cm.mm.", "tt.hot.cm.mm.", "tt.pof.cm.mm.", "tt.eod.cm.mm." } | ||
local PARENT_PATH = "Data/TehsTrails/Markers/" | ||
local PATH_END = ".png" | ||
|
||
Teh.alternatemounts = { | ||
isSwitched = false | ||
} | ||
|
||
Debug:Watch("Teh_AlternateMounts", Teh.alternatemounts) | ||
|
||
-- Function to actually change the mount icons | ||
local function switchMounts() | ||
for _, value in ipairs(PARENT_CATEGORIES) do | ||
for mountName, id in pairs(MOUNT_IDS) do | ||
local mountCategory = World:CategoryByType(value .. mountName) | ||
local mountMarkers = mountCategory:GetMarkers() | ||
if (mountMarkers ~= nil) then | ||
for _, marker in pairs(mountMarkers) do | ||
if (Teh.alternatemounts.isSwitched) then | ||
marker:SetTexture(id) | ||
else | ||
marker:SetTexture(PARENT_PATH .. mountName .. PATH_END) | ||
end | ||
end | ||
end | ||
end | ||
end | ||
end | ||
|
||
-- Global function to switch which mount art is used | ||
function Teh_AlternateMounts() | ||
Teh_ToggleStorage("alternateMounts") | ||
Teh.alternatemounts.isSwitched = Teh_GetBool("alternateMounts") | ||
switchMounts() | ||
end | ||
|
||
-- Load initial value from storage | ||
Teh.alternatemounts.isSwitched = Teh_GetBool("alternateMounts") | ||
|
||
-- If it's switched, switch them | ||
if (Teh.alternatemounts.isSwitched) then | ||
switchMounts() | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
Teh.bounce = { | ||
currentTarget = nil, | ||
isBouncing = false, | ||
wasFocused = false, | ||
timeSinceStarted = 0 | ||
} | ||
|
||
Debug:Watch("Teh_Bounce", Teh.bounce) | ||
|
||
-- Reset the bouncing marker to normal | ||
function Teh_BounceReset() | ||
local target = Teh.bounce.currentTarget | ||
local bounce = target:GetBehavior("BounceModifier") | ||
bounce.BounceHeight = 0 | ||
Teh.bounce.isBouncing = false | ||
local category = target.Category.Name | ||
if (category == "1") then | ||
target:SetTexture("Data/TehsTrails/Markers/1.png") | ||
elseif (category == "2") then | ||
target:SetTexture("Data/TehsTrails/Markers/2.png") | ||
elseif (category == "3") then | ||
target:SetTexture("Data/TehsTrails/Markers/3.png") | ||
end | ||
Teh.bounce.currentTarget = nil | ||
Teh.bounce.wasFocused = false | ||
Teh.bounce.timeSinceStarted = 0 | ||
end | ||
|
||
-- Checks if the player enters the markers trigger range, if they do, waits for them to no longer be in the trigger range to stop it from bouncing | ||
function Teh_BounceTickHandler(gameTime) | ||
Teh.bounce.timeSinceStarted = Teh.bounce.timeSinceStarted + gameTime.ElapsedGameTime.TotalSeconds | ||
if (not Teh_GetBool("bounceToggled")) then Teh_BounceReset() return end | ||
if (Teh.bounce.timeSinceStarted > 300) then Teh_BounceReset() return end | ||
|
||
if (Teh.bounce.wasFocused) then | ||
if (not Teh.bounce.currentTarget.Focused) then | ||
Teh_BounceReset() | ||
return | ||
end | ||
return | ||
end | ||
|
||
if (Teh.bounce.currentTarget.Focused) then | ||
Teh.bounce.wasFocused = true | ||
end | ||
end | ||
|
||
-- Makes the marker with the given guid bounce until you enter and leave it's trigger range | ||
function Teh_Bounce(marker, isAutoTrigger, guid) | ||
if (not Teh_GetBool("bounceToggled")) then return end | ||
|
||
local target = World:MarkerByGuid(guid) | ||
local category = target.Category.Name | ||
|
||
local bounce = target:GetBehavior("BounceModifier") | ||
bounce.BounceHeight = 1 | ||
|
||
if (category == "1") then | ||
target:SetTexture("Data/TehsTrails/Markers/1-shadow.png") | ||
elseif (category == "2") then | ||
target:SetTexture("Data/TehsTrails/Markers/2-shadow.png") | ||
elseif (category == "3") then | ||
target:SetTexture("Data/TehsTrails/Markers/3-shadow.png") | ||
end | ||
Teh.bounce.currentTarget = target | ||
Teh.bounce.isBouncing = true | ||
Teh.bounce.wasFocused = false | ||
Teh.bounce.timeSinceStarted = 0 | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
Teh.copy = { | ||
categoriesToWatch = { | ||
["tt"] = World:CategoryByType("tt.credits.tt.link"), | ||
["overflow"] = World:CategoryByType("tt.credits.overflow.link"), | ||
["bhud"] = World:CategoryByType("tt.credits.bhud.link"), | ||
["ign"] = World:CategoryByType("tt.credits.mail.m.ign"), | ||
["kofi"] = World:CategoryByType("tt.credits.kofi.k.link"), | ||
}, | ||
visibility = { | ||
["tt"] = nil, | ||
["overflow"] = nil, | ||
["bhud"] = nil, | ||
["ign"] = nil, | ||
["kofi"] = nil | ||
} | ||
} | ||
|
||
Debug:Watch("Teh_Copy", Teh.copy) | ||
|
||
-- Preload the visibility values to our internal table | ||
local c = Teh.copy.categoriesToWatch | ||
|
||
Teh.copy.visibility["tt"] = c["tt"]:IsVisible() | ||
Teh.copy.visibility["overflow"] = c["overflow"]:IsVisible() | ||
Teh.copy.visibility["bhud"] = c["bhud"]:IsVisible() | ||
Teh.copy.visibility["ign"] = c["ign"]:IsVisible() | ||
Teh.copy.visibility["kofi"] = c["kofi"]:IsVisible() | ||
|
||
|
||
-- Copies the display name of the given category to the clipboard | ||
function Teh_Copy(category) | ||
User.SetClipboard(category.DisplayName) | ||
end | ||
|
||
-- Handles listening for visibility changes in the watched categories | ||
function Teh_CopyTickHandler() | ||
-- For each watched category | ||
for key, value in pairs(Teh.copy.categoriesToWatch) do | ||
-- Get the current visibility | ||
local currentVis = value:IsVisible() | ||
-- If that doesn't match our saved visibility, then copy to clipboard and update the saved visibility | ||
if (currentVis ~= Teh.copy.visibility[key]) then | ||
Teh_Copy(value) | ||
Teh.copy.visibility[key] = currentVis | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,120 @@ | ||
Teh.heartfollower = { | ||
currentTarget = nil, | ||
isFollowing = false, | ||
followMarker = nil, | ||
target2 = nil, | ||
visible = false, | ||
originalMarker = nil, | ||
} | ||
|
||
Debug:Watch("Teh_HeartFollower", Teh.heartfollower) | ||
|
||
local category = World:CategoryByType("tt.s.tgsp") | ||
|
||
--Creates a follower targeting the specified target GUID | ||
local function createFollower(heartMarker, targetGuid) | ||
if (Teh.heartfollower.isFollowing) then --if we already have a follower, reset it | ||
Teh_FollowerReset() | ||
end | ||
|
||
local info = heartMarker:GetBehavior("InfoModifier").InfoValue | ||
|
||
local follower = Pack:CreateMarker({ | ||
Info = info, | ||
TriggerRange = 5, | ||
InGameVisibility = false, | ||
MiniMapVisibility = false, | ||
MapVisibility = false, | ||
IconSize = "0.5", | ||
Category = category, | ||
iconFile = "Data/TehsTrails/Markers/Renown_Heart_empty.png" | ||
}) | ||
|
||
if (Teh_GetBool("followerVisibleToggled")) then | ||
follower.InGameVisibility = true | ||
Teh.heartfollower.visible = true | ||
end | ||
|
||
heartMarker.TriggerRange = 0 | ||
Teh.heartfollower.originalMarker = heartMarker | ||
Teh.heartfollower.currentTarget = World:MarkerByGuid(targetGuid) | ||
Teh.heartfollower.isFollowing = true | ||
Teh.heartfollower.followMarker = follower | ||
Teh.heartfollower.currentTarget.TriggerRange = 15 | ||
end | ||
|
||
--Sets the given GUID as the target and creates a marker to point towards it and carrys around the info from the original marker | ||
function Teh_HeartFollower(marker, isfocused, guid) | ||
if (not Teh_GetBool("followerInfoToggled")) then return end | ||
|
||
if (isfocused) then | ||
createFollower(marker, guid) | ||
end | ||
end | ||
|
||
--Same as Teh_HeartFollower only it points to endGuid but doesnt disappear until in disappearGuid's focus | ||
function Teh_HeartFollower2(marker, isfocused, endGuid, disappearGuid) | ||
if (not Teh_GetBool("followerInfoToggled")) then return end | ||
|
||
if (isfocused) then | ||
createFollower(marker, endGuid) | ||
Teh.heartfollower.target2 = World:MarkerByGuid(disappearGuid) | ||
end | ||
end | ||
|
||
-- Animates the follower | ||
function Teh_FollowerTickHandler(gameTime) | ||
local target = Teh.heartfollower.currentTarget | ||
local follower = Teh.heartfollower.followMarker | ||
|
||
-- Visibility checks | ||
if (not Teh_GetBool("followerInfoToggled")) then | ||
Teh_FollowerReset() | ||
return | ||
end | ||
|
||
if (not Teh_GetBool("followerVisibleToggled")) then | ||
Teh.heartfollower.visible = false | ||
follower.InGameVisibility = false | ||
else | ||
Teh.heartfollower.visible = true | ||
follower.InGameVisibility = true | ||
end | ||
|
||
--Reset checks | ||
if (Teh.heartfollower.target2 == nil and target.Focused) then | ||
Teh_FollowerReset() | ||
return | ||
end | ||
|
||
if (Teh.heartfollower.target2 ~= nil and Teh.heartfollower.target2.Focused) then | ||
Teh_FollowerReset() | ||
return | ||
end | ||
|
||
-- Animating the position/rotation | ||
local playerPos = Mumble.PlayerCharacter.Position | ||
local vector = (target.Position - playerPos) | ||
vector = vector / vector:Length() | ||
local targetPos = playerPos + vector * 2 | ||
|
||
follower:SetPos(targetPos.X, targetPos.Y, targetPos.Z - 1.5) | ||
local rotZ = (math.atan2(vector.Y, vector.X) - ((3 * math.pi) / 2)) | ||
local rotX = (-math.atan(vector.Z, vector.X)) | ||
follower:SetRotZ(rotZ) | ||
follower:SetRotX(rotX) | ||
|
||
end | ||
|
||
--Reset the follower | ||
function Teh_FollowerReset() | ||
Teh.heartfollower.currentTarget.TriggerRange = 0 | ||
Teh.heartfollower.originalMarker.TriggerRange = 15 | ||
Teh.heartfollower.followMarker:Remove() | ||
Teh.heartfollower.currentTarget = nil | ||
Teh.heartfollower.isFollowing = false | ||
Teh.heartfollower.followMarker = nil | ||
Teh.heartfollower.target2 = nil | ||
Teh.heartfollower.visible = false | ||
Teh.heartfollower.originalMarker = nil | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
|
||
-- This is a maker-only function that converts markers to their continent coordinates. Never gets run during normal pack use. | ||
function Teh_Convert_Markers() | ||
-- Note for Teh: Doing this with the test pack is preferred | ||
local startMarkers = World:CategoryByType("tt.start"):GetMarkers(true) | ||
|
||
for i, marker in ipairs(startMarkers) do | ||
|
||
--hardcoded from lions arch | ||
local mapBottomLeftX = -27648 | ||
local mapTopRightX = 30720 | ||
local continentBottomRightX = 50432 | ||
local continentTopLeftX = 48000 | ||
local mapBottomLeftY = -18432 | ||
local mapTopRightY = 18432 | ||
local continentBottomRightY = 32256 | ||
local continentTopLeftY = 30720 | ||
|
||
local xContinent = continentTopLeftX + (1 * (((marker.Position.X * 39.3701) - mapBottomLeftX) / (mapTopRightX - mapBottomLeftX)) * (continentBottomRightX - continentTopLeftX)) | ||
local yContinent = continentTopLeftY + (-1 * (((marker.Position.Y * 39.3701) - mapTopRightY) / ( mapTopRightY - mapBottomLeftY)) * (continentBottomRightY - continentTopLeftY)) | ||
|
||
local str = "{ x = " .. xContinent .. ", y = " .. yContinent .. " }," | ||
Debug:Print(str) | ||
|
||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
Teh.globalmarker = { | ||
currentMarkers = {}, | ||
isVisible = false, | ||
rects = Teh.lookups.rects, | ||
coordinateTable = Teh.lookups.coordinateTable, | ||
category = World:CategoryByType("tt.mc.cm.rm.points_of_interest") | ||
} | ||
|
||
Debug:Watch("Teh_GlobalMarker", Teh.globalmarker) | ||
|
||
-- This function turns markers in the coordinate table to markers in the current map | ||
local function createGlobalMarkers() | ||
-- get lookup table for current map | ||
local map = Teh.globalmarker.rects[Mumble.CurrentMap.Id] | ||
|
||
-- for every pair of coordinates in the table, find the relative positioning and create the marker | ||
for i, coords in ipairs(Teh.globalmarker.coordinateTable) do | ||
|
||
local x = (map.MapRect.TopLeft.x + (coords.x - map.ContinentRect.TopLeft.x) / map.ContinentRect.Width * map.MapRect.Width) / 39.3701 | ||
local y = (map.MapRect.TopLeft.y - (coords.y - map.ContinentRect.TopLeft.y) / map.ContinentRect.Height * map.MapRect.Height) / 39.3701 | ||
|
||
local attributes = { | ||
xpos = x, | ||
ypos = 0, | ||
zpos = y, | ||
MapDisplaySize = 100, | ||
MapVisibility = true, | ||
InGameVisibility = false, | ||
ScaleOnMapWithZoom = false, | ||
Category = Teh.globalmarker.category, | ||
iconFile = "Data/TehsTrails/Markers/waypoint-highlight.png" | ||
} | ||
|
||
Teh.globalmarker.currentMarkers[i] = Pack:CreateMarker(attributes) | ||
end | ||
|
||
Teh.globalmarker.isVisible = true | ||
end | ||
|
||
-- Removes the markers once the user turns them off | ||
local function removeGlobalMarkers() | ||
Teh.globalmarker.isVisible = false | ||
|
||
if (Teh.globalmarker.currentMarkers ~= {}) then | ||
for i, marker in ipairs(Teh.globalmarker.currentMarkers) do | ||
marker:Remove() | ||
end | ||
|
||
Teh.globalmarker.currentMarkers = {} | ||
end | ||
end | ||
|
||
-- Toggles global markers on and off | ||
function Teh_ToggleGlobalMarker() | ||
if (Teh_MapIsIn(Teh.static.maps.core, Mumble.CurrentMap.Id) == false) then | ||
Debug:Warn("Could not manipulate global markers, current map " .. Mumble.CurrentMap.Id .. " is not in Core Tyria") | ||
return | ||
end | ||
if (Teh_GetBool("globalMarkersToggled")) then | ||
createGlobalMarkers() | ||
else | ||
removeGlobalMarkers() | ||
end | ||
end | ||
|
||
-- Initial load on startup | ||
Teh_ToggleGlobalMarker() |
Oops, something went wrong.