k I'm trying to find out what this line does as a trigger.
^[A-Za-z *]*\[(.*)\](.*) x:(.*) y:(.*) z:(.*) r:(.*) b:(.*) s:(.*) h:(.*) S:(.*)
for some reason when I reference theparameter(9) it takes anything after the h: instead of stopping at the S:
and when I ask for theparameter(10) instead of displaying what's after the S: it displays the whole entire line..
Other than that all the other variables I am grabbing from this line are working correctly.
Here's the VB code I have using this, cut short cause it's long but relevant info is there..
Sub StoreContact(thename, theoutput, theparameter)
'Inputs: Contact information from a "contacts"
'Outputs: None
'Purpose: Stores contact data on targets for later manipulation.
' A damage record is generated at this point if the target doesn't have one
Dim strID, strName, strLoc1, strLoc2, strLoc3, strHead, strSpeed, strStatus, strRange
Dim strData, strStored, strConChan, strStoredData, tCallIt, strDamage
Dim strOldContactInfo, strConType
strID = Trim(theparameter(1))
strStored = World.getvariable("DesiredContact")
strConChan = World.getvariable("ContactChannel")
strName = Trim(theparameter(2))
strLoc1 = "%cbX:%cy " & Trim(theparameter(3))
strLoc2 = "%cbY:%cy " & Trim(theparameter(4))
strLoc3 = "%cbZ:%cy " & Trim(theparameter(5))
strRange = "%cbRange:%cy " & Trim(theparameter(6))
strHead = "%cbHead:%cy " & Trim(theparameter(9))
strSpeed = "%cbSpeed:%cy " & Trim(theparameter(8))
strStatus = "%cbStatus:%cy " & Trim(theparameter(10))
strConType = Left(strName, 1)
strName = Trim(Mid(strName, 2, Len(strName)))
If strName = "something" Then
strOldContactInfo = world.GetVariable("CONTACTDATA_" & strID)
If Len(strOldContactInfo) = 0 then
strData = "[" & strID & "] - %cm" & strName & " %cy-" & strLoc & " " & strRange & " " & strSpeed & " " & strHead & " " & strStatus
Else
strData = left(strOldContactInfo, InStr(1, strOldContactInfo, "- x:")-1) & "- " & strLoc & " " & strRange & " " & strSpeed & " " & strHead & " " & strStatus
End if
Else
strData = "[" & strID & "] - " & strName & " - " & strLoc1 & " " & strLoc2 & " " & strLoc3 & " " & strRange & " " & strSpeed & " " & strHead & " " & strStatus
End If
^[A-Za-z *]*\[(.*)\](.*) x:(.*) y:(.*) z:(.*) r:(.*) b:(.*) s:(.*) h:(.*) S:(.*)
for some reason when I reference theparameter(9) it takes anything after the h: instead of stopping at the S:
and when I ask for theparameter(10) instead of displaying what's after the S: it displays the whole entire line..
Other than that all the other variables I am grabbing from this line are working correctly.
Here's the VB code I have using this, cut short cause it's long but relevant info is there..
Sub StoreContact(thename, theoutput, theparameter)
'Inputs: Contact information from a "contacts"
'Outputs: None
'Purpose: Stores contact data on targets for later manipulation.
' A damage record is generated at this point if the target doesn't have one
Dim strID, strName, strLoc1, strLoc2, strLoc3, strHead, strSpeed, strStatus, strRange
Dim strData, strStored, strConChan, strStoredData, tCallIt, strDamage
Dim strOldContactInfo, strConType
strID = Trim(theparameter(1))
strStored = World.getvariable("DesiredContact")
strConChan = World.getvariable("ContactChannel")
strName = Trim(theparameter(2))
strLoc1 = "%cbX:%cy " & Trim(theparameter(3))
strLoc2 = "%cbY:%cy " & Trim(theparameter(4))
strLoc3 = "%cbZ:%cy " & Trim(theparameter(5))
strRange = "%cbRange:%cy " & Trim(theparameter(6))
strHead = "%cbHead:%cy " & Trim(theparameter(9))
strSpeed = "%cbSpeed:%cy " & Trim(theparameter(8))
strStatus = "%cbStatus:%cy " & Trim(theparameter(10))
strConType = Left(strName, 1)
strName = Trim(Mid(strName, 2, Len(strName)))
If strName = "something" Then
strOldContactInfo = world.GetVariable("CONTACTDATA_" & strID)
If Len(strOldContactInfo) = 0 then
strData = "[" & strID & "] - %cm" & strName & " %cy-" & strLoc & " " & strRange & " " & strSpeed & " " & strHead & " " & strStatus
Else
strData = left(strOldContactInfo, InStr(1, strOldContactInfo, "- x:")-1) & "- " & strLoc & " " & strRange & " " & strSpeed & " " & strHead & " " & strStatus
End if
Else
strData = "[" & strID & "] - " & strName & " - " & strLoc1 & " " & strLoc2 & " " & strLoc3 & " " & strRange & " " & strSpeed & " " & strHead & " " & strStatus
End If