Added: Helper function trackasmlibGetPropertyCount

Fixed: some typos in the wire extension description
This commit is contained in:
Deyan Dobromirov 2022-11-04 14:35:44 +02:00
parent 151fd7e4c2
commit 6702a6af6e
3 changed files with 20 additions and 11 deletions

View File

@ -93,7 +93,7 @@ local asmlib = trackasmlib; if(not asmlib) then -- Module present
------------ CONFIGURE ASMLIB ------------
asmlib.InitBase("track","assembly")
asmlib.SetOpVar("TOOL_VERSION","8.696")
asmlib.SetOpVar("TOOL_VERSION","8.697")
asmlib.SetIndexes("V" ,1,2,3)
asmlib.SetIndexes("A" ,1,2,3)
asmlib.SetIndexes("WV",1,2,3)

View File

@ -1,5 +1,5 @@
E2Helper.Descriptions["trackasmlibApplyPhysicalAnchor(e:ennnn)"] = "Anchors the track entity to a base entity with weld 0/1 and no-collide 0/1 no-collide-world 0/1 and force limit."
E2Helper.Descriptions["trackasmlibApplyPhysicalSettings(e:nnns)"] = "Modifies track entity physical settings with phys-gun enabled, freeze, gravity toggle and surface material behavior"
E2Helper.Descriptions["trackasmlibApplyPhysicalSettings(e:nnns)"] = "Modifies track entity physical settings with physics gun enabled 0/1, freeze 0/1, gravity toggle 0/1 and surface material behavior"
E2Helper.Descriptions["trackasmlibAttachAdditions(e:)"] = "Attaches the track entity additions when available"
E2Helper.Descriptions["trackasmlibAttachBodyGroups(e:s)"] = "Attaches track piece body-groups by providing selection code"
E2Helper.Descriptions["trackasmlibGenActivePointDSV(e:essns)"] = "Exports the track entity as external database record"
@ -8,15 +8,16 @@ E2Helper.Descriptions["trackasmlibGetAdditionsCount(e:)"] = "Returns record addi
E2Helper.Descriptions["trackasmlibGetAdditionsCount(s)"] = "Returns record additions count by model"
E2Helper.Descriptions["trackasmlibGetAdditionsLine(e:n)"] = "Returns record additions line by entity"
E2Helper.Descriptions["trackasmlibGetAdditionsLine(sn)"] = "Returns record additions line by model"
E2Helper.Descriptions["trackasmlibGetBodyGroups(e:)"] = "Returns the track bodygoup selection list"
E2Helper.Descriptions["trackasmlibGetBodyGroups(e:)"] = "Returns the track bodygroup selection list"
E2Helper.Descriptions["trackasmlibGetName(e:)"] = "Returns record name by entity"
E2Helper.Descriptions["trackasmlibGetName(s)"] = "Returns record name by model"
E2Helper.Descriptions["trackasmlibGetOffset(e:ns)"] = "Returns record snap offsets by entity"
E2Helper.Descriptions["trackasmlibGetOffset(sns)"] = "Returns record snap offsets by model"
E2Helper.Descriptions["trackasmlibGetPointsCount(e:)"] = "Returns record points count by entity"
E2Helper.Descriptions["trackasmlibGetPointsCount(s)"] = "Returns record points count by model"
E2Helper.Descriptions["trackasmlibGetProperty()"] = "Returns the surface property types"
E2Helper.Descriptions["trackasmlibGetProperty()"] = "Returns an array with all surface property types"
E2Helper.Descriptions["trackasmlibGetProperty(s)"] = "Returns the surface properties available for a given type"
E2Helper.Descriptions["trackasmlibGetPropertyCount()"] = "Returns how many property types are available"
E2Helper.Descriptions["trackasmlibGetSkin(e:)"] = "Returns the track skin selection list"
E2Helper.Descriptions["trackasmlibGetType(e:)"] = "Returns record track type by entity"
E2Helper.Descriptions["trackasmlibGetType(s)"] = "Returns record track type by model"
@ -32,7 +33,7 @@ E2Helper.Descriptions["trackasmlibMakePiece(e:vansv)"] = "Creates new track piec
E2Helper.Descriptions["trackasmlibMakePiece(e:vansvn)"] = "Creates new track piece with position angle, mass, skin code and color as vector alpha as number by entity"
E2Helper.Descriptions["trackasmlibMakePiece(svan)"] = "Creates new track piece with position angle, mass by model"
E2Helper.Descriptions["trackasmlibMakePiece(svans)"] = "Creates new track piece with position angle, mass and skin code by model"
E2Helper.Descriptions["trackasmlibMakePiece(svansnnnn)"] = "Creates new track piece with position angle, mass, skin code and color and aplha as numbers by model"
E2Helper.Descriptions["trackasmlibMakePiece(svansnnnn)"] = "Creates new track piece with position angle, mass, skin code and color and alpha as numbers by model"
E2Helper.Descriptions["trackasmlibMakePiece(svansv)"] = "Creates new track piece with position angle, mass, skin code and color as vector alpha is 255 by model"
E2Helper.Descriptions["trackasmlibMakePiece(svansvn)"] = "Creates new track piece with position angle, mass, skin code and color as vector alpha by as number model"
E2Helper.Descriptions["trackasmlibSnapEntity(e:vsnnnnva)"] = "Returns track entity snap position and angle array by holder model, point ID, active radius, flatten, ignore type, position offset and angle offset"

View File

@ -248,17 +248,25 @@ end
__e2setcost(15)
e2function array trackasmlibGetProperty(string sType)
if(not enFlag) then return {} end
local stRec = asmlib.CacheQueryProperty(sType)
if(not stRec) then return {} end
return stRec
local stType = asmlib.CacheQueryProperty(sType)
if(not stType) then return {} end
return stType
end
__e2setcost(15)
e2function array trackasmlibGetProperty()
if(not enFlag) then return {} end
local stRec = asmlib.CacheQueryProperty()
if(not stRec) then return {} end
return stRec
local stType = asmlib.CacheQueryProperty()
if(not stType) then return {} end
return stType
end
__e2setcost(15)
e2function number trackasmlibGetPropertyCount()
if(not enFlag) then return 0 end
local stType = asmlib.CacheQueryProperty()
if(not stType) then return 0 end
return (tonumber(stType.Size) or 0)
end
--[[ **************************** CREATOR **************************** ]]