cond = true
s = if(cond, "The truth shall set you free", "Liar, liar, pants on fire.")
msg(s)msg(pi)msg(e)msg(sqrt(2))msg(asin(1))msg(abs(-3))msg(floor(2.5))msg(ceiling(2.5))msg(pow(2, 3))msg(log(e))Anything defined by Quest itself that can return any type (e.g. ListItem in this case) will have an "unknown" return type - in the C# code, anything that returns "object".
This is why functions like StringListItem exist, as that will have a known return type of string.
<function name="MyFunc" parameters="f1,f2" type="string">
msg("f1 is: " + f1)
return ("Howdy!")
</function>rundelegate(obj, "Method")
x = RunDelegateFunction(obj, "Method2")x = rundelegate(obj, "Method2")
RunDelegateFunction(obj, "Method")x = eval("1+1")
x = eval("RunDelegateFunction(player, \"doit\")")x = eval("msg(\"Howdy!\")")<function name="MyMsg" parameters="s" type="boolean">
msg(s)
return (true)
</function>
x = eval("MyMsg(\"Howdy!\")")
jaynabonne wrote:So the problem is that something like "list[0]" can have any type, which confuses things. Ironically, if you put it into a variable first, it works fine.
msg (1 and 3)msg(0xf7 and 0xcf)msg(0x30 or 0x1e)msg(not 255)msg(0x1234 and not 0xff)msg(0x1234 xor 0x1230)