Skip to content

Commit

Permalink
Fix unknown property getSelectedVertices #5
Browse files Browse the repository at this point in the history
  • Loading branch information
pudingus committed Jan 29, 2022
1 parent e4d427e commit cf522d9
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
2 changes: 1 addition & 1 deletion scripts/max4ds/init.ms
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
local set_heapsize = 64 * 1024 * 1024 --64 MiB
if heapsize < set_heapsize then heapsize = set_heapsize

global Max4ds_version = "v0.8.2"
global Max4ds_version = "v0.8.3"
--global Max4ds_scriptsPath = getFilenamePath (getThisScriptFilename())

fn DisableScript file = (
Expand Down
16 changes: 14 additions & 2 deletions scripts/max4ds/ui_find_weights.ms
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,13 @@ rollout Max4ds_FindWeights "" ( --module
)


local verts = skinOps.getSelectedVertices skinMod
local maxver = (maxVersion())[1]
if maxver >= 22000 then (
local verts = skinOps.getSelectedVertices skinMod
)
else (
local verts = grp.verts
)

for vertId in verts do (
util.TransferWeight skinMod vertId oldid newId
Expand Down Expand Up @@ -399,7 +405,13 @@ rollout Max4ds_FindWeights "" ( --module
newId = grp.upBoneIds[grp.upBoneIds.count]
)

local verts = skinOps.getSelectedVertices skinMod
local maxver = (maxVersion())[1]
if maxver >= 22000 then (
local verts = skinOps.getSelectedVertices skinMod
)
else (
local verts = grp.verts
)

for vertId in verts do (
util.TransferWeight skinMod vertId oldid newId
Expand Down

0 comments on commit cf522d9

Please sign in to comment.