(svn r15578) -Change: unexternalise squirrel.

This commit is contained in:
rubidium
2009-02-25 01:21:50 +00:00
parent 66a8c0a132
commit 1ad50ce4e6
81 changed files with 14906 additions and 0 deletions

33
src/3rdparty/squirrel/samples/flow.nut vendored Normal file
View File

@@ -0,0 +1,33 @@
function min(x,y)
return x<y?x:y;
function max(x,y)
return x>y?x:y;
if(min(100,200)>max(50,20))
print("I'm useless statement just to show up the if/else\n");
else
print("squirrel!!\n");
print("\n")
function typy(obj)
{
switch(typeof obj)
{
case "integer":
case "float":
return "is a number";
case "table":
case "array":
return "is a container";
default:
return "is other stuff"
}
}
local a=1,b={},c=function(a,b){return a+b;}
print("a "+typy(a)+"\n");
print("b "+typy(b)+"\n");
print("c "+typy(c)+"\n");