Skip to content

Commit

Permalink
try to catch the access_violation bug
Browse files Browse the repository at this point in the history
  • Loading branch information
TaylorMouse committed Mar 26, 2022
1 parent 469e204 commit 65645bf
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -229,23 +229,24 @@ struct Warcraft_3_Ref_Parser
),
function GetAllAnimatedKeyFrames=
(
clearSelection()
local uniqueKeys = #()
for obj in objects do
(
try (
for i=1 to obj.numSubs do
(
if obj[i].Keys != undefined then
(

for j=1 to obj[i].numsubs do
(
if obj[i][j].Keys != undefined then
(
for k in obj[i][j].keys do
(
local strTime = k.time as string
local iTime = substring strTime 1 (strTime.count - 1 ) as integer

local iTime = k.time as integer / TicksPerFrame

appendifunique uniqueKeys iTime

)
Expand All @@ -254,6 +255,7 @@ struct Warcraft_3_Ref_Parser
)

)
) catch()
)

local sortedKeys = sort uniqueKeys
Expand Down

0 comments on commit 65645bf

Please sign in to comment.