Expression of type string array cannot be invoked

BlitzMax Forums/BlitzMax Programming/Expression of type string array cannot be invoked

this line throws an error in strict mode but not in normal mode:


If object_type(bs.x , bs.y) = "barrel"


the error says: "Expression of type 'string array' cannot be invoked"

Looks like your function object_type(bs.x , bs.y) doesn't return a string?

Function object_type:String(bs.x , bs.y)
Return "barrel"
End Function

its an array
(sorry forgot to mention)

If it is an array you need
If object_type[bs.x , bs.y] = "barrel"


thanks that worked!