I want to pass a result list from a function. My code looks something like this:
When I try to build this code, it is saying that I am trying to assign an integer to a list. How would I pass the resultant list?
method whichpos() local a% local templist:TList for a = 1 to maxplayers% templist = lookupplayerval("PID",PID%[a]) <<Snipped code here>> Next End Method function lookupplayerval(fld$,val%) local tp:player local templist:TList for tp:player = eachin Plist select fld$ case "TID" if val% = tp.TID% then templist.AddLast tp end if <<Snipped other redundant cases here>> end select Next return templist End Function
When I try to build this code, it is saying that I am trying to assign an integer to a list. How would I pass the resultant list?