diff --git a/rcbasic_build/cbc_spec.txt b/rcbasic_build/cbc_spec.txt index 0344d98..086c571 100644 --- a/rcbasic_build/cbc_spec.txt +++ b/rcbasic_build/cbc_spec.txt @@ -43,3 +43,5 @@ DATA SEGMENT SIZE 8 BYTES //----PROGRAM---- CODE SEGMENT CODE SEGMENT SIZE DATA SEGMENT DATA SEGMENT SIZE + + diff --git a/rcbasic_build/embedded_functions.bas b/rcbasic_build/embedded_functions.bas index 22c6eee..40b7519 100644 --- a/rcbasic_build/embedded_functions.bas +++ b/rcbasic_build/embedded_functions.bas @@ -514,3 +514,14 @@ sub IncrementMatrixRows(mA, mB, r, num_rows, value) sub IncrementMatrixColumns(mA, mB, c, num_cols, value) sub JoinMatrixRows(mA, mB, mC) sub JoinMatrixColumns(mA, mB, mC) + +'v4.0 + +'Empty Type is used mainly for built-in functions that need to have a user type specified to be able to compile properly +type empty +end type + +function TypeArrayDim(Byref id as empty) +function TypeArraySize(Byref id as empty, array_dim) +sub TypeArrayCopy(ByRef src as empty, ByRef dst as empty) +sub TypeArrayFill(ByRef src as empty, fdata as empty) diff --git a/rcbasic_build/identifier.h b/rcbasic_build/identifier.h index 8fb8c83..f4bd83f 100644 --- a/rcbasic_build/identifier.h +++ b/rcbasic_build/identifier.h @@ -60,8 +60,8 @@ stack for_counter; stack do_end; stack while_end; -bool isFunctionArg_flag = false; - +bool isFunctionArg_flag = false; + bool enable_presets = true; struct if_data @@ -426,6 +426,82 @@ bool add_type_member(string member_name, int member_type, string member_utype_na return true; } +bool add_type_member_embedded(string member_name, int member_type, string member_utype_name, int member_dim_count, int dim1, int dim2, int dim3) +{ + int m_utype_index = member_utype_name.compare("")!=0 ? getUType(member_utype_name) : -1; + if(m_utype_index == current_type_index) + { + //cout << "you canno do is" << endl; + rc_setError("Cannot create member of type from within itself"); + return false; + } + //cout << "utype index = " << current_type_index << endl; + int utype_index = current_type_index; + int utype_current_member = utype[utype_index].num_members; + member_name = StringToLower(member_name); + utype[utype_index].member_name.push_back(member_name); + + string dim_mem_type = ""; + + switch(member_type) + { + case ID_TYPE_NUM: + dim_mem_type = "!0 !" + rc_intToString(utype_current_member); + utype[utype_index].member_type.push_back(ID_TYPE_USER_NUM); + utype[utype_index].member_vec_pos.push_back(utype[utype_index].nidCount); + utype[utype_index].nidCount++; + break; + case ID_TYPE_ARR_NUM: + dim_mem_type = "!0 !" + rc_intToString(utype_current_member); + utype[utype_index].member_type.push_back(ID_TYPE_USER_NUM_ARRAY); + utype[utype_index].member_vec_pos.push_back(utype[utype_index].nidCount); + utype[utype_index].nidCount++; + break; + case ID_TYPE_STR: + dim_mem_type = "!1 !" + rc_intToString(utype_current_member); + utype[utype_index].member_type.push_back(ID_TYPE_USER_STR); + utype[utype_index].member_vec_pos.push_back(utype[utype_index].sidCount); + utype[utype_index].sidCount++; + break; + case ID_TYPE_ARR_STR: + dim_mem_type = "!1 !" + rc_intToString(utype_current_member); + utype[utype_index].member_type.push_back(ID_TYPE_USER_STR_ARRAY); + utype[utype_index].member_vec_pos.push_back(utype[utype_index].sidCount); + utype[utype_index].sidCount++; + break; + case ID_TYPE_USER: + dim_mem_type = "!2 !" + rc_intToString(utype_current_member); + utype[utype_index].member_type.push_back(ID_TYPE_USER); + utype[utype_index].member_vec_pos.push_back(utype[utype_index].uidCount); + utype[utype_index].uidCount++; + break; + default: + rc_setError("Invalid member type in type definition"); + return false; + break; + } + + utype[utype_index].member_dim_count.push_back(member_dim_count); + utype[utype_index].member_utype_index.push_back(m_utype_index); + + + vm_asm.push_back("dim_tfield !" + rc_intToString(utype_index) + " " + dim_mem_type + " !" + + rc_intToString(member_dim_count) + " " + + "n0 n1 n2"); + + //NOTE: user_array_dim is no longer used + user_array_dim d; + d.dim_size[0] = dim1; + d.dim_size[1] = dim2; + d.dim_size[2] = dim3; + utype[utype_index].member_dim.push_back(d); + //cout << member_name << " has " << member_dim_count << " dimensions" << endl; + //utype[utype_index].member_dim[utype_current_member].dim_size[1] = dim2; + //utype[utype_index].member_dim[utype_current_member].dim_size[2] = dim3; + utype[utype_index].num_members++; + return true; +} + //return the index of the id name or -1 on failure int getIDInScope_ByIndex_TypeMatch(string id_name, string check_scope="") { @@ -441,13 +517,34 @@ int getIDInScope_ByIndex_TypeMatch(string id_name, string check_scope="") int id_match = -1; check_scope = StringToLower(check_scope); //cout << "CHECK SCOPE = " << check_scope << endl; + + string id_name_str = ""; + + if(id_name.substr(id_name.length()-1,1).compare("$")==0) + { + id_name_str = id_name; + } + else + { + id_name_str = id_name + "$"; + } + for(int i = 0; i < id.size(); i++) { if(id[i].scope.compare(check_scope)==0) { - //cout << id_name << " ~ " << id[i].name << endl; - if(id_name.compare(id[i].name)==0) - return i; + if(id[i].name.substr(id[i].name.length()-1,1).compare("$")==0) //id in type is string + { + //cout << id_name_str << " ~ " << id[i].name << endl; + if(id_name_str.compare(StringToLower(id[i].name))==0) + return i; + } + else + { + //cout << id_name << " ~ " << id[i].name << endl; + if(id_name.compare(StringToLower(id[i].name))==0) + return i; + } } } return id_match; @@ -815,7 +912,18 @@ bool create_variable(string name, int type, string utype_name="", int vec = -1) int var_index = id.size(); var.num_args = 0; var.parent_index = -1; - set_vectorPosition(var); + + if(vec == -1) + { + set_vectorPosition(var); + //cout << var.name << " <==> " << var.vec_pos << endl; + } + else + { + //cout << "set " << name << " to " << vec << endl; + var.vec_pos = vec; + } + id.push_back(var); if(isInFunctionScope && !isFunctionArg_flag) @@ -940,7 +1048,7 @@ bool create_array(string name, int type, string utype_name, int dim_count, strin return true; } -bool embed_function(string name, int type) +bool embed_function(string name, int type, int fn_utype=-1) { if(getIDInScope(name) >= 0) { @@ -958,6 +1066,7 @@ bool embed_function(string name, int type) break; case ID_TYPE_FN_NUM: case ID_TYPE_FN_STR: + case ID_TYPE_FN_USER: current_block_state = BLOCK_STATE_FUNCTION; break; default: @@ -976,9 +1085,11 @@ bool embed_function(string name, int type) fn.name = name; fn.scope = "main"; fn.type = type; + fn.type_index = fn_utype; fn.isBuiltin = true; fn.vmFunctionIndex = current_vmFunction_index; current_vmFunction_index++; + //cout << "current_vmFunction = " << current_vmFunction_index << endl; fn.num_args = 0; //function args default to 0; args are added with add_function_args current_fn_index = id.size(); @@ -986,7 +1097,7 @@ bool embed_function(string name, int type) return true; } -bool add_embedded_arg(string arg_name, int arg_type) +bool add_embedded_arg(string arg_name, int arg_type, int arg_utype=-1) { //fn_arg //fn_arg_type @@ -994,6 +1105,11 @@ bool add_embedded_arg(string arg_name, int arg_type) int fn_index = current_fn_index; id[fn_index].fn_arg.push_back(arg_name); id[fn_index].fn_arg_type.push_back(arg_type); + id[fn_index].fn_arg_utype.push_back(arg_utype); + + string fn_arg_utype_name = ""; + if(arg_utype >= 0) + fn_arg_utype_name = utype[arg_utype].name; string fn_id = ""; int fn_id_index = -1; @@ -1012,6 +1128,13 @@ bool add_embedded_arg(string arg_name, int arg_type) create_variable(fn_id, ID_TYPE_STR); fn_strCount++; } + else if(arg_type == ID_TYPE_USER) + { + fn_id = "#fu" + rc_intToString(fn_usrCount); + if(getIDInScope(fn_id) < 0) + create_variable(fn_id, ID_TYPE_USER, fn_arg_utype_name); + fn_usrCount++; + } else if(arg_type == ID_TYPE_BYREF_NUM) { fn_id = "#fn" + rc_intToString(fn_numCount); @@ -1026,6 +1149,13 @@ bool add_embedded_arg(string arg_name, int arg_type) create_variable(fn_id, ID_TYPE_BYREF_STR); fn_strCount++; } + else if(arg_type == ID_TYPE_BYREF_USER) + { + fn_id = "#fu" + rc_intToString(fn_usrCount); + if(getIDInScope(fn_id) < 0) + create_variable(fn_id, ID_TYPE_BYREF_USER, fn_arg_utype_name); + fn_usrCount++; + } else { rc_setError("Invalid type in function definition"); @@ -1037,7 +1167,7 @@ bool add_embedded_arg(string arg_name, int arg_type) isFunctionArg_flag = true; - create_variable(arg_name, arg_type, "", fn_arg_vec); + create_variable(arg_name, arg_type, fn_arg_utype_name, fn_arg_vec); id[fn_index].fn_reg.push_back( fn_id ); id[fn_index].fn_arg_vec.push_back(fn_arg_vec); diff --git a/rcbasic_build/main.cpp b/rcbasic_build/main.cpp index 0a04fe7..7d2024c 100644 --- a/rcbasic_build/main.cpp +++ b/rcbasic_build/main.cpp @@ -36,7 +36,8 @@ vector inc_files; void rcbasic_init() { - create_type("null"); + //init built-in types here + init_embedded_types(); //init built-in functions here @@ -46,7 +47,9 @@ void rcbasic_init() current_scope = "main"; vm_asm.push_back(".code"); - init_embedded(); + init_embedded_functions(); + + init_embedded_variables(); //cout << "numid_count = " << num_id_count << endl; //cout << "strid_count = " << str_id_count << endl << endl; @@ -61,7 +64,7 @@ void rcbasic_init() void rcbasic_dev_init() { - create_type("null"); + //create_type("empty"); //init built-in functions here @@ -166,354 +169,7 @@ bool rc_preprocessor() return true; } -bool Array_Macros(int tmp_start_token) -{ - //returning true is just saying there were no syntax errors found - if(tmp_token[tmp_start_token].length() < 5) - return true; - if(StringToLower(tmp_token[tmp_start_token].substr(4)).compare("arraydim")!=0 && StringToLower(tmp_token[tmp_start_token].substr(4)).compare("arraysize")!=0 && - StringToLower(tmp_token[tmp_start_token].substr(4)).compare("arraycopy")!=0 && StringToLower(tmp_token[tmp_start_token].substr(4)).compare("arrayfill")!=0) - return true; - int64_t arr_id = 0; - vector tmp_macro_token; - vector tmp_current_token; - //int ArrayDim_id = getIDInScope_ByIndex("ArrayDim"); - for(int i = tmp_start_token; i < tmp_token.size(); i++) - { - if(tmp_token[i].substr(0,4).compare("")==0) - { - if(StringToLower(tmp_token[i].substr(4)).compare("arraydim")==0) - { - if(tmp_token[i+1].compare("")!=0) - { - rc_setError("Invalid use of ArrayDim"); - return false; - } - if(tmp_token[i+2].substr(0,4).compare("")==0) - { - arr_id = getIDInScope_ByIndex(tmp_token[i+2].substr(4)); - if(arr_id < 0) - { - rc_setError("Identifier must be declared before call to ArrayDim"); - return false; - } - - id[arr_id].isArrayArg = true; - - } - else - { - rc_setError("Expected Identifier in ArrayDim"); - return false; - } - - int end_token = i+2; - int expr_scope = 1; - for(end_token; end_token < tmp_token.size(); end_token++) - { - if(tmp_token[end_token].compare("")==0 || tmp_token[end_token].compare("")==0) - expr_scope++; - else if(tmp_token[end_token].compare("")==0 || tmp_token[end_token].compare("")==0) - expr_scope--; - - if(expr_scope==0 && tmp_token[end_token].compare("")==0) - break; - } - - tmp_macro_token.clear(); - for(int n = i; n <= end_token; n++) - tmp_macro_token.push_back(tmp_token[n]); - - //cout << "<---- DEBUG ---->" << i << endl; - //for(int n = 0; n < token.size(); n++) - // cout <<"token[" << n << "] = " << token[n] << endl; - - tmp_current_token.clear(); - for(int n = 0; n < token.size(); n++) - tmp_current_token.push_back(token[n]); - - token.clear(); - for(int n = 0; n < tmp_macro_token.size(); n++) - token.push_back(tmp_macro_token[n]); - - //for(int n = 0; n < token.size(); n++) - // cout <<"new token[" << n << "] = " << token[n] << endl; - - - if(!eval_expression()) - { - rc_setError("Could not evaluate ArrayDim"); - return false; - } - - for(int n = i; n <= end_token; n++) - tmp_token[n] = token[n-i]; - - token.clear(); - for(int n = 0; n < tmp_current_token.size(); n++) - token.push_back(tmp_current_token[n]); - - //for(int n = 0; n < token.size(); n++) - // cout <<"final token[" << n << "] = " << token[n] << endl; - return true; - - } - else if(StringToLower(tmp_token[i].substr(4)).compare("arraysize")==0) - { - if(tmp_token[i+1].compare("")!=0) - { - rc_setError("Invalid use of ArraySize"); - return false; - } - if(tmp_token[i+2].substr(0,4).compare("")==0) - { - arr_id = getIDInScope_ByIndex(tmp_token[i+2].substr(4)); - if(arr_id < 0) - { - rc_setError("Identifier must be declared before call to ArraySize"); - return false; - } - - id[arr_id].isArrayArg = true; - - } - else - { - rc_setError("Expected Identifier in ArraySize"); - return false; - } - - int end_token = i+2; - int expr_scope = 1; - for(end_token; end_token < tmp_token.size(); end_token++) - { - if(tmp_token[end_token].compare("")==0 || tmp_token[end_token].compare("")==0) - expr_scope++; - else if(tmp_token[end_token].compare("")==0 || tmp_token[end_token].compare("")==0) - expr_scope--; - - if(expr_scope==0 && tmp_token[end_token].compare("")==0) - break; - } - - tmp_macro_token.clear(); - for(int n = i; n <= end_token; n++) - tmp_macro_token.push_back(tmp_token[n]); - - - tmp_current_token.clear(); - for(int n = 0; n < token.size(); n++) - tmp_current_token.push_back(token[n]); - - token.clear(); - for(int n = 0; n < tmp_macro_token.size(); n++) - token.push_back(tmp_macro_token[n]); - - if(!eval_expression(0, token.size()-1, true))//i, end_token)) - { - rc_setError("Could not evaluate ArraySize expression"); - //for(int n = 0; n < token.size(); n++) - // cout << "token["<< n << "] = " << token[n] << endl; - return false; - } - - for(int n = i; n <= end_token; n++) - tmp_token[n] = token[n-i]; - - token.clear(); - for(int n = 0; n < tmp_current_token.size(); n++) - token.push_back(tmp_current_token[n]); - - return true; - } - else if(StringToLower(tmp_token[i].substr(4)).compare("arraycopy")==0) - { - if(tmp_token.size() < 5) - { - rc_setError("Ivalid use of ArrayCopy"); - return false; - } - - if(tmp_token[i+1].compare("")!=0) - { - rc_setError("Invalid use of ArrayCopy"); - return false; - } - - if(tmp_token[i+2].substr(0,4).compare("")==0) - { - arr_id = getIDInScope_ByIndex(tmp_token[i+2].substr(4)); - if(arr_id < 0) - { - rc_setError("Identifier must be declared before call to ArrayCopy"); - return false; - } - - id[arr_id].isArrayArg = true; - - } - else - { - rc_setError("Expected Identifier in ArrayCopy"); - return false; - } - - if(!tmp_token[i+3].substr(0,7).compare("")==0) - { - rc_setError("Expected comma in ArrayCopy"); - return false; - } - - if(tmp_token[i+4].substr(0,4).compare("")==0) - { - arr_id = getIDInScope_ByIndex(tmp_token[i+4].substr(4)); - if(arr_id < 0) - { - rc_setError("Identifier must be declared before call to ArrayCopy"); - return false; - } - - id[arr_id].isArrayArg = true; - - } - else - { - rc_setError("Expected Identifier in ArrayCopy"); - return false; - } - - int end_token = i+4; - int expr_scope = 1; - for(end_token; end_token < tmp_token.size(); end_token++) - { - if(tmp_token[end_token].compare("")==0 || tmp_token[end_token].compare("")==0) - expr_scope++; - else if(tmp_token[end_token].compare("")==0 || tmp_token[end_token].compare("")==0) - expr_scope--; - - if(expr_scope==0 && tmp_token[end_token].compare("")==0) - break; - } - - tmp_macro_token.clear(); - for(int n = i; n <= end_token; n++) - tmp_macro_token.push_back(tmp_token[n]); - - //cout << "<---- DEBUG ---->" << i << endl; - //for(int n = 0; n < token.size(); n++) - // cout <<"token[" << n << "] = " << token[n] << endl; - - tmp_current_token.clear(); - for(int n = 0; n < token.size(); n++) - tmp_current_token.push_back(token[n]); - - token.clear(); - for(int n = 0; n < tmp_macro_token.size(); n++) - token.push_back(tmp_macro_token[n]); - - //for(int n = 0; n < token.size(); n++) - // cout <<"new token[" << n << "] = " << token[n] << endl; - - - if(!eval_expression()) - { - rc_setError("Could not evaluate ArrayCopy"); - return false; - } - - for(int n = i; n <= end_token; n++) - tmp_token[n] = token[n-i]; - - token.clear(); - for(int n = 0; n < tmp_current_token.size(); n++) - token.push_back(tmp_current_token[n]); - - //for(int n = 0; n < token.size(); n++) - // cout <<"final token[" << n << "] = " << token[n] << endl; - return true; - - } - else if(StringToLower(tmp_token[i].substr(4)).compare("arrayfill")==0) - { - if(tmp_token[i+1].compare("")!=0) - { - rc_setError("Invalid use of ArrayFill"); - return false; - } - if(tmp_token[i+2].substr(0,4).compare("")==0) - { - arr_id = getIDInScope_ByIndex(tmp_token[i+2].substr(4)); - if(arr_id < 0) - { - rc_setError("Identifier must be declared before call to ArrayFill"); - return false; - } - - id[arr_id].isArrayArg = true; - - } - else - { - rc_setError("Expected Identifier in ArrayFill"); - return false; - } - - int end_token = i+2; - int expr_scope = 1; - for(end_token; end_token < tmp_token.size(); end_token++) - { - if(tmp_token[end_token].compare("")==0 || tmp_token[end_token].compare("")==0) - expr_scope++; - else if(tmp_token[end_token].compare("")==0 || tmp_token[end_token].compare("")==0) - expr_scope--; - - if(expr_scope==0 && tmp_token[end_token].compare("")==0) - break; - } - - tmp_macro_token.clear(); - for(int n = i; n <= end_token; n++) - tmp_macro_token.push_back(tmp_token[n]); - - //cout << "<---- DEBUG ---->" << i << endl; - //for(int n = 0; n < token.size(); n++) - // cout <<"token[" << n << "] = " << token[n] << endl; - - tmp_current_token.clear(); - for(int n = 0; n < token.size(); n++) - tmp_current_token.push_back(token[n]); - - token.clear(); - for(int n = 0; n < tmp_macro_token.size(); n++) - token.push_back(tmp_macro_token[n]); - - //for(int n = 0; n < token.size(); n++) - // cout <<"new token[" << n << "] = " << token[n] << endl; - - - if(!eval_expression()) - { - rc_setError("Could not evaluate ArrayFill"); - return false; - } - - for(int n = i; n <= end_token; n++) - tmp_token[n] = token[n-i]; - - token.clear(); - for(int n = 0; n < tmp_current_token.size(); n++) - token.push_back(tmp_current_token[n]); - - //for(int n = 0; n < token.size(); n++) - // cout <<"final token[" << n << "] = " << token[n] << endl; - return true; - - } - } - } - return false; -} bool rc_eval(string line) { @@ -524,6 +180,8 @@ bool rc_eval(string line) ERROR_MSG = ""; clearRegs(); clearTokens(); + byref_type_exception.clear(); + if(line.compare("#var")==0) { output_vars(); @@ -597,11 +255,11 @@ bool rc_eval(string line) //cout << "i = " << i << " tmp_token_size = " << tmp_token.size() << endl; if(tmp_token[i].compare("<:>")==0) break; - else if(!Array_Macros(i)) - { - //cout << "ERROR:" << rc_getError() << endl; - return false; - } + //else if(!Array_Macros(i)) + //{ + // cout << "ERROR:" << rc_getError() << endl; + // return false; + //} //cout << "### tmp_token[" << i << "] = "; //cout << tmp_token[i] << endl; token.push_back(tmp_token[i]); @@ -617,6 +275,20 @@ bool rc_eval(string line) } } + if(byref_type_exception.size() > 0) + { + for(int i = 0; i < byref_type_exception.size(); i++) + { + //cout << "type exception: [" << byref_type_exception[i].tk_reg << "] exception_status = " << byref_type_exception[i].exception_used << endl; + + if(!byref_type_exception[i].exception_used) + { + rc_setError(byref_type_exception[i].error_log); + return false; + } + } + } + return true; //if(!eval_expression()) @@ -762,7 +434,7 @@ bool rcbasic_compile() { vm_asm.push_back("dbg uint=0 uint=" + rc_uint64ToString(rcbasic_program.top().dbg_inc_index) + " uint=" + rc_uint64ToString(rcbasic_program.top().line_number)); } - cout << "line " << rcbasic_program.top().line_number << ": " << rcbasic_file.tellg() << " -> " << line << endl; + //cout << "line " << rcbasic_program.top().line_number << ": " << rcbasic_file.tellg() << " -> " << line << endl; if(!rcbasic_program.top().eof_reached) rcbasic_program.top().line_position = rcbasic_file.tellg(); //vm_asm.push_back("mov n0 " + rc_intToString(rcbasic_program.top().line_number)); @@ -827,6 +499,7 @@ void rcbasic_export_dev() fstream f("rcbasic_dev.txt", fstream::out | fstream::trunc); fstream f2("rcbasic_dev2.txt", fstream::out | fstream::trunc); fstream f3("rcbasic_dev3.txt", fstream::out | fstream::trunc); + fstream f4("rcbasic_dev4.txt", fstream::out | fstream::trunc); if(!f.is_open()) return; @@ -848,6 +521,11 @@ void rcbasic_export_dev() f2 << fn_line << endl; f3 << "case FN_" << id[i].name << ": //String Function" << endl << "break;" << endl; break; + case ID_TYPE_FN_USER: + output_line += "ID_TYPE_FN_STR);"; + f2 << fn_line << endl; + f3 << "case FN_" << id[i].name << ": //UDT Function" << endl << "break;" << endl; + break; case ID_TYPE_SUB: output_line += "ID_TYPE_SUB);"; f2 << fn_line << endl; @@ -858,6 +536,7 @@ void rcbasic_export_dev() } f << output_line << endl; output_line = ""; + string fn_arg_utype = ""; for(int n = 0; n < id[i].num_args; n++) { fn_line = "#define " + StringToUpper(id[i].name + "_" + id[i].fn_arg[n]) + " "; @@ -868,19 +547,33 @@ void rcbasic_export_dev() case ID_TYPE_NUM: output_line += "ID_TYPE_NUM);"; //fn_line += "num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].nid_value[0].value[0]"; - fn_line += "num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].nid_value[0].value[ num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].byref_offset ]"; + fn_line += "num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].nid_value.value[ num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].byref_offset ]"; break; case ID_TYPE_BYREF_NUM: output_line += "ID_TYPE_BYREF_NUM);"; - fn_line += "num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].nid_value[0].value[ num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].byref_offset ]"; + fn_line += "num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].nid_value.value[ num_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].byref_offset ]"; break; case ID_TYPE_STR: output_line += "ID_TYPE_STR);"; - fn_line += "str_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].sid_value[0].value[ str_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].byref_offset ]"; + fn_line += "str_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].sid_value.value[ str_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].byref_offset ]"; break; case ID_TYPE_BYREF_STR: output_line += "ID_TYPE_BYREF_STR);"; - fn_line += "str_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].sid_value[0].value[ str_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].byref_offset ]"; + fn_line += "str_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].sid_value.value[ str_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].byref_offset ]"; + break; + case ID_TYPE_USER: + //fn_arg_utype = ""; + //if(id[i].fn_arg_utype[n] >= 0) + // fn_arg_utype = utype[id[i].fn_arg_utype[n]].name; + output_line += "ID_TYPE_USER, " + rc_intToString(id[i].fn_arg_utype[n]) + ");"; + fn_line += "usr_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].var_ref->uid_value[0]"; + break; + case ID_TYPE_BYREF_USER: + //fn_arg_utype = ""; + //if(id[i].fn_arg_utype[n] >= 0) + // fn_arg_utype = utype[id[i].fn_arg_utype[n]].name; + output_line += "ID_TYPE_BYREF_USER, " + rc_intToString(id[i].fn_arg_utype[n]) + ");"; + fn_line += "usr_var[" + rc_intToString(id[i].fn_arg_vec[n]) + "].var_ref"; break; } f2 << fn_line << endl; @@ -888,9 +581,50 @@ void rcbasic_export_dev() } } + + for(int i = 0; i < utype.size(); i++) + { + output_line = "create_type(\"" + utype[i].name + "\");"; + + f4 << output_line << endl; + + for(int n = 0; n < utype[i].num_members; n++) + { + output_line = "vm_asm.push_back(\"mov n0 " + rc_intToString(utype[i].member_dim[n].dim_size[0]) + "\");"; + f4 << output_line << endl; + + output_line = "vm_asm.push_back(\"mov n1 " + rc_intToString(utype[i].member_dim[n].dim_size[1]) + "\");"; + f4 << output_line << endl; + + output_line = "vm_asm.push_back(\"mov n2 " + rc_intToString(utype[i].member_dim[n].dim_size[2]) + "\");"; + f4 << output_line << endl; + + int ut_index = utype[i].member_utype_index[n]; + string member_utype_name = ""; + + if(ut_index >= 0) + member_utype_name = utype[ut_index].name; + else if(utype[i].member_type[n] == ID_TYPE_USER) + { + cout << "ERROR CREATING TYPE" << endl; + f.close(); + f2.close(); + f3.close(); + f4.close(); + return; + } + + + output_line = "add_type_member(\"" + utype[i].member_name[n] + "\", " + rc_intToString(utype[i].member_type[n]) + ", \"" + member_utype_name + "\", " + + rc_intToString(utype[i].member_dim_count[n]) + ", \"n0\", \"n1\", \"n2\");"; + f4 << output_line << endl; + } + } + f.close(); f2.close(); f3.close(); + f4.close(); cout << "rcbasic_dev file was created" << endl; } @@ -965,6 +699,9 @@ void rcbasic_output_debug_info() case ID_TYPE_USER: f << "U " << id[i].scope << " " << id[i].name << " " << id[i].vec_pos << "\n"; break; + case ID_TYPE_BYREF_USER: + f << "BU " << id[i].scope << " " << id[i].name << " " << id[i].vec_pos << "\n"; + break; case ID_TYPE_USER_NUM: f << "UN " << id[i].scope << " " << id[i].name << " " << id[i].vec_pos << "\n"; break; @@ -996,7 +733,7 @@ int main(int argc, char * argv[]) { string line = ""; - //rcbasic_dev("embedded_functions.bas"); return 0; + //rcbasic_dev("embedded_functions.bas"); rcbasic_output_debug_info(); return 0; string rc_filename = "";// = "tst.bas"; diff --git a/rcbasic_build/parser.h b/rcbasic_build/parser.h index 00b4dc8..0142b1f 100644 --- a/rcbasic_build/parser.h +++ b/rcbasic_build/parser.h @@ -22,7 +22,30 @@ int u_reg = 0; //expression result string expr_result = ""; bool type_delete_flag = false; -string type_delete_arg = ""; +string type_delete_arg = ""; +int type_delete_arg_type = 0; +bool type_delete_arg_whole = false; + +bool type_redim_flag = false; +string type_redim_arg = ""; +int type_redim_arg_type = 0; +string type_redim_arg_utype = ""; +string type_redim_dim[3]; +int type_redim_dim_count = 0; + +bool type_no_arg_exception_raised = false; + +struct type_error_exception +{ + string error_log; + string tk_reg; + string resolve_reg; + int num_args; + bool exception_used; +}; + +vector byref_type_exception; //This will store the error that might be generated if a user type var is in an expression without its dimensions expressed + bool pre_parse(int start_token, int end_token, int pp_flags = 0, bool eval_udt = false); //puts number and string values and variables inside number and string registers //void getBlock(int& start_block, int& end_block); //gets the start and end index of the next block to evaluate (first and last token if there isnt a block left to evaluate @@ -1001,6 +1024,13 @@ int getArrayObjStart(int arg_id) return 0; } + +bool byref_type_generic(string utype_name) +{ + if(utype_name.compare("empty")==0) + return true; + return false; +} bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_udt) @@ -1016,7 +1046,9 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ string s = ""; string u = ""; int expr_id = -1; - string sdata = ""; + string sdata = ""; + + bool byref_type_flag = false; for(int i = start_token; i <= end_token; i++) { @@ -1243,15 +1275,15 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ } else if( ID_TYPE_USER_ALL(expr_id) && eval_udt ) { - cout << "-Parsing User Variable: " << id[expr_id].name << endl; - cout << "----------------------------------------------- : " << eval_udt << endl; + //cout << "-Parsing User Variable: " << id[expr_id].name << endl; + //cout << "----------------------------------------------- : " << eval_udt << endl; bool udt_id_init = true; string tmp_scope = id[expr_id].scope; - for(int t = i; t < token.size(); t++) + /*for(int t = i; t < token.size(); t++) { try { @@ -1261,19 +1293,30 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ { cout << "Token Out of Range Error: " << e.what() << endl; } - } + }*/ int tmp_id = 0; bool has_child = false; + int num_id_parents = 0; + int num_id_children = 0; + byref_type_flag = false; + for(int t = i; t <= end_token; t++) { if(token[t].substr(0,4).compare("")==0) { - cout << "FIGURE IT OUT: " << t << endl; + if(num_id_parents != num_id_children) + { + rc_setError("Expected member separator or member ID"); + return false; + } + + num_id_parents++; + //cout << "FIGURE IT OUT: " << t << endl; string args[3]; int arg_count = 0; string full_id = token[t].substr(4); @@ -1287,7 +1330,7 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ return false; } - cout << "Scope = " << tmp_scope << " ID = " << full_id << " -- " << tmp_id << endl << endl; + //cout << "Scope = " << tmp_scope << " ID = " << full_id << " -- " << tmp_id << endl << endl; tmp_scope += "." + full_id; @@ -1307,7 +1350,7 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ arg_count = 0; arr_scope = 1; t2++; - cout << "T2 = " << t2 << endl << endl; + //cout << "T2 = " << t2 << endl << endl; for(; t2 <= end_token; t2++) { @@ -1350,6 +1393,8 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ arg_count++; } + else if(type_delete_flag || type_redim_flag) + t2--; } @@ -1361,15 +1406,83 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ { has_child = true; } - cout << "Has Child = " << has_child << ", " << t << ", " << t2 << endl; + //cout << "Has Child = " << has_child << ", " << t << ", " << t2 << endl; + } + + if(type_delete_flag && (!has_child) && arg_count != 0) + { + rc_setError("Expected identifier without index"); + return false; } if(arg_count != id[tmp_id].num_args) { - if(!type_delete_flag) + if(type_redim_flag) { - rc_setError("[0]Expected " + rc_intToString(id[tmp_id].num_args) + " dimension in " + id[tmp_id].name); + if(has_child) + { + rc_setError("[1]Expected " + rc_intToString(id[tmp_id].num_args) + " dimension in " + id[tmp_id].name); + return false; + } + } + else if(!type_delete_flag) + { + if(arg_count != 0) + { + rc_setError("[0]Expected " + rc_intToString(id[tmp_id].num_args) + " dimension in " + id[tmp_id].name); + return false; + } + + //cout << "ID_TYPE = " << id[tmp_id].type << ", " << arg_count << ", " << (has_child ? "true" : "false") << endl; + + args[0] = ""; + args[1] = ""; + args[2] = ""; + + string tmp_instruction = "obj_usr_"; + + //trying stuff out + if(id[tmp_id].type == ID_TYPE_USER_NUM) + { + vm_asm.push_back("mov " + n + " 0"); + tmp_instruction += "n" + ( id[tmp_id].num_args <= 0 ? "" : rc_intToString(id[tmp_id].num_args) ); + for(int tmp_arg_i = 0; tmp_arg_i < id[tmp_id].num_args; tmp_arg_i++) + args[tmp_arg_i] = n; + + + vm_asm.push_back(tmp_instruction + " !" + rc_intToString(id[tmp_id].vec_pos) + " " + args[0] + " " + args[1] + " " + args[2]); + byref_type_flag = true; + break; + } + else if(id[tmp_id].type == ID_TYPE_USER_STR) + { + vm_asm.push_back("mov " + n + " 0"); + tmp_instruction += "s" + ( id[tmp_id].num_args <= 0 ? "" : rc_intToString(id[tmp_id].num_args) ); + for(int tmp_arg_i = 0; tmp_arg_i < id[tmp_id].num_args; tmp_arg_i++) + args[tmp_arg_i] = n; + + vm_asm.push_back(tmp_instruction + " !" + rc_intToString(id[tmp_id].vec_pos) + " " + args[0] + " " + args[1] + " " + args[2]); + byref_type_flag = true; + break; + } + else if(id[tmp_id].type == ID_TYPE_USER) + { + if(udt_id_init) + tmp_instruction = "obj_usr_init"; + else + tmp_instruction = "obj_usr"; + vm_asm.push_back("mov " + n + " 0"); + tmp_instruction += ( id[tmp_id].num_args <= 0 ? "" : rc_intToString(id[tmp_id].num_args) ); + for(int tmp_arg_i = 0; tmp_arg_i < id[tmp_id].num_args; tmp_arg_i++) + args[tmp_arg_i] = n; + + vm_asm.push_back(tmp_instruction + " !" + rc_intToString(id[tmp_id].vec_pos) + " " + args[0] + " " + args[1] + " " + args[2]); + byref_type_flag = true; + break; + } + //------------------------------- + return false; } else @@ -1389,7 +1502,21 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ } } - if(type_delete_flag && (!has_child)) + if(type_redim_flag && (!has_child)) + { + //cout << "NO CHILD: " << id[tmp_id].name << " -- arg_count = " << arg_count << " -- arg[0] = " << args[0] << endl; + type_redim_dim_count = arg_count; + type_redim_dim[0] = args[0]; + type_redim_dim[1] = args[1]; + type_redim_dim[2] = args[2]; + + if(arg_count != id[tmp_id].num_args) + { + rc_setError("Expected " + rc_intToString(id[tmp_id].num_args) + " dimensions but found " + rc_intToString(arg_count)); + return false; + } + } + else if(type_delete_flag && (!has_child)) { //DO NOTHING //cout << "NO CHILD: " << id[tmp_id].name << endl; @@ -1397,7 +1524,7 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ else { //if(type_delete_flag) - // cout << "TESTING STUFF" << endl; + //cout << "TESTING STUFF" << endl; switch(arg_count) { @@ -1483,6 +1610,8 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ } else if(token[t].compare("")==0) { + num_id_children++; + type_delete_arg_whole = false; token[t] = ""; continue; } @@ -1495,17 +1624,24 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ //START HERE - if(type_delete_flag && (!has_child)) + if(type_redim_flag && (!has_child)) + { + type_redim_arg = "!" + rc_intToString(id[tmp_id].vec_pos); + type_redim_arg_type = id[tmp_id].type; + type_redim_arg_utype = "!" + rc_intToString(id[tmp_id].type_index); + } + else if(type_delete_flag && (!has_child)) { //cout << "DELETE_VAR = " << id[tmp_id].name << endl; type_delete_arg = "!" + rc_intToString(id[tmp_id].vec_pos); + type_delete_arg_type = id[tmp_id].type; } else switch(id[tmp_id].type) { case ID_TYPE_USER: case ID_TYPE_BYREF_USER: - cout << "test --> " << u << ", " << id[tmp_id].name << endl; + //cout << "test --> " << u << ", " << id[tmp_id].name << endl; vm_asm.push_back("obj_usr_get " + u); token[i] = u; resolveID_id_reg.push_back(token[i]); @@ -1517,18 +1653,46 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ case ID_TYPE_USER_NUM: vm_asm.push_back("obj_usr_get " + n); token[i] = n; + + //cout << "GET N: " << n << ", " << id[tmp_id].scope << " :: " << id[tmp_id].name << endl; + resolveID_id_reg.push_back(token[i]); + resolveID_id_type.push_back(id[tmp_id].type); + resolveID_id_ut_index.push_back(id[tmp_id].type_index); + resolveID_id_vec_pos.push_back(tmp_id); + inc_n(1); break; case ID_TYPE_USER_STR: vm_asm.push_back("obj_usr_get " + s); token[i] = s; + + resolveID_id_reg.push_back(token[i]); + resolveID_id_type.push_back(id[tmp_id].type); + resolveID_id_ut_index.push_back(id[tmp_id].type_index); + resolveID_id_vec_pos.push_back(tmp_id); + inc_s(1); break; default: break; } + if(byref_type_flag) + { + type_error_exception tx; + tx.error_log = "[0]Expected " + rc_intToString(id[tmp_id].num_args) + " dimension in " + id[tmp_id].name; + tx.tk_reg = token[i]; + tx.num_args = id[tmp_id].num_args; + tx.exception_used = false; + //cout << "!!!! type_no_arg_exception_raised = false;" << endl; + //cout << "store = " << id[tmp_id].name << " = " << tx.tk_reg << " arg_count = " << arg_count << ", expected = " << id[tmp_id].num_args << endl; + byref_type_exception.push_back(tx); + byref_type_flag = false; + type_no_arg_exception_raised = true; + } + + /* cout << "$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$" << endl; for(int t = 0; t < token.size(); t++) @@ -1544,6 +1708,7 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ } cout << "-----------------------------------------------" << endl; + */ //for(int t = 0; t < id.size(); t++) @@ -1845,155 +2010,7 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ int resolve_id2 = -1; int arg_index = -1; - if(StringToLower(id[expr_id].name).compare("arraydim")==0) - { - //cout << "HERES JOHNNY" << endl; - resolve_index = getResolveReg(args[0]); - if(resolve_index < 0) - { - rc_setError("Expected Identifier in ArrayDim argument: " + args[0]); - return false; - } - switch(resolveID_id_type[resolve_index]) - { - case ID_TYPE_ARR_NUM: - case ID_TYPE_BYREF_NUM: - case ID_TYPE_NUM: - expr_id = getIDInScope_ByIndex("NumberArrayDim"); - break; - case ID_TYPE_ARR_STR: - case ID_TYPE_BYREF_STR: - case ID_TYPE_STR: - expr_id = getIDInScope_ByIndex("StringArrayDim"); - break; - } - if(expr_id < 0) - { - rc_setError("ArrayDim Syntax Error"); - return false; - } - } - else if(StringToLower(id[expr_id].name).compare("arraysize")==0) - { - //cout << "HERES JOHNNY" << endl; - resolve_index = getResolveReg(args[0]); - if(resolve_index < 0) - { - rc_setError("Expected Identifier in ArraySize argument: " +args[0]); - return false; - } - switch(resolveID_id_type[resolve_index]) - { - case ID_TYPE_ARR_NUM: - case ID_TYPE_BYREF_NUM: - case ID_TYPE_NUM: - expr_id = getIDInScope_ByIndex("NumberArraySize"); - break; - case ID_TYPE_ARR_STR: - case ID_TYPE_BYREF_STR: - case ID_TYPE_STR: - expr_id = getIDInScope_ByIndex("StringArraySize"); - break; - } - if(expr_id < 0) - { - rc_setError("ArraySize Syntax Error"); - return false; - } - } - else if(StringToLower(id[expr_id].name).compare("arraycopy")==0) - { - //cout << "HERES JOHNNY" << endl; - if(num_args != 2) - { - rc_setError("ArrayCopy expects 2 arguments"); - return false; - } - - resolve_index = getResolveReg(args[0]); - resolve_index2 = getResolveReg(args[1]); - - if(resolve_index < 0 || resolve_index2 < 0) - { - rc_setError("Expected Identifier in ArrayCopy argument: " +args[0]); - return false; - } - - resolve_id = resolveID_id_vec_pos[resolve_index]; - resolve_id2 = resolveID_id_vec_pos[resolve_index2]; - - switch(resolveID_id_type[resolve_index]) - { - case ID_TYPE_ARR_NUM: - case ID_TYPE_BYREF_NUM: - case ID_TYPE_NUM: - expr_id = getIDInScope_ByIndex("NumberArrayCopy"); - if(resolveID_id_type[resolve_index2] != ID_TYPE_ARR_NUM && - resolveID_id_type[resolve_index2] != ID_TYPE_BYREF_NUM && - resolveID_id_type[resolve_index2] != ID_TYPE_NUM) - { - rc_setError("ArrayCopy argument types don't match"); - return false; - } - - if(id[resolve_id].num_args != id[resolve_id2].num_args) - { - rc_setError("ArrayCopy dimensions don't match"); - return false; - } - break; - case ID_TYPE_ARR_STR: - case ID_TYPE_BYREF_STR: - case ID_TYPE_STR: - expr_id = getIDInScope_ByIndex("StringArrayCopy"); - if(resolveID_id_type[resolve_index2] != ID_TYPE_ARR_STR && - resolveID_id_type[resolve_index2] != ID_TYPE_BYREF_STR && - resolveID_id_type[resolve_index2] != ID_TYPE_STR) - { - rc_setError("ArrayCopy argument types don't match"); - return false; - } - if(id[resolve_id].num_args != id[resolve_id2].num_args) - { - rc_setError("ArrayCopy dimensions don't match"); - return false; - } - break; - } - if(expr_id < 0) - { - rc_setError("ArrayCopy Syntax Error"); - return false; - } - } - else if(StringToLower(id[expr_id].name).compare("arrayfill")==0) - { - //cout << "HERES JOHNNY" << endl; - resolve_index = getResolveReg(args[0]); - if(resolve_index < 0) - { - rc_setError("Expected Identifier in ArrayFill argument: " + args[0]); - return false; - } - switch(resolveID_id_type[resolve_index]) - { - case ID_TYPE_ARR_NUM: - case ID_TYPE_BYREF_NUM: - case ID_TYPE_NUM: - expr_id = getIDInScope_ByIndex("NumberArrayFill"); - break; - case ID_TYPE_ARR_STR: - case ID_TYPE_BYREF_STR: - case ID_TYPE_STR: - expr_id = getIDInScope_ByIndex("StringArrayFill"); - break; - } - if(expr_id < 0) - { - rc_setError("ArrayFill Syntax Error"); - return false; - } - } + bool local_state_is_pushed = false; //this variable checks will be set to true if the following function call is recursive if(block_state.size() > 0) @@ -2087,11 +2104,33 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ rc_setError("Could not resolve Identifier in ByRef argument"); return false; } - } + } + else if( (args[n].substr(0,1).compare("n")==0 || args[n].substr(0,1).compare("s")==0) && resolve_index >= 0 ) + { + //string t_replace = args[n]; + } + + //check if byref_type_exception + bool type_exception_found = false; + int type_exception_index = -1; + //cout << "CHECK EXCEPTION: " << args[n] << endl; + for(int bt_i = 0; bt_i < byref_type_exception.size(); bt_i++) + { + if(args[n].compare(byref_type_exception[bt_i].tk_reg)==0) + { + //cout << "FOUND EXCEPTION: " << args[n] << endl; + byref_type_exception[bt_i].tk_reg = ""; + type_exception_found = true; + type_exception_index = bt_i; + } + //else + //cout << "NO MATCH (" << args[n] << ", " << byref_type_exception[bt_i].tk_reg << ")" << endl; + } + //---------------- - if(resolve_index < 0) + if(resolve_index < 0 && (!type_exception_found)) { - rc_setError("Expected identifier for ByRef argument"); + rc_setError("[4]Expected identifier for ByRef argument"); return false; } @@ -2101,12 +2140,181 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ { rc_setError("Identifier " + resolveID_id_reg[resolve_index] + " was not defined in this scope"); return false; - }*/ - + }*/ + + //Array Functions + string tmp_fn_name = StringToLower(id[expr_id].name); + if(tmp_fn_name.compare("arraydim")==0) + { + //cout << "found array dim" << endl; + int tmp_id_type = -1; + + if(args[n].substr(0,4).compare("")==0) + { + int tmp_id = getIDInScope_ByIndex(args[n].substr(4)); + + if(tmp_id >= 0) + tmp_id_type = id[tmp_id].type; + } + + + if(args[n].substr(0,1).compare("n")==0 || tmp_id_type == ID_TYPE_NUM || tmp_id_type == ID_TYPE_ARR_NUM || tmp_id_type == ID_TYPE_BYREF_NUM) + expr_id = getIDInScope_ByIndex("numberarraydim"); + else if(args[n].substr(0,1).compare("s")==0 || tmp_id_type == ID_TYPE_STR || tmp_id_type == ID_TYPE_ARR_STR || tmp_id_type == ID_TYPE_BYREF_STR) + expr_id = getIDInScope_ByIndex("stringarraydim"); + else if(args[n].substr(0,1).compare("u")==0 || tmp_id_type == ID_TYPE_USER || tmp_id_type == ID_TYPE_BYREF_USER) + expr_id = getIDInScope_ByIndex("typearraydim"); + else + { + rc_setError("Expected valid array identifier: " + args[n]); + expr_id = -1; + } + + if(expr_id < 0) + { + rc_setError("ArrayDim macro function does not exists for variable type"); + return false; + } + } + else if(tmp_fn_name.compare("arraysize")==0) + { + //cout << "found array size: " << args[0] << endl; + int tmp_id_type = -1; + + if(args[0].substr(0,4).compare("")==0) // arg[0] is what determines the macro function used + { + int tmp_id = getIDInScope_ByIndex(args[n].substr(4)); + + if(tmp_id >= 0) + tmp_id_type = id[tmp_id].type; + } + + + if(args[0].substr(0,1).compare("n")==0 || tmp_id_type == ID_TYPE_NUM || tmp_id_type == ID_TYPE_ARR_NUM || tmp_id_type == ID_TYPE_BYREF_NUM) + expr_id = getIDInScope_ByIndex("numberarraysize"); + else if(args[0].substr(0,1).compare("s")==0 || tmp_id_type == ID_TYPE_STR || tmp_id_type == ID_TYPE_ARR_STR || tmp_id_type == ID_TYPE_BYREF_STR) + expr_id = getIDInScope_ByIndex("stringarraysize"); + else if(args[0].substr(0,1).compare("u")==0 || tmp_id_type == ID_TYPE_USER || tmp_id_type == ID_TYPE_BYREF_USER) + expr_id = getIDInScope_ByIndex("typearraysize"); + else + { + rc_setError("Expected valid array identifier: " + args[0]); + expr_id = -1; + } + + if(expr_id < 0) + { + rc_setError("ArraySize macro function does not exists for variable type"); + return false; + } + } + else if(tmp_fn_name.compare("arraycopy")==0) + { + //cout << "found array copy: " << args[0] << endl; + int tmp_id_type = -1; + + if(args[0].substr(0,4).compare("")==0) // arg[0] is what determines the macro function used + { + int tmp_id = getIDInScope_ByIndex(args[n].substr(4)); + + if(tmp_id >= 0) + tmp_id_type = id[tmp_id].type; + } + + + if(args[0].substr(0,1).compare("n")==0 || tmp_id_type == ID_TYPE_NUM || tmp_id_type == ID_TYPE_ARR_NUM || tmp_id_type == ID_TYPE_BYREF_NUM) + expr_id = getIDInScope_ByIndex("numberarraycopy"); + else if(args[0].substr(0,1).compare("s")==0 || tmp_id_type == ID_TYPE_STR || tmp_id_type == ID_TYPE_ARR_STR || tmp_id_type == ID_TYPE_BYREF_STR) + expr_id = getIDInScope_ByIndex("stringarraycopy"); + else if(args[0].substr(0,1).compare("u")==0 || tmp_id_type == ID_TYPE_USER || tmp_id_type == ID_TYPE_BYREF_USER) + expr_id = getIDInScope_ByIndex("typearraycopy"); + else + { + rc_setError("Expected valid array identifier: " + args[0]); + expr_id = -1; + } + + if(expr_id < 0) + { + rc_setError("ArrayCopy macro function does not exists for variable type"); + return false; + } + } + else if(tmp_fn_name.compare("arrayfill")==0) + { + //cout << "found array fill: " << args[0] << endl; + int tmp_id_type = -1; + + if(args[0].substr(0,4).compare("")==0) // arg[0] is what determines the macro function used + { + int tmp_id = getIDInScope_ByIndex(args[n].substr(4)); + + if(tmp_id >= 0) + tmp_id_type = id[tmp_id].type; + } + + + if(args[0].substr(0,1).compare("n")==0 || tmp_id_type == ID_TYPE_NUM || tmp_id_type == ID_TYPE_ARR_NUM || tmp_id_type == ID_TYPE_BYREF_NUM) + expr_id = getIDInScope_ByIndex("numberarrayfill"); + else if(args[0].substr(0,1).compare("s")==0 || tmp_id_type == ID_TYPE_STR || tmp_id_type == ID_TYPE_ARR_STR || tmp_id_type == ID_TYPE_BYREF_STR) + expr_id = getIDInScope_ByIndex("stringarrayfill"); + else if(args[0].substr(0,1).compare("u")==0 || tmp_id_type == ID_TYPE_USER || tmp_id_type == ID_TYPE_BYREF_USER) + expr_id = getIDInScope_ByIndex("typearrayfill"); + else + { + rc_setError("Expected valid array identifier: " + args[0]); + expr_id = -1; + } + + //cout << "dbg data: " << expr_id << " arg = " << args[0] << " type = " << tmp_id_type << " name = " << id[expr_id].name << endl; + + if(expr_id < 0) + { + rc_setError("ArrayFill macro function does not exists for variable type"); + return false; + } + } + //-------------------------------- + + if(type_exception_found) + switch(id[expr_id].fn_arg_type[n]) + { + case ID_TYPE_BYREF_NUM: + if(args[n].substr(0,1).compare("n")!=0) + { + rc_setError("Expected number identifier for argument in " + id[expr_id].name); + return false; + } + byref_type_exception[type_exception_index].exception_used = true; + vm_asm.push_back("ptr !" + rc_intToString(id[expr_id].fn_arg_vec[n]) + " " + args[n]); + break; + case ID_TYPE_BYREF_STR: + if(args[n].substr(0,1).compare("s")!=0) + { + rc_setError("Expected string identifier for argument"); + return false; + } + byref_type_exception[type_exception_index].exception_used = true; + vm_asm.push_back("ptr$ !" + rc_intToString(id[expr_id].fn_arg_vec[n]) + " " + args[n]); + break; + case ID_TYPE_BYREF_USER: + //cout << "start up" << endl; + if(args[n].substr(0,1).compare("u")!=0) + { + rc_setError("Expected defined type identifier for argument: " + rc_intToString(id[expr_id].fn_arg_utype[n])); + return false; + } + //cout << "yolo: " << expr_id << " ~ " << id.size() << " -- " << id[expr_id].num_args << endl; + byref_type_exception[type_exception_index].exception_used = true; + vm_asm.push_back("uref_ptr !" + rc_intToString(id[expr_id].fn_arg_vec[n]) + " " + args[n]); + //cout << "testing" << endl; + break; + } + else switch(id[expr_id].fn_arg_type[n]) { case ID_TYPE_BYREF_NUM: - if(resolveID_id_type[resolve_index] != ID_TYPE_NUM && resolveID_id_type[resolve_index] != ID_TYPE_ARR_NUM && resolveID_id_type[resolve_index] != ID_TYPE_BYREF_NUM) + if(resolveID_id_type[resolve_index] != ID_TYPE_NUM && resolveID_id_type[resolve_index] != ID_TYPE_ARR_NUM && resolveID_id_type[resolve_index] != ID_TYPE_BYREF_NUM && resolveID_id_type[resolve_index] != ID_TYPE_USER_NUM && resolveID_id_type[resolve_index] != ID_TYPE_USER_NUM_ARRAY) { rc_setError("Expected number identifier for argument"); return false; @@ -2114,25 +2322,52 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ vm_asm.push_back("ptr !" + rc_intToString(id[expr_id].fn_arg_vec[n]) + " " + resolveID_id_reg[resolve_index]); break; case ID_TYPE_BYREF_STR: - if(resolveID_id_type[resolve_index] != ID_TYPE_STR && resolveID_id_type[resolve_index] != ID_TYPE_ARR_STR && resolveID_id_type[resolve_index] != ID_TYPE_BYREF_STR) + if(resolveID_id_type[resolve_index] != ID_TYPE_STR && resolveID_id_type[resolve_index] != ID_TYPE_ARR_STR && resolveID_id_type[resolve_index] != ID_TYPE_BYREF_STR && resolveID_id_type[resolve_index] != ID_TYPE_USER_STR && resolveID_id_type[resolve_index] != ID_TYPE_USER_STR_ARRAY) { rc_setError("Expected string identifier for argument"); return false; } vm_asm.push_back("ptr$ !" + rc_intToString(id[expr_id].fn_arg_vec[n]) + " " + resolveID_id_reg[resolve_index]); + break; + case ID_TYPE_BYREF_USER: + if(resolveID_id_type[resolve_index] != ID_TYPE_USER && resolveID_id_type[resolve_index] != ID_TYPE_BYREF_USER) + { + rc_setError("Expected defined type identifier for argument: " + rc_intToString(id[expr_id].fn_arg_utype[n])); + return false; + } + vm_asm.push_back("uref_ptr !" + rc_intToString(id[expr_id].fn_arg_vec[n]) + " " + resolveID_id_reg[resolve_index]); break; } } else if(id[expr_id].fn_arg_type[n] == ID_TYPE_BYREF_USER) { + //cout << "BYREF USER TYPE CHECK" << endl; + + //check if byref_type_exception + bool type_exception_found = false; + //cout << "CHECK EXCEPTION: " << args[n] << endl; + for(int bt_i = 0; bt_i < byref_type_exception.size(); bt_i++) + { + if(args[n].compare(byref_type_exception[bt_i].tk_reg)==0) + { + //cout << "FOUND EXCEPTION: " << args[n] << endl; + byref_type_exception[bt_i].tk_reg = ""; + type_exception_found = true; + } + //else + //cout << "NO MATCH (" << args[n] << ", " << byref_type_exception[bt_i].tk_reg << ")" << endl; + } + //---------------- + int ut_info = -1; int ut_index = -1; getRegInfo(args[n], ut_info, ut_index); - if(ut_index != id[expr_id].fn_arg_utype[n]) + if(ut_index != id[expr_id].fn_arg_utype[n] && (!byref_type_generic(utype[id[expr_id].fn_arg_utype[n]].name))) { rc_setError("Expected \"" + utype[id[expr_id].fn_arg_utype[n]].name + "\" identifier for ByRef argument"); return false; } + //cout << "BYREF USER MATCH ID: " << id[expr_id].fn_arg[n] << endl; vm_asm.push_back("uref_ptr !" + rc_intToString(id[expr_id].fn_arg_vec[n]) + " " + args[n]); } else if(id[expr_id].fn_arg_type[n] == ID_TYPE_NUM) @@ -2167,7 +2402,7 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ int ut_info = -1; int ut_index = -1; getRegInfo(args[n], ut_info, ut_index); - if(ut_index != id[expr_id].fn_arg_utype[n]) + if(ut_index != id[expr_id].fn_arg_utype[n] && (!byref_type_generic(utype[id[expr_id].fn_arg_utype[n]].name))) { rc_setError("Expected \"" + utype[id[expr_id].fn_arg_utype[n]].name + "\" identifier for argument"); return false; @@ -2177,7 +2412,18 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ vm_asm.push_back("mov_type !" + rc_intToString(id[expr_id].fn_arg_vec[n]) + " " + args[n]); } - } + } + + //check if any exceptions weren't used and return error if there are any left + for(int bt_i = 0; bt_i < byref_type_exception.size(); bt_i++) + { + if(byref_type_exception[bt_i].tk_reg.compare("")!=0) + { + rc_setError(byref_type_exception[bt_i].error_log); + return false; + } + } + //----------------------------------------------------------------------------- string token_replace = ""; @@ -2302,7 +2548,7 @@ bool pre_parse(int start_token = 0, int end_token = -1, int pp_flags, bool eval_ } else if(token[i].compare("")==0) { - cout << "USER DEFINED TYPE REGISTER ARGUMENT" << endl; + //cout << "USER DEFINED TYPE REGISTER ARGUMENT" << endl; n = "n" + rc_intToString(n_reg); s = "s" + rc_intToString(s_reg); @@ -3357,7 +3603,7 @@ bool check_rule() } else { - cout << "create variable (" << id_name << ") of type " << token[3].substr(4) << endl; + //cout << "create variable (" << id_name << ") of type " << token[3].substr(4) << endl; if(!create_variable(id_name, id_type, token[3].substr(4))) return false; } @@ -3467,7 +3713,8 @@ bool check_rule() } - id_type = id[id_index].type; + id_type = id[id_index].type; + type_redim_arg_type = 0; //cout << "db1\n"; @@ -3531,13 +3778,25 @@ bool check_rule() multi_arg[2] = ""; multi_arg_count = 0; int end_token = token_index+1; - int sq_scope = 1; + int sq_scope = 1; + bool has_child = false; for(; end_token < token.size(); end_token++) { if(token[end_token].compare("")==0) sq_scope--; else if(token[end_token].compare("")==0) - sq_scope++; + sq_scope++; + + if( (end_token+1) < token.size() ) + { + if(token[end_token+1].compare("")==0 || token[end_token].compare("")==0) + { + has_child = true; + continue; + } + else if(token[end_token+1].compare("")==0) + continue; + } if(sq_scope==0) break; @@ -3547,7 +3806,21 @@ bool check_rule() { rc_setError("Expected ] in array definition"); return false; - } + } + + //cout << "DEBUG TOKENS: " << endl; + //cout << "----------------------" << endl; + //for(int tk = token_index; tk < end_token; tk++) cout << token[tk] << endl; + //cout << "-------------------------------------" << endl; + + if(has_child) + { + token_index = 1; + type_redim_flag = true; + type_redim_arg_type = 0; + } + else + type_redim_flag = false; //cout << "debug 1: " << id_index << endl; @@ -3559,7 +3832,21 @@ bool check_rule() //cout << "debug 2: " << id_index << endl; - if(multi_arg_count <= 0 || multi_arg_count > 3) + if(type_redim_flag) + { + if(type_redim_dim_count <= 0) + { + rc_setError("Expected 1 to 3 Arguments for array re-dimension, Found " + rc_intToString(multi_arg_count)); + return false; + } + dimensions = type_redim_dim_count; + multi_arg[0] = type_redim_dim[0]; + multi_arg[1] = type_redim_dim[1]; + multi_arg[2] = type_redim_dim[2]; + + //cout << "type arg = " << type_redim_arg << " type = " << type_redim_arg_type << " utype = " << type_redim_arg_utype << endl; + } + else if(multi_arg_count <= 0 || multi_arg_count > 3) { rc_setError("Expected 1 to 3 Arguments for array re-dimension, Found " + rc_intToString(multi_arg_count)); return false; @@ -3595,7 +3882,18 @@ bool check_rule() //if the next token is not an id then the syntax is incorrect and false is returned rc_setError("Expected Identifier name"); return false; - } + } + + if(!type_redim_flag) //if type_redim_flag is set, then this error will get raised in the pre_parse step + { + if(dimensions != id[id_index].num_args) // no longer allowing the user to change dimensions since it can lead to unnecessary confusion + { + rc_setError("Expected " + rc_intToString(id[id_index].num_args) + " dimensions but found " + rc_intToString(dimensions)); + return false; + } + } + + type_redim_flag = false; if(dimensions > 0) { @@ -3612,14 +3910,89 @@ bool check_rule() //cout << "debug 6: " << id_index << endl; - if(id[id_index].num_args != dimensions) - { - id[id_index].num_args = dimensions; - } + //if(id[id_index].num_args != dimensions) + //{ + // id[id_index].num_args = dimensions; + //} //cout << "debug 7: " << id_index << " -- " << id[id_index].type << endl; - if(id[id_index].type == ID_TYPE_NUM || id[id_index].type == ID_TYPE_ARR_NUM) + if(type_redim_arg_type == ID_TYPE_USER) + { + switch(dimensions) + { + case 1: + vm_asm.push_back("redim_type1 " + type_redim_arg + " " + type_redim_arg_utype + " " + multi_arg[0]); + break; + case 2: + vm_asm.push_back("redim_type2 " + type_redim_arg + " " + type_redim_arg_utype + " " + multi_arg[0] + " " + multi_arg[1]); + break; + case 3: + vm_asm.push_back("redim_type3 " + type_redim_arg + " " + type_redim_arg_utype + " " + multi_arg[0] + " " + multi_arg[1] + " " + multi_arg[2]); + break; + default: + rc_setError("Invalid number of dimensions in REDIM"); + return false; + } + } + else if(type_redim_arg_type == ID_TYPE_USER_NUM || type_redim_arg_type == ID_TYPE_USER_NUM_ARRAY) + { + switch(dimensions) + { + case 1: + vm_asm.push_back("redim_type_n1 " + type_redim_arg + " " + multi_arg[0]); + break; + case 2: + vm_asm.push_back("redim_type_n2 " + type_redim_arg + " " + multi_arg[0] + " " + multi_arg[1]); + break; + case 3: + vm_asm.push_back("redim_type_n3 " + type_redim_arg + " " + multi_arg[0] + " " + multi_arg[1] + " " + multi_arg[2]); + break; + default: + rc_setError("Invalid number of dimensions in REDIM"); + return false; + } + } + else if(type_redim_arg_type == ID_TYPE_USER_STR || type_redim_arg_type == ID_TYPE_USER_STR_ARRAY) + { + switch(dimensions) + { + case 1: + vm_asm.push_back("redim_type_s1 " + type_redim_arg + " " + multi_arg[0]); + break; + case 2: + vm_asm.push_back("redim_type_s2 " + type_redim_arg + " " + multi_arg[0] + " " + multi_arg[1]); + break; + case 3: + vm_asm.push_back("redim_type_s3 " + type_redim_arg + " " + multi_arg[0] + " " + multi_arg[1] + " " + multi_arg[2]); + break; + default: + rc_setError("Invalid number of dimensions in REDIM"); + return false; + } + } + else if(id[id_index].type == ID_TYPE_USER) + { + vm_asm.push_back("redim_top"); //This will set the top level flag for redim_type + + //cout << "debug 8" << endl; + switch(dimensions) + { + case 1: + vm_asm.push_back("redim_type1 !" + rc_intToString(id[id_index].vec_pos) + " !" + rc_intToString(id[id_index].type_index) + " " + multi_arg[0]); + break; + case 2: + vm_asm.push_back("redim_type2 !" + rc_intToString(id[id_index].vec_pos) + " !" + rc_intToString(id[id_index].type_index) + " " + multi_arg[0] + " " + multi_arg[1]); + break; + case 3: + vm_asm.push_back("redim_type3 !" + rc_intToString(id[id_index].vec_pos) + " !" + rc_intToString(id[id_index].type_index) + " " + multi_arg[0] + " " + multi_arg[1] + " " + multi_arg[2]); + break; + default: + rc_setError("Invalid number of dimensions in REDIM"); + return false; + } + } + else if(id[id_index].type == ID_TYPE_NUM || id[id_index].type == ID_TYPE_ARR_NUM) { //cout << "debug 8" << endl; switch(dimensions) @@ -3658,7 +4031,7 @@ bool check_rule() } else { - rc_setError("Invalid type for REDIM"); + rc_setError("Invalid type for REDIM: " + rc_intToString(id[id_index].type)); return false; } //cout << "balls" << endl; @@ -4695,7 +5068,11 @@ bool check_rule() string counter_var = ""; string start_value = ""; string end_value = ""; - string step_value = ""; + string step_value = ""; + + bool d_type_counter = false; + int d_type_equal_index = 0; + if(rc_substr(token[1], 0, 4).compare("")==0) { counter_var = token[1].substr(4); @@ -4720,6 +5097,55 @@ bool check_rule() rc_setError("Could not create identifier " + counter_var); return false; } + } + else if(id[counter_id].type == ID_TYPE_USER) + { + //cout << "FOR debug: " << token[1].substr(4) << endl; + + int end_token = 0; + int scope = 0; + bool expr_start = false; + for(end_token = 0; end_token < token.size(); end_token++) + { + if(token[end_token].compare("")==0 || token[end_token].compare("")==0) + scope++; + else if(token[end_token].compare("")==0 || token[end_token].compare("")==0) + scope--; + + if(scope == 0 && token[end_token].compare("")==0) + { + d_type_equal_index = end_token; + end_token--; + expr_start = true; + break; + } + } + + if(!expr_start) + { + rc_setError("[0]Could not evaluate defined type member in FOR identifier"); + return false; + } + + if(!eval_expression(1, end_token)) + { + rc_setError("[1]Could not evaluate defined type member in FOR identifier"); + return false; + } + + if(multi_arg_count != 1) + { + rc_setError("[2]Could not evaluate defined type member in FOR identifier"); + return false; + } + + if(multi_arg[0].substr(0,1).compare("n") != 0) + { + rc_setError("[3]Could not evaluate defined type member in FOR identifier"); + return false; + } + + d_type_counter = true; } else if(id[counter_id].type != ID_TYPE_NUM && id[counter_id].type != ID_TYPE_BYREF_NUM && id[counter_id].type != ID_TYPE_ARR_NUM) { @@ -4730,9 +5156,27 @@ bool check_rule() { rc_setError("Expected \"[\" in array"); return false; + } + + if(d_type_counter) + { + //DO STUFF HERE + create_variable("!FOR_TYPE_COUNTER[" + rc_intToString(current_for_index) + "]", ID_TYPE_NUM,""); + counter_id = getIDInScope_ByIndex("!FOR_TYPE_COUNTER[" + rc_intToString(current_for_index) + "]"); + if(counter_id < 0) + { + rc_setError("RCBasic Compiler ERROR: Type member in FOR caused internal error"); + return false; + } + + vm_asm.push_back("ptr !" + rc_intToString(id[counter_id].vec_pos) + " " + multi_arg[0]); + for_counter.push(counter_id); + } + else + { + counter_id = getIDInScope_ByIndex(counter_var); + for_counter.push(counter_id); } - counter_id = getIDInScope_ByIndex(counter_var); - for_counter.push(counter_id); } else @@ -4744,6 +5188,9 @@ bool check_rule() int for_equal_op_offset = 2; int for_counter_args = 0; + if(d_type_counter) + for_equal_op_offset = d_type_equal_index; + if(id[counter_id].type == ID_TYPE_ARR_NUM || id[counter_id].type == ID_TYPE_BYREF_NUM) { if(token[2].compare("") == 0) @@ -5255,8 +5702,13 @@ bool check_rule() } if(expr_result.substr(0,1).compare("n")==0) vm_asm.push_back("print " + expr_result); - else - vm_asm.push_back("print$ " + expr_result); + else if(expr_result.substr(0,1).compare("s")==0) + vm_asm.push_back("print$ " + expr_result); + else + { + rc_setError("Invalid expression in PRINT"); + return false; + } start_token = i; } } @@ -5269,8 +5721,13 @@ bool check_rule() } if(expr_result.substr(0,1).compare("n")==0) vm_asm.push_back("print " + expr_result); - else - vm_asm.push_back("print$ " + expr_result); + else if(expr_result.substr(0,1).compare("s")==0) + vm_asm.push_back("print$ " + expr_result); + else + { + rc_setError("Invalid expression in PRINT"); + return false; + } } if(last_token.compare("")!=0) vm_asm.push_back("println"); @@ -5319,6 +5776,7 @@ bool check_rule() type_delete_flag = true; type_delete_arg = ""; + type_delete_arg_whole = true; if(!eval_expression()) { @@ -5330,9 +5788,38 @@ bool check_rule() rc_setError("Could not determine Identifier Type in DELETE: " + type_delete_arg); return false; } - vm_asm.push_back("delete_t " + type_delete_arg); + + string d_type = "!"; + string top_level_flag = "!0"; + + if(!type_delete_arg_whole) + top_level_flag = "!1"; + + if(type_delete_arg_type == ID_TYPE_USER_STR || type_delete_arg_type == ID_TYPE_USER_STR_ARRAY) + { + cout << "DELETE STRING" << endl; + d_type += "1"; + } + else if(type_delete_arg_type == ID_TYPE_USER_NUM || type_delete_arg_type == ID_TYPE_USER_NUM_ARRAY) + { + cout << "DELETE NUMBER" << endl; + d_type += "0"; + } + else if(type_delete_arg_type == ID_TYPE_USER) + { + cout << "DELETE USER TYPE" << endl; + d_type += "2"; + } + else + { + rc_setError("Cannot delete identifier of this type or within this scope"); + return false; + } + + vm_asm.push_back("delete_t " + type_delete_arg + " " + top_level_flag + " " + d_type); type_delete_flag = false; + type_delete_arg_whole = true; } else { @@ -5819,7 +6306,34 @@ bool check_rule() bool check_rule_embedded() { if(token.size() > 0) - { + { + if(current_block_state == BLOCK_STATE_TYPE) + { + if(token[0].compare("")!=0 && token[0].compare("")!=0) + { + rc_setError("Expected DIM in TYPE definition"); + return false; + } + } + else if(current_block_state != BLOCK_STATE_MAIN) + { + if(token[0].compare("")==0) + { + rc_setError("TYPE cannot be declared in the current scope"); + return false; + } + else if(token[0].compare("")==0) + { + rc_setError("FUNCTION cannot be declared in the current scope"); + return false; + } + else if(token[0].compare("")==0) + { + rc_setError("SUB ROUTINE cannot be declared in the current scope"); + return false; + } + } + if(token[0].compare("")==0) { if(token.size()<2) @@ -5840,98 +6354,158 @@ bool check_rule_embedded() return false; } - int fn_type = ID_TYPE_FN_NUM; - if(fn_name.substr(fn_name.length()-1,1).compare("$")==0) - fn_type = ID_TYPE_FN_STR; - - embed_function(fn_name, fn_type); - current_block_state = BLOCK_STATE_FUNCTION; - block_state.push(current_block_state); - - string fn_arg = ""; - int fn_arg_type = ID_TYPE_NUM; - bool fn_byref = false; - - int end_token = 0; - - for(int i = 3; i < token.size(); i++) - { - if(token[i].compare("")==0) - { - fn_byref = true; - } - else if(rc_substr(token[i], 0, 4).compare("")==0) - { - fn_arg += token[i]; - if(fn_arg.substr(fn_arg.length()-1,1).compare("$")==0) - fn_arg_type = ID_TYPE_STR; - else - fn_arg_type = ID_TYPE_NUM; - } - else if(token[i].compare("")==0) - { - fn_arg = rc_substr(fn_arg, 4, fn_arg.length()-1); - if(!isValidIDName(fn_arg)) - { - rc_setError("Function argument is not a valid identifier name"); - return false; - } - if(idExistsInScope(fn_arg)) - { - rc_setError("Function argument identifier already exists in current scope"); - return false; - } - - if(fn_byref) - { - if(fn_arg_type == ID_TYPE_NUM) - fn_arg_type = ID_TYPE_BYREF_NUM; - else - fn_arg_type = ID_TYPE_BYREF_STR; - } - - add_embedded_arg(fn_arg, fn_arg_type); - fn_arg = ""; - fn_byref = false; - } - else if(token[i].compare("")==0) - { - if(fn_arg.compare("")==0) - { - end_token = i+1; - break; - } - fn_arg = rc_substr(fn_arg, 4, fn_arg.length()-1); - if(!isValidIDName(fn_arg)) - { - rc_setError("Function argument is not a valid identifier name"); - return false; - } - if(idExistsInScope(fn_arg)) - { - rc_setError("Function argument identifier already exists in current scope: " + fn_arg + " -> " + current_scope + " ? "); - return false; - } - - if(fn_byref) - { - if(fn_arg_type == ID_TYPE_NUM) - fn_arg_type = ID_TYPE_BYREF_NUM; - else - fn_arg_type = ID_TYPE_BYREF_STR; - } - - add_embedded_arg(fn_arg, fn_arg_type); - fn_arg = ""; - fn_byref = false; - end_token = i+1; - break; - } - else - { - rc_setError("Argument to function must be a valid identifier: " + token[i]); - return false; - } + int fn_type = ID_TYPE_FN_NUM; + if(fn_name.substr(fn_name.length()-1,1).compare("$")==0) + fn_type = ID_TYPE_FN_STR; + + string fn_type_name = ""; + if(token.size()>2) + { + if(token[token.size()-2].compare("")==0) + { + fn_type = ID_TYPE_FN_USER; + if(token[token.size()-1].substr(0,4).compare("")==0) + fn_type_name = token[token.size()-1].substr(4); + else + { + rc_setError("Invalid return type in FUNCTION definition"); + return false; + } + token.pop_back(); + token.pop_back(); + } + } + + if(!embed_function(fn_name, fn_type, getUType(fn_type_name))) + { + rc_setError("Could not create FUNCTION \"" + fn_name + "\" of type \"" + fn_type_name + "\""); + return false; + } + current_block_state = BLOCK_STATE_FUNCTION; + block_state.push(current_block_state); + + string fn_arg = ""; + int fn_arg_type = ID_TYPE_NUM; + string fn_arg_user_type = ""; + bool fn_byref = false; + + int end_token = 0; + + for(int i = 3; i < token.size(); i++) + { + if(token[i].compare("")==0) + { + fn_byref = true; + } + else if(rc_substr(token[i], 0, 4).compare("")==0) + { + fn_arg += token[i]; + if(fn_arg.substr(fn_arg.length()-1,1).compare("$")==0) + fn_arg_type = ID_TYPE_STR; + else + fn_arg_type = ID_TYPE_NUM; + } + else if(token[i].compare("")==0) + { + i++; + fn_arg_type = ID_TYPE_USER; + fn_arg_user_type = ""; + int arg_type_index = -1; + if(i < token.size()) + if(token[i].substr(0,4).compare("")==0) + fn_arg_user_type = token[i].substr(4); + + if(fn_arg_user_type.compare("")==0) + { + rc_setError("Invalid Type in FUNCTION Definition"); + return false; + } + + } + else if(token[i].compare("")==0) + { + //cout << "ADD ARG: " << fn_arg << endl; + fn_arg = rc_substr(fn_arg, 4, fn_arg.length()-1); + if(!isValidIDName(fn_arg)) + { + rc_setError("FUNCTION argument is not a valid identifier name"); + return false; + } + if(idExistsInScope(fn_arg)) + { + rc_setError("FUNCTION argument identifier already exists in current scope"); + return false; + } + + //cout << "CHECK 1" << endl; + + if(fn_byref) + { + if(fn_arg_type == ID_TYPE_NUM) + fn_arg_type = ID_TYPE_BYREF_NUM; + else if(fn_arg_type == ID_TYPE_STR) + fn_arg_type = ID_TYPE_BYREF_STR; + else + fn_arg_type = ID_TYPE_BYREF_USER; + } + + if(!add_embedded_arg(fn_arg, fn_arg_type, getUType(fn_arg_user_type))) + { + return false; + } + fn_arg = ""; + fn_byref = false; + + //cout << "DONE" << endl; + } + else if(token[i].compare("")==0) + { + if((i+1) < token.size()) + { + rc_setError("Expected End of FUNCTION Declaration"); + return false; + } + if(fn_arg.compare("")==0) + { + end_token = i+1; + break; + } + fn_arg = rc_substr(fn_arg, 4, fn_arg.length()-1); + if(!isValidIDName(fn_arg)) + { + rc_setError("FUNCTION argument is not a valid identifier name"); + return false; + } + if(idExistsInScope(fn_arg)) + { + rc_setError("FUNCTION argument identifier already exists in current scope"); + return false; + } + + if(fn_byref) + { + if(fn_arg_type == ID_TYPE_NUM) + fn_arg_type = ID_TYPE_BYREF_NUM; + else if(fn_arg_type == ID_TYPE_STR) + fn_arg_type = ID_TYPE_BYREF_STR; + else + fn_arg_type = ID_TYPE_BYREF_USER; + } + + if(!add_embedded_arg(fn_arg, fn_arg_type, getUType(fn_arg_user_type))) + { + return false; + } + + fn_arg = ""; + fn_byref = false; + end_token = i+1; + break; + } + else + { + rc_setError("Argument to FUNCTION must be a valid identifier: " + token[i]); + } } current_block_state = BLOCK_STATE_MAIN; @@ -5967,96 +6541,140 @@ bool check_rule_embedded() return false; } - int fn_type = ID_TYPE_SUB; - - embed_function(fn_name, fn_type); - current_block_state = BLOCK_STATE_SUB; - block_state.push(current_block_state); - - string fn_arg = ""; - int fn_arg_type = ID_TYPE_NUM; - bool fn_byref = false; - - int end_token = 0; - - for(int i = 3; i < token.size(); i++) - { - if(token[i].compare("")==0) - { - fn_byref = true; - } - else if(rc_substr(token[i], 0, 4).compare("")==0) - { - fn_arg += token[i]; - if(fn_arg.substr(fn_arg.length()-1,1).compare("$")==0) - fn_arg_type = ID_TYPE_STR; - else - fn_arg_type = ID_TYPE_NUM; - } - else if(token[i].compare("")==0) - { - fn_arg = rc_substr(fn_arg, 4, fn_arg.length()-1); - if(!isValidIDName(fn_arg)) - { - rc_setError("Function argument is not a valid identifier name"); - return false; - } - if(idExistsInScope(fn_arg)) - { - rc_setError("Function argument identifier already exists in current scope"); - return false; - } - - if(fn_byref) - { - if(fn_arg_type == ID_TYPE_NUM) - fn_arg_type = ID_TYPE_BYREF_NUM; - else - fn_arg_type = ID_TYPE_BYREF_STR; - } - - add_embedded_arg(fn_arg, fn_arg_type); - fn_arg = ""; - fn_byref = false; - } - else if(token[i].compare("")==0) - { - if(fn_arg.compare("")==0) - { - end_token = i+1; - break; - } - fn_arg = rc_substr(fn_arg, 4, fn_arg.length()-1); - if(!isValidIDName(fn_arg)) - { - rc_setError("Function argument is not a valid identifier name"); - return false; - } - if(idExistsInScope(fn_arg)) - { - rc_setError("Function argument identifier already exists in current scope"); - return false; - } - - if(fn_byref) - { - if(fn_arg_type == ID_TYPE_NUM) - fn_arg_type = ID_TYPE_BYREF_NUM; - else - fn_arg_type = ID_TYPE_BYREF_STR; - } - - add_embedded_arg(fn_arg, fn_arg_type); - fn_arg = ""; - fn_byref = false; - end_token = i+1; - break; - } - else - { - rc_setError("Argument to function must be a valid identifier: " + token[i]); - return false; - } + int fn_type = ID_TYPE_SUB; + + string fn_type_name = ""; + + if(!embed_function(fn_name, fn_type, getUType(fn_type_name))) + { + rc_setError("Could not create SUB ROUTINE \"" + fn_name + "\""); + return false; + } + current_block_state = BLOCK_STATE_SUB; + block_state.push(current_block_state); + + string fn_arg = ""; + int fn_arg_type = ID_TYPE_NUM; + string fn_arg_user_type = ""; + bool fn_byref = false; + + int end_token = 0; + + for(int i = 3; i < token.size(); i++) + { + if(token[i].compare("")==0) + { + fn_byref = true; + } + else if(rc_substr(token[i], 0, 4).compare("")==0) + { + fn_arg += token[i]; + if(fn_arg.substr(fn_arg.length()-1,1).compare("$")==0) + fn_arg_type = ID_TYPE_STR; + else + fn_arg_type = ID_TYPE_NUM; + } + else if(token[i].compare("")==0) + { + i++; + fn_arg_type = ID_TYPE_USER; + fn_arg_user_type = ""; + int arg_type_index = -1; + if(i < token.size()) + if(token[i].substr(0,4).compare("")==0) + fn_arg_user_type = token[i].substr(4); + + if(fn_arg_user_type.compare("")==0) + { + rc_setError("Invalid Type in SUB ROUTINE Definition"); + return false; + } + + } + else if(token[i].compare("")==0) + { + //cout << "ADD ARG: " << fn_arg << endl; + fn_arg = rc_substr(fn_arg, 4, fn_arg.length()-1); + if(!isValidIDName(fn_arg)) + { + rc_setError("SUB ROUTINE argument is not a valid identifier name"); + return false; + } + if(idExistsInScope(fn_arg)) + { + rc_setError("SUB ROUTINE argument identifier already exists in current scope"); + return false; + } + + //cout << "CHECK 1" << endl; + + if(fn_byref) + { + if(fn_arg_type == ID_TYPE_NUM) + fn_arg_type = ID_TYPE_BYREF_NUM; + else if(fn_arg_type == ID_TYPE_STR) + fn_arg_type = ID_TYPE_BYREF_STR; + else + fn_arg_type = ID_TYPE_BYREF_USER; + } + + if(!add_embedded_arg(fn_arg, fn_arg_type, getUType(fn_arg_user_type))) + { + return false; + } + fn_arg = ""; + fn_byref = false; + + //cout << "DONE" << endl; + } + else if(token[i].compare("")==0) + { + if((i+1) < token.size()) + { + rc_setError("Expected End of SUB ROUTINE Declaration"); + return false; + } + if(fn_arg.compare("")==0) + { + end_token = i+1; + break; + } + fn_arg = rc_substr(fn_arg, 4, fn_arg.length()-1); + if(!isValidIDName(fn_arg)) + { + rc_setError("SUB ROUTINE argument is not a valid identifier name"); + return false; + } + if(idExistsInScope(fn_arg)) + { + rc_setError("SUB ROUTINE argument identifier already exists in current scope"); + return false; + } + + if(fn_byref) + { + if(fn_arg_type == ID_TYPE_NUM) + fn_arg_type = ID_TYPE_BYREF_NUM; + else if(fn_arg_type == ID_TYPE_STR) + fn_arg_type = ID_TYPE_BYREF_STR; + else + fn_arg_type = ID_TYPE_BYREF_USER; + } + + if(!add_embedded_arg(fn_arg, fn_arg_type, getUType(fn_arg_user_type))) + { + return false; + } + + fn_arg = ""; + fn_byref = false; + end_token = i+1; + break; + } + else + { + rc_setError("Argument to SUB ROUTINE must be a valid identifier: " + token[i]); + } } current_block_state = BLOCK_STATE_MAIN; @@ -6071,6 +6689,276 @@ bool check_rule_embedded() return false; } + } + else if(token[0].compare("")==0) + { + if(current_scope.compare("main")!=0) + { + rc_setError("TYPE cannot be defined in this scope"); + return false; + } + if(token.size() != 2) + { + rc_setError("Expected TYPE Identifier in TYPE statement"); + return false; + } + if(token[1].substr(0,4).compare("")!=0) + { + rc_setError("Expected TYPE Identifier in TYPE statement"); + return false; + } + int id_index = getIDInScope_ByIndex(token[1].substr(4)); + if(id_index >= 0) + { + rc_setError("TYPE Identifier exists in current scope"); + return false; + } + create_type(token[1].substr(4)); + current_block_state = BLOCK_STATE_TYPE; + block_state.push(current_block_state); + + string start_label = current_scope + ".#TYPE:" + token[1].substr(4); + + current_scope = start_label; + } + else if(token[0].compare("")==0) + { + if(current_block_state != BLOCK_STATE_TYPE) + { + rc_setError("DIM can only be used for type members when embedding"); + return false; + } + //cout << "DIM RULE FOUND" << endl; //'DIM' [ID]; '[' #; #; # ']' ; 'AS' [TYPE]; '=' (VALUE) + + string id_name = ""; + int id_type = ID_TYPE_NUM; + string id_type_name = ""; + int dimensions = 0; + + //check if the next token is a identifier + if(token.size() > 1) + { + if(token[1].substr(0,4).compare("")==0) + { + //if the identifier is not a valid name then return false + id_name = token[1].substr(4); + id_type = ID_TYPE_NUM; + id_type_name = ""; + dimensions = 0; + + if(!isValidIDName(id_name)) + { + rc_setError("Invalid Identifier name"); + return false; + } + + //check if the data type is a string + if(id_name.substr(id_name.length()-1).compare("$")==0) + id_type = ID_TYPE_STR; + + //if the identifier already exists and current_block state is not type then return false + if(idExistsInScope(id_name)) + { + rc_setError("Identifier already defined in current scope"); + return false; + } + + //cout << "db1\n"; + + //if there are only two tokens then return here because there is nothing left to check + if(token.size()==2) + { + if(current_block_state == BLOCK_STATE_TYPE) + { + //cout << "adding type member" << endl; + if(!add_type_member_embedded(id_name, id_type, "", 0, 0, 0, 0)) + { + //cout << rc_getError() << endl; + return false; + } + } + + //cout << "return true here" << endl; + return true; + } + + //cout << "db2\n"; + + //current token + int token_index = 2; + + int t_dim_arg[3]; + t_dim_arg[0] = 0; + t_dim_arg[1] = 0; + t_dim_arg[2] = 0; + + //check for the next rule; must be [], AS, or = + //cout << "token = " << token[token_index] << endl; + if(token[token_index].compare("")==0 && current_block_state == BLOCK_STATE_TYPE) + { + //token_index++; + int end_token = token_index+1; + int sq_scope = 1; + multi_arg_count = 0; + int arg_index = 0; + + t_dim_arg[0] = 0; + t_dim_arg[1] = 0; + t_dim_arg[2] = 0; + for(; end_token < token.size(); end_token++) + { + if(token[end_token].compare("")==0) + sq_scope++; + else if(token[end_token].compare("")==0) + sq_scope--; + else if(token[end_token].substr(0,5).compare("")==0) + { + if(arg_index > 2) + { + rc_setError("Too many dimensions in type member declaration for embedded"); + return false; + } + multi_arg[arg_index] = token[end_token].substr(5); + t_dim_arg[arg_index] = rc_stringToInt(multi_arg[arg_index]); + multi_arg_count = arg_index+1; + } + else if(token[end_token].compare("")==0) + arg_index++; + else + { + rc_setError("Expected number constant in type member declaration for embedded: " + token[end_token]); + return false; + } + + if(sq_scope==0) + break; + } + if(sq_scope != 0) + { + rc_setError("Expected ] in array definition"); + return false; + } + + dimensions = multi_arg_count; + + + token_index = end_token+1; + + //cout << "DBG token = " << token[token_index] << std::endl; + + if(token.size() > token_index) + { + if(token[token_index].compare("")==0) + { + token_index++; + if(token[token_index].substr(0,4).compare("")!=0) + { + rc_setError("Invalid type identifier name in DIM"); + return false; + } + + id_type = ID_TYPE_USER; + id_type_name = token[token_index].substr(4); + //cout << "Add member (" << id_name << ") of type (" << id_type_name << ") with " << dimensions << " dimensions [" << constant_arg[0] << "," << constant_arg[1] << "," << constant_arg[2] << "]" << endl; + //if(!add_type_member(id_name, id_type, id_type_name, dimensions, constant_arg[0], constant_arg[1], constant_arg[2])) + if(!add_type_member_embedded(id_name, id_type, id_type_name, dimensions, t_dim_arg[0], t_dim_arg[1], t_dim_arg[2])) + return false; + } + else + { + rc_setError("Invalid member array declaration in DIM"); + return false; + } + } + else + { + //cout << "Add member (" << id_name << ") of type (num/str) with " << dimensions << " dimensions [" << constant_arg[0] << "," << constant_arg[1] << "," << constant_arg[2] << "]" << endl; + //if(!add_type_member(id_name, id_type, "", dimensions, constant_arg[0], constant_arg[1], constant_arg[2])) + if(!add_type_member_embedded(id_name, id_type, "", dimensions, t_dim_arg[0], t_dim_arg[1], t_dim_arg[2])) + return false; + } + + return true; + + } + else if(token[token_index].compare("")==0) + { + token_index++; + + if(token_index >= token.size()) + { + rc_setError("Invalid member declaration"); + return false; + } + + if(token[token_index].substr(0,4).compare("")!=0) + { + rc_setError("Invalid type identifier name in DIM"); + return false; + } + + id_type = ID_TYPE_USER; + id_type_name = token[token_index].substr(4); + //cout << "Add member (" << id_name << ") of type (" << id_type_name << ") with " << dimensions << " dimensions [" << constant_arg[0] << "," << constant_arg[1] << "," << constant_arg[2] << "]" << endl; + //if(!add_type_member(id_name, id_type, id_type_name, dimensions, constant_arg[0], constant_arg[1], constant_arg[2])) + if(!add_type_member_embedded(id_name, id_type, id_type_name, 0, 0, 0, 0)) + return false; + + return true; + } + + + if(token.size()>token_index) + { + rc_setError("Invalid variable definition: " + token[token_index] + ", " + rc_intToString(current_block_state) + " <--> " + rc_intToString(BLOCK_STATE_TYPE)); + return false; + } + + } + else + { + //if the next token is not an id then the syntax is incorrect and false is returned + rc_setError("Expected Identifier name"); + return false; + } + + } + else + { + //if the size of the token vector is not greater than one then the syntax for the line is incomplete so I return false + rc_setError("Expected Identifier name"); + return false; + } + } + else if(token[0].compare("")==0) + { + if(token.size()==1) + { + rc_setError("END can only be used to end TYPE when embedding"); + return false; + } + if(token[1].compare("")==0) + { + if(token.size()>2) + { + rc_setError("Expected End of Line in END TYPE"); + return false; + } + if(current_block_state != BLOCK_STATE_TYPE) + { + rc_setError("Cannot exit TYPE definition from this scope"); + return false; + } + + block_state.pop(); + current_block_state = BLOCK_STATE_MAIN; + current_scope = "main"; + } + else + { + rc_setError("END can only be used to end TYPE when embedding"); + return false; + } } } return true; diff --git a/rcbasic_build/rc_builtin.h b/rcbasic_build/rc_builtin.h index f7dc2ef..1c6b5b1 100644 --- a/rcbasic_build/rc_builtin.h +++ b/rcbasic_build/rc_builtin.h @@ -2,1427 +2,1447 @@ #define RC_BUILTIN_H_INCLUDED #include "identifier.h" -void init_embedded() -{ -embed_function("FPrint", ID_TYPE_SUB); -add_embedded_arg("txt$", ID_TYPE_STR); -embed_function("Input$", ID_TYPE_FN_STR); -add_embedded_arg("prompt$", ID_TYPE_STR); -embed_function("ArrayDim", ID_TYPE_FN_NUM); -add_embedded_arg("id", ID_TYPE_BYREF_NUM); -embed_function("StringArrayDim", ID_TYPE_FN_NUM); -add_embedded_arg("id$", ID_TYPE_BYREF_STR); -embed_function("NumberArrayDim", ID_TYPE_FN_NUM); -add_embedded_arg("id", ID_TYPE_BYREF_NUM); -embed_function("ArraySize", ID_TYPE_FN_NUM); -add_embedded_arg("id", ID_TYPE_BYREF_NUM); -add_embedded_arg("array_dim", ID_TYPE_NUM); -embed_function("StringArraySize", ID_TYPE_FN_NUM); -add_embedded_arg("id$", ID_TYPE_BYREF_STR); -add_embedded_arg("array_dim", ID_TYPE_NUM); -embed_function("NumberArraySize", ID_TYPE_FN_NUM); -add_embedded_arg("id", ID_TYPE_BYREF_NUM); -add_embedded_arg("array_dim", ID_TYPE_NUM); -embed_function("Abs", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("ACos", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("AndBit", ID_TYPE_FN_NUM); -add_embedded_arg("a", ID_TYPE_NUM); -add_embedded_arg("b", ID_TYPE_NUM); -embed_function("ASin", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("ATan", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Bin$", ID_TYPE_FN_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("CInt32", ID_TYPE_FN_NUM); -add_embedded_arg("i", ID_TYPE_NUM); -embed_function("CInt64", ID_TYPE_FN_NUM); -add_embedded_arg("i", ID_TYPE_NUM); -embed_function("Cos", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Degrees", ID_TYPE_FN_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -embed_function("Exp", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Frac", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Hex$", ID_TYPE_FN_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("HexVal", ID_TYPE_FN_NUM); -add_embedded_arg("n$", ID_TYPE_STR); -embed_function("Int", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Log", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Max", ID_TYPE_FN_NUM); -add_embedded_arg("a", ID_TYPE_NUM); -add_embedded_arg("b", ID_TYPE_NUM); -embed_function("Min", ID_TYPE_FN_NUM); -add_embedded_arg("a", ID_TYPE_NUM); -add_embedded_arg("b", ID_TYPE_NUM); -embed_function("OrBit", ID_TYPE_FN_NUM); -add_embedded_arg("a", ID_TYPE_NUM); -add_embedded_arg("b", ID_TYPE_NUM); -embed_function("Radians", ID_TYPE_FN_NUM); -add_embedded_arg("d", ID_TYPE_NUM); -embed_function("Randomize", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Rand", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Round", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Sign", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Sin", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Sqrt", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Tan", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("XOrBit", ID_TYPE_FN_NUM); -add_embedded_arg("a", ID_TYPE_NUM); -add_embedded_arg("b", ID_TYPE_NUM); -embed_function("Asc", ID_TYPE_FN_NUM); -add_embedded_arg("c$", ID_TYPE_STR); -embed_function("Chr$", ID_TYPE_FN_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Insert$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("tgt$", ID_TYPE_STR); -add_embedded_arg("pos", ID_TYPE_NUM); -embed_function("InStr", ID_TYPE_FN_NUM); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("substr$", ID_TYPE_STR); -embed_function("LCase$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -embed_function("Left$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Length", ID_TYPE_FN_NUM); -add_embedded_arg("src$", ID_TYPE_STR); -embed_function("Len", ID_TYPE_FN_NUM); -add_embedded_arg("src$", ID_TYPE_STR); -embed_function("LTrim$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -embed_function("Mid$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("start", ID_TYPE_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("ReplaceSubstr$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("rpc$", ID_TYPE_STR); -add_embedded_arg("pos", ID_TYPE_NUM); -embed_function("Replace$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("tgt$", ID_TYPE_STR); -add_embedded_arg("rpc$", ID_TYPE_STR); -embed_function("Reverse$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -embed_function("Right$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("RTrim$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -embed_function("StringFill$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Str$", ID_TYPE_FN_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Str_F$", ID_TYPE_FN_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Str_S$", ID_TYPE_FN_STR); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Tally", ID_TYPE_FN_NUM); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("substr$", ID_TYPE_STR); -embed_function("Trim$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -embed_function("UCase$", ID_TYPE_FN_STR); -add_embedded_arg("src$", ID_TYPE_STR); -embed_function("Val", ID_TYPE_FN_NUM); -add_embedded_arg("n$", ID_TYPE_STR); -embed_function("Stack_N", ID_TYPE_SUB); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Stack_S", ID_TYPE_SUB); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Push_N", ID_TYPE_SUB); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("Pop_N", ID_TYPE_FN_NUM); -embed_function("Push_S", ID_TYPE_SUB); -add_embedded_arg("s$", ID_TYPE_STR); -embed_function("Pop_S$", ID_TYPE_FN_STR); -embed_function("Stack_Size_N", ID_TYPE_FN_NUM); -embed_function("Stack_Size_S", ID_TYPE_FN_NUM); -embed_function("FileOpen", ID_TYPE_FN_NUM); -add_embedded_arg("stream", ID_TYPE_NUM); -add_embedded_arg("fileName$", ID_TYPE_STR); -add_embedded_arg("mode", ID_TYPE_NUM); -embed_function("FileClose", ID_TYPE_SUB); -add_embedded_arg("stream", ID_TYPE_NUM); -embed_function("ReadByte", ID_TYPE_FN_NUM); -add_embedded_arg("stream", ID_TYPE_NUM); -embed_function("WriteByte", ID_TYPE_SUB); -add_embedded_arg("stream", ID_TYPE_NUM); -add_embedded_arg("byte", ID_TYPE_NUM); -embed_function("ReadLine$", ID_TYPE_FN_STR); -add_embedded_arg("stream", ID_TYPE_NUM); -embed_function("Write", ID_TYPE_SUB); -add_embedded_arg("stream", ID_TYPE_NUM); -add_embedded_arg("txt$", ID_TYPE_STR); -embed_function("WriteLine", ID_TYPE_SUB); -add_embedded_arg("stream", ID_TYPE_NUM); -add_embedded_arg("txt$", ID_TYPE_STR); -embed_function("CopyFile", ID_TYPE_SUB); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("dst$", ID_TYPE_STR); -embed_function("RemoveFile", ID_TYPE_FN_NUM); -add_embedded_arg("fileName$", ID_TYPE_STR); -embed_function("FileExists", ID_TYPE_FN_NUM); -add_embedded_arg("fileName$", ID_TYPE_STR); -embed_function("MoveFile", ID_TYPE_FN_NUM); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("dst$", ID_TYPE_STR); -embed_function("RenameFile", ID_TYPE_FN_NUM); -add_embedded_arg("src$", ID_TYPE_STR); -add_embedded_arg("dst$", ID_TYPE_STR); -embed_function("FileLength", ID_TYPE_FN_NUM); -add_embedded_arg("fileName$", ID_TYPE_STR); -embed_function("Tell", ID_TYPE_FN_NUM); -add_embedded_arg("stream", ID_TYPE_NUM); -embed_function("Seek", ID_TYPE_FN_NUM); -add_embedded_arg("stream", ID_TYPE_NUM); -add_embedded_arg("pos", ID_TYPE_NUM); -embed_function("EOF", ID_TYPE_FN_NUM); -add_embedded_arg("stream", ID_TYPE_NUM); -embed_function("FreeFile", ID_TYPE_FN_NUM); -embed_function("ChangeDir", ID_TYPE_SUB); -add_embedded_arg("p$", ID_TYPE_STR); -embed_function("DirExists", ID_TYPE_FN_NUM); -add_embedded_arg("p$", ID_TYPE_STR); -embed_function("DirFirst$", ID_TYPE_FN_STR); -embed_function("Dir$", ID_TYPE_FN_STR); -embed_function("DirNext$", ID_TYPE_FN_STR); -embed_function("MakeDir", ID_TYPE_FN_NUM); -add_embedded_arg("p$", ID_TYPE_STR); -embed_function("RemoveDir", ID_TYPE_FN_NUM); -add_embedded_arg("p$", ID_TYPE_STR); -embed_function("Date$", ID_TYPE_FN_STR); -embed_function("Easter$", ID_TYPE_FN_STR); -add_embedded_arg("year", ID_TYPE_NUM); -embed_function("Ticks", ID_TYPE_FN_NUM); -embed_function("Time$", ID_TYPE_FN_STR); -embed_function("Timer", ID_TYPE_FN_NUM); -embed_function("Wait", ID_TYPE_SUB); -add_embedded_arg("m_sec", ID_TYPE_NUM); -embed_function("WindowOpen", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("title$", ID_TYPE_STR); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("flag", ID_TYPE_NUM); -add_embedded_arg("vsync", ID_TYPE_NUM); -embed_function("WindowClose", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("RaiseWindow", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("Window", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("Update", ID_TYPE_SUB); -embed_function("Cls", ID_TYPE_SUB); -embed_function("SetClearColor", ID_TYPE_SUB); -add_embedded_arg("c", ID_TYPE_NUM); -embed_function("ShowWindow", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("HideWindow", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("SetWindowTitle", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("title$", ID_TYPE_STR); -embed_function("WindowTitle$", ID_TYPE_FN_STR); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("SetWindowPosition", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("GetWindowPosition", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -embed_function("SetWindowSize", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("GetWindowSize", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("SetWindowMinSize", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("GetWindowMinSize", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("SetWindowMaxSize", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("GetWindowMaxSize", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("WindowIsFullscreen", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowIsVisible", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowIsBordered", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowIsResizable", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowIsMinimized", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowIsMaximized", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowHasInputFocus", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowHasMouseFocus", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("SetWindowFullscreen", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("MaximizeWindow", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("MinimizeWindow", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("SetWindowBorder", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("WindowClip", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("WindowExists", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("NumWindows", ID_TYPE_FN_NUM); -embed_function("WindowEvent_Close", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowEvent_Maximize", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("WindowEvent_Minimize", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("ActiveWindow", ID_TYPE_FN_NUM); -embed_function("FPS", ID_TYPE_FN_NUM); -embed_function("SetWindowIcon", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("CanvasOpen", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("viewport_x", ID_TYPE_NUM); -add_embedded_arg("viewport_y", ID_TYPE_NUM); -add_embedded_arg("viewport_w", ID_TYPE_NUM); -add_embedded_arg("viewport_h", ID_TYPE_NUM); -add_embedded_arg("mode", ID_TYPE_NUM); -embed_function("CanvasClose", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -embed_function("SetCanvasVisible", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("CanvasIsVisible", ID_TYPE_FN_NUM); -add_embedded_arg("c_num", ID_TYPE_NUM); -embed_function("SetCanvasViewport", ID_TYPE_SUB); -add_embedded_arg("cnum", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("GetCanvasViewport", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("Canvas", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -embed_function("SetCanvasOffset", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("GetCanvasOffset", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -embed_function("GetCanvasSize", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("ClearCanvas", ID_TYPE_SUB); -embed_function("SetCanvasAlpha", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("a", ID_TYPE_NUM); -embed_function("CanvasAlpha", ID_TYPE_FN_NUM); -add_embedded_arg("c_num", ID_TYPE_NUM); -embed_function("SetCanvasBlendMode", ID_TYPE_FN_NUM); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("blend_mode", ID_TYPE_NUM); -embed_function("CanvasBlendMode", ID_TYPE_FN_NUM); -add_embedded_arg("c_num", ID_TYPE_NUM); -embed_function("SetCanvasColorMod", ID_TYPE_FN_NUM); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -embed_function("CanvasColorMod", ID_TYPE_FN_NUM); -add_embedded_arg("c_num", ID_TYPE_NUM); -embed_function("CopyCanvas", ID_TYPE_SUB); -add_embedded_arg("src", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("dst", ID_TYPE_NUM); -add_embedded_arg("dx", ID_TYPE_NUM); -add_embedded_arg("dy", ID_TYPE_NUM); -embed_function("CloneCanvas", ID_TYPE_SUB); -add_embedded_arg("src", ID_TYPE_NUM); -add_embedded_arg("dst", ID_TYPE_NUM); -embed_function("SetCanvasZ", ID_TYPE_SUB); -add_embedded_arg("c_num", ID_TYPE_NUM); -add_embedded_arg("z", ID_TYPE_NUM); -embed_function("CanvasZ", ID_TYPE_FN_NUM); -add_embedded_arg("c_num", ID_TYPE_NUM); -embed_function("CanvasClip", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("ActiveCanvas", ID_TYPE_FN_NUM); -embed_function("Box", ID_TYPE_SUB); -add_embedded_arg("x1", ID_TYPE_NUM); -add_embedded_arg("y1", ID_TYPE_NUM); -add_embedded_arg("x2", ID_TYPE_NUM); -add_embedded_arg("y2", ID_TYPE_NUM); -embed_function("BoxFill", ID_TYPE_SUB); -add_embedded_arg("x1", ID_TYPE_NUM); -add_embedded_arg("y1", ID_TYPE_NUM); -add_embedded_arg("x2", ID_TYPE_NUM); -add_embedded_arg("y2", ID_TYPE_NUM); -embed_function("Circle", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("radius", ID_TYPE_NUM); -embed_function("CircleFill", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("radius", ID_TYPE_NUM); -embed_function("Ellipse", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("rx", ID_TYPE_NUM); -add_embedded_arg("ry", ID_TYPE_NUM); -embed_function("EllipseFill", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("rx", ID_TYPE_NUM); -add_embedded_arg("ry", ID_TYPE_NUM); -embed_function("FloodFill", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("GetPixel", ID_TYPE_FN_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("SetColor", ID_TYPE_SUB); -add_embedded_arg("c", ID_TYPE_NUM); -embed_function("Line", ID_TYPE_SUB); -add_embedded_arg("x1", ID_TYPE_NUM); -add_embedded_arg("y1", ID_TYPE_NUM); -add_embedded_arg("x2", ID_TYPE_NUM); -add_embedded_arg("y2", ID_TYPE_NUM); -embed_function("Poly", ID_TYPE_SUB); -add_embedded_arg("n", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -embed_function("PolyFill", ID_TYPE_SUB); -add_embedded_arg("n", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -embed_function("Rect", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("RectFill", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("RoundRect", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -embed_function("RoundRectFill", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -embed_function("RGB", ID_TYPE_FN_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("g", ID_TYPE_NUM); -add_embedded_arg("b", ID_TYPE_NUM); -embed_function("RGBA", ID_TYPE_FN_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("g", ID_TYPE_NUM); -add_embedded_arg("b", ID_TYPE_NUM); -add_embedded_arg("a", ID_TYPE_NUM); -embed_function("PSet", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("LoadImage", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("img$", ID_TYPE_STR); -embed_function("LoadImage_Ex", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("img$", ID_TYPE_STR); -add_embedded_arg("colkey", ID_TYPE_NUM); -embed_function("ImageFromBuffer", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); -embed_function("ImageFromBuffer_Ex", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); -add_embedded_arg("colkey", ID_TYPE_NUM); -embed_function("BufferFromImage", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); -embed_function("ImageExists", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("ColorKey", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -embed_function("CopyImage", ID_TYPE_SUB); -add_embedded_arg("src", ID_TYPE_NUM); -add_embedded_arg("dst", ID_TYPE_NUM); -embed_function("DeleteImage", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("SetImageAlpha", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("a", ID_TYPE_NUM); -embed_function("ImageAlpha", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("GetImageSize", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("SetImageBlendMode", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("blend_mode", ID_TYPE_NUM); -embed_function("ImageBlendMode", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("SetImageColorMod", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -embed_function("ImageColorMod", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("DrawImage", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("DrawImage_Blit", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("src_x", ID_TYPE_NUM); -add_embedded_arg("src_y", ID_TYPE_NUM); -add_embedded_arg("src_w", ID_TYPE_NUM); -add_embedded_arg("src_h", ID_TYPE_NUM); -embed_function("DrawImage_Blit_Ex", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("src_x", ID_TYPE_NUM); -add_embedded_arg("src_y", ID_TYPE_NUM); -add_embedded_arg("src_w", ID_TYPE_NUM); -add_embedded_arg("src_h", ID_TYPE_NUM); -embed_function("DrawImage_Rotate", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("angle", ID_TYPE_NUM); -embed_function("DrawImage_Rotate_Ex", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("src_x", ID_TYPE_NUM); -add_embedded_arg("src_y", ID_TYPE_NUM); -add_embedded_arg("src_w", ID_TYPE_NUM); -add_embedded_arg("src_h", ID_TYPE_NUM); -add_embedded_arg("angle", ID_TYPE_NUM); -embed_function("DrawImage_Zoom", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("zx", ID_TYPE_NUM); -add_embedded_arg("zy", ID_TYPE_NUM); -embed_function("DrawImage_Zoom_Ex", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("src_x", ID_TYPE_NUM); -add_embedded_arg("src_y", ID_TYPE_NUM); -add_embedded_arg("src_w", ID_TYPE_NUM); -add_embedded_arg("src_h", ID_TYPE_NUM); -add_embedded_arg("zx", ID_TYPE_NUM); -add_embedded_arg("zy", ID_TYPE_NUM); -embed_function("DrawImage_Rotozoom", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("angle", ID_TYPE_NUM); -add_embedded_arg("zx", ID_TYPE_NUM); -add_embedded_arg("zy", ID_TYPE_NUM); -embed_function("DrawImage_Rotozoom_Ex", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("src_x", ID_TYPE_NUM); -add_embedded_arg("src_y", ID_TYPE_NUM); -add_embedded_arg("src_w", ID_TYPE_NUM); -add_embedded_arg("src_h", ID_TYPE_NUM); -add_embedded_arg("angle", ID_TYPE_NUM); -add_embedded_arg("zx", ID_TYPE_NUM); -add_embedded_arg("zy", ID_TYPE_NUM); -embed_function("DrawImage_Flip", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("v", ID_TYPE_NUM); -embed_function("DrawImage_Flip_Ex", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("src_x", ID_TYPE_NUM); -add_embedded_arg("src_y", ID_TYPE_NUM); -add_embedded_arg("src_w", ID_TYPE_NUM); -add_embedded_arg("src_h", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("v", ID_TYPE_NUM); -embed_function("InKey", ID_TYPE_FN_NUM); -embed_function("Key", ID_TYPE_FN_NUM); -add_embedded_arg("key_code", ID_TYPE_NUM); -embed_function("WaitKey", ID_TYPE_FN_NUM); -embed_function("HideMouse", ID_TYPE_SUB); -embed_function("ShowMouse", ID_TYPE_SUB); -embed_function("MouseIsVisible", ID_TYPE_FN_NUM); -embed_function("GetMouse", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("mb1", ID_TYPE_BYREF_NUM); -add_embedded_arg("mb2", ID_TYPE_BYREF_NUM); -add_embedded_arg("mb3", ID_TYPE_BYREF_NUM); -embed_function("MouseX", ID_TYPE_FN_NUM); -embed_function("MouseY", ID_TYPE_FN_NUM); -embed_function("MouseButton", ID_TYPE_FN_NUM); -add_embedded_arg("mb", ID_TYPE_NUM); -embed_function("GetMouseWheel", ID_TYPE_SUB); -add_embedded_arg("x_axis", ID_TYPE_BYREF_NUM); -add_embedded_arg("y_axis", ID_TYPE_BYREF_NUM); -embed_function("MouseWheelX", ID_TYPE_FN_NUM); -embed_function("MouseWheelY", ID_TYPE_FN_NUM); -embed_function("SoundFromBuffer", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); -add_embedded_arg("buffer_size", ID_TYPE_NUM); -add_embedded_arg("vol", ID_TYPE_NUM); -embed_function("LoadSound", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("snd_file$", ID_TYPE_STR); -embed_function("LoadMusic", ID_TYPE_SUB); -add_embedded_arg("music_file$", ID_TYPE_STR); -embed_function("PlaySound", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("channel", ID_TYPE_NUM); -add_embedded_arg("loops", ID_TYPE_NUM); -embed_function("PlaySoundTimed", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("channel", ID_TYPE_NUM); -add_embedded_arg("loops", ID_TYPE_NUM); -add_embedded_arg("ms", ID_TYPE_NUM); -embed_function("PlayMusic", ID_TYPE_SUB); -add_embedded_arg("mLoops", ID_TYPE_NUM); -embed_function("PauseSound", ID_TYPE_SUB); -add_embedded_arg("channel", ID_TYPE_NUM); -embed_function("ResumeSound", ID_TYPE_SUB); -add_embedded_arg("channel", ID_TYPE_NUM); -embed_function("PauseMusic", ID_TYPE_SUB); -embed_function("ResumeMusic", ID_TYPE_SUB); -embed_function("DeleteSound", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("DeleteMusic", ID_TYPE_SUB); -embed_function("FadeMusicIn", ID_TYPE_SUB); -add_embedded_arg("fade_time", ID_TYPE_NUM); -add_embedded_arg("loops", ID_TYPE_NUM); -embed_function("FadeMusicOut", ID_TYPE_SUB); -add_embedded_arg("fade_time", ID_TYPE_NUM); -embed_function("MusicExists", ID_TYPE_FN_NUM); -embed_function("SetMusicVolume", ID_TYPE_SUB); -add_embedded_arg("vol", ID_TYPE_NUM); -embed_function("MusicVolume", ID_TYPE_FN_NUM); -embed_function("SetMusicPosition", ID_TYPE_SUB); -add_embedded_arg("pos", ID_TYPE_NUM); -embed_function("MusicPosition", ID_TYPE_FN_NUM); -embed_function("RewindMusic", ID_TYPE_SUB); -embed_function("SetSoundChannels", ID_TYPE_SUB); -add_embedded_arg("max_channels", ID_TYPE_NUM); -embed_function("NumSoundChannels", ID_TYPE_FN_NUM); -embed_function("SoundIsEnabled", ID_TYPE_FN_NUM); -embed_function("SoundExists", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("SetChannelVolume", ID_TYPE_SUB); -add_embedded_arg("channel", ID_TYPE_NUM); -add_embedded_arg("vol", ID_TYPE_NUM); -embed_function("ChannelVolume", ID_TYPE_FN_NUM); -add_embedded_arg("channel", ID_TYPE_NUM); -embed_function("SetSoundVolume", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("vol", ID_TYPE_NUM); -embed_function("SoundVolume", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("StopMusic", ID_TYPE_SUB); -embed_function("StopSound", ID_TYPE_SUB); -add_embedded_arg("channel", ID_TYPE_NUM); -embed_function("SetChannelPanning", ID_TYPE_FN_NUM); -add_embedded_arg("channel", ID_TYPE_NUM); -add_embedded_arg("left_value", ID_TYPE_NUM); -add_embedded_arg("right_value", ID_TYPE_NUM); -embed_function("SetChannelDistance", ID_TYPE_FN_NUM); -add_embedded_arg("channel", ID_TYPE_NUM); -add_embedded_arg("dist_value", ID_TYPE_NUM); -embed_function("ChannelIsPlaying", ID_TYPE_FN_NUM); -add_embedded_arg("channel", ID_TYPE_NUM); -embed_function("ChannelIsPaused", ID_TYPE_FN_NUM); -add_embedded_arg("channel", ID_TYPE_NUM); -embed_function("NumJoysticks", ID_TYPE_FN_NUM); -embed_function("NumJoyAxes", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -embed_function("NumJoyButtons", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -embed_function("NumJoyHats", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -embed_function("NumJoyTrackBalls", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -embed_function("JoyAxis", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -add_embedded_arg("joy_axis", ID_TYPE_NUM); -embed_function("JoyButton", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -add_embedded_arg("joy_button", ID_TYPE_NUM); -embed_function("JoyHat", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -add_embedded_arg("joy_hat", ID_TYPE_NUM); -embed_function("GetJoyTrackBall", ID_TYPE_SUB); -add_embedded_arg("joy_num", ID_TYPE_NUM); -add_embedded_arg("ball", ID_TYPE_NUM); -add_embedded_arg("dx", ID_TYPE_BYREF_NUM); -add_embedded_arg("dy", ID_TYPE_BYREF_NUM); -embed_function("JoyName$", ID_TYPE_FN_STR); -add_embedded_arg("joy_num", ID_TYPE_NUM); -embed_function("JoystickIsConnected", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -embed_function("GetCursor", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -embed_function("PrintS", ID_TYPE_SUB); -add_embedded_arg("txt$", ID_TYPE_STR); -embed_function("InputS$", ID_TYPE_FN_STR); -add_embedded_arg("prompt$", ID_TYPE_STR); -embed_function("ZoneInputS$", ID_TYPE_FN_STR); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("Locate", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("ReadInput_Start", ID_TYPE_SUB); -embed_function("ReadInput_Stop", ID_TYPE_SUB); -embed_function("ReadInput_Text$", ID_TYPE_FN_STR); -embed_function("ReadInput_SetText", ID_TYPE_SUB); -add_embedded_arg("txt$", ID_TYPE_STR); -embed_function("ReadInput_ToggleBackspace", ID_TYPE_SUB); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("LoadFont", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("fnt_file$", ID_TYPE_STR); -add_embedded_arg("size", ID_TYPE_NUM); -embed_function("DeleteFont", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("FontIsLoaded", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("Font", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -embed_function("SetFontStyle", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("style", ID_TYPE_NUM); -embed_function("DrawText", ID_TYPE_SUB); -add_embedded_arg("txt$", ID_TYPE_STR); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("DrawText_Shaded", ID_TYPE_SUB); -add_embedded_arg("txt$", ID_TYPE_STR); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("fg_color", ID_TYPE_NUM); -add_embedded_arg("bg_color", ID_TYPE_NUM); -embed_function("DrawText_Blended", ID_TYPE_SUB); -add_embedded_arg("txt$", ID_TYPE_STR); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("RenderText", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("txt$", ID_TYPE_STR); -embed_function("GetTextSize", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("txt$", ID_TYPE_STR); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("TouchPressure", ID_TYPE_FN_NUM); -embed_function("GetTouch", ID_TYPE_SUB); -add_embedded_arg("status", ID_TYPE_BYREF_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("dx", ID_TYPE_BYREF_NUM); -add_embedded_arg("dy", ID_TYPE_BYREF_NUM); -embed_function("GetMultiTouch", ID_TYPE_SUB); -add_embedded_arg("status", ID_TYPE_BYREF_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("fingers", ID_TYPE_BYREF_NUM); -add_embedded_arg("dist", ID_TYPE_BYREF_NUM); -add_embedded_arg("theta", ID_TYPE_BYREF_NUM); -embed_function("GetTouchFinger", ID_TYPE_SUB); -add_embedded_arg("finger", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("pressure", ID_TYPE_BYREF_NUM); -embed_function("NumFingers", ID_TYPE_FN_NUM); -embed_function("CheckSockets", ID_TYPE_FN_NUM); -add_embedded_arg("timeout_ms", ID_TYPE_NUM); -embed_function("TCP_SocketReady", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -embed_function("UDP_SocketReady", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -embed_function("TCP_SocketOpen", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -add_embedded_arg("host$", ID_TYPE_STR); -add_embedded_arg("port", ID_TYPE_NUM); -embed_function("TCP_SocketClose", ID_TYPE_SUB); -add_embedded_arg("socket", ID_TYPE_NUM); -embed_function("TCP_RemoteHost", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -embed_function("TCP_RemotePort", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -embed_function("TCP_GetData", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -add_embedded_arg("sData$", ID_TYPE_BYREF_STR); -add_embedded_arg("numBytes", ID_TYPE_NUM); -embed_function("TCP_SendData", ID_TYPE_SUB); -add_embedded_arg("socket", ID_TYPE_NUM); -add_embedded_arg("sData$", ID_TYPE_STR); -embed_function("TCP_AcceptSocket", ID_TYPE_FN_NUM); -add_embedded_arg("server", ID_TYPE_NUM); -add_embedded_arg("client", ID_TYPE_NUM); -embed_function("UDP_SocketOpen", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -add_embedded_arg("port", ID_TYPE_NUM); -embed_function("UDP_SocketClose", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -embed_function("UDP_GetData", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -add_embedded_arg("sData$", ID_TYPE_BYREF_STR); -add_embedded_arg("host$", ID_TYPE_BYREF_STR); -add_embedded_arg("port", ID_TYPE_BYREF_NUM); -embed_function("UDP_Length", ID_TYPE_FN_NUM); -embed_function("UDP_MaxLength", ID_TYPE_FN_NUM); -embed_function("UDP_RemoteHost$", ID_TYPE_FN_STR); -add_embedded_arg("socket", ID_TYPE_NUM); -embed_function("UDP_RemotePort", ID_TYPE_FN_NUM); -add_embedded_arg("socket", ID_TYPE_NUM); -embed_function("UDP_SendData", ID_TYPE_SUB); -add_embedded_arg("socket", ID_TYPE_NUM); -add_embedded_arg("sData$", ID_TYPE_STR); -add_embedded_arg("host$", ID_TYPE_STR); -add_embedded_arg("port", ID_TYPE_NUM); -embed_function("LoadVideo", ID_TYPE_SUB); -add_embedded_arg("vid$", ID_TYPE_STR); -embed_function("PlayVideo", ID_TYPE_SUB); -add_embedded_arg("vLoops", ID_TYPE_NUM); -embed_function("PauseVideo", ID_TYPE_SUB); -embed_function("StopVideo", ID_TYPE_SUB); -embed_function("SetVideoPosition", ID_TYPE_SUB); -add_embedded_arg("pos", ID_TYPE_NUM); -embed_function("ResumeVideo", ID_TYPE_SUB); -embed_function("VideoPosition", ID_TYPE_FN_NUM); -embed_function("DeleteVideo", ID_TYPE_SUB); -embed_function("VideoIsPlaying", ID_TYPE_FN_NUM); -embed_function("VideoEnd", ID_TYPE_FN_NUM); -embed_function("GetVideoStats", ID_TYPE_SUB); -add_embedded_arg("vFile$", ID_TYPE_STR); -add_embedded_arg("vLen", ID_TYPE_BYREF_NUM); -add_embedded_arg("vfps", ID_TYPE_BYREF_NUM); -add_embedded_arg("frame_w", ID_TYPE_BYREF_NUM); -add_embedded_arg("frame_h", ID_TYPE_BYREF_NUM); -embed_function("SetVideoDrawRect", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("GetVideoDrawRect", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("GetVideoSize", ID_TYPE_SUB); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -embed_function("VideoExists", ID_TYPE_FN_NUM); -embed_function("SetVideoAlpha", ID_TYPE_SUB); -add_embedded_arg("a", ID_TYPE_NUM); -embed_function("System", ID_TYPE_FN_NUM); -add_embedded_arg("cmd$", ID_TYPE_STR); -embed_function("OS$", ID_TYPE_FN_STR); -embed_function("Command$", ID_TYPE_FN_STR); -add_embedded_arg("arg", ID_TYPE_NUM); -embed_function("NumCommands", ID_TYPE_FN_NUM); -embed_function("Env$", ID_TYPE_FN_STR); -add_embedded_arg("v$", ID_TYPE_STR); -embed_function("SetEnv", ID_TYPE_SUB); -add_embedded_arg("var$", ID_TYPE_STR); -add_embedded_arg("value$", ID_TYPE_STR); -add_embedded_arg("overwrite", ID_TYPE_NUM); -embed_function("PrefPath$", ID_TYPE_FN_STR); -add_embedded_arg("org_name$", ID_TYPE_STR); -add_embedded_arg("app_name$", ID_TYPE_STR); -embed_function("Android_GetExternalStoragePath$", ID_TYPE_FN_STR); -embed_function("Android_GetExternalStorageState", ID_TYPE_FN_NUM); -embed_function("Android_GetInternalStoragePath$", ID_TYPE_FN_STR); -embed_function("Android_JNI_Message$", ID_TYPE_FN_STR); -add_embedded_arg("arg$", ID_TYPE_STR); -embed_function("Runtime_Utility_Message$", ID_TYPE_FN_STR); -add_embedded_arg("arg$", ID_TYPE_STR); -embed_function("ClipboardText$", ID_TYPE_FN_STR); -embed_function("SetClipboardText", ID_TYPE_SUB); -add_embedded_arg("txt$", ID_TYPE_STR); -embed_function("HasClipboardText", ID_TYPE_FN_NUM); -embed_function("GetDesktopDisplayMode", ID_TYPE_SUB); -add_embedded_arg("index", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_BYREF_NUM); -add_embedded_arg("h", ID_TYPE_BYREF_NUM); -add_embedded_arg("freq", ID_TYPE_BYREF_NUM); -embed_function("DrawImage_Transform", ID_TYPE_SUB); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -add_embedded_arg("src_x", ID_TYPE_NUM); -add_embedded_arg("src_y", ID_TYPE_NUM); -add_embedded_arg("src_w", ID_TYPE_NUM); -add_embedded_arg("src_h", ID_TYPE_NUM); -add_embedded_arg("angle", ID_TYPE_NUM); -add_embedded_arg("center_x", ID_TYPE_NUM); -add_embedded_arg("center_y", ID_TYPE_NUM); -add_embedded_arg("flip_h", ID_TYPE_NUM); -add_embedded_arg("flip_v", ID_TYPE_NUM); -embed_function("GetPowerInfo", ID_TYPE_SUB); -add_embedded_arg("status", ID_TYPE_BYREF_NUM); -add_embedded_arg("secs", ID_TYPE_BYREF_NUM); -add_embedded_arg("pct", ID_TYPE_BYREF_NUM); -embed_function("SystemRam", ID_TYPE_FN_NUM); -embed_function("SetRenderScaleQuality", ID_TYPE_FN_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("EvalJS$", ID_TYPE_FN_STR); -add_embedded_arg("js_code$", ID_TYPE_STR); -embed_function("GetRenderScaleQuality", ID_TYPE_FN_NUM); -embed_function("GetGlobalMouse", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("mb1", ID_TYPE_BYREF_NUM); -add_embedded_arg("mb2", ID_TYPE_BYREF_NUM); -add_embedded_arg("mb3", ID_TYPE_BYREF_NUM); -embed_function("GlobalMouseX", ID_TYPE_FN_NUM); -embed_function("GlobalMouseY", ID_TYPE_FN_NUM); -embed_function("GetAccel", ID_TYPE_SUB); -add_embedded_arg("accel_num", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("z", ID_TYPE_BYREF_NUM); -embed_function("AccelName$", ID_TYPE_FN_STR); -add_embedded_arg("accel_num", ID_TYPE_NUM); -embed_function("NumAccels", ID_TYPE_FN_NUM); -embed_function("GetGyro", ID_TYPE_SUB); -add_embedded_arg("gyro_num", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_BYREF_NUM); -add_embedded_arg("y", ID_TYPE_BYREF_NUM); -add_embedded_arg("z", ID_TYPE_BYREF_NUM); -embed_function("GyroName$", ID_TYPE_FN_STR); -add_embedded_arg("gyro_num", ID_TYPE_NUM); -embed_function("NumGyros", ID_TYPE_FN_NUM); -embed_function("JoyRumblePlay", ID_TYPE_SUB); -add_embedded_arg("joy_num", ID_TYPE_NUM); -add_embedded_arg("strength", ID_TYPE_NUM); -add_embedded_arg("duration", ID_TYPE_NUM); -embed_function("JoyRumbleStop", ID_TYPE_SUB); -add_embedded_arg("joy_num", ID_TYPE_NUM); -embed_function("JoystickIsHaptic", ID_TYPE_FN_NUM); -add_embedded_arg("joy_num", ID_TYPE_NUM); -embed_function("WriteByteBuffer", ID_TYPE_FN_NUM); -add_embedded_arg("stream", ID_TYPE_NUM); -add_embedded_arg("buf", ID_TYPE_BYREF_NUM); -add_embedded_arg("buf_size", ID_TYPE_NUM); -embed_function("ReadByteBuffer", ID_TYPE_FN_NUM); -add_embedded_arg("stream", ID_TYPE_NUM); -add_embedded_arg("buf", ID_TYPE_BYREF_NUM); -add_embedded_arg("buf_size", ID_TYPE_NUM); -embed_function("WindowEvent_Resize", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("SetWindowAutoClose", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("exit_on_close", ID_TYPE_NUM); -embed_function("SetWindowResizable", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("SystemReturnStdOut$", ID_TYPE_FN_STR); -add_embedded_arg("cmd$", ID_TYPE_STR); -embed_function("WindowMode", ID_TYPE_FN_NUM); -add_embedded_arg("visible", ID_TYPE_NUM); -add_embedded_arg("fullscreen", ID_TYPE_NUM); -add_embedded_arg("resizable", ID_TYPE_NUM); -add_embedded_arg("borderless", ID_TYPE_NUM); -add_embedded_arg("highDPI", ID_TYPE_NUM); -embed_function("WindowFlags", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("RestoreWindow", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("UpdateAllWindows", ID_TYPE_SUB); -embed_function("QueryAudioSpec", ID_TYPE_FN_NUM); -add_embedded_arg("freq", ID_TYPE_BYREF_NUM); -add_embedded_arg("format", ID_TYPE_BYREF_NUM); -add_embedded_arg("channels", ID_TYPE_BYREF_NUM); -embed_function("MusicIsPlaying", ID_TYPE_FN_NUM); -embed_function("DrawGeometry", ID_TYPE_FN_NUM); -add_embedded_arg("slot", ID_TYPE_NUM); -add_embedded_arg("num_vertices", ID_TYPE_NUM); -add_embedded_arg("vertices", ID_TYPE_BYREF_NUM); -add_embedded_arg("num_indices", ID_TYPE_NUM); -add_embedded_arg("Indices", ID_TYPE_BYREF_NUM); -embed_function("Size", ID_TYPE_FN_NUM); -add_embedded_arg("s$", ID_TYPE_STR); -embed_function("BufferFromString", ID_TYPE_FN_NUM); -add_embedded_arg("s$", ID_TYPE_STR); -add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); -embed_function("StringFromBuffer$", ID_TYPE_FN_STR); -add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); -add_embedded_arg("buffer_size", ID_TYPE_NUM); -embed_function("GrabInput", ID_TYPE_SUB); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("GrabbedWindow", ID_TYPE_FN_NUM); -embed_function("WarpMouse", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("WarpMouseGlobal", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -embed_function("SetMouseZone", ID_TYPE_SUB); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("w", ID_TYPE_NUM); -add_embedded_arg("h", ID_TYPE_NUM); -embed_function("ClearMouseZone", ID_TYPE_SUB); -embed_function("SetWindowAlwaysOnTop", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("SetMouseRelative", ID_TYPE_SUB); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("SetWindowVSync", ID_TYPE_SUB); -add_embedded_arg("win", ID_TYPE_NUM); -add_embedded_arg("flag", ID_TYPE_NUM); -embed_function("OpenURL", ID_TYPE_FN_NUM); -add_embedded_arg("url$", ID_TYPE_STR); -embed_function("APIVersion$", ID_TYPE_FN_STR); -embed_function("FlashWindow", ID_TYPE_FN_NUM); -add_embedded_arg("win", ID_TYPE_NUM); -embed_function("MessageBox", ID_TYPE_FN_NUM); -add_embedded_arg("title$", ID_TYPE_STR); -add_embedded_arg("msg$", ID_TYPE_STR); -embed_function("NumberArrayCopy", ID_TYPE_SUB); -add_embedded_arg("src", ID_TYPE_BYREF_NUM); -add_embedded_arg("dst", ID_TYPE_BYREF_NUM); -embed_function("StringArrayCopy", ID_TYPE_SUB); -add_embedded_arg("src$", ID_TYPE_BYREF_STR); -add_embedded_arg("dst$", ID_TYPE_BYREF_STR); -embed_function("ArrayCopy", ID_TYPE_SUB); -add_embedded_arg("src", ID_TYPE_BYREF_NUM); -add_embedded_arg("dst", ID_TYPE_BYREF_NUM); -embed_function("NumberArrayFill", ID_TYPE_SUB); -add_embedded_arg("src", ID_TYPE_BYREF_NUM); -add_embedded_arg("fdata", ID_TYPE_NUM); -embed_function("StringArrayFill", ID_TYPE_SUB); -add_embedded_arg("src$", ID_TYPE_BYREF_STR); -add_embedded_arg("fdata$", ID_TYPE_STR); -embed_function("ArrayFill", ID_TYPE_SUB); -add_embedded_arg("src", ID_TYPE_BYREF_NUM); -add_embedded_arg("fdata", ID_TYPE_NUM); -embed_function("Runtime$", ID_TYPE_FN_STR); -embed_function("DimMatrix", ID_TYPE_SUB); -add_embedded_arg("m", ID_TYPE_NUM); -add_embedded_arg("m_rows", ID_TYPE_NUM); -add_embedded_arg("m_cols", ID_TYPE_NUM); -add_embedded_arg("preserve_flag", ID_TYPE_NUM); -embed_function("AddMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("mC", ID_TYPE_NUM); -embed_function("AugmentMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("mC", ID_TYPE_NUM); -embed_function("CopyMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -embed_function("InsertMatrixColumns", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("num_cols", ID_TYPE_NUM); -embed_function("InsertMatrixRows", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("num_rows", ID_TYPE_NUM); -embed_function("MultiplyMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("mC", ID_TYPE_NUM); -embed_function("CubeMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -embed_function("DeleteMatrixColumns", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("num_cols", ID_TYPE_NUM); -embed_function("DeleteMatrixRows", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("num_rows", ID_TYPE_NUM); -embed_function("ClearMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -embed_function("ClearMatrixColumns", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("num_cols", ID_TYPE_NUM); -embed_function("ClearMatrixRows", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("num_rows", ID_TYPE_NUM); -embed_function("FillMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("v", ID_TYPE_NUM); -embed_function("FillMatrixColumns", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("num_cols", ID_TYPE_NUM); -add_embedded_arg("v", ID_TYPE_NUM); -embed_function("FillMatrixRows", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("num_rows", ID_TYPE_NUM); -add_embedded_arg("v", ID_TYPE_NUM); -embed_function("CopyMatrixColumns", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("num_cols", ID_TYPE_NUM); -embed_function("CopyMatrixRows", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("num_rows", ID_TYPE_NUM); -embed_function("IdentityMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("n", ID_TYPE_NUM); -embed_function("SolveMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("mC", ID_TYPE_NUM); -embed_function("IsEqualMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("tolerance", ID_TYPE_NUM); -embed_function("Determinant", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -embed_function("AdjointMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -embed_function("InvertMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -embed_function("MatrixFromBuffer", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); -embed_function("GetMatrix", ID_TYPE_SUB); -add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -embed_function("RandomizeMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("vmin", ID_TYPE_NUM); -add_embedded_arg("vmax", ID_TYPE_NUM); -embed_function("MatrixValue", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -embed_function("SetMatrixValue", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("v", ID_TYPE_NUM); -embed_function("ScalarMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("s_value", ID_TYPE_NUM); -embed_function("ScalarMatrixColumns", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("num_cols", ID_TYPE_NUM); -add_embedded_arg("s_value", ID_TYPE_NUM); -embed_function("ScalarMatrixRows", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("num_rows", ID_TYPE_NUM); -add_embedded_arg("s_value", ID_TYPE_NUM); -embed_function("SquareMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -embed_function("SubMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -embed_function("SubtractMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("mC", ID_TYPE_NUM); -embed_function("SwapMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -embed_function("SwapMatrixColumn", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("C1", ID_TYPE_NUM); -add_embedded_arg("C2", ID_TYPE_NUM); -embed_function("SwapMatrixRow", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("R1", ID_TYPE_NUM); -add_embedded_arg("R2", ID_TYPE_NUM); -embed_function("TransposeMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -embed_function("UnAugmentMatrix", ID_TYPE_FN_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("mC", ID_TYPE_NUM); -embed_function("ZeroMatrix", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -embed_function("GetMatrixSize", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_BYREF_NUM); -add_embedded_arg("c", ID_TYPE_BYREF_NUM); -embed_function("SetMatrixProcess", ID_TYPE_FN_NUM); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessOpen", ID_TYPE_FN_NUM); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("SetProcessErrorMode", ID_TYPE_SUB); -add_embedded_arg("p_num", ID_TYPE_NUM); -add_embedded_arg("error_mode", ID_TYPE_NUM); -embed_function("ProcessError", ID_TYPE_FN_NUM); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessWait", ID_TYPE_SUB); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessWaitAll", ID_TYPE_SUB); -embed_function("ProcessContinue", ID_TYPE_SUB); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessStop", ID_TYPE_SUB); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessClear", ID_TYPE_SUB); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessClose", ID_TYPE_FN_NUM); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessErrorMode", ID_TYPE_FN_NUM); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessSleep", ID_TYPE_SUB); -add_embedded_arg("p_num", ID_TYPE_NUM); -add_embedded_arg("msec", ID_TYPE_NUM); -embed_function("ProcessExists", ID_TYPE_FN_NUM); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("ProcessStopAll", ID_TYPE_SUB); -embed_function("ProcessContinueAll", ID_TYPE_SUB); -embed_function("ProcessQueueSize", ID_TYPE_FN_NUM); -add_embedded_arg("p_num", ID_TYPE_NUM); -embed_function("NumCPUs", ID_TYPE_FN_NUM); -embed_function("GetProjectionGeometry", ID_TYPE_SUB); -add_embedded_arg("cam_dist", ID_TYPE_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("f_vertex_count", ID_TYPE_NUM); -add_embedded_arg("columns", ID_TYPE_BYREF_NUM); -add_embedded_arg("uv", ID_TYPE_BYREF_NUM); -add_embedded_arg("graph_offset_x", ID_TYPE_NUM); -add_embedded_arg("graph_offset_y", ID_TYPE_NUM); -add_embedded_arg("v_color", ID_TYPE_NUM); -add_embedded_arg("vertex_count", ID_TYPE_BYREF_NUM); -add_embedded_arg("vertex2D", ID_TYPE_BYREF_NUM); -add_embedded_arg("index_count", ID_TYPE_BYREF_NUM); -add_embedded_arg("index", ID_TYPE_BYREF_NUM); -add_embedded_arg("clip_dist", ID_TYPE_BYREF_NUM); -add_embedded_arg("min_x", ID_TYPE_BYREF_NUM); -add_embedded_arg("min_y", ID_TYPE_BYREF_NUM); -add_embedded_arg("max_x", ID_TYPE_BYREF_NUM); -add_embedded_arg("max_y", ID_TYPE_BYREF_NUM); -embed_function("CalculateFaceZ", ID_TYPE_FN_NUM); -add_embedded_arg("cam_dist", ID_TYPE_NUM); -add_embedded_arg("graph_offset_x", ID_TYPE_NUM); -add_embedded_arg("graph_offset_y", ID_TYPE_NUM); -add_embedded_arg("view_w", ID_TYPE_NUM); -add_embedded_arg("view_h", ID_TYPE_NUM); -add_embedded_arg("view_depth", ID_TYPE_NUM); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("f_vertex_count", ID_TYPE_NUM); -add_embedded_arg("columns", ID_TYPE_BYREF_NUM); -add_embedded_arg("face_min_z", ID_TYPE_BYREF_NUM); -add_embedded_arg("face_max_z", ID_TYPE_BYREF_NUM); -add_embedded_arg("z_avg", ID_TYPE_BYREF_NUM); -embed_function("SetChannelSpacePosition", ID_TYPE_FN_NUM); -add_embedded_arg("channel", ID_TYPE_NUM); -add_embedded_arg("angle", ID_TYPE_NUM); -add_embedded_arg("distance", ID_TYPE_NUM); -embed_function("SaveBMP", ID_TYPE_FN_NUM); -add_embedded_arg("img", ID_TYPE_NUM); -add_embedded_arg("file$", ID_TYPE_STR); -embed_function("SavePNG", ID_TYPE_FN_NUM); -add_embedded_arg("img", ID_TYPE_NUM); -add_embedded_arg("file$", ID_TYPE_STR); -embed_function("SaveJPG", ID_TYPE_FN_NUM); -add_embedded_arg("img", ID_TYPE_NUM); -add_embedded_arg("file$", ID_TYPE_STR); -embed_function("GetLineIntersection", ID_TYPE_FN_NUM); -add_embedded_arg("p0_x", ID_TYPE_NUM); -add_embedded_arg("p0_y", ID_TYPE_NUM); -add_embedded_arg("p1_x", ID_TYPE_NUM); -add_embedded_arg("p1_y", ID_TYPE_NUM); -add_embedded_arg("p2_x", ID_TYPE_NUM); -add_embedded_arg("p2_y", ID_TYPE_NUM); -add_embedded_arg("p3_x", ID_TYPE_NUM); -add_embedded_arg("p3_y", ID_TYPE_NUM); -add_embedded_arg("i_x", ID_TYPE_BYREF_NUM); -add_embedded_arg("i_y", ID_TYPE_BYREF_NUM); -embed_function("Interpolate", ID_TYPE_FN_NUM); -add_embedded_arg("min_a", ID_TYPE_NUM); -add_embedded_arg("max_a", ID_TYPE_NUM); -add_embedded_arg("mid_a", ID_TYPE_NUM); -add_embedded_arg("min_b", ID_TYPE_NUM); -add_embedded_arg("max_b", ID_TYPE_NUM); -embed_function("ATan2", ID_TYPE_FN_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -embed_function("PointInQuad", ID_TYPE_FN_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("x1", ID_TYPE_NUM); -add_embedded_arg("y1", ID_TYPE_NUM); -add_embedded_arg("x2", ID_TYPE_NUM); -add_embedded_arg("y2", ID_TYPE_NUM); -add_embedded_arg("x3", ID_TYPE_NUM); -add_embedded_arg("y3", ID_TYPE_NUM); -add_embedded_arg("x4", ID_TYPE_NUM); -add_embedded_arg("y4", ID_TYPE_NUM); -embed_function("PointInTri", ID_TYPE_FN_NUM); -add_embedded_arg("x", ID_TYPE_NUM); -add_embedded_arg("y", ID_TYPE_NUM); -add_embedded_arg("x1", ID_TYPE_NUM); -add_embedded_arg("y1", ID_TYPE_NUM); -add_embedded_arg("x2", ID_TYPE_NUM); -add_embedded_arg("y2", ID_TYPE_NUM); -add_embedded_arg("x3", ID_TYPE_NUM); -add_embedded_arg("y3", ID_TYPE_NUM); -embed_function("Distance2D", ID_TYPE_FN_NUM); -add_embedded_arg("x1", ID_TYPE_NUM); -add_embedded_arg("y1", ID_TYPE_NUM); -add_embedded_arg("x2", ID_TYPE_NUM); -add_embedded_arg("y2", ID_TYPE_NUM); -embed_function("Distance3D", ID_TYPE_FN_NUM); -add_embedded_arg("x1", ID_TYPE_NUM); -add_embedded_arg("y1", ID_TYPE_NUM); -add_embedded_arg("z1", ID_TYPE_NUM); -add_embedded_arg("x2", ID_TYPE_NUM); -add_embedded_arg("y2", ID_TYPE_NUM); -add_embedded_arg("z2", ID_TYPE_NUM); -embed_function("GetCircleLineIntersection", ID_TYPE_FN_NUM); -add_embedded_arg("circle_x", ID_TYPE_NUM); -add_embedded_arg("circle_y", ID_TYPE_NUM); -add_embedded_arg("radius", ID_TYPE_NUM); -add_embedded_arg("x1", ID_TYPE_NUM); -add_embedded_arg("y1", ID_TYPE_NUM); -add_embedded_arg("x2", ID_TYPE_NUM); -add_embedded_arg("y2", ID_TYPE_NUM); -add_embedded_arg("ix1", ID_TYPE_BYREF_NUM); -add_embedded_arg("iy1", ID_TYPE_BYREF_NUM); -add_embedded_arg("ix2", ID_TYPE_BYREF_NUM); -add_embedded_arg("iy2", ID_TYPE_BYREF_NUM); -embed_function("GetLinePlaneIntersection", ID_TYPE_FN_NUM); -add_embedded_arg("line_point", ID_TYPE_BYREF_NUM); -add_embedded_arg("line_direction", ID_TYPE_BYREF_NUM); -add_embedded_arg("plane_point_1", ID_TYPE_BYREF_NUM); -add_embedded_arg("plane_point_2", ID_TYPE_BYREF_NUM); -add_embedded_arg("plane_point_3", ID_TYPE_BYREF_NUM); -add_embedded_arg("intersection", ID_TYPE_BYREF_NUM); -embed_function("IncrementMatrixRows", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("r", ID_TYPE_NUM); -add_embedded_arg("num_rows", ID_TYPE_NUM); -add_embedded_arg("value", ID_TYPE_NUM); -embed_function("IncrementMatrixColumns", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("c", ID_TYPE_NUM); -add_embedded_arg("num_cols", ID_TYPE_NUM); -add_embedded_arg("value", ID_TYPE_NUM); -embed_function("JoinMatrixRows", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("mC", ID_TYPE_NUM); -embed_function("JoinMatrixColumns", ID_TYPE_SUB); -add_embedded_arg("mA", ID_TYPE_NUM); -add_embedded_arg("mB", ID_TYPE_NUM); -add_embedded_arg("mC", ID_TYPE_NUM); +void init_embedded_functions() +{ + embed_function("FPrint", ID_TYPE_SUB); + add_embedded_arg("txt$", ID_TYPE_STR); + embed_function("Input$", ID_TYPE_FN_STR); + add_embedded_arg("prompt$", ID_TYPE_STR); + embed_function("ArrayDim", ID_TYPE_FN_NUM); + add_embedded_arg("id", ID_TYPE_BYREF_NUM); + embed_function("StringArrayDim", ID_TYPE_FN_NUM); + add_embedded_arg("id$", ID_TYPE_BYREF_STR); + embed_function("NumberArrayDim", ID_TYPE_FN_NUM); + add_embedded_arg("id", ID_TYPE_BYREF_NUM); + embed_function("ArraySize", ID_TYPE_FN_NUM); + add_embedded_arg("id", ID_TYPE_BYREF_NUM); + add_embedded_arg("array_dim", ID_TYPE_NUM); + embed_function("StringArraySize", ID_TYPE_FN_NUM); + add_embedded_arg("id$", ID_TYPE_BYREF_STR); + add_embedded_arg("array_dim", ID_TYPE_NUM); + embed_function("NumberArraySize", ID_TYPE_FN_NUM); + add_embedded_arg("id", ID_TYPE_BYREF_NUM); + add_embedded_arg("array_dim", ID_TYPE_NUM); + embed_function("Abs", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("ACos", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("AndBit", ID_TYPE_FN_NUM); + add_embedded_arg("a", ID_TYPE_NUM); + add_embedded_arg("b", ID_TYPE_NUM); + embed_function("ASin", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("ATan", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Bin$", ID_TYPE_FN_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("CInt32", ID_TYPE_FN_NUM); + add_embedded_arg("i", ID_TYPE_NUM); + embed_function("CInt64", ID_TYPE_FN_NUM); + add_embedded_arg("i", ID_TYPE_NUM); + embed_function("Cos", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Degrees", ID_TYPE_FN_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + embed_function("Exp", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Frac", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Hex$", ID_TYPE_FN_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("HexVal", ID_TYPE_FN_NUM); + add_embedded_arg("n$", ID_TYPE_STR); + embed_function("Int", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Log", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Max", ID_TYPE_FN_NUM); + add_embedded_arg("a", ID_TYPE_NUM); + add_embedded_arg("b", ID_TYPE_NUM); + embed_function("Min", ID_TYPE_FN_NUM); + add_embedded_arg("a", ID_TYPE_NUM); + add_embedded_arg("b", ID_TYPE_NUM); + embed_function("OrBit", ID_TYPE_FN_NUM); + add_embedded_arg("a", ID_TYPE_NUM); + add_embedded_arg("b", ID_TYPE_NUM); + embed_function("Radians", ID_TYPE_FN_NUM); + add_embedded_arg("d", ID_TYPE_NUM); + embed_function("Randomize", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Rand", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Round", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Sign", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Sin", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Sqrt", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Tan", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("XOrBit", ID_TYPE_FN_NUM); + add_embedded_arg("a", ID_TYPE_NUM); + add_embedded_arg("b", ID_TYPE_NUM); + embed_function("Asc", ID_TYPE_FN_NUM); + add_embedded_arg("c$", ID_TYPE_STR); + embed_function("Chr$", ID_TYPE_FN_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Insert$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("tgt$", ID_TYPE_STR); + add_embedded_arg("pos", ID_TYPE_NUM); + embed_function("InStr", ID_TYPE_FN_NUM); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("substr$", ID_TYPE_STR); + embed_function("LCase$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + embed_function("Left$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Length", ID_TYPE_FN_NUM); + add_embedded_arg("src$", ID_TYPE_STR); + embed_function("Len", ID_TYPE_FN_NUM); + add_embedded_arg("src$", ID_TYPE_STR); + embed_function("LTrim$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + embed_function("Mid$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("start", ID_TYPE_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("ReplaceSubstr$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("rpc$", ID_TYPE_STR); + add_embedded_arg("pos", ID_TYPE_NUM); + embed_function("Replace$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("tgt$", ID_TYPE_STR); + add_embedded_arg("rpc$", ID_TYPE_STR); + embed_function("Reverse$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + embed_function("Right$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("RTrim$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + embed_function("StringFill$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Str$", ID_TYPE_FN_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Str_F$", ID_TYPE_FN_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Str_S$", ID_TYPE_FN_STR); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Tally", ID_TYPE_FN_NUM); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("substr$", ID_TYPE_STR); + embed_function("Trim$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + embed_function("UCase$", ID_TYPE_FN_STR); + add_embedded_arg("src$", ID_TYPE_STR); + embed_function("Val", ID_TYPE_FN_NUM); + add_embedded_arg("n$", ID_TYPE_STR); + embed_function("Stack_N", ID_TYPE_SUB); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Stack_S", ID_TYPE_SUB); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Push_N", ID_TYPE_SUB); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("Pop_N", ID_TYPE_FN_NUM); + embed_function("Push_S", ID_TYPE_SUB); + add_embedded_arg("s$", ID_TYPE_STR); + embed_function("Pop_S$", ID_TYPE_FN_STR); + embed_function("Stack_Size_N", ID_TYPE_FN_NUM); + embed_function("Stack_Size_S", ID_TYPE_FN_NUM); + embed_function("FileOpen", ID_TYPE_FN_NUM); + add_embedded_arg("stream", ID_TYPE_NUM); + add_embedded_arg("fileName$", ID_TYPE_STR); + add_embedded_arg("mode", ID_TYPE_NUM); + embed_function("FileClose", ID_TYPE_SUB); + add_embedded_arg("stream", ID_TYPE_NUM); + embed_function("ReadByte", ID_TYPE_FN_NUM); + add_embedded_arg("stream", ID_TYPE_NUM); + embed_function("WriteByte", ID_TYPE_SUB); + add_embedded_arg("stream", ID_TYPE_NUM); + add_embedded_arg("byte", ID_TYPE_NUM); + embed_function("ReadLine$", ID_TYPE_FN_STR); + add_embedded_arg("stream", ID_TYPE_NUM); + embed_function("Write", ID_TYPE_SUB); + add_embedded_arg("stream", ID_TYPE_NUM); + add_embedded_arg("txt$", ID_TYPE_STR); + embed_function("WriteLine", ID_TYPE_SUB); + add_embedded_arg("stream", ID_TYPE_NUM); + add_embedded_arg("txt$", ID_TYPE_STR); + embed_function("CopyFile", ID_TYPE_SUB); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("dst$", ID_TYPE_STR); + embed_function("RemoveFile", ID_TYPE_FN_NUM); + add_embedded_arg("fileName$", ID_TYPE_STR); + embed_function("FileExists", ID_TYPE_FN_NUM); + add_embedded_arg("fileName$", ID_TYPE_STR); + embed_function("MoveFile", ID_TYPE_FN_NUM); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("dst$", ID_TYPE_STR); + embed_function("RenameFile", ID_TYPE_FN_NUM); + add_embedded_arg("src$", ID_TYPE_STR); + add_embedded_arg("dst$", ID_TYPE_STR); + embed_function("FileLength", ID_TYPE_FN_NUM); + add_embedded_arg("fileName$", ID_TYPE_STR); + embed_function("Tell", ID_TYPE_FN_NUM); + add_embedded_arg("stream", ID_TYPE_NUM); + embed_function("Seek", ID_TYPE_FN_NUM); + add_embedded_arg("stream", ID_TYPE_NUM); + add_embedded_arg("pos", ID_TYPE_NUM); + embed_function("EOF", ID_TYPE_FN_NUM); + add_embedded_arg("stream", ID_TYPE_NUM); + embed_function("FreeFile", ID_TYPE_FN_NUM); + embed_function("ChangeDir", ID_TYPE_SUB); + add_embedded_arg("p$", ID_TYPE_STR); + embed_function("DirExists", ID_TYPE_FN_NUM); + add_embedded_arg("p$", ID_TYPE_STR); + embed_function("DirFirst$", ID_TYPE_FN_STR); + embed_function("Dir$", ID_TYPE_FN_STR); + embed_function("DirNext$", ID_TYPE_FN_STR); + embed_function("MakeDir", ID_TYPE_FN_NUM); + add_embedded_arg("p$", ID_TYPE_STR); + embed_function("RemoveDir", ID_TYPE_FN_NUM); + add_embedded_arg("p$", ID_TYPE_STR); + embed_function("Date$", ID_TYPE_FN_STR); + embed_function("Easter$", ID_TYPE_FN_STR); + add_embedded_arg("year", ID_TYPE_NUM); + embed_function("Ticks", ID_TYPE_FN_NUM); + embed_function("Time$", ID_TYPE_FN_STR); + embed_function("Timer", ID_TYPE_FN_NUM); + embed_function("Wait", ID_TYPE_SUB); + add_embedded_arg("m_sec", ID_TYPE_NUM); + embed_function("WindowOpen", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("title$", ID_TYPE_STR); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("flag", ID_TYPE_NUM); + add_embedded_arg("vsync", ID_TYPE_NUM); + embed_function("WindowClose", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("RaiseWindow", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("Window", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("Update", ID_TYPE_SUB); + embed_function("Cls", ID_TYPE_SUB); + embed_function("SetClearColor", ID_TYPE_SUB); + add_embedded_arg("c", ID_TYPE_NUM); + embed_function("ShowWindow", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("HideWindow", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("SetWindowTitle", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("title$", ID_TYPE_STR); + embed_function("WindowTitle$", ID_TYPE_FN_STR); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("SetWindowPosition", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("GetWindowPosition", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + embed_function("SetWindowSize", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("GetWindowSize", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("SetWindowMinSize", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("GetWindowMinSize", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("SetWindowMaxSize", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("GetWindowMaxSize", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("WindowIsFullscreen", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowIsVisible", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowIsBordered", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowIsResizable", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowIsMinimized", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowIsMaximized", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowHasInputFocus", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowHasMouseFocus", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("SetWindowFullscreen", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("MaximizeWindow", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("MinimizeWindow", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("SetWindowBorder", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("WindowClip", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("WindowExists", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("NumWindows", ID_TYPE_FN_NUM); + embed_function("WindowEvent_Close", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowEvent_Maximize", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("WindowEvent_Minimize", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("ActiveWindow", ID_TYPE_FN_NUM); + embed_function("FPS", ID_TYPE_FN_NUM); + embed_function("SetWindowIcon", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("CanvasOpen", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("viewport_x", ID_TYPE_NUM); + add_embedded_arg("viewport_y", ID_TYPE_NUM); + add_embedded_arg("viewport_w", ID_TYPE_NUM); + add_embedded_arg("viewport_h", ID_TYPE_NUM); + add_embedded_arg("mode", ID_TYPE_NUM); + embed_function("CanvasClose", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + embed_function("SetCanvasVisible", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("CanvasIsVisible", ID_TYPE_FN_NUM); + add_embedded_arg("c_num", ID_TYPE_NUM); + embed_function("SetCanvasViewport", ID_TYPE_SUB); + add_embedded_arg("cnum", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("GetCanvasViewport", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("Canvas", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + embed_function("SetCanvasOffset", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("GetCanvasOffset", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + embed_function("GetCanvasSize", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("ClearCanvas", ID_TYPE_SUB); + embed_function("SetCanvasAlpha", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("a", ID_TYPE_NUM); + embed_function("CanvasAlpha", ID_TYPE_FN_NUM); + add_embedded_arg("c_num", ID_TYPE_NUM); + embed_function("SetCanvasBlendMode", ID_TYPE_FN_NUM); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("blend_mode", ID_TYPE_NUM); + embed_function("CanvasBlendMode", ID_TYPE_FN_NUM); + add_embedded_arg("c_num", ID_TYPE_NUM); + embed_function("SetCanvasColorMod", ID_TYPE_FN_NUM); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + embed_function("CanvasColorMod", ID_TYPE_FN_NUM); + add_embedded_arg("c_num", ID_TYPE_NUM); + embed_function("CopyCanvas", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("dst", ID_TYPE_NUM); + add_embedded_arg("dx", ID_TYPE_NUM); + add_embedded_arg("dy", ID_TYPE_NUM); + embed_function("CloneCanvas", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_NUM); + add_embedded_arg("dst", ID_TYPE_NUM); + embed_function("SetCanvasZ", ID_TYPE_SUB); + add_embedded_arg("c_num", ID_TYPE_NUM); + add_embedded_arg("z", ID_TYPE_NUM); + embed_function("CanvasZ", ID_TYPE_FN_NUM); + add_embedded_arg("c_num", ID_TYPE_NUM); + embed_function("CanvasClip", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("ActiveCanvas", ID_TYPE_FN_NUM); + embed_function("Box", ID_TYPE_SUB); + add_embedded_arg("x1", ID_TYPE_NUM); + add_embedded_arg("y1", ID_TYPE_NUM); + add_embedded_arg("x2", ID_TYPE_NUM); + add_embedded_arg("y2", ID_TYPE_NUM); + embed_function("BoxFill", ID_TYPE_SUB); + add_embedded_arg("x1", ID_TYPE_NUM); + add_embedded_arg("y1", ID_TYPE_NUM); + add_embedded_arg("x2", ID_TYPE_NUM); + add_embedded_arg("y2", ID_TYPE_NUM); + embed_function("Circle", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("radius", ID_TYPE_NUM); + embed_function("CircleFill", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("radius", ID_TYPE_NUM); + embed_function("Ellipse", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("rx", ID_TYPE_NUM); + add_embedded_arg("ry", ID_TYPE_NUM); + embed_function("EllipseFill", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("rx", ID_TYPE_NUM); + add_embedded_arg("ry", ID_TYPE_NUM); + embed_function("FloodFill", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("GetPixel", ID_TYPE_FN_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("SetColor", ID_TYPE_SUB); + add_embedded_arg("c", ID_TYPE_NUM); + embed_function("Line", ID_TYPE_SUB); + add_embedded_arg("x1", ID_TYPE_NUM); + add_embedded_arg("y1", ID_TYPE_NUM); + add_embedded_arg("x2", ID_TYPE_NUM); + add_embedded_arg("y2", ID_TYPE_NUM); + embed_function("Poly", ID_TYPE_SUB); + add_embedded_arg("n", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + embed_function("PolyFill", ID_TYPE_SUB); + add_embedded_arg("n", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + embed_function("Rect", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("RectFill", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("RoundRect", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + embed_function("RoundRectFill", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + embed_function("RGB", ID_TYPE_FN_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("g", ID_TYPE_NUM); + add_embedded_arg("b", ID_TYPE_NUM); + embed_function("RGBA", ID_TYPE_FN_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("g", ID_TYPE_NUM); + add_embedded_arg("b", ID_TYPE_NUM); + add_embedded_arg("a", ID_TYPE_NUM); + embed_function("PSet", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("LoadImage", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("img$", ID_TYPE_STR); + embed_function("LoadImage_Ex", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("img$", ID_TYPE_STR); + add_embedded_arg("colkey", ID_TYPE_NUM); + embed_function("ImageFromBuffer", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); + embed_function("ImageFromBuffer_Ex", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); + add_embedded_arg("colkey", ID_TYPE_NUM); + embed_function("BufferFromImage", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); + embed_function("ImageExists", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("ColorKey", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + embed_function("CopyImage", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_NUM); + add_embedded_arg("dst", ID_TYPE_NUM); + embed_function("DeleteImage", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("SetImageAlpha", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("a", ID_TYPE_NUM); + embed_function("ImageAlpha", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("GetImageSize", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("SetImageBlendMode", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("blend_mode", ID_TYPE_NUM); + embed_function("ImageBlendMode", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("SetImageColorMod", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + embed_function("ImageColorMod", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("DrawImage", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("DrawImage_Blit", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("src_x", ID_TYPE_NUM); + add_embedded_arg("src_y", ID_TYPE_NUM); + add_embedded_arg("src_w", ID_TYPE_NUM); + add_embedded_arg("src_h", ID_TYPE_NUM); + embed_function("DrawImage_Blit_Ex", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("src_x", ID_TYPE_NUM); + add_embedded_arg("src_y", ID_TYPE_NUM); + add_embedded_arg("src_w", ID_TYPE_NUM); + add_embedded_arg("src_h", ID_TYPE_NUM); + embed_function("DrawImage_Rotate", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("angle", ID_TYPE_NUM); + embed_function("DrawImage_Rotate_Ex", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("src_x", ID_TYPE_NUM); + add_embedded_arg("src_y", ID_TYPE_NUM); + add_embedded_arg("src_w", ID_TYPE_NUM); + add_embedded_arg("src_h", ID_TYPE_NUM); + add_embedded_arg("angle", ID_TYPE_NUM); + embed_function("DrawImage_Zoom", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("zx", ID_TYPE_NUM); + add_embedded_arg("zy", ID_TYPE_NUM); + embed_function("DrawImage_Zoom_Ex", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("src_x", ID_TYPE_NUM); + add_embedded_arg("src_y", ID_TYPE_NUM); + add_embedded_arg("src_w", ID_TYPE_NUM); + add_embedded_arg("src_h", ID_TYPE_NUM); + add_embedded_arg("zx", ID_TYPE_NUM); + add_embedded_arg("zy", ID_TYPE_NUM); + embed_function("DrawImage_Rotozoom", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("angle", ID_TYPE_NUM); + add_embedded_arg("zx", ID_TYPE_NUM); + add_embedded_arg("zy", ID_TYPE_NUM); + embed_function("DrawImage_Rotozoom_Ex", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("src_x", ID_TYPE_NUM); + add_embedded_arg("src_y", ID_TYPE_NUM); + add_embedded_arg("src_w", ID_TYPE_NUM); + add_embedded_arg("src_h", ID_TYPE_NUM); + add_embedded_arg("angle", ID_TYPE_NUM); + add_embedded_arg("zx", ID_TYPE_NUM); + add_embedded_arg("zy", ID_TYPE_NUM); + embed_function("DrawImage_Flip", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("v", ID_TYPE_NUM); + embed_function("DrawImage_Flip_Ex", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("src_x", ID_TYPE_NUM); + add_embedded_arg("src_y", ID_TYPE_NUM); + add_embedded_arg("src_w", ID_TYPE_NUM); + add_embedded_arg("src_h", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("v", ID_TYPE_NUM); + embed_function("InKey", ID_TYPE_FN_NUM); + embed_function("Key", ID_TYPE_FN_NUM); + add_embedded_arg("key_code", ID_TYPE_NUM); + embed_function("WaitKey", ID_TYPE_FN_NUM); + embed_function("HideMouse", ID_TYPE_SUB); + embed_function("ShowMouse", ID_TYPE_SUB); + embed_function("MouseIsVisible", ID_TYPE_FN_NUM); + embed_function("GetMouse", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("mb1", ID_TYPE_BYREF_NUM); + add_embedded_arg("mb2", ID_TYPE_BYREF_NUM); + add_embedded_arg("mb3", ID_TYPE_BYREF_NUM); + embed_function("MouseX", ID_TYPE_FN_NUM); + embed_function("MouseY", ID_TYPE_FN_NUM); + embed_function("MouseButton", ID_TYPE_FN_NUM); + add_embedded_arg("mb", ID_TYPE_NUM); + embed_function("GetMouseWheel", ID_TYPE_SUB); + add_embedded_arg("x_axis", ID_TYPE_BYREF_NUM); + add_embedded_arg("y_axis", ID_TYPE_BYREF_NUM); + embed_function("MouseWheelX", ID_TYPE_FN_NUM); + embed_function("MouseWheelY", ID_TYPE_FN_NUM); + embed_function("SoundFromBuffer", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); + add_embedded_arg("buffer_size", ID_TYPE_NUM); + add_embedded_arg("vol", ID_TYPE_NUM); + embed_function("LoadSound", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("snd_file$", ID_TYPE_STR); + embed_function("LoadMusic", ID_TYPE_SUB); + add_embedded_arg("music_file$", ID_TYPE_STR); + embed_function("PlaySound", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("channel", ID_TYPE_NUM); + add_embedded_arg("loops", ID_TYPE_NUM); + embed_function("PlaySoundTimed", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("channel", ID_TYPE_NUM); + add_embedded_arg("loops", ID_TYPE_NUM); + add_embedded_arg("ms", ID_TYPE_NUM); + embed_function("PlayMusic", ID_TYPE_SUB); + add_embedded_arg("mLoops", ID_TYPE_NUM); + embed_function("PauseSound", ID_TYPE_SUB); + add_embedded_arg("channel", ID_TYPE_NUM); + embed_function("ResumeSound", ID_TYPE_SUB); + add_embedded_arg("channel", ID_TYPE_NUM); + embed_function("PauseMusic", ID_TYPE_SUB); + embed_function("ResumeMusic", ID_TYPE_SUB); + embed_function("DeleteSound", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("DeleteMusic", ID_TYPE_SUB); + embed_function("FadeMusicIn", ID_TYPE_SUB); + add_embedded_arg("fade_time", ID_TYPE_NUM); + add_embedded_arg("loops", ID_TYPE_NUM); + embed_function("FadeMusicOut", ID_TYPE_SUB); + add_embedded_arg("fade_time", ID_TYPE_NUM); + embed_function("MusicExists", ID_TYPE_FN_NUM); + embed_function("SetMusicVolume", ID_TYPE_SUB); + add_embedded_arg("vol", ID_TYPE_NUM); + embed_function("MusicVolume", ID_TYPE_FN_NUM); + embed_function("SetMusicPosition", ID_TYPE_SUB); + add_embedded_arg("pos", ID_TYPE_NUM); + embed_function("MusicPosition", ID_TYPE_FN_NUM); + embed_function("RewindMusic", ID_TYPE_SUB); + embed_function("SetSoundChannels", ID_TYPE_SUB); + add_embedded_arg("max_channels", ID_TYPE_NUM); + embed_function("NumSoundChannels", ID_TYPE_FN_NUM); + embed_function("SoundIsEnabled", ID_TYPE_FN_NUM); + embed_function("SoundExists", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("SetChannelVolume", ID_TYPE_SUB); + add_embedded_arg("channel", ID_TYPE_NUM); + add_embedded_arg("vol", ID_TYPE_NUM); + embed_function("ChannelVolume", ID_TYPE_FN_NUM); + add_embedded_arg("channel", ID_TYPE_NUM); + embed_function("SetSoundVolume", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("vol", ID_TYPE_NUM); + embed_function("SoundVolume", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("StopMusic", ID_TYPE_SUB); + embed_function("StopSound", ID_TYPE_SUB); + add_embedded_arg("channel", ID_TYPE_NUM); + embed_function("SetChannelPanning", ID_TYPE_FN_NUM); + add_embedded_arg("channel", ID_TYPE_NUM); + add_embedded_arg("left_value", ID_TYPE_NUM); + add_embedded_arg("right_value", ID_TYPE_NUM); + embed_function("SetChannelDistance", ID_TYPE_FN_NUM); + add_embedded_arg("channel", ID_TYPE_NUM); + add_embedded_arg("dist_value", ID_TYPE_NUM); + embed_function("ChannelIsPlaying", ID_TYPE_FN_NUM); + add_embedded_arg("channel", ID_TYPE_NUM); + embed_function("ChannelIsPaused", ID_TYPE_FN_NUM); + add_embedded_arg("channel", ID_TYPE_NUM); + embed_function("NumJoysticks", ID_TYPE_FN_NUM); + embed_function("NumJoyAxes", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + embed_function("NumJoyButtons", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + embed_function("NumJoyHats", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + embed_function("NumJoyTrackBalls", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + embed_function("JoyAxis", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + add_embedded_arg("joy_axis", ID_TYPE_NUM); + embed_function("JoyButton", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + add_embedded_arg("joy_button", ID_TYPE_NUM); + embed_function("JoyHat", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + add_embedded_arg("joy_hat", ID_TYPE_NUM); + embed_function("GetJoyTrackBall", ID_TYPE_SUB); + add_embedded_arg("joy_num", ID_TYPE_NUM); + add_embedded_arg("ball", ID_TYPE_NUM); + add_embedded_arg("dx", ID_TYPE_BYREF_NUM); + add_embedded_arg("dy", ID_TYPE_BYREF_NUM); + embed_function("JoyName$", ID_TYPE_FN_STR); + add_embedded_arg("joy_num", ID_TYPE_NUM); + embed_function("JoystickIsConnected", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + embed_function("GetCursor", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + embed_function("PrintS", ID_TYPE_SUB); + add_embedded_arg("txt$", ID_TYPE_STR); + embed_function("InputS$", ID_TYPE_FN_STR); + add_embedded_arg("prompt$", ID_TYPE_STR); + embed_function("ZoneInputS$", ID_TYPE_FN_STR); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("Locate", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("ReadInput_Start", ID_TYPE_SUB); + embed_function("ReadInput_Stop", ID_TYPE_SUB); + embed_function("ReadInput_Text$", ID_TYPE_FN_STR); + embed_function("ReadInput_SetText", ID_TYPE_SUB); + add_embedded_arg("txt$", ID_TYPE_STR); + embed_function("ReadInput_ToggleBackspace", ID_TYPE_SUB); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("LoadFont", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("fnt_file$", ID_TYPE_STR); + add_embedded_arg("size", ID_TYPE_NUM); + embed_function("DeleteFont", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("FontIsLoaded", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("Font", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + embed_function("SetFontStyle", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("style", ID_TYPE_NUM); + embed_function("DrawText", ID_TYPE_SUB); + add_embedded_arg("txt$", ID_TYPE_STR); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("DrawText_Shaded", ID_TYPE_SUB); + add_embedded_arg("txt$", ID_TYPE_STR); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("fg_color", ID_TYPE_NUM); + add_embedded_arg("bg_color", ID_TYPE_NUM); + embed_function("DrawText_Blended", ID_TYPE_SUB); + add_embedded_arg("txt$", ID_TYPE_STR); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("RenderText", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("txt$", ID_TYPE_STR); + embed_function("GetTextSize", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("txt$", ID_TYPE_STR); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("TouchPressure", ID_TYPE_FN_NUM); + embed_function("GetTouch", ID_TYPE_SUB); + add_embedded_arg("status", ID_TYPE_BYREF_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("dx", ID_TYPE_BYREF_NUM); + add_embedded_arg("dy", ID_TYPE_BYREF_NUM); + embed_function("GetMultiTouch", ID_TYPE_SUB); + add_embedded_arg("status", ID_TYPE_BYREF_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("fingers", ID_TYPE_BYREF_NUM); + add_embedded_arg("dist", ID_TYPE_BYREF_NUM); + add_embedded_arg("theta", ID_TYPE_BYREF_NUM); + embed_function("GetTouchFinger", ID_TYPE_SUB); + add_embedded_arg("finger", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("pressure", ID_TYPE_BYREF_NUM); + embed_function("NumFingers", ID_TYPE_FN_NUM); + embed_function("CheckSockets", ID_TYPE_FN_NUM); + add_embedded_arg("timeout_ms", ID_TYPE_NUM); + embed_function("TCP_SocketReady", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + embed_function("UDP_SocketReady", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + embed_function("TCP_SocketOpen", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + add_embedded_arg("host$", ID_TYPE_STR); + add_embedded_arg("port", ID_TYPE_NUM); + embed_function("TCP_SocketClose", ID_TYPE_SUB); + add_embedded_arg("socket", ID_TYPE_NUM); + embed_function("TCP_RemoteHost", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + embed_function("TCP_RemotePort", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + embed_function("TCP_GetData", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + add_embedded_arg("sData$", ID_TYPE_BYREF_STR); + add_embedded_arg("numBytes", ID_TYPE_NUM); + embed_function("TCP_SendData", ID_TYPE_SUB); + add_embedded_arg("socket", ID_TYPE_NUM); + add_embedded_arg("sData$", ID_TYPE_STR); + embed_function("TCP_AcceptSocket", ID_TYPE_FN_NUM); + add_embedded_arg("server", ID_TYPE_NUM); + add_embedded_arg("client", ID_TYPE_NUM); + embed_function("UDP_SocketOpen", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + add_embedded_arg("port", ID_TYPE_NUM); + embed_function("UDP_SocketClose", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + embed_function("UDP_GetData", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + add_embedded_arg("sData$", ID_TYPE_BYREF_STR); + add_embedded_arg("host$", ID_TYPE_BYREF_STR); + add_embedded_arg("port", ID_TYPE_BYREF_NUM); + embed_function("UDP_Length", ID_TYPE_FN_NUM); + embed_function("UDP_MaxLength", ID_TYPE_FN_NUM); + embed_function("UDP_RemoteHost$", ID_TYPE_FN_STR); + add_embedded_arg("socket", ID_TYPE_NUM); + embed_function("UDP_RemotePort", ID_TYPE_FN_NUM); + add_embedded_arg("socket", ID_TYPE_NUM); + embed_function("UDP_SendData", ID_TYPE_SUB); + add_embedded_arg("socket", ID_TYPE_NUM); + add_embedded_arg("sData$", ID_TYPE_STR); + add_embedded_arg("host$", ID_TYPE_STR); + add_embedded_arg("port", ID_TYPE_NUM); + embed_function("LoadVideo", ID_TYPE_SUB); + add_embedded_arg("vid$", ID_TYPE_STR); + embed_function("PlayVideo", ID_TYPE_SUB); + add_embedded_arg("vLoops", ID_TYPE_NUM); + embed_function("PauseVideo", ID_TYPE_SUB); + embed_function("StopVideo", ID_TYPE_SUB); + embed_function("SetVideoPosition", ID_TYPE_SUB); + add_embedded_arg("pos", ID_TYPE_NUM); + embed_function("ResumeVideo", ID_TYPE_SUB); + embed_function("VideoPosition", ID_TYPE_FN_NUM); + embed_function("DeleteVideo", ID_TYPE_SUB); + embed_function("VideoIsPlaying", ID_TYPE_FN_NUM); + embed_function("VideoEnd", ID_TYPE_FN_NUM); + embed_function("GetVideoStats", ID_TYPE_SUB); + add_embedded_arg("vFile$", ID_TYPE_STR); + add_embedded_arg("vLen", ID_TYPE_BYREF_NUM); + add_embedded_arg("vfps", ID_TYPE_BYREF_NUM); + add_embedded_arg("frame_w", ID_TYPE_BYREF_NUM); + add_embedded_arg("frame_h", ID_TYPE_BYREF_NUM); + embed_function("SetVideoDrawRect", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("GetVideoDrawRect", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("GetVideoSize", ID_TYPE_SUB); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + embed_function("VideoExists", ID_TYPE_FN_NUM); + embed_function("SetVideoAlpha", ID_TYPE_SUB); + add_embedded_arg("a", ID_TYPE_NUM); + embed_function("System", ID_TYPE_FN_NUM); + add_embedded_arg("cmd$", ID_TYPE_STR); + embed_function("OS$", ID_TYPE_FN_STR); + embed_function("Command$", ID_TYPE_FN_STR); + add_embedded_arg("arg", ID_TYPE_NUM); + embed_function("NumCommands", ID_TYPE_FN_NUM); + embed_function("Env$", ID_TYPE_FN_STR); + add_embedded_arg("v$", ID_TYPE_STR); + embed_function("SetEnv", ID_TYPE_SUB); + add_embedded_arg("var$", ID_TYPE_STR); + add_embedded_arg("value$", ID_TYPE_STR); + add_embedded_arg("overwrite", ID_TYPE_NUM); + embed_function("PrefPath$", ID_TYPE_FN_STR); + add_embedded_arg("org_name$", ID_TYPE_STR); + add_embedded_arg("app_name$", ID_TYPE_STR); + embed_function("Android_GetExternalStoragePath$", ID_TYPE_FN_STR); + embed_function("Android_GetExternalStorageState", ID_TYPE_FN_NUM); + embed_function("Android_GetInternalStoragePath$", ID_TYPE_FN_STR); + embed_function("Android_JNI_Message$", ID_TYPE_FN_STR); + add_embedded_arg("arg$", ID_TYPE_STR); + embed_function("Runtime_Utility_Message$", ID_TYPE_FN_STR); + add_embedded_arg("arg$", ID_TYPE_STR); + embed_function("ClipboardText$", ID_TYPE_FN_STR); + embed_function("SetClipboardText", ID_TYPE_SUB); + add_embedded_arg("txt$", ID_TYPE_STR); + embed_function("HasClipboardText", ID_TYPE_FN_NUM); + embed_function("GetDesktopDisplayMode", ID_TYPE_SUB); + add_embedded_arg("index", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_BYREF_NUM); + add_embedded_arg("h", ID_TYPE_BYREF_NUM); + add_embedded_arg("freq", ID_TYPE_BYREF_NUM); + embed_function("DrawImage_Transform", ID_TYPE_SUB); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + add_embedded_arg("src_x", ID_TYPE_NUM); + add_embedded_arg("src_y", ID_TYPE_NUM); + add_embedded_arg("src_w", ID_TYPE_NUM); + add_embedded_arg("src_h", ID_TYPE_NUM); + add_embedded_arg("angle", ID_TYPE_NUM); + add_embedded_arg("center_x", ID_TYPE_NUM); + add_embedded_arg("center_y", ID_TYPE_NUM); + add_embedded_arg("flip_h", ID_TYPE_NUM); + add_embedded_arg("flip_v", ID_TYPE_NUM); + embed_function("GetPowerInfo", ID_TYPE_SUB); + add_embedded_arg("status", ID_TYPE_BYREF_NUM); + add_embedded_arg("secs", ID_TYPE_BYREF_NUM); + add_embedded_arg("pct", ID_TYPE_BYREF_NUM); + embed_function("SystemRam", ID_TYPE_FN_NUM); + embed_function("SetRenderScaleQuality", ID_TYPE_FN_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("EvalJS$", ID_TYPE_FN_STR); + add_embedded_arg("js_code$", ID_TYPE_STR); + embed_function("GetRenderScaleQuality", ID_TYPE_FN_NUM); + embed_function("GetGlobalMouse", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("mb1", ID_TYPE_BYREF_NUM); + add_embedded_arg("mb2", ID_TYPE_BYREF_NUM); + add_embedded_arg("mb3", ID_TYPE_BYREF_NUM); + embed_function("GlobalMouseX", ID_TYPE_FN_NUM); + embed_function("GlobalMouseY", ID_TYPE_FN_NUM); + embed_function("GetAccel", ID_TYPE_SUB); + add_embedded_arg("accel_num", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("z", ID_TYPE_BYREF_NUM); + embed_function("AccelName$", ID_TYPE_FN_STR); + add_embedded_arg("accel_num", ID_TYPE_NUM); + embed_function("NumAccels", ID_TYPE_FN_NUM); + embed_function("GetGyro", ID_TYPE_SUB); + add_embedded_arg("gyro_num", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_BYREF_NUM); + add_embedded_arg("y", ID_TYPE_BYREF_NUM); + add_embedded_arg("z", ID_TYPE_BYREF_NUM); + embed_function("GyroName$", ID_TYPE_FN_STR); + add_embedded_arg("gyro_num", ID_TYPE_NUM); + embed_function("NumGyros", ID_TYPE_FN_NUM); + embed_function("JoyRumblePlay", ID_TYPE_SUB); + add_embedded_arg("joy_num", ID_TYPE_NUM); + add_embedded_arg("strength", ID_TYPE_NUM); + add_embedded_arg("duration", ID_TYPE_NUM); + embed_function("JoyRumbleStop", ID_TYPE_SUB); + add_embedded_arg("joy_num", ID_TYPE_NUM); + embed_function("JoystickIsHaptic", ID_TYPE_FN_NUM); + add_embedded_arg("joy_num", ID_TYPE_NUM); + embed_function("WriteByteBuffer", ID_TYPE_FN_NUM); + add_embedded_arg("stream", ID_TYPE_NUM); + add_embedded_arg("buf", ID_TYPE_BYREF_NUM); + add_embedded_arg("buf_size", ID_TYPE_NUM); + embed_function("ReadByteBuffer", ID_TYPE_FN_NUM); + add_embedded_arg("stream", ID_TYPE_NUM); + add_embedded_arg("buf", ID_TYPE_BYREF_NUM); + add_embedded_arg("buf_size", ID_TYPE_NUM); + embed_function("WindowEvent_Resize", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("SetWindowAutoClose", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("exit_on_close", ID_TYPE_NUM); + embed_function("SetWindowResizable", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("SystemReturnStdOut$", ID_TYPE_FN_STR); + add_embedded_arg("cmd$", ID_TYPE_STR); + embed_function("WindowMode", ID_TYPE_FN_NUM); + add_embedded_arg("visible", ID_TYPE_NUM); + add_embedded_arg("fullscreen", ID_TYPE_NUM); + add_embedded_arg("resizable", ID_TYPE_NUM); + add_embedded_arg("borderless", ID_TYPE_NUM); + add_embedded_arg("highDPI", ID_TYPE_NUM); + embed_function("WindowFlags", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("RestoreWindow", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("UpdateAllWindows", ID_TYPE_SUB); + embed_function("QueryAudioSpec", ID_TYPE_FN_NUM); + add_embedded_arg("freq", ID_TYPE_BYREF_NUM); + add_embedded_arg("format", ID_TYPE_BYREF_NUM); + add_embedded_arg("channels", ID_TYPE_BYREF_NUM); + embed_function("MusicIsPlaying", ID_TYPE_FN_NUM); + embed_function("DrawGeometry", ID_TYPE_FN_NUM); + add_embedded_arg("slot", ID_TYPE_NUM); + add_embedded_arg("num_vertices", ID_TYPE_NUM); + add_embedded_arg("vertices", ID_TYPE_BYREF_NUM); + add_embedded_arg("num_indices", ID_TYPE_NUM); + add_embedded_arg("Indices", ID_TYPE_BYREF_NUM); + embed_function("Size", ID_TYPE_FN_NUM); + add_embedded_arg("s$", ID_TYPE_STR); + embed_function("BufferFromString", ID_TYPE_FN_NUM); + add_embedded_arg("s$", ID_TYPE_STR); + add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); + embed_function("StringFromBuffer$", ID_TYPE_FN_STR); + add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); + add_embedded_arg("buffer_size", ID_TYPE_NUM); + embed_function("GrabInput", ID_TYPE_SUB); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("GrabbedWindow", ID_TYPE_FN_NUM); + embed_function("WarpMouse", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("WarpMouseGlobal", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + embed_function("SetMouseZone", ID_TYPE_SUB); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("w", ID_TYPE_NUM); + add_embedded_arg("h", ID_TYPE_NUM); + embed_function("ClearMouseZone", ID_TYPE_SUB); + embed_function("SetWindowAlwaysOnTop", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("SetMouseRelative", ID_TYPE_SUB); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("SetWindowVSync", ID_TYPE_SUB); + add_embedded_arg("win", ID_TYPE_NUM); + add_embedded_arg("flag", ID_TYPE_NUM); + embed_function("OpenURL", ID_TYPE_FN_NUM); + add_embedded_arg("url$", ID_TYPE_STR); + embed_function("APIVersion$", ID_TYPE_FN_STR); + embed_function("FlashWindow", ID_TYPE_FN_NUM); + add_embedded_arg("win", ID_TYPE_NUM); + embed_function("MessageBox", ID_TYPE_FN_NUM); + add_embedded_arg("title$", ID_TYPE_STR); + add_embedded_arg("msg$", ID_TYPE_STR); + embed_function("NumberArrayCopy", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_BYREF_NUM); + add_embedded_arg("dst", ID_TYPE_BYREF_NUM); + embed_function("StringArrayCopy", ID_TYPE_SUB); + add_embedded_arg("src$", ID_TYPE_BYREF_STR); + add_embedded_arg("dst$", ID_TYPE_BYREF_STR); + embed_function("ArrayCopy", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_BYREF_NUM); + add_embedded_arg("dst", ID_TYPE_BYREF_NUM); + embed_function("NumberArrayFill", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_BYREF_NUM); + add_embedded_arg("fdata", ID_TYPE_NUM); + embed_function("StringArrayFill", ID_TYPE_SUB); + add_embedded_arg("src$", ID_TYPE_BYREF_STR); + add_embedded_arg("fdata$", ID_TYPE_STR); + embed_function("ArrayFill", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_BYREF_NUM); + add_embedded_arg("fdata", ID_TYPE_NUM); + embed_function("Runtime$", ID_TYPE_FN_STR); + embed_function("DimMatrix", ID_TYPE_SUB); + add_embedded_arg("m", ID_TYPE_NUM); + add_embedded_arg("m_rows", ID_TYPE_NUM); + add_embedded_arg("m_cols", ID_TYPE_NUM); + add_embedded_arg("preserve_flag", ID_TYPE_NUM); + embed_function("AddMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("mC", ID_TYPE_NUM); + embed_function("AugmentMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("mC", ID_TYPE_NUM); + embed_function("CopyMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + embed_function("InsertMatrixColumns", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("num_cols", ID_TYPE_NUM); + embed_function("InsertMatrixRows", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("num_rows", ID_TYPE_NUM); + embed_function("MultiplyMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("mC", ID_TYPE_NUM); + embed_function("CubeMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + embed_function("DeleteMatrixColumns", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("num_cols", ID_TYPE_NUM); + embed_function("DeleteMatrixRows", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("num_rows", ID_TYPE_NUM); + embed_function("ClearMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + embed_function("ClearMatrixColumns", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("num_cols", ID_TYPE_NUM); + embed_function("ClearMatrixRows", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("num_rows", ID_TYPE_NUM); + embed_function("FillMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("v", ID_TYPE_NUM); + embed_function("FillMatrixColumns", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("num_cols", ID_TYPE_NUM); + add_embedded_arg("v", ID_TYPE_NUM); + embed_function("FillMatrixRows", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("num_rows", ID_TYPE_NUM); + add_embedded_arg("v", ID_TYPE_NUM); + embed_function("CopyMatrixColumns", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("num_cols", ID_TYPE_NUM); + embed_function("CopyMatrixRows", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("num_rows", ID_TYPE_NUM); + embed_function("IdentityMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("n", ID_TYPE_NUM); + embed_function("SolveMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("mC", ID_TYPE_NUM); + embed_function("IsEqualMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("tolerance", ID_TYPE_NUM); + embed_function("Determinant", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + embed_function("AdjointMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + embed_function("InvertMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + embed_function("MatrixFromBuffer", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); + embed_function("GetMatrix", ID_TYPE_SUB); + add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + embed_function("RandomizeMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("vmin", ID_TYPE_NUM); + add_embedded_arg("vmax", ID_TYPE_NUM); + embed_function("MatrixValue", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + embed_function("SetMatrixValue", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("v", ID_TYPE_NUM); + embed_function("ScalarMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("s_value", ID_TYPE_NUM); + embed_function("ScalarMatrixColumns", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("num_cols", ID_TYPE_NUM); + add_embedded_arg("s_value", ID_TYPE_NUM); + embed_function("ScalarMatrixRows", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("num_rows", ID_TYPE_NUM); + add_embedded_arg("s_value", ID_TYPE_NUM); + embed_function("SquareMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + embed_function("SubMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + embed_function("SubtractMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("mC", ID_TYPE_NUM); + embed_function("SwapMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + embed_function("SwapMatrixColumn", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("C1", ID_TYPE_NUM); + add_embedded_arg("C2", ID_TYPE_NUM); + embed_function("SwapMatrixRow", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("R1", ID_TYPE_NUM); + add_embedded_arg("R2", ID_TYPE_NUM); + embed_function("TransposeMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + embed_function("UnAugmentMatrix", ID_TYPE_FN_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("mC", ID_TYPE_NUM); + embed_function("ZeroMatrix", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + embed_function("GetMatrixSize", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_BYREF_NUM); + add_embedded_arg("c", ID_TYPE_BYREF_NUM); + embed_function("SetMatrixProcess", ID_TYPE_FN_NUM); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessOpen", ID_TYPE_FN_NUM); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("SetProcessErrorMode", ID_TYPE_SUB); + add_embedded_arg("p_num", ID_TYPE_NUM); + add_embedded_arg("error_mode", ID_TYPE_NUM); + embed_function("ProcessError", ID_TYPE_FN_NUM); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessWait", ID_TYPE_SUB); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessWaitAll", ID_TYPE_SUB); + embed_function("ProcessContinue", ID_TYPE_SUB); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessStop", ID_TYPE_SUB); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessClear", ID_TYPE_SUB); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessClose", ID_TYPE_FN_NUM); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessErrorMode", ID_TYPE_FN_NUM); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessSleep", ID_TYPE_SUB); + add_embedded_arg("p_num", ID_TYPE_NUM); + add_embedded_arg("msec", ID_TYPE_NUM); + embed_function("ProcessExists", ID_TYPE_FN_NUM); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("ProcessStopAll", ID_TYPE_SUB); + embed_function("ProcessContinueAll", ID_TYPE_SUB); + embed_function("ProcessQueueSize", ID_TYPE_FN_NUM); + add_embedded_arg("p_num", ID_TYPE_NUM); + embed_function("NumCPUs", ID_TYPE_FN_NUM); + embed_function("GetProjectionGeometry", ID_TYPE_SUB); + add_embedded_arg("cam_dist", ID_TYPE_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("f_vertex_count", ID_TYPE_NUM); + add_embedded_arg("columns", ID_TYPE_BYREF_NUM); + add_embedded_arg("uv", ID_TYPE_BYREF_NUM); + add_embedded_arg("graph_offset_x", ID_TYPE_NUM); + add_embedded_arg("graph_offset_y", ID_TYPE_NUM); + add_embedded_arg("v_color", ID_TYPE_NUM); + add_embedded_arg("vertex_count", ID_TYPE_BYREF_NUM); + add_embedded_arg("vertex2D", ID_TYPE_BYREF_NUM); + add_embedded_arg("index_count", ID_TYPE_BYREF_NUM); + add_embedded_arg("index", ID_TYPE_BYREF_NUM); + add_embedded_arg("clip_dist", ID_TYPE_BYREF_NUM); + add_embedded_arg("min_x", ID_TYPE_BYREF_NUM); + add_embedded_arg("min_y", ID_TYPE_BYREF_NUM); + add_embedded_arg("max_x", ID_TYPE_BYREF_NUM); + add_embedded_arg("max_y", ID_TYPE_BYREF_NUM); + embed_function("CalculateFaceZ", ID_TYPE_FN_NUM); + add_embedded_arg("cam_dist", ID_TYPE_NUM); + add_embedded_arg("graph_offset_x", ID_TYPE_NUM); + add_embedded_arg("graph_offset_y", ID_TYPE_NUM); + add_embedded_arg("view_w", ID_TYPE_NUM); + add_embedded_arg("view_h", ID_TYPE_NUM); + add_embedded_arg("view_depth", ID_TYPE_NUM); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("f_vertex_count", ID_TYPE_NUM); + add_embedded_arg("columns", ID_TYPE_BYREF_NUM); + add_embedded_arg("face_min_z", ID_TYPE_BYREF_NUM); + add_embedded_arg("face_max_z", ID_TYPE_BYREF_NUM); + add_embedded_arg("z_avg", ID_TYPE_BYREF_NUM); + embed_function("SetChannelSpacePosition", ID_TYPE_FN_NUM); + add_embedded_arg("channel", ID_TYPE_NUM); + add_embedded_arg("angle", ID_TYPE_NUM); + add_embedded_arg("distance", ID_TYPE_NUM); + embed_function("SaveBMP", ID_TYPE_FN_NUM); + add_embedded_arg("img", ID_TYPE_NUM); + add_embedded_arg("file$", ID_TYPE_STR); + embed_function("SavePNG", ID_TYPE_FN_NUM); + add_embedded_arg("img", ID_TYPE_NUM); + add_embedded_arg("file$", ID_TYPE_STR); + embed_function("SaveJPG", ID_TYPE_FN_NUM); + add_embedded_arg("img", ID_TYPE_NUM); + add_embedded_arg("file$", ID_TYPE_STR); + embed_function("GetLineIntersection", ID_TYPE_FN_NUM); + add_embedded_arg("p0_x", ID_TYPE_NUM); + add_embedded_arg("p0_y", ID_TYPE_NUM); + add_embedded_arg("p1_x", ID_TYPE_NUM); + add_embedded_arg("p1_y", ID_TYPE_NUM); + add_embedded_arg("p2_x", ID_TYPE_NUM); + add_embedded_arg("p2_y", ID_TYPE_NUM); + add_embedded_arg("p3_x", ID_TYPE_NUM); + add_embedded_arg("p3_y", ID_TYPE_NUM); + add_embedded_arg("i_x", ID_TYPE_BYREF_NUM); + add_embedded_arg("i_y", ID_TYPE_BYREF_NUM); + embed_function("Interpolate", ID_TYPE_FN_NUM); + add_embedded_arg("min_a", ID_TYPE_NUM); + add_embedded_arg("max_a", ID_TYPE_NUM); + add_embedded_arg("mid_a", ID_TYPE_NUM); + add_embedded_arg("min_b", ID_TYPE_NUM); + add_embedded_arg("max_b", ID_TYPE_NUM); + embed_function("ATan2", ID_TYPE_FN_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + embed_function("PointInQuad", ID_TYPE_FN_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("x1", ID_TYPE_NUM); + add_embedded_arg("y1", ID_TYPE_NUM); + add_embedded_arg("x2", ID_TYPE_NUM); + add_embedded_arg("y2", ID_TYPE_NUM); + add_embedded_arg("x3", ID_TYPE_NUM); + add_embedded_arg("y3", ID_TYPE_NUM); + add_embedded_arg("x4", ID_TYPE_NUM); + add_embedded_arg("y4", ID_TYPE_NUM); + embed_function("PointInTri", ID_TYPE_FN_NUM); + add_embedded_arg("x", ID_TYPE_NUM); + add_embedded_arg("y", ID_TYPE_NUM); + add_embedded_arg("x1", ID_TYPE_NUM); + add_embedded_arg("y1", ID_TYPE_NUM); + add_embedded_arg("x2", ID_TYPE_NUM); + add_embedded_arg("y2", ID_TYPE_NUM); + add_embedded_arg("x3", ID_TYPE_NUM); + add_embedded_arg("y3", ID_TYPE_NUM); + embed_function("Distance2D", ID_TYPE_FN_NUM); + add_embedded_arg("x1", ID_TYPE_NUM); + add_embedded_arg("y1", ID_TYPE_NUM); + add_embedded_arg("x2", ID_TYPE_NUM); + add_embedded_arg("y2", ID_TYPE_NUM); + embed_function("Distance3D", ID_TYPE_FN_NUM); + add_embedded_arg("x1", ID_TYPE_NUM); + add_embedded_arg("y1", ID_TYPE_NUM); + add_embedded_arg("z1", ID_TYPE_NUM); + add_embedded_arg("x2", ID_TYPE_NUM); + add_embedded_arg("y2", ID_TYPE_NUM); + add_embedded_arg("z2", ID_TYPE_NUM); + embed_function("GetCircleLineIntersection", ID_TYPE_FN_NUM); + add_embedded_arg("circle_x", ID_TYPE_NUM); + add_embedded_arg("circle_y", ID_TYPE_NUM); + add_embedded_arg("radius", ID_TYPE_NUM); + add_embedded_arg("x1", ID_TYPE_NUM); + add_embedded_arg("y1", ID_TYPE_NUM); + add_embedded_arg("x2", ID_TYPE_NUM); + add_embedded_arg("y2", ID_TYPE_NUM); + add_embedded_arg("ix1", ID_TYPE_BYREF_NUM); + add_embedded_arg("iy1", ID_TYPE_BYREF_NUM); + add_embedded_arg("ix2", ID_TYPE_BYREF_NUM); + add_embedded_arg("iy2", ID_TYPE_BYREF_NUM); + embed_function("GetLinePlaneIntersection", ID_TYPE_FN_NUM); + add_embedded_arg("line_point", ID_TYPE_BYREF_NUM); + add_embedded_arg("line_direction", ID_TYPE_BYREF_NUM); + add_embedded_arg("plane_point_1", ID_TYPE_BYREF_NUM); + add_embedded_arg("plane_point_2", ID_TYPE_BYREF_NUM); + add_embedded_arg("plane_point_3", ID_TYPE_BYREF_NUM); + add_embedded_arg("intersection", ID_TYPE_BYREF_NUM); + embed_function("IncrementMatrixRows", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("r", ID_TYPE_NUM); + add_embedded_arg("num_rows", ID_TYPE_NUM); + add_embedded_arg("value", ID_TYPE_NUM); + embed_function("IncrementMatrixColumns", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("c", ID_TYPE_NUM); + add_embedded_arg("num_cols", ID_TYPE_NUM); + add_embedded_arg("value", ID_TYPE_NUM); + embed_function("JoinMatrixRows", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("mC", ID_TYPE_NUM); + embed_function("JoinMatrixColumns", ID_TYPE_SUB); + add_embedded_arg("mA", ID_TYPE_NUM); + add_embedded_arg("mB", ID_TYPE_NUM); + add_embedded_arg("mC", ID_TYPE_NUM); + embed_function("TypeArrayDim", ID_TYPE_FN_NUM); + add_embedded_arg("id", ID_TYPE_BYREF_USER, 0); + embed_function("TypeArraySize", ID_TYPE_FN_NUM); + add_embedded_arg("id", ID_TYPE_BYREF_USER, 0); + add_embedded_arg("array_dim", ID_TYPE_NUM); + embed_function("TypeArrayCopy", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_BYREF_USER, 0); + add_embedded_arg("dst", ID_TYPE_BYREF_USER, 0); + embed_function("TypeArrayFill", ID_TYPE_SUB); + add_embedded_arg("src", ID_TYPE_BYREF_USER, 0); + add_embedded_arg("fdata", ID_TYPE_USER, 0); } - + + +void init_embedded_types() +{ + create_type("empty"); +} + +void init_embedded_variables() +{ +} #endif // RC_BUILTIN_H_INCLUDED diff --git a/rcbasic_build/rc_global.h b/rcbasic_build/rc_global.h index 688837f..4b61fee 100644 --- a/rcbasic_build/rc_global.h +++ b/rcbasic_build/rc_global.h @@ -70,7 +70,9 @@ public: s.substr(0,s.find_first_of(" ")).compare("redim1")==0 || s.substr(0,s.find_first_of(" ")).compare("redim1$")==0 || s.substr(0,s.find_first_of(" ")).compare("for_offset_arr2")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_n1")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_s1")==0 || s.substr(0,s.find_first_of(" ")).compare("uref_ptr")==0 || - s.substr(0,s.find_first_of(" ")).compare("obj_usr_init1")==0 || s.substr(0,s.find_first_of(" ")).compare("preset_t")==0) + s.substr(0,s.find_first_of(" ")).compare("obj_usr_init1")==0 || s.substr(0,s.find_first_of(" ")).compare("preset_t")==0 || + s.substr(0,s.find_first_of(" ")).compare("redim_type")==0 || s.substr(0,s.find_first_of(" ")).compare("redim_type_n1")==0 || + s.substr(0,s.find_first_of(" ")).compare("redim_type_s1")==0) { current_address[current_segment] += 17; //1 byte for instruction and 8 bytes for each argument } @@ -128,7 +130,8 @@ public: s.substr(0,s.find_first_of(" ")).compare("end_x")==0 || s.substr(0,s.find_first_of(" ")).compare("lval")==0 || s.substr(0,s.find_first_of(" ")).compare("lval$")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_n")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_s")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_get")==0 || - s.substr(0,s.find_first_of(" ")).compare("delete_t")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_init")==0) + s.substr(0,s.find_first_of(" ")).compare("obj_usr_init")==0 || s.substr(0,s.find_first_of(" ")).compare("redim_type_n")==0 || + s.substr(0,s.find_first_of(" ")).compare("redim_type_s")==0) { current_address[current_segment] += 9; //1 byte for instruction and 8 bytes a single argument } @@ -138,7 +141,9 @@ public: s.substr(0,s.find_first_of(" ")).compare("redim2")==0 || s.substr(0,s.find_first_of(" ")).compare("redim2$")==0 || s.substr(0,s.find_first_of(" ")).compare("for_offset_arr3")==0 || s.substr(0,s.find_first_of(" ")).compare("dbg")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_n2")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_s2")==0 || - s.substr(0,s.find_first_of(" ")).compare("obj_usr_init2")==0 || s.substr(0,s.find_first_of(" ")).compare("preset_t1")==0) + s.substr(0,s.find_first_of(" ")).compare("obj_usr_init2")==0 || s.substr(0,s.find_first_of(" ")).compare("preset_t1")==0 || + s.substr(0,s.find_first_of(" ")).compare("delete_t")==0 || s.substr(0,s.find_first_of(" ")).compare("redim_type1")==0 || + s.substr(0,s.find_first_of(" ")).compare("redim_type_n2")==0 || s.substr(0,s.find_first_of(" ")).compare("redim_type_s2")==0) { current_address[current_segment] += 25; //1 byte for instruction and 8 bytes for 3 arguments } @@ -148,11 +153,13 @@ public: s.substr(0,s.find_first_of(" ")).compare("redim3")==0 || s.substr(0,s.find_first_of(" ")).compare("redim3$")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_n3")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_s3")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr3")==0 || s.substr(0,s.find_first_of(" ")).compare("obj_usr_init3")==0 || - s.substr(0,s.find_first_of(" ")).compare("preset_t2")==0) + s.substr(0,s.find_first_of(" ")).compare("preset_t2")==0 || s.substr(0,s.find_first_of(" ")).compare("redim_type2")==0 || + s.substr(0,s.find_first_of(" ")).compare("redim_type_n3")==0 || s.substr(0,s.find_first_of(" ")).compare("redim_type_s3")==0) { current_address[current_segment] += 33; //1 byte for instruction and 8 bytes for 4 arguments } - else if(s.substr(0,s.find_first_of(" ")).compare("dim_type3")==0 || s.substr(0,s.find_first_of(" ")).compare("preset_t3")==0) + else if(s.substr(0,s.find_first_of(" ")).compare("dim_type3")==0 || s.substr(0,s.find_first_of(" ")).compare("preset_t3")==0 || + s.substr(0,s.find_first_of(" ")).compare("redim_type3")==0) { current_address[current_segment] += 41; //1 byte for instruction and 8 bytes for 5 arguments } @@ -161,7 +168,7 @@ public: s.substr(0,s.find_first_of(" ")).compare("clear_stack$")==0 || s.substr(0,s.find_first_of(" ")).compare("do")==0 || s.substr(0,s.find_first_of(" ")).compare("pop_loop_stack")==0 || s.substr(0,s.find_first_of(" ")).compare("return")==0 || s.substr(0,s.find_first_of(" ")).compare("println")==0 || s.substr(0,s.find_first_of(" ")).compare("for_offset_0")==0 || - s.substr(0,s.find_first_of(" ")).compare("push_t_null")==0) + s.substr(0,s.find_first_of(" ")).compare("push_t_null")==0 || s.substr(0,s.find_first_of(" ")).compare("redim_top")==0) { current_address[current_segment] += 1; //1 byte for instruction and no arguments } diff --git a/rcbasic_build/rc_vm_asm.h b/rcbasic_build/rc_vm_asm.h index 5b28db8..aa5aa6b 100644 --- a/rcbasic_build/rc_vm_asm.h +++ b/rcbasic_build/rc_vm_asm.h @@ -1207,6 +1207,74 @@ namespace rc_cbc_assembler { writeSegment(191); } + else if(line_arg[0].compare("redim_type")==0) + { + string arg_type = line_arg[1].substr(0,1); + if(arg_type.compare("u")==0) + writeSegment(192); + else if(arg_type.compare("!")==0) + writeSegment(204); + } + else if(line_arg[0].compare("redim_type1")==0) + { + string arg_type = line_arg[1].substr(0,1); + if(arg_type.compare("u")==0) + writeSegment(193); + else if(arg_type.compare("!")==0) + writeSegment(205); + } + else if(line_arg[0].compare("redim_type2")==0) + { + string arg_type = line_arg[1].substr(0,1); + if(arg_type.compare("u")==0) + writeSegment(194); + else if(arg_type.compare("!")==0) + writeSegment(206); + } + else if(line_arg[0].compare("redim_type3")==0) + { + string arg_type = line_arg[1].substr(0,1); + if(arg_type.compare("u")==0) + writeSegment(195); + else if(arg_type.compare("!")==0) + writeSegment(207); + } + else if(line_arg[0].compare("redim_type_n")==0) + { + writeSegment(196); + } + else if(line_arg[0].compare("redim_type_n1")==0) + { + writeSegment(197); + } + else if(line_arg[0].compare("redim_type_n2")==0) + { + writeSegment(198); + } + else if(line_arg[0].compare("redim_type_n3")==0) + { + writeSegment(199); + } + else if(line_arg[0].compare("redim_type_s")==0) + { + writeSegment(200); + } + else if(line_arg[0].compare("redim_type_s1")==0) + { + writeSegment(201); + } + else if(line_arg[0].compare("redim_type_s2")==0) + { + writeSegment(202); + } + else if(line_arg[0].compare("redim_type_s3")==0) + { + writeSegment(203); + } + else if(line_arg[0].compare("redim_top")==0) + { + writeSegment(208); + } else { cout << "unrecognized cmd: " << line_arg[0] << endl; diff --git a/rcbasic_build/rcbasic_dev.txt b/rcbasic_build/rcbasic_dev.txt new file mode 100644 index 0000000..8947c90 --- /dev/null +++ b/rcbasic_build/rcbasic_dev.txt @@ -0,0 +1,1428 @@ +embed_function("FPrint", ID_TYPE_SUB); +add_embedded_arg("txt$", ID_TYPE_STR); +embed_function("Input$", ID_TYPE_FN_STR); +add_embedded_arg("prompt$", ID_TYPE_STR); +embed_function("ArrayDim", ID_TYPE_FN_NUM); +add_embedded_arg("id", ID_TYPE_BYREF_NUM); +embed_function("StringArrayDim", ID_TYPE_FN_NUM); +add_embedded_arg("id$", ID_TYPE_BYREF_STR); +embed_function("NumberArrayDim", ID_TYPE_FN_NUM); +add_embedded_arg("id", ID_TYPE_BYREF_NUM); +embed_function("ArraySize", ID_TYPE_FN_NUM); +add_embedded_arg("id", ID_TYPE_BYREF_NUM); +add_embedded_arg("array_dim", ID_TYPE_NUM); +embed_function("StringArraySize", ID_TYPE_FN_NUM); +add_embedded_arg("id$", ID_TYPE_BYREF_STR); +add_embedded_arg("array_dim", ID_TYPE_NUM); +embed_function("NumberArraySize", ID_TYPE_FN_NUM); +add_embedded_arg("id", ID_TYPE_BYREF_NUM); +add_embedded_arg("array_dim", ID_TYPE_NUM); +embed_function("Abs", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("ACos", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("AndBit", ID_TYPE_FN_NUM); +add_embedded_arg("a", ID_TYPE_NUM); +add_embedded_arg("b", ID_TYPE_NUM); +embed_function("ASin", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("ATan", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Bin$", ID_TYPE_FN_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("CInt32", ID_TYPE_FN_NUM); +add_embedded_arg("i", ID_TYPE_NUM); +embed_function("CInt64", ID_TYPE_FN_NUM); +add_embedded_arg("i", ID_TYPE_NUM); +embed_function("Cos", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Degrees", ID_TYPE_FN_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +embed_function("Exp", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Frac", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Hex$", ID_TYPE_FN_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("HexVal", ID_TYPE_FN_NUM); +add_embedded_arg("n$", ID_TYPE_STR); +embed_function("Int", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Log", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Max", ID_TYPE_FN_NUM); +add_embedded_arg("a", ID_TYPE_NUM); +add_embedded_arg("b", ID_TYPE_NUM); +embed_function("Min", ID_TYPE_FN_NUM); +add_embedded_arg("a", ID_TYPE_NUM); +add_embedded_arg("b", ID_TYPE_NUM); +embed_function("OrBit", ID_TYPE_FN_NUM); +add_embedded_arg("a", ID_TYPE_NUM); +add_embedded_arg("b", ID_TYPE_NUM); +embed_function("Radians", ID_TYPE_FN_NUM); +add_embedded_arg("d", ID_TYPE_NUM); +embed_function("Randomize", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Rand", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Round", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Sign", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Sin", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Sqrt", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Tan", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("XOrBit", ID_TYPE_FN_NUM); +add_embedded_arg("a", ID_TYPE_NUM); +add_embedded_arg("b", ID_TYPE_NUM); +embed_function("Asc", ID_TYPE_FN_NUM); +add_embedded_arg("c$", ID_TYPE_STR); +embed_function("Chr$", ID_TYPE_FN_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Insert$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("tgt$", ID_TYPE_STR); +add_embedded_arg("pos", ID_TYPE_NUM); +embed_function("InStr", ID_TYPE_FN_NUM); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("substr$", ID_TYPE_STR); +embed_function("LCase$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +embed_function("Left$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Length", ID_TYPE_FN_NUM); +add_embedded_arg("src$", ID_TYPE_STR); +embed_function("Len", ID_TYPE_FN_NUM); +add_embedded_arg("src$", ID_TYPE_STR); +embed_function("LTrim$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +embed_function("Mid$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("start", ID_TYPE_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("ReplaceSubstr$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("rpc$", ID_TYPE_STR); +add_embedded_arg("pos", ID_TYPE_NUM); +embed_function("Replace$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("tgt$", ID_TYPE_STR); +add_embedded_arg("rpc$", ID_TYPE_STR); +embed_function("Reverse$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +embed_function("Right$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("RTrim$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +embed_function("StringFill$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Str$", ID_TYPE_FN_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Str_F$", ID_TYPE_FN_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Str_S$", ID_TYPE_FN_STR); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Tally", ID_TYPE_FN_NUM); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("substr$", ID_TYPE_STR); +embed_function("Trim$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +embed_function("UCase$", ID_TYPE_FN_STR); +add_embedded_arg("src$", ID_TYPE_STR); +embed_function("Val", ID_TYPE_FN_NUM); +add_embedded_arg("n$", ID_TYPE_STR); +embed_function("Stack_N", ID_TYPE_SUB); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Stack_S", ID_TYPE_SUB); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Push_N", ID_TYPE_SUB); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("Pop_N", ID_TYPE_FN_NUM); +embed_function("Push_S", ID_TYPE_SUB); +add_embedded_arg("s$", ID_TYPE_STR); +embed_function("Pop_S$", ID_TYPE_FN_STR); +embed_function("Stack_Size_N", ID_TYPE_FN_NUM); +embed_function("Stack_Size_S", ID_TYPE_FN_NUM); +embed_function("FileOpen", ID_TYPE_FN_NUM); +add_embedded_arg("stream", ID_TYPE_NUM); +add_embedded_arg("fileName$", ID_TYPE_STR); +add_embedded_arg("mode", ID_TYPE_NUM); +embed_function("FileClose", ID_TYPE_SUB); +add_embedded_arg("stream", ID_TYPE_NUM); +embed_function("ReadByte", ID_TYPE_FN_NUM); +add_embedded_arg("stream", ID_TYPE_NUM); +embed_function("WriteByte", ID_TYPE_SUB); +add_embedded_arg("stream", ID_TYPE_NUM); +add_embedded_arg("byte", ID_TYPE_NUM); +embed_function("ReadLine$", ID_TYPE_FN_STR); +add_embedded_arg("stream", ID_TYPE_NUM); +embed_function("Write", ID_TYPE_SUB); +add_embedded_arg("stream", ID_TYPE_NUM); +add_embedded_arg("txt$", ID_TYPE_STR); +embed_function("WriteLine", ID_TYPE_SUB); +add_embedded_arg("stream", ID_TYPE_NUM); +add_embedded_arg("txt$", ID_TYPE_STR); +embed_function("CopyFile", ID_TYPE_SUB); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("dst$", ID_TYPE_STR); +embed_function("RemoveFile", ID_TYPE_FN_NUM); +add_embedded_arg("fileName$", ID_TYPE_STR); +embed_function("FileExists", ID_TYPE_FN_NUM); +add_embedded_arg("fileName$", ID_TYPE_STR); +embed_function("MoveFile", ID_TYPE_FN_NUM); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("dst$", ID_TYPE_STR); +embed_function("RenameFile", ID_TYPE_FN_NUM); +add_embedded_arg("src$", ID_TYPE_STR); +add_embedded_arg("dst$", ID_TYPE_STR); +embed_function("FileLength", ID_TYPE_FN_NUM); +add_embedded_arg("fileName$", ID_TYPE_STR); +embed_function("Tell", ID_TYPE_FN_NUM); +add_embedded_arg("stream", ID_TYPE_NUM); +embed_function("Seek", ID_TYPE_FN_NUM); +add_embedded_arg("stream", ID_TYPE_NUM); +add_embedded_arg("pos", ID_TYPE_NUM); +embed_function("EOF", ID_TYPE_FN_NUM); +add_embedded_arg("stream", ID_TYPE_NUM); +embed_function("FreeFile", ID_TYPE_FN_NUM); +embed_function("ChangeDir", ID_TYPE_SUB); +add_embedded_arg("p$", ID_TYPE_STR); +embed_function("DirExists", ID_TYPE_FN_NUM); +add_embedded_arg("p$", ID_TYPE_STR); +embed_function("DirFirst$", ID_TYPE_FN_STR); +embed_function("Dir$", ID_TYPE_FN_STR); +embed_function("DirNext$", ID_TYPE_FN_STR); +embed_function("MakeDir", ID_TYPE_FN_NUM); +add_embedded_arg("p$", ID_TYPE_STR); +embed_function("RemoveDir", ID_TYPE_FN_NUM); +add_embedded_arg("p$", ID_TYPE_STR); +embed_function("Date$", ID_TYPE_FN_STR); +embed_function("Easter$", ID_TYPE_FN_STR); +add_embedded_arg("year", ID_TYPE_NUM); +embed_function("Ticks", ID_TYPE_FN_NUM); +embed_function("Time$", ID_TYPE_FN_STR); +embed_function("Timer", ID_TYPE_FN_NUM); +embed_function("Wait", ID_TYPE_SUB); +add_embedded_arg("m_sec", ID_TYPE_NUM); +embed_function("WindowOpen", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("title$", ID_TYPE_STR); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("flag", ID_TYPE_NUM); +add_embedded_arg("vsync", ID_TYPE_NUM); +embed_function("WindowClose", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("RaiseWindow", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("Window", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("Update", ID_TYPE_SUB); +embed_function("Cls", ID_TYPE_SUB); +embed_function("SetClearColor", ID_TYPE_SUB); +add_embedded_arg("c", ID_TYPE_NUM); +embed_function("ShowWindow", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("HideWindow", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("SetWindowTitle", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("title$", ID_TYPE_STR); +embed_function("WindowTitle$", ID_TYPE_FN_STR); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("SetWindowPosition", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("GetWindowPosition", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +embed_function("SetWindowSize", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("GetWindowSize", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("SetWindowMinSize", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("GetWindowMinSize", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("SetWindowMaxSize", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("GetWindowMaxSize", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("WindowIsFullscreen", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowIsVisible", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowIsBordered", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowIsResizable", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowIsMinimized", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowIsMaximized", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowHasInputFocus", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowHasMouseFocus", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("SetWindowFullscreen", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("MaximizeWindow", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("MinimizeWindow", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("SetWindowBorder", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("WindowClip", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("WindowExists", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("NumWindows", ID_TYPE_FN_NUM); +embed_function("WindowEvent_Close", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowEvent_Maximize", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("WindowEvent_Minimize", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("ActiveWindow", ID_TYPE_FN_NUM); +embed_function("FPS", ID_TYPE_FN_NUM); +embed_function("SetWindowIcon", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("CanvasOpen", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("viewport_x", ID_TYPE_NUM); +add_embedded_arg("viewport_y", ID_TYPE_NUM); +add_embedded_arg("viewport_w", ID_TYPE_NUM); +add_embedded_arg("viewport_h", ID_TYPE_NUM); +add_embedded_arg("mode", ID_TYPE_NUM); +embed_function("CanvasClose", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +embed_function("SetCanvasVisible", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("CanvasIsVisible", ID_TYPE_FN_NUM); +add_embedded_arg("c_num", ID_TYPE_NUM); +embed_function("SetCanvasViewport", ID_TYPE_SUB); +add_embedded_arg("cnum", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("GetCanvasViewport", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("Canvas", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +embed_function("SetCanvasOffset", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("GetCanvasOffset", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +embed_function("GetCanvasSize", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("ClearCanvas", ID_TYPE_SUB); +embed_function("SetCanvasAlpha", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("a", ID_TYPE_NUM); +embed_function("CanvasAlpha", ID_TYPE_FN_NUM); +add_embedded_arg("c_num", ID_TYPE_NUM); +embed_function("SetCanvasBlendMode", ID_TYPE_FN_NUM); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("blend_mode", ID_TYPE_NUM); +embed_function("CanvasBlendMode", ID_TYPE_FN_NUM); +add_embedded_arg("c_num", ID_TYPE_NUM); +embed_function("SetCanvasColorMod", ID_TYPE_FN_NUM); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +embed_function("CanvasColorMod", ID_TYPE_FN_NUM); +add_embedded_arg("c_num", ID_TYPE_NUM); +embed_function("CopyCanvas", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("dst", ID_TYPE_NUM); +add_embedded_arg("dx", ID_TYPE_NUM); +add_embedded_arg("dy", ID_TYPE_NUM); +embed_function("CloneCanvas", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_NUM); +add_embedded_arg("dst", ID_TYPE_NUM); +embed_function("SetCanvasZ", ID_TYPE_SUB); +add_embedded_arg("c_num", ID_TYPE_NUM); +add_embedded_arg("z", ID_TYPE_NUM); +embed_function("CanvasZ", ID_TYPE_FN_NUM); +add_embedded_arg("c_num", ID_TYPE_NUM); +embed_function("CanvasClip", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("ActiveCanvas", ID_TYPE_FN_NUM); +embed_function("Box", ID_TYPE_SUB); +add_embedded_arg("x1", ID_TYPE_NUM); +add_embedded_arg("y1", ID_TYPE_NUM); +add_embedded_arg("x2", ID_TYPE_NUM); +add_embedded_arg("y2", ID_TYPE_NUM); +embed_function("BoxFill", ID_TYPE_SUB); +add_embedded_arg("x1", ID_TYPE_NUM); +add_embedded_arg("y1", ID_TYPE_NUM); +add_embedded_arg("x2", ID_TYPE_NUM); +add_embedded_arg("y2", ID_TYPE_NUM); +embed_function("Circle", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("radius", ID_TYPE_NUM); +embed_function("CircleFill", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("radius", ID_TYPE_NUM); +embed_function("Ellipse", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("rx", ID_TYPE_NUM); +add_embedded_arg("ry", ID_TYPE_NUM); +embed_function("EllipseFill", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("rx", ID_TYPE_NUM); +add_embedded_arg("ry", ID_TYPE_NUM); +embed_function("FloodFill", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("GetPixel", ID_TYPE_FN_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("SetColor", ID_TYPE_SUB); +add_embedded_arg("c", ID_TYPE_NUM); +embed_function("Line", ID_TYPE_SUB); +add_embedded_arg("x1", ID_TYPE_NUM); +add_embedded_arg("y1", ID_TYPE_NUM); +add_embedded_arg("x2", ID_TYPE_NUM); +add_embedded_arg("y2", ID_TYPE_NUM); +embed_function("Poly", ID_TYPE_SUB); +add_embedded_arg("n", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +embed_function("PolyFill", ID_TYPE_SUB); +add_embedded_arg("n", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +embed_function("Rect", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("RectFill", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("RoundRect", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +embed_function("RoundRectFill", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +embed_function("RGB", ID_TYPE_FN_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("g", ID_TYPE_NUM); +add_embedded_arg("b", ID_TYPE_NUM); +embed_function("RGBA", ID_TYPE_FN_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("g", ID_TYPE_NUM); +add_embedded_arg("b", ID_TYPE_NUM); +add_embedded_arg("a", ID_TYPE_NUM); +embed_function("PSet", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("LoadImage", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("img$", ID_TYPE_STR); +embed_function("LoadImage_Ex", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("img$", ID_TYPE_STR); +add_embedded_arg("colkey", ID_TYPE_NUM); +embed_function("ImageFromBuffer", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); +embed_function("ImageFromBuffer_Ex", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); +add_embedded_arg("colkey", ID_TYPE_NUM); +embed_function("BufferFromImage", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); +embed_function("ImageExists", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("ColorKey", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +embed_function("CopyImage", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_NUM); +add_embedded_arg("dst", ID_TYPE_NUM); +embed_function("DeleteImage", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("SetImageAlpha", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("a", ID_TYPE_NUM); +embed_function("ImageAlpha", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("GetImageSize", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("SetImageBlendMode", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("blend_mode", ID_TYPE_NUM); +embed_function("ImageBlendMode", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("SetImageColorMod", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +embed_function("ImageColorMod", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("DrawImage", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("DrawImage_Blit", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("src_x", ID_TYPE_NUM); +add_embedded_arg("src_y", ID_TYPE_NUM); +add_embedded_arg("src_w", ID_TYPE_NUM); +add_embedded_arg("src_h", ID_TYPE_NUM); +embed_function("DrawImage_Blit_Ex", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("src_x", ID_TYPE_NUM); +add_embedded_arg("src_y", ID_TYPE_NUM); +add_embedded_arg("src_w", ID_TYPE_NUM); +add_embedded_arg("src_h", ID_TYPE_NUM); +embed_function("DrawImage_Rotate", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("angle", ID_TYPE_NUM); +embed_function("DrawImage_Rotate_Ex", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("src_x", ID_TYPE_NUM); +add_embedded_arg("src_y", ID_TYPE_NUM); +add_embedded_arg("src_w", ID_TYPE_NUM); +add_embedded_arg("src_h", ID_TYPE_NUM); +add_embedded_arg("angle", ID_TYPE_NUM); +embed_function("DrawImage_Zoom", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("zx", ID_TYPE_NUM); +add_embedded_arg("zy", ID_TYPE_NUM); +embed_function("DrawImage_Zoom_Ex", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("src_x", ID_TYPE_NUM); +add_embedded_arg("src_y", ID_TYPE_NUM); +add_embedded_arg("src_w", ID_TYPE_NUM); +add_embedded_arg("src_h", ID_TYPE_NUM); +add_embedded_arg("zx", ID_TYPE_NUM); +add_embedded_arg("zy", ID_TYPE_NUM); +embed_function("DrawImage_Rotozoom", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("angle", ID_TYPE_NUM); +add_embedded_arg("zx", ID_TYPE_NUM); +add_embedded_arg("zy", ID_TYPE_NUM); +embed_function("DrawImage_Rotozoom_Ex", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("src_x", ID_TYPE_NUM); +add_embedded_arg("src_y", ID_TYPE_NUM); +add_embedded_arg("src_w", ID_TYPE_NUM); +add_embedded_arg("src_h", ID_TYPE_NUM); +add_embedded_arg("angle", ID_TYPE_NUM); +add_embedded_arg("zx", ID_TYPE_NUM); +add_embedded_arg("zy", ID_TYPE_NUM); +embed_function("DrawImage_Flip", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("v", ID_TYPE_NUM); +embed_function("DrawImage_Flip_Ex", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("src_x", ID_TYPE_NUM); +add_embedded_arg("src_y", ID_TYPE_NUM); +add_embedded_arg("src_w", ID_TYPE_NUM); +add_embedded_arg("src_h", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("v", ID_TYPE_NUM); +embed_function("InKey", ID_TYPE_FN_NUM); +embed_function("Key", ID_TYPE_FN_NUM); +add_embedded_arg("key_code", ID_TYPE_NUM); +embed_function("WaitKey", ID_TYPE_FN_NUM); +embed_function("HideMouse", ID_TYPE_SUB); +embed_function("ShowMouse", ID_TYPE_SUB); +embed_function("MouseIsVisible", ID_TYPE_FN_NUM); +embed_function("GetMouse", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("mb1", ID_TYPE_BYREF_NUM); +add_embedded_arg("mb2", ID_TYPE_BYREF_NUM); +add_embedded_arg("mb3", ID_TYPE_BYREF_NUM); +embed_function("MouseX", ID_TYPE_FN_NUM); +embed_function("MouseY", ID_TYPE_FN_NUM); +embed_function("MouseButton", ID_TYPE_FN_NUM); +add_embedded_arg("mb", ID_TYPE_NUM); +embed_function("GetMouseWheel", ID_TYPE_SUB); +add_embedded_arg("x_axis", ID_TYPE_BYREF_NUM); +add_embedded_arg("y_axis", ID_TYPE_BYREF_NUM); +embed_function("MouseWheelX", ID_TYPE_FN_NUM); +embed_function("MouseWheelY", ID_TYPE_FN_NUM); +embed_function("SoundFromBuffer", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); +add_embedded_arg("buffer_size", ID_TYPE_NUM); +add_embedded_arg("vol", ID_TYPE_NUM); +embed_function("LoadSound", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("snd_file$", ID_TYPE_STR); +embed_function("LoadMusic", ID_TYPE_SUB); +add_embedded_arg("music_file$", ID_TYPE_STR); +embed_function("PlaySound", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("channel", ID_TYPE_NUM); +add_embedded_arg("loops", ID_TYPE_NUM); +embed_function("PlaySoundTimed", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("channel", ID_TYPE_NUM); +add_embedded_arg("loops", ID_TYPE_NUM); +add_embedded_arg("ms", ID_TYPE_NUM); +embed_function("PlayMusic", ID_TYPE_SUB); +add_embedded_arg("mLoops", ID_TYPE_NUM); +embed_function("PauseSound", ID_TYPE_SUB); +add_embedded_arg("channel", ID_TYPE_NUM); +embed_function("ResumeSound", ID_TYPE_SUB); +add_embedded_arg("channel", ID_TYPE_NUM); +embed_function("PauseMusic", ID_TYPE_SUB); +embed_function("ResumeMusic", ID_TYPE_SUB); +embed_function("DeleteSound", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("DeleteMusic", ID_TYPE_SUB); +embed_function("FadeMusicIn", ID_TYPE_SUB); +add_embedded_arg("fade_time", ID_TYPE_NUM); +add_embedded_arg("loops", ID_TYPE_NUM); +embed_function("FadeMusicOut", ID_TYPE_SUB); +add_embedded_arg("fade_time", ID_TYPE_NUM); +embed_function("MusicExists", ID_TYPE_FN_NUM); +embed_function("SetMusicVolume", ID_TYPE_SUB); +add_embedded_arg("vol", ID_TYPE_NUM); +embed_function("MusicVolume", ID_TYPE_FN_NUM); +embed_function("SetMusicPosition", ID_TYPE_SUB); +add_embedded_arg("pos", ID_TYPE_NUM); +embed_function("MusicPosition", ID_TYPE_FN_NUM); +embed_function("RewindMusic", ID_TYPE_SUB); +embed_function("SetSoundChannels", ID_TYPE_SUB); +add_embedded_arg("max_channels", ID_TYPE_NUM); +embed_function("NumSoundChannels", ID_TYPE_FN_NUM); +embed_function("SoundIsEnabled", ID_TYPE_FN_NUM); +embed_function("SoundExists", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("SetChannelVolume", ID_TYPE_SUB); +add_embedded_arg("channel", ID_TYPE_NUM); +add_embedded_arg("vol", ID_TYPE_NUM); +embed_function("ChannelVolume", ID_TYPE_FN_NUM); +add_embedded_arg("channel", ID_TYPE_NUM); +embed_function("SetSoundVolume", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("vol", ID_TYPE_NUM); +embed_function("SoundVolume", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("StopMusic", ID_TYPE_SUB); +embed_function("StopSound", ID_TYPE_SUB); +add_embedded_arg("channel", ID_TYPE_NUM); +embed_function("SetChannelPanning", ID_TYPE_FN_NUM); +add_embedded_arg("channel", ID_TYPE_NUM); +add_embedded_arg("left_value", ID_TYPE_NUM); +add_embedded_arg("right_value", ID_TYPE_NUM); +embed_function("SetChannelDistance", ID_TYPE_FN_NUM); +add_embedded_arg("channel", ID_TYPE_NUM); +add_embedded_arg("dist_value", ID_TYPE_NUM); +embed_function("ChannelIsPlaying", ID_TYPE_FN_NUM); +add_embedded_arg("channel", ID_TYPE_NUM); +embed_function("ChannelIsPaused", ID_TYPE_FN_NUM); +add_embedded_arg("channel", ID_TYPE_NUM); +embed_function("NumJoysticks", ID_TYPE_FN_NUM); +embed_function("NumJoyAxes", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +embed_function("NumJoyButtons", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +embed_function("NumJoyHats", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +embed_function("NumJoyTrackBalls", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +embed_function("JoyAxis", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +add_embedded_arg("joy_axis", ID_TYPE_NUM); +embed_function("JoyButton", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +add_embedded_arg("joy_button", ID_TYPE_NUM); +embed_function("JoyHat", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +add_embedded_arg("joy_hat", ID_TYPE_NUM); +embed_function("GetJoyTrackBall", ID_TYPE_SUB); +add_embedded_arg("joy_num", ID_TYPE_NUM); +add_embedded_arg("ball", ID_TYPE_NUM); +add_embedded_arg("dx", ID_TYPE_BYREF_NUM); +add_embedded_arg("dy", ID_TYPE_BYREF_NUM); +embed_function("JoyName$", ID_TYPE_FN_STR); +add_embedded_arg("joy_num", ID_TYPE_NUM); +embed_function("JoystickIsConnected", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +embed_function("GetCursor", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +embed_function("PrintS", ID_TYPE_SUB); +add_embedded_arg("txt$", ID_TYPE_STR); +embed_function("InputS$", ID_TYPE_FN_STR); +add_embedded_arg("prompt$", ID_TYPE_STR); +embed_function("ZoneInputS$", ID_TYPE_FN_STR); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("Locate", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("ReadInput_Start", ID_TYPE_SUB); +embed_function("ReadInput_Stop", ID_TYPE_SUB); +embed_function("ReadInput_Text$", ID_TYPE_FN_STR); +embed_function("ReadInput_SetText", ID_TYPE_SUB); +add_embedded_arg("txt$", ID_TYPE_STR); +embed_function("ReadInput_ToggleBackspace", ID_TYPE_SUB); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("LoadFont", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("fnt_file$", ID_TYPE_STR); +add_embedded_arg("size", ID_TYPE_NUM); +embed_function("DeleteFont", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("FontIsLoaded", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("Font", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +embed_function("SetFontStyle", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("style", ID_TYPE_NUM); +embed_function("DrawText", ID_TYPE_SUB); +add_embedded_arg("txt$", ID_TYPE_STR); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("DrawText_Shaded", ID_TYPE_SUB); +add_embedded_arg("txt$", ID_TYPE_STR); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("fg_color", ID_TYPE_NUM); +add_embedded_arg("bg_color", ID_TYPE_NUM); +embed_function("DrawText_Blended", ID_TYPE_SUB); +add_embedded_arg("txt$", ID_TYPE_STR); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("RenderText", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("txt$", ID_TYPE_STR); +embed_function("GetTextSize", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("txt$", ID_TYPE_STR); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("TouchPressure", ID_TYPE_FN_NUM); +embed_function("GetTouch", ID_TYPE_SUB); +add_embedded_arg("status", ID_TYPE_BYREF_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("dx", ID_TYPE_BYREF_NUM); +add_embedded_arg("dy", ID_TYPE_BYREF_NUM); +embed_function("GetMultiTouch", ID_TYPE_SUB); +add_embedded_arg("status", ID_TYPE_BYREF_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("fingers", ID_TYPE_BYREF_NUM); +add_embedded_arg("dist", ID_TYPE_BYREF_NUM); +add_embedded_arg("theta", ID_TYPE_BYREF_NUM); +embed_function("GetTouchFinger", ID_TYPE_SUB); +add_embedded_arg("finger", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("pressure", ID_TYPE_BYREF_NUM); +embed_function("NumFingers", ID_TYPE_FN_NUM); +embed_function("CheckSockets", ID_TYPE_FN_NUM); +add_embedded_arg("timeout_ms", ID_TYPE_NUM); +embed_function("TCP_SocketReady", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +embed_function("UDP_SocketReady", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +embed_function("TCP_SocketOpen", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +add_embedded_arg("host$", ID_TYPE_STR); +add_embedded_arg("port", ID_TYPE_NUM); +embed_function("TCP_SocketClose", ID_TYPE_SUB); +add_embedded_arg("socket", ID_TYPE_NUM); +embed_function("TCP_RemoteHost", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +embed_function("TCP_RemotePort", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +embed_function("TCP_GetData", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +add_embedded_arg("sData$", ID_TYPE_BYREF_STR); +add_embedded_arg("numBytes", ID_TYPE_NUM); +embed_function("TCP_SendData", ID_TYPE_SUB); +add_embedded_arg("socket", ID_TYPE_NUM); +add_embedded_arg("sData$", ID_TYPE_STR); +embed_function("TCP_AcceptSocket", ID_TYPE_FN_NUM); +add_embedded_arg("server", ID_TYPE_NUM); +add_embedded_arg("client", ID_TYPE_NUM); +embed_function("UDP_SocketOpen", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +add_embedded_arg("port", ID_TYPE_NUM); +embed_function("UDP_SocketClose", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +embed_function("UDP_GetData", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +add_embedded_arg("sData$", ID_TYPE_BYREF_STR); +add_embedded_arg("host$", ID_TYPE_BYREF_STR); +add_embedded_arg("port", ID_TYPE_BYREF_NUM); +embed_function("UDP_Length", ID_TYPE_FN_NUM); +embed_function("UDP_MaxLength", ID_TYPE_FN_NUM); +embed_function("UDP_RemoteHost$", ID_TYPE_FN_STR); +add_embedded_arg("socket", ID_TYPE_NUM); +embed_function("UDP_RemotePort", ID_TYPE_FN_NUM); +add_embedded_arg("socket", ID_TYPE_NUM); +embed_function("UDP_SendData", ID_TYPE_SUB); +add_embedded_arg("socket", ID_TYPE_NUM); +add_embedded_arg("sData$", ID_TYPE_STR); +add_embedded_arg("host$", ID_TYPE_STR); +add_embedded_arg("port", ID_TYPE_NUM); +embed_function("LoadVideo", ID_TYPE_SUB); +add_embedded_arg("vid$", ID_TYPE_STR); +embed_function("PlayVideo", ID_TYPE_SUB); +add_embedded_arg("vLoops", ID_TYPE_NUM); +embed_function("PauseVideo", ID_TYPE_SUB); +embed_function("StopVideo", ID_TYPE_SUB); +embed_function("SetVideoPosition", ID_TYPE_SUB); +add_embedded_arg("pos", ID_TYPE_NUM); +embed_function("ResumeVideo", ID_TYPE_SUB); +embed_function("VideoPosition", ID_TYPE_FN_NUM); +embed_function("DeleteVideo", ID_TYPE_SUB); +embed_function("VideoIsPlaying", ID_TYPE_FN_NUM); +embed_function("VideoEnd", ID_TYPE_FN_NUM); +embed_function("GetVideoStats", ID_TYPE_SUB); +add_embedded_arg("vFile$", ID_TYPE_STR); +add_embedded_arg("vLen", ID_TYPE_BYREF_NUM); +add_embedded_arg("vfps", ID_TYPE_BYREF_NUM); +add_embedded_arg("frame_w", ID_TYPE_BYREF_NUM); +add_embedded_arg("frame_h", ID_TYPE_BYREF_NUM); +embed_function("SetVideoDrawRect", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("GetVideoDrawRect", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("GetVideoSize", ID_TYPE_SUB); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +embed_function("VideoExists", ID_TYPE_FN_NUM); +embed_function("SetVideoAlpha", ID_TYPE_SUB); +add_embedded_arg("a", ID_TYPE_NUM); +embed_function("System", ID_TYPE_FN_NUM); +add_embedded_arg("cmd$", ID_TYPE_STR); +embed_function("OS$", ID_TYPE_FN_STR); +embed_function("Command$", ID_TYPE_FN_STR); +add_embedded_arg("arg", ID_TYPE_NUM); +embed_function("NumCommands", ID_TYPE_FN_NUM); +embed_function("Env$", ID_TYPE_FN_STR); +add_embedded_arg("v$", ID_TYPE_STR); +embed_function("SetEnv", ID_TYPE_SUB); +add_embedded_arg("var$", ID_TYPE_STR); +add_embedded_arg("value$", ID_TYPE_STR); +add_embedded_arg("overwrite", ID_TYPE_NUM); +embed_function("PrefPath$", ID_TYPE_FN_STR); +add_embedded_arg("org_name$", ID_TYPE_STR); +add_embedded_arg("app_name$", ID_TYPE_STR); +embed_function("Android_GetExternalStoragePath$", ID_TYPE_FN_STR); +embed_function("Android_GetExternalStorageState", ID_TYPE_FN_NUM); +embed_function("Android_GetInternalStoragePath$", ID_TYPE_FN_STR); +embed_function("Android_JNI_Message$", ID_TYPE_FN_STR); +add_embedded_arg("arg$", ID_TYPE_STR); +embed_function("Runtime_Utility_Message$", ID_TYPE_FN_STR); +add_embedded_arg("arg$", ID_TYPE_STR); +embed_function("ClipboardText$", ID_TYPE_FN_STR); +embed_function("SetClipboardText", ID_TYPE_SUB); +add_embedded_arg("txt$", ID_TYPE_STR); +embed_function("HasClipboardText", ID_TYPE_FN_NUM); +embed_function("GetDesktopDisplayMode", ID_TYPE_SUB); +add_embedded_arg("index", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_BYREF_NUM); +add_embedded_arg("h", ID_TYPE_BYREF_NUM); +add_embedded_arg("freq", ID_TYPE_BYREF_NUM); +embed_function("DrawImage_Transform", ID_TYPE_SUB); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +add_embedded_arg("src_x", ID_TYPE_NUM); +add_embedded_arg("src_y", ID_TYPE_NUM); +add_embedded_arg("src_w", ID_TYPE_NUM); +add_embedded_arg("src_h", ID_TYPE_NUM); +add_embedded_arg("angle", ID_TYPE_NUM); +add_embedded_arg("center_x", ID_TYPE_NUM); +add_embedded_arg("center_y", ID_TYPE_NUM); +add_embedded_arg("flip_h", ID_TYPE_NUM); +add_embedded_arg("flip_v", ID_TYPE_NUM); +embed_function("GetPowerInfo", ID_TYPE_SUB); +add_embedded_arg("status", ID_TYPE_BYREF_NUM); +add_embedded_arg("secs", ID_TYPE_BYREF_NUM); +add_embedded_arg("pct", ID_TYPE_BYREF_NUM); +embed_function("SystemRam", ID_TYPE_FN_NUM); +embed_function("SetRenderScaleQuality", ID_TYPE_FN_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("EvalJS$", ID_TYPE_FN_STR); +add_embedded_arg("js_code$", ID_TYPE_STR); +embed_function("GetRenderScaleQuality", ID_TYPE_FN_NUM); +embed_function("GetGlobalMouse", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("mb1", ID_TYPE_BYREF_NUM); +add_embedded_arg("mb2", ID_TYPE_BYREF_NUM); +add_embedded_arg("mb3", ID_TYPE_BYREF_NUM); +embed_function("GlobalMouseX", ID_TYPE_FN_NUM); +embed_function("GlobalMouseY", ID_TYPE_FN_NUM); +embed_function("GetAccel", ID_TYPE_SUB); +add_embedded_arg("accel_num", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("z", ID_TYPE_BYREF_NUM); +embed_function("AccelName$", ID_TYPE_FN_STR); +add_embedded_arg("accel_num", ID_TYPE_NUM); +embed_function("NumAccels", ID_TYPE_FN_NUM); +embed_function("GetGyro", ID_TYPE_SUB); +add_embedded_arg("gyro_num", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_BYREF_NUM); +add_embedded_arg("y", ID_TYPE_BYREF_NUM); +add_embedded_arg("z", ID_TYPE_BYREF_NUM); +embed_function("GyroName$", ID_TYPE_FN_STR); +add_embedded_arg("gyro_num", ID_TYPE_NUM); +embed_function("NumGyros", ID_TYPE_FN_NUM); +embed_function("JoyRumblePlay", ID_TYPE_SUB); +add_embedded_arg("joy_num", ID_TYPE_NUM); +add_embedded_arg("strength", ID_TYPE_NUM); +add_embedded_arg("duration", ID_TYPE_NUM); +embed_function("JoyRumbleStop", ID_TYPE_SUB); +add_embedded_arg("joy_num", ID_TYPE_NUM); +embed_function("JoystickIsHaptic", ID_TYPE_FN_NUM); +add_embedded_arg("joy_num", ID_TYPE_NUM); +embed_function("WriteByteBuffer", ID_TYPE_FN_NUM); +add_embedded_arg("stream", ID_TYPE_NUM); +add_embedded_arg("buf", ID_TYPE_BYREF_NUM); +add_embedded_arg("buf_size", ID_TYPE_NUM); +embed_function("ReadByteBuffer", ID_TYPE_FN_NUM); +add_embedded_arg("stream", ID_TYPE_NUM); +add_embedded_arg("buf", ID_TYPE_BYREF_NUM); +add_embedded_arg("buf_size", ID_TYPE_NUM); +embed_function("WindowEvent_Resize", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("SetWindowAutoClose", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("exit_on_close", ID_TYPE_NUM); +embed_function("SetWindowResizable", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("SystemReturnStdOut$", ID_TYPE_FN_STR); +add_embedded_arg("cmd$", ID_TYPE_STR); +embed_function("WindowMode", ID_TYPE_FN_NUM); +add_embedded_arg("visible", ID_TYPE_NUM); +add_embedded_arg("fullscreen", ID_TYPE_NUM); +add_embedded_arg("resizable", ID_TYPE_NUM); +add_embedded_arg("borderless", ID_TYPE_NUM); +add_embedded_arg("highDPI", ID_TYPE_NUM); +embed_function("WindowFlags", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("RestoreWindow", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("UpdateAllWindows", ID_TYPE_SUB); +embed_function("QueryAudioSpec", ID_TYPE_FN_NUM); +add_embedded_arg("freq", ID_TYPE_BYREF_NUM); +add_embedded_arg("format", ID_TYPE_BYREF_NUM); +add_embedded_arg("channels", ID_TYPE_BYREF_NUM); +embed_function("MusicIsPlaying", ID_TYPE_FN_NUM); +embed_function("DrawGeometry", ID_TYPE_FN_NUM); +add_embedded_arg("slot", ID_TYPE_NUM); +add_embedded_arg("num_vertices", ID_TYPE_NUM); +add_embedded_arg("vertices", ID_TYPE_BYREF_NUM); +add_embedded_arg("num_indices", ID_TYPE_NUM); +add_embedded_arg("Indices", ID_TYPE_BYREF_NUM); +embed_function("Size", ID_TYPE_FN_NUM); +add_embedded_arg("s$", ID_TYPE_STR); +embed_function("BufferFromString", ID_TYPE_FN_NUM); +add_embedded_arg("s$", ID_TYPE_STR); +add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); +embed_function("StringFromBuffer$", ID_TYPE_FN_STR); +add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); +add_embedded_arg("buffer_size", ID_TYPE_NUM); +embed_function("GrabInput", ID_TYPE_SUB); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("GrabbedWindow", ID_TYPE_FN_NUM); +embed_function("WarpMouse", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("WarpMouseGlobal", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +embed_function("SetMouseZone", ID_TYPE_SUB); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("w", ID_TYPE_NUM); +add_embedded_arg("h", ID_TYPE_NUM); +embed_function("ClearMouseZone", ID_TYPE_SUB); +embed_function("SetWindowAlwaysOnTop", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("SetMouseRelative", ID_TYPE_SUB); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("SetWindowVSync", ID_TYPE_SUB); +add_embedded_arg("win", ID_TYPE_NUM); +add_embedded_arg("flag", ID_TYPE_NUM); +embed_function("OpenURL", ID_TYPE_FN_NUM); +add_embedded_arg("url$", ID_TYPE_STR); +embed_function("APIVersion$", ID_TYPE_FN_STR); +embed_function("FlashWindow", ID_TYPE_FN_NUM); +add_embedded_arg("win", ID_TYPE_NUM); +embed_function("MessageBox", ID_TYPE_FN_NUM); +add_embedded_arg("title$", ID_TYPE_STR); +add_embedded_arg("msg$", ID_TYPE_STR); +embed_function("NumberArrayCopy", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_BYREF_NUM); +add_embedded_arg("dst", ID_TYPE_BYREF_NUM); +embed_function("StringArrayCopy", ID_TYPE_SUB); +add_embedded_arg("src$", ID_TYPE_BYREF_STR); +add_embedded_arg("dst$", ID_TYPE_BYREF_STR); +embed_function("ArrayCopy", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_BYREF_NUM); +add_embedded_arg("dst", ID_TYPE_BYREF_NUM); +embed_function("NumberArrayFill", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_BYREF_NUM); +add_embedded_arg("fdata", ID_TYPE_NUM); +embed_function("StringArrayFill", ID_TYPE_SUB); +add_embedded_arg("src$", ID_TYPE_BYREF_STR); +add_embedded_arg("fdata$", ID_TYPE_STR); +embed_function("ArrayFill", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_BYREF_NUM); +add_embedded_arg("fdata", ID_TYPE_NUM); +embed_function("Runtime$", ID_TYPE_FN_STR); +embed_function("DimMatrix", ID_TYPE_SUB); +add_embedded_arg("m", ID_TYPE_NUM); +add_embedded_arg("m_rows", ID_TYPE_NUM); +add_embedded_arg("m_cols", ID_TYPE_NUM); +add_embedded_arg("preserve_flag", ID_TYPE_NUM); +embed_function("AddMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("mC", ID_TYPE_NUM); +embed_function("AugmentMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("mC", ID_TYPE_NUM); +embed_function("CopyMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +embed_function("InsertMatrixColumns", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("num_cols", ID_TYPE_NUM); +embed_function("InsertMatrixRows", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("num_rows", ID_TYPE_NUM); +embed_function("MultiplyMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("mC", ID_TYPE_NUM); +embed_function("CubeMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +embed_function("DeleteMatrixColumns", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("num_cols", ID_TYPE_NUM); +embed_function("DeleteMatrixRows", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("num_rows", ID_TYPE_NUM); +embed_function("ClearMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +embed_function("ClearMatrixColumns", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("num_cols", ID_TYPE_NUM); +embed_function("ClearMatrixRows", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("num_rows", ID_TYPE_NUM); +embed_function("FillMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("v", ID_TYPE_NUM); +embed_function("FillMatrixColumns", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("num_cols", ID_TYPE_NUM); +add_embedded_arg("v", ID_TYPE_NUM); +embed_function("FillMatrixRows", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("num_rows", ID_TYPE_NUM); +add_embedded_arg("v", ID_TYPE_NUM); +embed_function("CopyMatrixColumns", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("num_cols", ID_TYPE_NUM); +embed_function("CopyMatrixRows", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("num_rows", ID_TYPE_NUM); +embed_function("IdentityMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("n", ID_TYPE_NUM); +embed_function("SolveMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("mC", ID_TYPE_NUM); +embed_function("IsEqualMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("tolerance", ID_TYPE_NUM); +embed_function("Determinant", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +embed_function("AdjointMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +embed_function("InvertMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +embed_function("MatrixFromBuffer", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); +embed_function("GetMatrix", ID_TYPE_SUB); +add_embedded_arg("buffer", ID_TYPE_BYREF_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +embed_function("RandomizeMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("vmin", ID_TYPE_NUM); +add_embedded_arg("vmax", ID_TYPE_NUM); +embed_function("MatrixValue", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +embed_function("SetMatrixValue", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("v", ID_TYPE_NUM); +embed_function("ScalarMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("s_value", ID_TYPE_NUM); +embed_function("ScalarMatrixColumns", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("num_cols", ID_TYPE_NUM); +add_embedded_arg("s_value", ID_TYPE_NUM); +embed_function("ScalarMatrixRows", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("num_rows", ID_TYPE_NUM); +add_embedded_arg("s_value", ID_TYPE_NUM); +embed_function("SquareMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +embed_function("SubMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +embed_function("SubtractMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("mC", ID_TYPE_NUM); +embed_function("SwapMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +embed_function("SwapMatrixColumn", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("C1", ID_TYPE_NUM); +add_embedded_arg("C2", ID_TYPE_NUM); +embed_function("SwapMatrixRow", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("R1", ID_TYPE_NUM); +add_embedded_arg("R2", ID_TYPE_NUM); +embed_function("TransposeMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +embed_function("UnAugmentMatrix", ID_TYPE_FN_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("mC", ID_TYPE_NUM); +embed_function("ZeroMatrix", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +embed_function("GetMatrixSize", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_BYREF_NUM); +add_embedded_arg("c", ID_TYPE_BYREF_NUM); +embed_function("SetMatrixProcess", ID_TYPE_FN_NUM); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessOpen", ID_TYPE_FN_NUM); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("SetProcessErrorMode", ID_TYPE_SUB); +add_embedded_arg("p_num", ID_TYPE_NUM); +add_embedded_arg("error_mode", ID_TYPE_NUM); +embed_function("ProcessError", ID_TYPE_FN_NUM); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessWait", ID_TYPE_SUB); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessWaitAll", ID_TYPE_SUB); +embed_function("ProcessContinue", ID_TYPE_SUB); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessStop", ID_TYPE_SUB); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessClear", ID_TYPE_SUB); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessClose", ID_TYPE_FN_NUM); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessErrorMode", ID_TYPE_FN_NUM); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessSleep", ID_TYPE_SUB); +add_embedded_arg("p_num", ID_TYPE_NUM); +add_embedded_arg("msec", ID_TYPE_NUM); +embed_function("ProcessExists", ID_TYPE_FN_NUM); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("ProcessStopAll", ID_TYPE_SUB); +embed_function("ProcessContinueAll", ID_TYPE_SUB); +embed_function("ProcessQueueSize", ID_TYPE_FN_NUM); +add_embedded_arg("p_num", ID_TYPE_NUM); +embed_function("NumCPUs", ID_TYPE_FN_NUM); +embed_function("GetProjectionGeometry", ID_TYPE_SUB); +add_embedded_arg("cam_dist", ID_TYPE_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("f_vertex_count", ID_TYPE_NUM); +add_embedded_arg("columns", ID_TYPE_BYREF_NUM); +add_embedded_arg("uv", ID_TYPE_BYREF_NUM); +add_embedded_arg("graph_offset_x", ID_TYPE_NUM); +add_embedded_arg("graph_offset_y", ID_TYPE_NUM); +add_embedded_arg("v_color", ID_TYPE_NUM); +add_embedded_arg("vertex_count", ID_TYPE_BYREF_NUM); +add_embedded_arg("vertex2D", ID_TYPE_BYREF_NUM); +add_embedded_arg("index_count", ID_TYPE_BYREF_NUM); +add_embedded_arg("index", ID_TYPE_BYREF_NUM); +add_embedded_arg("clip_dist", ID_TYPE_BYREF_NUM); +add_embedded_arg("min_x", ID_TYPE_BYREF_NUM); +add_embedded_arg("min_y", ID_TYPE_BYREF_NUM); +add_embedded_arg("max_x", ID_TYPE_BYREF_NUM); +add_embedded_arg("max_y", ID_TYPE_BYREF_NUM); +embed_function("CalculateFaceZ", ID_TYPE_FN_NUM); +add_embedded_arg("cam_dist", ID_TYPE_NUM); +add_embedded_arg("graph_offset_x", ID_TYPE_NUM); +add_embedded_arg("graph_offset_y", ID_TYPE_NUM); +add_embedded_arg("view_w", ID_TYPE_NUM); +add_embedded_arg("view_h", ID_TYPE_NUM); +add_embedded_arg("view_depth", ID_TYPE_NUM); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("f_vertex_count", ID_TYPE_NUM); +add_embedded_arg("columns", ID_TYPE_BYREF_NUM); +add_embedded_arg("face_min_z", ID_TYPE_BYREF_NUM); +add_embedded_arg("face_max_z", ID_TYPE_BYREF_NUM); +add_embedded_arg("z_avg", ID_TYPE_BYREF_NUM); +embed_function("SetChannelSpacePosition", ID_TYPE_FN_NUM); +add_embedded_arg("channel", ID_TYPE_NUM); +add_embedded_arg("angle", ID_TYPE_NUM); +add_embedded_arg("distance", ID_TYPE_NUM); +embed_function("SaveBMP", ID_TYPE_FN_NUM); +add_embedded_arg("img", ID_TYPE_NUM); +add_embedded_arg("file$", ID_TYPE_STR); +embed_function("SavePNG", ID_TYPE_FN_NUM); +add_embedded_arg("img", ID_TYPE_NUM); +add_embedded_arg("file$", ID_TYPE_STR); +embed_function("SaveJPG", ID_TYPE_FN_NUM); +add_embedded_arg("img", ID_TYPE_NUM); +add_embedded_arg("file$", ID_TYPE_STR); +embed_function("GetLineIntersection", ID_TYPE_FN_NUM); +add_embedded_arg("p0_x", ID_TYPE_NUM); +add_embedded_arg("p0_y", ID_TYPE_NUM); +add_embedded_arg("p1_x", ID_TYPE_NUM); +add_embedded_arg("p1_y", ID_TYPE_NUM); +add_embedded_arg("p2_x", ID_TYPE_NUM); +add_embedded_arg("p2_y", ID_TYPE_NUM); +add_embedded_arg("p3_x", ID_TYPE_NUM); +add_embedded_arg("p3_y", ID_TYPE_NUM); +add_embedded_arg("i_x", ID_TYPE_BYREF_NUM); +add_embedded_arg("i_y", ID_TYPE_BYREF_NUM); +embed_function("Interpolate", ID_TYPE_FN_NUM); +add_embedded_arg("min_a", ID_TYPE_NUM); +add_embedded_arg("max_a", ID_TYPE_NUM); +add_embedded_arg("mid_a", ID_TYPE_NUM); +add_embedded_arg("min_b", ID_TYPE_NUM); +add_embedded_arg("max_b", ID_TYPE_NUM); +embed_function("ATan2", ID_TYPE_FN_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +embed_function("PointInQuad", ID_TYPE_FN_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("x1", ID_TYPE_NUM); +add_embedded_arg("y1", ID_TYPE_NUM); +add_embedded_arg("x2", ID_TYPE_NUM); +add_embedded_arg("y2", ID_TYPE_NUM); +add_embedded_arg("x3", ID_TYPE_NUM); +add_embedded_arg("y3", ID_TYPE_NUM); +add_embedded_arg("x4", ID_TYPE_NUM); +add_embedded_arg("y4", ID_TYPE_NUM); +embed_function("PointInTri", ID_TYPE_FN_NUM); +add_embedded_arg("x", ID_TYPE_NUM); +add_embedded_arg("y", ID_TYPE_NUM); +add_embedded_arg("x1", ID_TYPE_NUM); +add_embedded_arg("y1", ID_TYPE_NUM); +add_embedded_arg("x2", ID_TYPE_NUM); +add_embedded_arg("y2", ID_TYPE_NUM); +add_embedded_arg("x3", ID_TYPE_NUM); +add_embedded_arg("y3", ID_TYPE_NUM); +embed_function("Distance2D", ID_TYPE_FN_NUM); +add_embedded_arg("x1", ID_TYPE_NUM); +add_embedded_arg("y1", ID_TYPE_NUM); +add_embedded_arg("x2", ID_TYPE_NUM); +add_embedded_arg("y2", ID_TYPE_NUM); +embed_function("Distance3D", ID_TYPE_FN_NUM); +add_embedded_arg("x1", ID_TYPE_NUM); +add_embedded_arg("y1", ID_TYPE_NUM); +add_embedded_arg("z1", ID_TYPE_NUM); +add_embedded_arg("x2", ID_TYPE_NUM); +add_embedded_arg("y2", ID_TYPE_NUM); +add_embedded_arg("z2", ID_TYPE_NUM); +embed_function("GetCircleLineIntersection", ID_TYPE_FN_NUM); +add_embedded_arg("circle_x", ID_TYPE_NUM); +add_embedded_arg("circle_y", ID_TYPE_NUM); +add_embedded_arg("radius", ID_TYPE_NUM); +add_embedded_arg("x1", ID_TYPE_NUM); +add_embedded_arg("y1", ID_TYPE_NUM); +add_embedded_arg("x2", ID_TYPE_NUM); +add_embedded_arg("y2", ID_TYPE_NUM); +add_embedded_arg("ix1", ID_TYPE_BYREF_NUM); +add_embedded_arg("iy1", ID_TYPE_BYREF_NUM); +add_embedded_arg("ix2", ID_TYPE_BYREF_NUM); +add_embedded_arg("iy2", ID_TYPE_BYREF_NUM); +embed_function("GetLinePlaneIntersection", ID_TYPE_FN_NUM); +add_embedded_arg("line_point", ID_TYPE_BYREF_NUM); +add_embedded_arg("line_direction", ID_TYPE_BYREF_NUM); +add_embedded_arg("plane_point_1", ID_TYPE_BYREF_NUM); +add_embedded_arg("plane_point_2", ID_TYPE_BYREF_NUM); +add_embedded_arg("plane_point_3", ID_TYPE_BYREF_NUM); +add_embedded_arg("intersection", ID_TYPE_BYREF_NUM); +embed_function("IncrementMatrixRows", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("r", ID_TYPE_NUM); +add_embedded_arg("num_rows", ID_TYPE_NUM); +add_embedded_arg("value", ID_TYPE_NUM); +embed_function("IncrementMatrixColumns", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("c", ID_TYPE_NUM); +add_embedded_arg("num_cols", ID_TYPE_NUM); +add_embedded_arg("value", ID_TYPE_NUM); +embed_function("JoinMatrixRows", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("mC", ID_TYPE_NUM); +embed_function("JoinMatrixColumns", ID_TYPE_SUB); +add_embedded_arg("mA", ID_TYPE_NUM); +add_embedded_arg("mB", ID_TYPE_NUM); +add_embedded_arg("mC", ID_TYPE_NUM); +embed_function("TypeArrayDim", ID_TYPE_FN_NUM); +add_embedded_arg("id", ID_TYPE_BYREF_USER, 0); +embed_function("TypeArraySize", ID_TYPE_FN_NUM); +add_embedded_arg("id", ID_TYPE_BYREF_USER, 0); +add_embedded_arg("array_dim", ID_TYPE_NUM); +embed_function("TypeArrayCopy", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_BYREF_USER, 0); +add_embedded_arg("dst", ID_TYPE_BYREF_USER, 0); +embed_function("TypeArrayFill", ID_TYPE_SUB); +add_embedded_arg("src", ID_TYPE_BYREF_USER, 0); +add_embedded_arg("fdata", ID_TYPE_USER, 0); diff --git a/rcbasic_build/rcbasic_dev2.txt b/rcbasic_build/rcbasic_dev2.txt new file mode 100644 index 0000000..c3f29dd --- /dev/null +++ b/rcbasic_build/rcbasic_dev2.txt @@ -0,0 +1,1428 @@ +#define FN_FPrint 0 +#define FPRINT_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Input$ 1 +#define INPUT$_PROMPT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_ArrayDim 2 +#define ARRAYDIM_ID num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_StringArrayDim 3 +#define STRINGARRAYDIM_ID$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_NumberArrayDim 4 +#define NUMBERARRAYDIM_ID num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ArraySize 5 +#define ARRAYSIZE_ID num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ARRAYSIZE_ARRAY_DIM num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_StringArraySize 6 +#define STRINGARRAYSIZE_ID$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define STRINGARRAYSIZE_ARRAY_DIM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumberArraySize 7 +#define NUMBERARRAYSIZE_ID num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define NUMBERARRAYSIZE_ARRAY_DIM num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_Abs 8 +#define ABS_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ACos 9 +#define ACOS_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_AndBit 10 +#define ANDBIT_A num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ANDBIT_B num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ASin 11 +#define ASIN_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ATan 12 +#define ATAN_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Bin$ 13 +#define BIN$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_CInt32 14 +#define CINT32_I num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_CInt64 15 +#define CINT64_I num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Cos 16 +#define COS_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Degrees 17 +#define DEGREES_R num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Exp 18 +#define EXP_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Frac 19 +#define FRAC_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Hex$ 20 +#define HEX$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_HexVal 21 +#define HEXVAL_N$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Int 22 +#define INT_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Log 23 +#define LOG_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Max 24 +#define MAX_A num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define MAX_B num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_Min 25 +#define MIN_A num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define MIN_B num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_OrBit 26 +#define ORBIT_A num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ORBIT_B num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_Radians 27 +#define RADIANS_D num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Randomize 28 +#define RANDOMIZE_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Rand 29 +#define RAND_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Round 30 +#define ROUND_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Sign 31 +#define SIGN_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Sin 32 +#define SIN_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Sqrt 33 +#define SQRT_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Tan 34 +#define TAN_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_XOrBit 35 +#define XORBIT_A num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define XORBIT_B num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_Asc 36 +#define ASC_C$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Chr$ 37 +#define CHR$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Insert$ 38 +#define INSERT$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define INSERT$_TGT$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define INSERT$_POS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_InStr 39 +#define INSTR_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define INSTR_SUBSTR$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_LCase$ 40 +#define LCASE$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Left$ 41 +#define LEFT$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define LEFT$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Length 42 +#define LENGTH_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Len 43 +#define LEN_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_LTrim$ 44 +#define LTRIM$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Mid$ 45 +#define MID$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define MID$_START num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define MID$_N num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ReplaceSubstr$ 46 +#define REPLACESUBSTR$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define REPLACESUBSTR$_RPC$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define REPLACESUBSTR$_POS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Replace$ 47 +#define REPLACE$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define REPLACE$_TGT$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define REPLACE$_RPC$ str_var[2].sid_value.value[ str_var[2].byref_offset ] +#define FN_Reverse$ 48 +#define REVERSE$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Right$ 49 +#define RIGHT$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define RIGHT$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_RTrim$ 50 +#define RTRIM$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_StringFill$ 51 +#define STRINGFILL$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define STRINGFILL$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Str$ 52 +#define STR$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Str_F$ 53 +#define STR_F$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Str_S$ 54 +#define STR_S$_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Tally 55 +#define TALLY_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define TALLY_SUBSTR$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_Trim$ 56 +#define TRIM$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_UCase$ 57 +#define UCASE$_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Val 58 +#define VAL_N$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Stack_N 59 +#define STACK_N_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Stack_S 60 +#define STACK_S_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Push_N 61 +#define PUSH_N_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Pop_N 62 +#define FN_Push_S 63 +#define PUSH_S_S$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Pop_S$ 64 +#define FN_Stack_Size_N 65 +#define FN_Stack_Size_S 66 +#define FN_FileOpen 67 +#define FILEOPEN_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FILEOPEN_FILENAME$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FILEOPEN_MODE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_FileClose 68 +#define FILECLOSE_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ReadByte 69 +#define READBYTE_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WriteByte 70 +#define WRITEBYTE_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WRITEBYTE_BYTE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ReadLine$ 71 +#define READLINE$_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Write 72 +#define WRITE_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WRITE_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_WriteLine 73 +#define WRITELINE_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WRITELINE_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_CopyFile 74 +#define COPYFILE_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define COPYFILE_DST$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_RemoveFile 75 +#define REMOVEFILE_FILENAME$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_FileExists 76 +#define FILEEXISTS_FILENAME$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_MoveFile 77 +#define MOVEFILE_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define MOVEFILE_DST$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_RenameFile 78 +#define RENAMEFILE_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define RENAMEFILE_DST$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_FileLength 79 +#define FILELENGTH_FILENAME$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Tell 80 +#define TELL_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Seek 81 +#define SEEK_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SEEK_POS num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_EOF 82 +#define EOF_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_FreeFile 83 +#define FN_ChangeDir 84 +#define CHANGEDIR_P$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_DirExists 85 +#define DIREXISTS_P$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_DirFirst$ 86 +#define FN_Dir$ 87 +#define FN_DirNext$ 88 +#define FN_MakeDir 89 +#define MAKEDIR_P$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_RemoveDir 90 +#define REMOVEDIR_P$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Date$ 91 +#define FN_Easter$ 92 +#define EASTER$_YEAR num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Ticks 93 +#define FN_Time$ 94 +#define FN_Timer 95 +#define FN_Wait 96 +#define WAIT_M_SEC num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowOpen 97 +#define WINDOWOPEN_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WINDOWOPEN_TITLE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define WINDOWOPEN_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define WINDOWOPEN_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define WINDOWOPEN_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define WINDOWOPEN_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define WINDOWOPEN_FLAG num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define WINDOWOPEN_VSYNC num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define FN_WindowClose 98 +#define WINDOWCLOSE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_RaiseWindow 99 +#define RAISEWINDOW_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Window 100 +#define WINDOW_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Update 101 +#define FN_Cls 102 +#define FN_SetClearColor 103 +#define SETCLEARCOLOR_C num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ShowWindow 104 +#define SHOWWINDOW_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_HideWindow 105 +#define HIDEWINDOW_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetWindowTitle 106 +#define SETWINDOWTITLE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWTITLE_TITLE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_WindowTitle$ 107 +#define WINDOWTITLE$_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetWindowPosition 108 +#define SETWINDOWPOSITION_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWPOSITION_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETWINDOWPOSITION_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_GetWindowPosition 109 +#define GETWINDOWPOSITION_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETWINDOWPOSITION_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETWINDOWPOSITION_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SetWindowSize 110 +#define SETWINDOWSIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWSIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETWINDOWSIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_GetWindowSize 111 +#define GETWINDOWSIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETWINDOWSIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETWINDOWSIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SetWindowMinSize 112 +#define SETWINDOWMINSIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWMINSIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETWINDOWMINSIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_GetWindowMinSize 113 +#define GETWINDOWMINSIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETWINDOWMINSIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETWINDOWMINSIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SetWindowMaxSize 114 +#define SETWINDOWMAXSIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWMAXSIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETWINDOWMAXSIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_GetWindowMaxSize 115 +#define GETWINDOWMAXSIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETWINDOWMAXSIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETWINDOWMAXSIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_WindowIsFullscreen 116 +#define WINDOWISFULLSCREEN_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowIsVisible 117 +#define WINDOWISVISIBLE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowIsBordered 118 +#define WINDOWISBORDERED_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowIsResizable 119 +#define WINDOWISRESIZABLE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowIsMinimized 120 +#define WINDOWISMINIMIZED_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowIsMaximized 121 +#define WINDOWISMAXIMIZED_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowHasInputFocus 122 +#define WINDOWHASINPUTFOCUS_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowHasMouseFocus 123 +#define WINDOWHASMOUSEFOCUS_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetWindowFullscreen 124 +#define SETWINDOWFULLSCREEN_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWFULLSCREEN_FLAG num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_MaximizeWindow 125 +#define MAXIMIZEWINDOW_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_MinimizeWindow 126 +#define MINIMIZEWINDOW_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetWindowBorder 127 +#define SETWINDOWBORDER_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWBORDER_FLAG num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_WindowClip 128 +#define WINDOWCLIP_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WINDOWCLIP_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define WINDOWCLIP_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define WINDOWCLIP_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define WINDOWCLIP_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_WindowExists 129 +#define WINDOWEXISTS_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumWindows 130 +#define FN_WindowEvent_Close 131 +#define WINDOWEVENT_CLOSE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowEvent_Maximize 132 +#define WINDOWEVENT_MAXIMIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WindowEvent_Minimize 133 +#define WINDOWEVENT_MINIMIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ActiveWindow 134 +#define FN_FPS 135 +#define FN_SetWindowIcon 136 +#define SETWINDOWICON_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWICON_SLOT num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_CanvasOpen 137 +#define CANVASOPEN_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CANVASOPEN_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define CANVASOPEN_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define CANVASOPEN_VIEWPORT_X num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define CANVASOPEN_VIEWPORT_Y num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define CANVASOPEN_VIEWPORT_W num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define CANVASOPEN_VIEWPORT_H num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define CANVASOPEN_MODE num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define FN_CanvasClose 138 +#define CANVASCLOSE_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetCanvasVisible 139 +#define SETCANVASVISIBLE_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCANVASVISIBLE_FLAG num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_CanvasIsVisible 140 +#define CANVASISVISIBLE_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetCanvasViewport 141 +#define SETCANVASVIEWPORT_CNUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCANVASVIEWPORT_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETCANVASVIEWPORT_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define SETCANVASVIEWPORT_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define SETCANVASVIEWPORT_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_GetCanvasViewport 142 +#define GETCANVASVIEWPORT_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETCANVASVIEWPORT_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETCANVASVIEWPORT_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETCANVASVIEWPORT_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETCANVASVIEWPORT_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_Canvas 143 +#define CANVAS_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetCanvasOffset 144 +#define SETCANVASOFFSET_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCANVASOFFSET_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETCANVASOFFSET_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_GetCanvasOffset 145 +#define GETCANVASOFFSET_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETCANVASOFFSET_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETCANVASOFFSET_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_GetCanvasSize 146 +#define GETCANVASSIZE_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETCANVASSIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETCANVASSIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_ClearCanvas 147 +#define FN_SetCanvasAlpha 148 +#define SETCANVASALPHA_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCANVASALPHA_A num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_CanvasAlpha 149 +#define CANVASALPHA_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetCanvasBlendMode 150 +#define SETCANVASBLENDMODE_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCANVASBLENDMODE_BLEND_MODE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_CanvasBlendMode 151 +#define CANVASBLENDMODE_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetCanvasColorMod 152 +#define SETCANVASCOLORMOD_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCANVASCOLORMOD_C num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_CanvasColorMod 153 +#define CANVASCOLORMOD_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_CopyCanvas 154 +#define COPYCANVAS_SRC num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define COPYCANVAS_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define COPYCANVAS_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define COPYCANVAS_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define COPYCANVAS_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define COPYCANVAS_DST num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define COPYCANVAS_DX num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define COPYCANVAS_DY num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define FN_CloneCanvas 155 +#define CLONECANVAS_SRC num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CLONECANVAS_DST num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SetCanvasZ 156 +#define SETCANVASZ_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCANVASZ_Z num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_CanvasZ 157 +#define CANVASZ_C_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_CanvasClip 158 +#define CANVASCLIP_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CANVASCLIP_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define CANVASCLIP_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define CANVASCLIP_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define CANVASCLIP_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define CANVASCLIP_FLAG num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define FN_ActiveCanvas 159 +#define FN_Box 160 +#define BOX_X1 num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define BOX_Y1 num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define BOX_X2 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define BOX_Y2 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_BoxFill 161 +#define BOXFILL_X1 num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define BOXFILL_Y1 num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define BOXFILL_X2 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define BOXFILL_Y2 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_Circle 162 +#define CIRCLE_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CIRCLE_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define CIRCLE_RADIUS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_CircleFill 163 +#define CIRCLEFILL_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CIRCLEFILL_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define CIRCLEFILL_RADIUS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_Ellipse 164 +#define ELLIPSE_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ELLIPSE_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define ELLIPSE_RX num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define ELLIPSE_RY num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_EllipseFill 165 +#define ELLIPSEFILL_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ELLIPSEFILL_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define ELLIPSEFILL_RX num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define ELLIPSEFILL_RY num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_FloodFill 166 +#define FLOODFILL_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FLOODFILL_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_GetPixel 167 +#define GETPIXEL_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETPIXEL_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SetColor 168 +#define SETCOLOR_C num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Line 169 +#define LINE_X1 num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define LINE_Y1 num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define LINE_X2 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define LINE_Y2 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_Poly 170 +#define POLY_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define POLY_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define POLY_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_PolyFill 171 +#define POLYFILL_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define POLYFILL_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define POLYFILL_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_Rect 172 +#define RECT_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define RECT_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define RECT_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define RECT_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_RectFill 173 +#define RECTFILL_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define RECTFILL_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define RECTFILL_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define RECTFILL_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_RoundRect 174 +#define ROUNDRECT_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ROUNDRECT_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define ROUNDRECT_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define ROUNDRECT_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define ROUNDRECT_R num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_RoundRectFill 175 +#define ROUNDRECTFILL_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ROUNDRECTFILL_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define ROUNDRECTFILL_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define ROUNDRECTFILL_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define ROUNDRECTFILL_R num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_RGB 176 +#define RGB_R num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define RGB_G num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define RGB_B num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_RGBA 177 +#define RGBA_R num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define RGBA_G num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define RGBA_B num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define RGBA_A num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_PSet 178 +#define PSET_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define PSET_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_LoadImage 179 +#define LOADIMAGE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define LOADIMAGE_IMG$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_LoadImage_Ex 180 +#define LOADIMAGE_EX_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define LOADIMAGE_EX_IMG$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define LOADIMAGE_EX_COLKEY num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ImageFromBuffer 181 +#define IMAGEFROMBUFFER_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define IMAGEFROMBUFFER_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define IMAGEFROMBUFFER_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define IMAGEFROMBUFFER_BUFFER num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_ImageFromBuffer_Ex 182 +#define IMAGEFROMBUFFER_EX_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define IMAGEFROMBUFFER_EX_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define IMAGEFROMBUFFER_EX_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define IMAGEFROMBUFFER_EX_BUFFER num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define IMAGEFROMBUFFER_EX_COLKEY num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_BufferFromImage 183 +#define BUFFERFROMIMAGE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define BUFFERFROMIMAGE_BUFFER num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ImageExists 184 +#define IMAGEEXISTS_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ColorKey 185 +#define COLORKEY_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define COLORKEY_C num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_CopyImage 186 +#define COPYIMAGE_SRC num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define COPYIMAGE_DST num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_DeleteImage 187 +#define DELETEIMAGE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetImageAlpha 188 +#define SETIMAGEALPHA_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETIMAGEALPHA_A num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ImageAlpha 189 +#define IMAGEALPHA_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_GetImageSize 190 +#define GETIMAGESIZE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETIMAGESIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETIMAGESIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SetImageBlendMode 191 +#define SETIMAGEBLENDMODE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETIMAGEBLENDMODE_BLEND_MODE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ImageBlendMode 192 +#define IMAGEBLENDMODE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetImageColorMod 193 +#define SETIMAGECOLORMOD_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETIMAGECOLORMOD_C num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ImageColorMod 194 +#define IMAGECOLORMOD_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_DrawImage 195 +#define DRAWIMAGE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_DrawImage_Blit 196 +#define DRAWIMAGE_BLIT_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_BLIT_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_BLIT_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_BLIT_SRC_X num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_BLIT_SRC_Y num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DRAWIMAGE_BLIT_SRC_W num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define DRAWIMAGE_BLIT_SRC_H num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define FN_DrawImage_Blit_Ex 197 +#define DRAWIMAGE_BLIT_EX_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_BLIT_EX_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_BLIT_EX_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_BLIT_EX_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_BLIT_EX_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DRAWIMAGE_BLIT_EX_SRC_X num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define DRAWIMAGE_BLIT_EX_SRC_Y num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define DRAWIMAGE_BLIT_EX_SRC_W num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define DRAWIMAGE_BLIT_EX_SRC_H num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define FN_DrawImage_Rotate 198 +#define DRAWIMAGE_ROTATE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_ROTATE_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_ROTATE_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_ROTATE_ANGLE num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_DrawImage_Rotate_Ex 199 +#define DRAWIMAGE_ROTATE_EX_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_ROTATE_EX_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_ROTATE_EX_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_ROTATE_EX_SRC_X num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_ROTATE_EX_SRC_Y num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DRAWIMAGE_ROTATE_EX_SRC_W num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define DRAWIMAGE_ROTATE_EX_SRC_H num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define DRAWIMAGE_ROTATE_EX_ANGLE num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define FN_DrawImage_Zoom 200 +#define DRAWIMAGE_ZOOM_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_ZOOM_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_ZOOM_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_ZOOM_ZX num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_ZOOM_ZY num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_DrawImage_Zoom_Ex 201 +#define DRAWIMAGE_ZOOM_EX_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_ZOOM_EX_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_ZOOM_EX_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_ZOOM_EX_SRC_X num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_ZOOM_EX_SRC_Y num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DRAWIMAGE_ZOOM_EX_SRC_W num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define DRAWIMAGE_ZOOM_EX_SRC_H num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define DRAWIMAGE_ZOOM_EX_ZX num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define DRAWIMAGE_ZOOM_EX_ZY num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define FN_DrawImage_Rotozoom 202 +#define DRAWIMAGE_ROTOZOOM_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_ANGLE num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_ZX num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_ZY num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define FN_DrawImage_Rotozoom_Ex 203 +#define DRAWIMAGE_ROTOZOOM_EX_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_SRC_X num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_SRC_Y num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_SRC_W num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_SRC_H num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_ANGLE num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_ZX num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define DRAWIMAGE_ROTOZOOM_EX_ZY num_var[9].nid_value.value[ num_var[9].byref_offset ] +#define FN_DrawImage_Flip 204 +#define DRAWIMAGE_FLIP_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_FLIP_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_FLIP_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_FLIP_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_FLIP_V num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_DrawImage_Flip_Ex 205 +#define DRAWIMAGE_FLIP_EX_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_FLIP_EX_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_FLIP_EX_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_FLIP_EX_SRC_X num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_FLIP_EX_SRC_Y num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DRAWIMAGE_FLIP_EX_SRC_W num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define DRAWIMAGE_FLIP_EX_SRC_H num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define DRAWIMAGE_FLIP_EX_H num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define DRAWIMAGE_FLIP_EX_V num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define FN_InKey 206 +#define FN_Key 207 +#define KEY_KEY_CODE num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WaitKey 208 +#define FN_HideMouse 209 +#define FN_ShowMouse 210 +#define FN_MouseIsVisible 211 +#define FN_GetMouse 212 +#define GETMOUSE_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETMOUSE_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETMOUSE_MB1 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETMOUSE_MB2 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETMOUSE_MB3 num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_MouseX 213 +#define FN_MouseY 214 +#define FN_MouseButton 215 +#define MOUSEBUTTON_MB num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_GetMouseWheel 216 +#define GETMOUSEWHEEL_X_AXIS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETMOUSEWHEEL_Y_AXIS num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_MouseWheelX 217 +#define FN_MouseWheelY 218 +#define FN_SoundFromBuffer 219 +#define SOUNDFROMBUFFER_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SOUNDFROMBUFFER_BUFFER num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SOUNDFROMBUFFER_BUFFER_SIZE num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define SOUNDFROMBUFFER_VOL num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_LoadSound 220 +#define LOADSOUND_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define LOADSOUND_SND_FILE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_LoadMusic 221 +#define LOADMUSIC_MUSIC_FILE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_PlaySound 222 +#define PLAYSOUND_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define PLAYSOUND_CHANNEL num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define PLAYSOUND_LOOPS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_PlaySoundTimed 223 +#define PLAYSOUNDTIMED_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define PLAYSOUNDTIMED_CHANNEL num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define PLAYSOUNDTIMED_LOOPS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define PLAYSOUNDTIMED_MS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_PlayMusic 224 +#define PLAYMUSIC_MLOOPS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_PauseSound 225 +#define PAUSESOUND_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ResumeSound 226 +#define RESUMESOUND_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_PauseMusic 227 +#define FN_ResumeMusic 228 +#define FN_DeleteSound 229 +#define DELETESOUND_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_DeleteMusic 230 +#define FN_FadeMusicIn 231 +#define FADEMUSICIN_FADE_TIME num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FADEMUSICIN_LOOPS num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_FadeMusicOut 232 +#define FADEMUSICOUT_FADE_TIME num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_MusicExists 233 +#define FN_SetMusicVolume 234 +#define SETMUSICVOLUME_VOL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_MusicVolume 235 +#define FN_SetMusicPosition 236 +#define SETMUSICPOSITION_POS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_MusicPosition 237 +#define FN_RewindMusic 238 +#define FN_SetSoundChannels 239 +#define SETSOUNDCHANNELS_MAX_CHANNELS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumSoundChannels 240 +#define FN_SoundIsEnabled 241 +#define FN_SoundExists 242 +#define SOUNDEXISTS_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetChannelVolume 243 +#define SETCHANNELVOLUME_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCHANNELVOLUME_VOL num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ChannelVolume 244 +#define CHANNELVOLUME_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetSoundVolume 245 +#define SETSOUNDVOLUME_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETSOUNDVOLUME_VOL num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SoundVolume 246 +#define SOUNDVOLUME_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_StopMusic 247 +#define FN_StopSound 248 +#define STOPSOUND_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetChannelPanning 249 +#define SETCHANNELPANNING_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCHANNELPANNING_LEFT_VALUE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETCHANNELPANNING_RIGHT_VALUE num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SetChannelDistance 250 +#define SETCHANNELDISTANCE_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCHANNELDISTANCE_DIST_VALUE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ChannelIsPlaying 251 +#define CHANNELISPLAYING_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ChannelIsPaused 252 +#define CHANNELISPAUSED_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumJoysticks 253 +#define FN_NumJoyAxes 254 +#define NUMJOYAXES_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumJoyButtons 255 +#define NUMJOYBUTTONS_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumJoyHats 256 +#define NUMJOYHATS_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumJoyTrackBalls 257 +#define NUMJOYTRACKBALLS_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_JoyAxis 258 +#define JOYAXIS_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define JOYAXIS_JOY_AXIS num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_JoyButton 259 +#define JOYBUTTON_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define JOYBUTTON_JOY_BUTTON num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_JoyHat 260 +#define JOYHAT_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define JOYHAT_JOY_HAT num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_GetJoyTrackBall 261 +#define GETJOYTRACKBALL_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETJOYTRACKBALL_BALL num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETJOYTRACKBALL_DX num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETJOYTRACKBALL_DY num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_JoyName$ 262 +#define JOYNAME$_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_JoystickIsConnected 263 +#define JOYSTICKISCONNECTED_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_GetCursor 264 +#define GETCURSOR_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETCURSOR_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_PrintS 265 +#define PRINTS_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_InputS$ 266 +#define INPUTS$_PROMPT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_ZoneInputS$ 267 +#define ZONEINPUTS$_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ZONEINPUTS$_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define ZONEINPUTS$_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define ZONEINPUTS$_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_Locate 268 +#define LOCATE_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define LOCATE_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ReadInput_Start 269 +#define FN_ReadInput_Stop 270 +#define FN_ReadInput_Text$ 271 +#define FN_ReadInput_SetText 272 +#define READINPUT_SETTEXT_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_ReadInput_ToggleBackspace 273 +#define READINPUT_TOGGLEBACKSPACE_FLAG num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_LoadFont 274 +#define LOADFONT_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define LOADFONT_FNT_FILE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define LOADFONT_SIZE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_DeleteFont 275 +#define DELETEFONT_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_FontIsLoaded 276 +#define FONTISLOADED_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_Font 277 +#define FONT_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetFontStyle 278 +#define SETFONTSTYLE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETFONTSTYLE_STYLE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_DrawText 279 +#define DRAWTEXT_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define DRAWTEXT_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWTEXT_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_DrawText_Shaded 280 +#define DRAWTEXT_SHADED_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define DRAWTEXT_SHADED_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWTEXT_SHADED_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWTEXT_SHADED_FG_COLOR num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWTEXT_SHADED_BG_COLOR num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_DrawText_Blended 281 +#define DRAWTEXT_BLENDED_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define DRAWTEXT_BLENDED_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWTEXT_BLENDED_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_RenderText 282 +#define RENDERTEXT_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define RENDERTEXT_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_GetTextSize 283 +#define GETTEXTSIZE_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETTEXTSIZE_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define GETTEXTSIZE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETTEXTSIZE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_TouchPressure 284 +#define FN_GetTouch 285 +#define GETTOUCH_STATUS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETTOUCH_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETTOUCH_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETTOUCH_DX num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETTOUCH_DY num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_GetMultiTouch 286 +#define GETMULTITOUCH_STATUS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETMULTITOUCH_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETMULTITOUCH_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETMULTITOUCH_FINGERS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETMULTITOUCH_DIST num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define GETMULTITOUCH_THETA num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define FN_GetTouchFinger 287 +#define GETTOUCHFINGER_FINGER num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETTOUCHFINGER_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETTOUCHFINGER_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETTOUCHFINGER_PRESSURE num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_NumFingers 288 +#define FN_CheckSockets 289 +#define CHECKSOCKETS_TIMEOUT_MS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_TCP_SocketReady 290 +#define TCP_SOCKETREADY_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_UDP_SocketReady 291 +#define UDP_SOCKETREADY_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_TCP_SocketOpen 292 +#define TCP_SOCKETOPEN_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define TCP_SOCKETOPEN_HOST$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define TCP_SOCKETOPEN_PORT num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_TCP_SocketClose 293 +#define TCP_SOCKETCLOSE_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_TCP_RemoteHost 294 +#define TCP_REMOTEHOST_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_TCP_RemotePort 295 +#define TCP_REMOTEPORT_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_TCP_GetData 296 +#define TCP_GETDATA_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define TCP_GETDATA_SDATA$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define TCP_GETDATA_NUMBYTES num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_TCP_SendData 297 +#define TCP_SENDDATA_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define TCP_SENDDATA_SDATA$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_TCP_AcceptSocket 298 +#define TCP_ACCEPTSOCKET_SERVER num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define TCP_ACCEPTSOCKET_CLIENT num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_UDP_SocketOpen 299 +#define UDP_SOCKETOPEN_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define UDP_SOCKETOPEN_PORT num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_UDP_SocketClose 300 +#define UDP_SOCKETCLOSE_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_UDP_GetData 301 +#define UDP_GETDATA_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define UDP_GETDATA_SDATA$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define UDP_GETDATA_HOST$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define UDP_GETDATA_PORT num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_UDP_Length 302 +#define FN_UDP_MaxLength 303 +#define FN_UDP_RemoteHost$ 304 +#define UDP_REMOTEHOST$_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_UDP_RemotePort 305 +#define UDP_REMOTEPORT_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_UDP_SendData 306 +#define UDP_SENDDATA_SOCKET num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define UDP_SENDDATA_SDATA$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define UDP_SENDDATA_HOST$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define UDP_SENDDATA_PORT num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_LoadVideo 307 +#define LOADVIDEO_VID$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_PlayVideo 308 +#define PLAYVIDEO_VLOOPS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_PauseVideo 309 +#define FN_StopVideo 310 +#define FN_SetVideoPosition 311 +#define SETVIDEOPOSITION_POS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ResumeVideo 312 +#define FN_VideoPosition 313 +#define FN_DeleteVideo 314 +#define FN_VideoIsPlaying 315 +#define FN_VideoEnd 316 +#define FN_GetVideoStats 317 +#define GETVIDEOSTATS_VFILE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define GETVIDEOSTATS_VLEN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETVIDEOSTATS_VFPS num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETVIDEOSTATS_FRAME_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETVIDEOSTATS_FRAME_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_SetVideoDrawRect 318 +#define SETVIDEODRAWRECT_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETVIDEODRAWRECT_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETVIDEODRAWRECT_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define SETVIDEODRAWRECT_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_GetVideoDrawRect 319 +#define GETVIDEODRAWRECT_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETVIDEODRAWRECT_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETVIDEODRAWRECT_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETVIDEODRAWRECT_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_GetVideoSize 320 +#define GETVIDEOSIZE_W num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETVIDEOSIZE_H num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_VideoExists 321 +#define FN_SetVideoAlpha 322 +#define SETVIDEOALPHA_A num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_System 323 +#define SYSTEM_CMD$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_OS$ 324 +#define FN_Command$ 325 +#define COMMAND$_ARG num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumCommands 326 +#define FN_Env$ 327 +#define ENV$_V$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_SetEnv 328 +#define SETENV_VAR$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define SETENV_VALUE$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define SETENV_OVERWRITE num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_PrefPath$ 329 +#define PREFPATH$_ORG_NAME$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define PREFPATH$_APP_NAME$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_Android_GetExternalStoragePath$ 330 +#define FN_Android_GetExternalStorageState 331 +#define FN_Android_GetInternalStoragePath$ 332 +#define FN_Android_JNI_Message$ 333 +#define ANDROID_JNI_MESSAGE$_ARG$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_Runtime_Utility_Message$ 334 +#define RUNTIME_UTILITY_MESSAGE$_ARG$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_ClipboardText$ 335 +#define FN_SetClipboardText 336 +#define SETCLIPBOARDTEXT_TXT$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_HasClipboardText 337 +#define FN_GetDesktopDisplayMode 338 +#define GETDESKTOPDISPLAYMODE_INDEX num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETDESKTOPDISPLAYMODE_W num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETDESKTOPDISPLAYMODE_H num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETDESKTOPDISPLAYMODE_FREQ num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_DrawImage_Transform 339 +#define DRAWIMAGE_TRANSFORM_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWIMAGE_TRANSFORM_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWIMAGE_TRANSFORM_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWIMAGE_TRANSFORM_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWIMAGE_TRANSFORM_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DRAWIMAGE_TRANSFORM_SRC_X num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define DRAWIMAGE_TRANSFORM_SRC_Y num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define DRAWIMAGE_TRANSFORM_SRC_W num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define DRAWIMAGE_TRANSFORM_SRC_H num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define DRAWIMAGE_TRANSFORM_ANGLE num_var[9].nid_value.value[ num_var[9].byref_offset ] +#define DRAWIMAGE_TRANSFORM_CENTER_X num_var[10].nid_value.value[ num_var[10].byref_offset ] +#define DRAWIMAGE_TRANSFORM_CENTER_Y num_var[11].nid_value.value[ num_var[11].byref_offset ] +#define DRAWIMAGE_TRANSFORM_FLIP_H num_var[12].nid_value.value[ num_var[12].byref_offset ] +#define DRAWIMAGE_TRANSFORM_FLIP_V num_var[13].nid_value.value[ num_var[13].byref_offset ] +#define FN_GetPowerInfo 340 +#define GETPOWERINFO_STATUS num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETPOWERINFO_SECS num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETPOWERINFO_PCT num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SystemRam 341 +#define FN_SetRenderScaleQuality 342 +#define SETRENDERSCALEQUALITY_N num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_EvalJS$ 343 +#define EVALJS$_JS_CODE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_GetRenderScaleQuality 344 +#define FN_GetGlobalMouse 345 +#define GETGLOBALMOUSE_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETGLOBALMOUSE_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETGLOBALMOUSE_MB1 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETGLOBALMOUSE_MB2 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETGLOBALMOUSE_MB3 num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_GlobalMouseX 346 +#define FN_GlobalMouseY 347 +#define FN_GetAccel 348 +#define GETACCEL_ACCEL_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETACCEL_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETACCEL_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETACCEL_Z num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_AccelName$ 349 +#define ACCELNAME$_ACCEL_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumAccels 350 +#define FN_GetGyro 351 +#define GETGYRO_GYRO_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETGYRO_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETGYRO_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETGYRO_Z num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_GyroName$ 352 +#define GYRONAME$_GYRO_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumGyros 353 +#define FN_JoyRumblePlay 354 +#define JOYRUMBLEPLAY_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define JOYRUMBLEPLAY_STRENGTH num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define JOYRUMBLEPLAY_DURATION num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_JoyRumbleStop 355 +#define JOYRUMBLESTOP_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_JoystickIsHaptic 356 +#define JOYSTICKISHAPTIC_JOY_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_WriteByteBuffer 357 +#define WRITEBYTEBUFFER_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WRITEBYTEBUFFER_BUF num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define WRITEBYTEBUFFER_BUF_SIZE num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_ReadByteBuffer 358 +#define READBYTEBUFFER_STREAM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define READBYTEBUFFER_BUF num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define READBYTEBUFFER_BUF_SIZE num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_WindowEvent_Resize 359 +#define WINDOWEVENT_RESIZE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetWindowAutoClose 360 +#define SETWINDOWAUTOCLOSE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWAUTOCLOSE_EXIT_ON_CLOSE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SetWindowResizable 361 +#define SETWINDOWRESIZABLE_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWRESIZABLE_FLAG num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SystemReturnStdOut$ 362 +#define SYSTEMRETURNSTDOUT$_CMD$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_WindowMode 363 +#define WINDOWMODE_VISIBLE num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WINDOWMODE_FULLSCREEN num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define WINDOWMODE_RESIZABLE num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define WINDOWMODE_BORDERLESS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define WINDOWMODE_HIGHDPI num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_WindowFlags 364 +#define WINDOWFLAGS_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_RestoreWindow 365 +#define RESTOREWINDOW_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_UpdateAllWindows 366 +#define FN_QueryAudioSpec 367 +#define QUERYAUDIOSPEC_FREQ num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define QUERYAUDIOSPEC_FORMAT num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define QUERYAUDIOSPEC_CHANNELS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_MusicIsPlaying 368 +#define FN_DrawGeometry 369 +#define DRAWGEOMETRY_SLOT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DRAWGEOMETRY_NUM_VERTICES num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DRAWGEOMETRY_VERTICES num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DRAWGEOMETRY_NUM_INDICES num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DRAWGEOMETRY_INDICES num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_Size 370 +#define SIZE_S$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_BufferFromString 371 +#define BUFFERFROMSTRING_S$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define BUFFERFROMSTRING_BUFFER num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_StringFromBuffer$ 372 +#define STRINGFROMBUFFER$_BUFFER num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define STRINGFROMBUFFER$_BUFFER_SIZE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_GrabInput 373 +#define GRABINPUT_FLAG num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_GrabbedWindow 374 +#define FN_WarpMouse 375 +#define WARPMOUSE_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WARPMOUSE_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_WarpMouseGlobal 376 +#define WARPMOUSEGLOBAL_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define WARPMOUSEGLOBAL_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SetMouseZone 377 +#define SETMOUSEZONE_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETMOUSEZONE_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETMOUSEZONE_W num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define SETMOUSEZONE_H num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_ClearMouseZone 378 +#define FN_SetWindowAlwaysOnTop 379 +#define SETWINDOWALWAYSONTOP_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWALWAYSONTOP_FLAG num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SetMouseRelative 380 +#define SETMOUSERELATIVE_FLAG num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetWindowVSync 381 +#define SETWINDOWVSYNC_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETWINDOWVSYNC_FLAG num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_OpenURL 382 +#define OPENURL_URL$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_APIVersion$ 383 +#define FN_FlashWindow 384 +#define FLASHWINDOW_WIN num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_MessageBox 385 +#define MESSAGEBOX_TITLE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define MESSAGEBOX_MSG$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_NumberArrayCopy 386 +#define NUMBERARRAYCOPY_SRC num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define NUMBERARRAYCOPY_DST num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_StringArrayCopy 387 +#define STRINGARRAYCOPY_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define STRINGARRAYCOPY_DST$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_ArrayCopy 388 +#define ARRAYCOPY_SRC num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ARRAYCOPY_DST num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_NumberArrayFill 389 +#define NUMBERARRAYFILL_SRC num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define NUMBERARRAYFILL_FDATA num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_StringArrayFill 390 +#define STRINGARRAYFILL_SRC$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define STRINGARRAYFILL_FDATA$ str_var[1].sid_value.value[ str_var[1].byref_offset ] +#define FN_ArrayFill 391 +#define ARRAYFILL_SRC num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ARRAYFILL_FDATA num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_Runtime$ 392 +#define FN_DimMatrix 393 +#define DIMMATRIX_M num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DIMMATRIX_M_ROWS num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DIMMATRIX_M_COLS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DIMMATRIX_PRESERVE_FLAG num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_AddMatrix 394 +#define ADDMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ADDMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define ADDMATRIX_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_AugmentMatrix 395 +#define AUGMENTMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define AUGMENTMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define AUGMENTMATRIX_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_CopyMatrix 396 +#define COPYMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define COPYMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_InsertMatrixColumns 397 +#define INSERTMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define INSERTMATRIXCOLUMNS_C num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define INSERTMATRIXCOLUMNS_NUM_COLS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_InsertMatrixRows 398 +#define INSERTMATRIXROWS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define INSERTMATRIXROWS_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define INSERTMATRIXROWS_NUM_ROWS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_MultiplyMatrix 399 +#define MULTIPLYMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define MULTIPLYMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define MULTIPLYMATRIX_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_CubeMatrix 400 +#define CUBEMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CUBEMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_DeleteMatrixColumns 401 +#define DELETEMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DELETEMATRIXCOLUMNS_C num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DELETEMATRIXCOLUMNS_NUM_COLS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_DeleteMatrixRows 402 +#define DELETEMATRIXROWS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DELETEMATRIXROWS_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DELETEMATRIXROWS_NUM_ROWS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_ClearMatrix 403 +#define CLEARMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ClearMatrixColumns 404 +#define CLEARMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CLEARMATRIXCOLUMNS_C num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define CLEARMATRIXCOLUMNS_NUM_COLS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_ClearMatrixRows 405 +#define CLEARMATRIXROWS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CLEARMATRIXROWS_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define CLEARMATRIXROWS_NUM_ROWS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_FillMatrix 406 +#define FILLMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FILLMATRIX_V num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_FillMatrixColumns 407 +#define FILLMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FILLMATRIXCOLUMNS_C num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FILLMATRIXCOLUMNS_NUM_COLS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FILLMATRIXCOLUMNS_V num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_FillMatrixRows 408 +#define FILLMATRIXROWS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FILLMATRIXROWS_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FILLMATRIXROWS_NUM_ROWS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FILLMATRIXROWS_V num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_CopyMatrixColumns 409 +#define COPYMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define COPYMATRIXCOLUMNS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define COPYMATRIXCOLUMNS_C num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define COPYMATRIXCOLUMNS_NUM_COLS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_CopyMatrixRows 410 +#define COPYMATRIXROWS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define COPYMATRIXROWS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define COPYMATRIXROWS_R num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define COPYMATRIXROWS_NUM_ROWS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_IdentityMatrix 411 +#define IDENTITYMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define IDENTITYMATRIX_N num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SolveMatrix 412 +#define SOLVEMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SOLVEMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SOLVEMATRIX_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_IsEqualMatrix 413 +#define ISEQUALMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ISEQUALMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define ISEQUALMATRIX_TOLERANCE num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_Determinant 414 +#define DETERMINANT_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_AdjointMatrix 415 +#define ADJOINTMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ADJOINTMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_InvertMatrix 416 +#define INVERTMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define INVERTMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_MatrixFromBuffer 417 +#define MATRIXFROMBUFFER_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define MATRIXFROMBUFFER_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define MATRIXFROMBUFFER_C num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define MATRIXFROMBUFFER_BUFFER num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_GetMatrix 418 +#define GETMATRIX_BUFFER num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETMATRIX_MA num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_RandomizeMatrix 419 +#define RANDOMIZEMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define RANDOMIZEMATRIX_VMIN num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define RANDOMIZEMATRIX_VMAX num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_MatrixValue 420 +#define MATRIXVALUE_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define MATRIXVALUE_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define MATRIXVALUE_C num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SetMatrixValue 421 +#define SETMATRIXVALUE_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETMATRIXVALUE_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETMATRIXVALUE_C num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define SETMATRIXVALUE_V num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_ScalarMatrix 422 +#define SCALARMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SCALARMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SCALARMATRIX_S_VALUE num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_ScalarMatrixColumns 423 +#define SCALARMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SCALARMATRIXCOLUMNS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SCALARMATRIXCOLUMNS_C num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define SCALARMATRIXCOLUMNS_NUM_COLS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define SCALARMATRIXCOLUMNS_S_VALUE num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_ScalarMatrixRows 424 +#define SCALARMATRIXROWS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SCALARMATRIXROWS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SCALARMATRIXROWS_R num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define SCALARMATRIXROWS_NUM_ROWS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define SCALARMATRIXROWS_S_VALUE num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_SquareMatrix 425 +#define SQUAREMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SQUAREMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SubMatrix 426 +#define SUBMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SUBMATRIX_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SUBMATRIX_C num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SubtractMatrix 427 +#define SUBTRACTMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SUBTRACTMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SUBTRACTMATRIX_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SwapMatrix 428 +#define SWAPMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SWAPMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_SwapMatrixColumn 429 +#define SWAPMATRIXCOLUMN_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SWAPMATRIXCOLUMN_C1 num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SWAPMATRIXCOLUMN_C2 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SwapMatrixRow 430 +#define SWAPMATRIXROW_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SWAPMATRIXROW_R1 num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SWAPMATRIXROW_R2 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_TransposeMatrix 431 +#define TRANSPOSEMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define TRANSPOSEMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_UnAugmentMatrix 432 +#define UNAUGMENTMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define UNAUGMENTMATRIX_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define UNAUGMENTMATRIX_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_ZeroMatrix 433 +#define ZEROMATRIX_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_GetMatrixSize 434 +#define GETMATRIXSIZE_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETMATRIXSIZE_R num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETMATRIXSIZE_C num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SetMatrixProcess 435 +#define SETMATRIXPROCESS_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessOpen 436 +#define PROCESSOPEN_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_SetProcessErrorMode 437 +#define SETPROCESSERRORMODE_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETPROCESSERRORMODE_ERROR_MODE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ProcessError 438 +#define PROCESSERROR_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessWait 439 +#define PROCESSWAIT_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessWaitAll 440 +#define FN_ProcessContinue 441 +#define PROCESSCONTINUE_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessStop 442 +#define PROCESSSTOP_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessClear 443 +#define PROCESSCLEAR_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessClose 444 +#define PROCESSCLOSE_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessErrorMode 445 +#define PROCESSERRORMODE_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessSleep 446 +#define PROCESSSLEEP_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define PROCESSSLEEP_MSEC num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_ProcessExists 447 +#define PROCESSEXISTS_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_ProcessStopAll 448 +#define FN_ProcessContinueAll 449 +#define FN_ProcessQueueSize 450 +#define PROCESSQUEUESIZE_P_NUM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_NumCPUs 451 +#define FN_GetProjectionGeometry 452 +#define GETPROJECTIONGEOMETRY_CAM_DIST num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETPROJECTIONGEOMETRY_MA num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETPROJECTIONGEOMETRY_F_VERTEX_COUNT num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETPROJECTIONGEOMETRY_COLUMNS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETPROJECTIONGEOMETRY_UV num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define GETPROJECTIONGEOMETRY_GRAPH_OFFSET_X num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define GETPROJECTIONGEOMETRY_GRAPH_OFFSET_Y num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define GETPROJECTIONGEOMETRY_V_COLOR num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define GETPROJECTIONGEOMETRY_VERTEX_COUNT num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define GETPROJECTIONGEOMETRY_VERTEX2D num_var[9].nid_value.value[ num_var[9].byref_offset ] +#define GETPROJECTIONGEOMETRY_INDEX_COUNT num_var[10].nid_value.value[ num_var[10].byref_offset ] +#define GETPROJECTIONGEOMETRY_INDEX num_var[11].nid_value.value[ num_var[11].byref_offset ] +#define GETPROJECTIONGEOMETRY_CLIP_DIST num_var[12].nid_value.value[ num_var[12].byref_offset ] +#define GETPROJECTIONGEOMETRY_MIN_X num_var[13].nid_value.value[ num_var[13].byref_offset ] +#define GETPROJECTIONGEOMETRY_MIN_Y num_var[14].nid_value.value[ num_var[14].byref_offset ] +#define GETPROJECTIONGEOMETRY_MAX_X num_var[15].nid_value.value[ num_var[15].byref_offset ] +#define GETPROJECTIONGEOMETRY_MAX_Y num_var[16].nid_value.value[ num_var[16].byref_offset ] +#define FN_CalculateFaceZ 453 +#define CALCULATEFACEZ_CAM_DIST num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define CALCULATEFACEZ_GRAPH_OFFSET_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define CALCULATEFACEZ_GRAPH_OFFSET_Y num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define CALCULATEFACEZ_VIEW_W num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define CALCULATEFACEZ_VIEW_H num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define CALCULATEFACEZ_VIEW_DEPTH num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define CALCULATEFACEZ_MA num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define CALCULATEFACEZ_F_VERTEX_COUNT num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define CALCULATEFACEZ_COLUMNS num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define CALCULATEFACEZ_FACE_MIN_Z num_var[9].nid_value.value[ num_var[9].byref_offset ] +#define CALCULATEFACEZ_FACE_MAX_Z num_var[10].nid_value.value[ num_var[10].byref_offset ] +#define CALCULATEFACEZ_Z_AVG num_var[11].nid_value.value[ num_var[11].byref_offset ] +#define FN_SetChannelSpacePosition 454 +#define SETCHANNELSPACEPOSITION_CHANNEL num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SETCHANNELSPACEPOSITION_ANGLE num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define SETCHANNELSPACEPOSITION_DISTANCE num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_SaveBMP 455 +#define SAVEBMP_IMG num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SAVEBMP_FILE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_SavePNG 456 +#define SAVEPNG_IMG num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SAVEPNG_FILE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_SaveJPG 457 +#define SAVEJPG_IMG num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define SAVEJPG_FILE$ str_var[0].sid_value.value[ str_var[0].byref_offset ] +#define FN_GetLineIntersection 458 +#define GETLINEINTERSECTION_P0_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETLINEINTERSECTION_P0_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETLINEINTERSECTION_P1_X num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETLINEINTERSECTION_P1_Y num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETLINEINTERSECTION_P2_X num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define GETLINEINTERSECTION_P2_Y num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define GETLINEINTERSECTION_P3_X num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define GETLINEINTERSECTION_P3_Y num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define GETLINEINTERSECTION_I_X num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define GETLINEINTERSECTION_I_Y num_var[9].nid_value.value[ num_var[9].byref_offset ] +#define FN_Interpolate 459 +#define INTERPOLATE_MIN_A num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define INTERPOLATE_MAX_A num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define INTERPOLATE_MID_A num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define INTERPOLATE_MIN_B num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define INTERPOLATE_MAX_B num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_ATan2 460 +#define ATAN2_Y num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define ATAN2_X num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define FN_PointInQuad 461 +#define POINTINQUAD_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define POINTINQUAD_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define POINTINQUAD_X1 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define POINTINQUAD_Y1 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define POINTINQUAD_X2 num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define POINTINQUAD_Y2 num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define POINTINQUAD_X3 num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define POINTINQUAD_Y3 num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define POINTINQUAD_X4 num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define POINTINQUAD_Y4 num_var[9].nid_value.value[ num_var[9].byref_offset ] +#define FN_PointInTri 462 +#define POINTINTRI_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define POINTINTRI_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define POINTINTRI_X1 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define POINTINTRI_Y1 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define POINTINTRI_X2 num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define POINTINTRI_Y2 num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define POINTINTRI_X3 num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define POINTINTRI_Y3 num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define FN_Distance2D 463 +#define DISTANCE2D_X1 num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DISTANCE2D_Y1 num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DISTANCE2D_X2 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DISTANCE2D_Y2 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define FN_Distance3D 464 +#define DISTANCE3D_X1 num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define DISTANCE3D_Y1 num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define DISTANCE3D_Z1 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define DISTANCE3D_X2 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define DISTANCE3D_Y2 num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define DISTANCE3D_Z2 num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define FN_GetCircleLineIntersection 465 +#define GETCIRCLELINEINTERSECTION_CIRCLE_X num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETCIRCLELINEINTERSECTION_CIRCLE_Y num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETCIRCLELINEINTERSECTION_RADIUS num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETCIRCLELINEINTERSECTION_X1 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETCIRCLELINEINTERSECTION_Y1 num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define GETCIRCLELINEINTERSECTION_X2 num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define GETCIRCLELINEINTERSECTION_Y2 num_var[6].nid_value.value[ num_var[6].byref_offset ] +#define GETCIRCLELINEINTERSECTION_IX1 num_var[7].nid_value.value[ num_var[7].byref_offset ] +#define GETCIRCLELINEINTERSECTION_IY1 num_var[8].nid_value.value[ num_var[8].byref_offset ] +#define GETCIRCLELINEINTERSECTION_IX2 num_var[9].nid_value.value[ num_var[9].byref_offset ] +#define GETCIRCLELINEINTERSECTION_IY2 num_var[10].nid_value.value[ num_var[10].byref_offset ] +#define FN_GetLinePlaneIntersection 466 +#define GETLINEPLANEINTERSECTION_LINE_POINT num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define GETLINEPLANEINTERSECTION_LINE_DIRECTION num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define GETLINEPLANEINTERSECTION_PLANE_POINT_1 num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define GETLINEPLANEINTERSECTION_PLANE_POINT_2 num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define GETLINEPLANEINTERSECTION_PLANE_POINT_3 num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define GETLINEPLANEINTERSECTION_INTERSECTION num_var[5].nid_value.value[ num_var[5].byref_offset ] +#define FN_IncrementMatrixRows 467 +#define INCREMENTMATRIXROWS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define INCREMENTMATRIXROWS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define INCREMENTMATRIXROWS_R num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define INCREMENTMATRIXROWS_NUM_ROWS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define INCREMENTMATRIXROWS_VALUE num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_IncrementMatrixColumns 468 +#define INCREMENTMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define INCREMENTMATRIXCOLUMNS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define INCREMENTMATRIXCOLUMNS_C num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define INCREMENTMATRIXCOLUMNS_NUM_COLS num_var[3].nid_value.value[ num_var[3].byref_offset ] +#define INCREMENTMATRIXCOLUMNS_VALUE num_var[4].nid_value.value[ num_var[4].byref_offset ] +#define FN_JoinMatrixRows 469 +#define JOINMATRIXROWS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define JOINMATRIXROWS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define JOINMATRIXROWS_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_JoinMatrixColumns 470 +#define JOINMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define JOINMATRIXCOLUMNS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] +#define JOINMATRIXCOLUMNS_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_TypeArrayDim 471 +#define TYPEARRAYDIM_ID usr_var[0].var_ref +#define FN_TypeArraySize 472 +#define TYPEARRAYSIZE_ID usr_var[0].var_ref +#define TYPEARRAYSIZE_ARRAY_DIM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_TypeArrayCopy 473 +#define TYPEARRAYCOPY_SRC usr_var[0].var_ref +#define TYPEARRAYCOPY_DST usr_var[1].var_ref +#define FN_TypeArrayFill 474 +#define TYPEARRAYFILL_SRC usr_var[0].var_ref +#define TYPEARRAYFILL_FDATA usr_var[1].var_ref->uid_value[0] diff --git a/rcbasic_build/rcbasic_dev3.txt b/rcbasic_build/rcbasic_dev3.txt new file mode 100644 index 0000000..1389185 --- /dev/null +++ b/rcbasic_build/rcbasic_dev3.txt @@ -0,0 +1,950 @@ +case FN_FPrint: //Sub Procedure +break; +case FN_Input$: //String Function +break; +case FN_ArrayDim: //Number Function +break; +case FN_StringArrayDim: //Number Function +break; +case FN_NumberArrayDim: //Number Function +break; +case FN_ArraySize: //Number Function +break; +case FN_StringArraySize: //Number Function +break; +case FN_NumberArraySize: //Number Function +break; +case FN_Abs: //Number Function +break; +case FN_ACos: //Number Function +break; +case FN_AndBit: //Number Function +break; +case FN_ASin: //Number Function +break; +case FN_ATan: //Number Function +break; +case FN_Bin$: //String Function +break; +case FN_CInt32: //Number Function +break; +case FN_CInt64: //Number Function +break; +case FN_Cos: //Number Function +break; +case FN_Degrees: //Number Function +break; +case FN_Exp: //Number Function +break; +case FN_Frac: //Number Function +break; +case FN_Hex$: //String Function +break; +case FN_HexVal: //Number Function +break; +case FN_Int: //Number Function +break; +case FN_Log: //Number Function +break; +case FN_Max: //Number Function +break; +case FN_Min: //Number Function +break; +case FN_OrBit: //Number Function +break; +case FN_Radians: //Number Function +break; +case FN_Randomize: //Number Function +break; +case FN_Rand: //Number Function +break; +case FN_Round: //Number Function +break; +case FN_Sign: //Number Function +break; +case FN_Sin: //Number Function +break; +case FN_Sqrt: //Number Function +break; +case FN_Tan: //Number Function +break; +case FN_XOrBit: //Number Function +break; +case FN_Asc: //Number Function +break; +case FN_Chr$: //String Function +break; +case FN_Insert$: //String Function +break; +case FN_InStr: //Number Function +break; +case FN_LCase$: //String Function +break; +case FN_Left$: //String Function +break; +case FN_Length: //Number Function +break; +case FN_Len: //Number Function +break; +case FN_LTrim$: //String Function +break; +case FN_Mid$: //String Function +break; +case FN_ReplaceSubstr$: //String Function +break; +case FN_Replace$: //String Function +break; +case FN_Reverse$: //String Function +break; +case FN_Right$: //String Function +break; +case FN_RTrim$: //String Function +break; +case FN_StringFill$: //String Function +break; +case FN_Str$: //String Function +break; +case FN_Str_F$: //String Function +break; +case FN_Str_S$: //String Function +break; +case FN_Tally: //Number Function +break; +case FN_Trim$: //String Function +break; +case FN_UCase$: //String Function +break; +case FN_Val: //Number Function +break; +case FN_Stack_N: //Sub Procedure +break; +case FN_Stack_S: //Sub Procedure +break; +case FN_Push_N: //Sub Procedure +break; +case FN_Pop_N: //Number Function +break; +case FN_Push_S: //Sub Procedure +break; +case FN_Pop_S$: //String Function +break; +case FN_Stack_Size_N: //Number Function +break; +case FN_Stack_Size_S: //Number Function +break; +case FN_FileOpen: //Number Function +break; +case FN_FileClose: //Sub Procedure +break; +case FN_ReadByte: //Number Function +break; +case FN_WriteByte: //Sub Procedure +break; +case FN_ReadLine$: //String Function +break; +case FN_Write: //Sub Procedure +break; +case FN_WriteLine: //Sub Procedure +break; +case FN_CopyFile: //Sub Procedure +break; +case FN_RemoveFile: //Number Function +break; +case FN_FileExists: //Number Function +break; +case FN_MoveFile: //Number Function +break; +case FN_RenameFile: //Number Function +break; +case FN_FileLength: //Number Function +break; +case FN_Tell: //Number Function +break; +case FN_Seek: //Number Function +break; +case FN_EOF: //Number Function +break; +case FN_FreeFile: //Number Function +break; +case FN_ChangeDir: //Sub Procedure +break; +case FN_DirExists: //Number Function +break; +case FN_DirFirst$: //String Function +break; +case FN_Dir$: //String Function +break; +case FN_DirNext$: //String Function +break; +case FN_MakeDir: //Number Function +break; +case FN_RemoveDir: //Number Function +break; +case FN_Date$: //String Function +break; +case FN_Easter$: //String Function +break; +case FN_Ticks: //Number Function +break; +case FN_Time$: //String Function +break; +case FN_Timer: //Number Function +break; +case FN_Wait: //Sub Procedure +break; +case FN_WindowOpen: //Sub Procedure +break; +case FN_WindowClose: //Sub Procedure +break; +case FN_RaiseWindow: //Sub Procedure +break; +case FN_Window: //Sub Procedure +break; +case FN_Update: //Sub Procedure +break; +case FN_Cls: //Sub Procedure +break; +case FN_SetClearColor: //Sub Procedure +break; +case FN_ShowWindow: //Sub Procedure +break; +case FN_HideWindow: //Sub Procedure +break; +case FN_SetWindowTitle: //Sub Procedure +break; +case FN_WindowTitle$: //String Function +break; +case FN_SetWindowPosition: //Sub Procedure +break; +case FN_GetWindowPosition: //Sub Procedure +break; +case FN_SetWindowSize: //Sub Procedure +break; +case FN_GetWindowSize: //Sub Procedure +break; +case FN_SetWindowMinSize: //Sub Procedure +break; +case FN_GetWindowMinSize: //Sub Procedure +break; +case FN_SetWindowMaxSize: //Sub Procedure +break; +case FN_GetWindowMaxSize: //Sub Procedure +break; +case FN_WindowIsFullscreen: //Number Function +break; +case FN_WindowIsVisible: //Number Function +break; +case FN_WindowIsBordered: //Number Function +break; +case FN_WindowIsResizable: //Number Function +break; +case FN_WindowIsMinimized: //Number Function +break; +case FN_WindowIsMaximized: //Number Function +break; +case FN_WindowHasInputFocus: //Number Function +break; +case FN_WindowHasMouseFocus: //Number Function +break; +case FN_SetWindowFullscreen: //Sub Procedure +break; +case FN_MaximizeWindow: //Sub Procedure +break; +case FN_MinimizeWindow: //Sub Procedure +break; +case FN_SetWindowBorder: //Sub Procedure +break; +case FN_WindowClip: //Sub Procedure +break; +case FN_WindowExists: //Number Function +break; +case FN_NumWindows: //Number Function +break; +case FN_WindowEvent_Close: //Number Function +break; +case FN_WindowEvent_Maximize: //Number Function +break; +case FN_WindowEvent_Minimize: //Number Function +break; +case FN_ActiveWindow: //Number Function +break; +case FN_FPS: //Number Function +break; +case FN_SetWindowIcon: //Sub Procedure +break; +case FN_CanvasOpen: //Sub Procedure +break; +case FN_CanvasClose: //Sub Procedure +break; +case FN_SetCanvasVisible: //Sub Procedure +break; +case FN_CanvasIsVisible: //Number Function +break; +case FN_SetCanvasViewport: //Sub Procedure +break; +case FN_GetCanvasViewport: //Sub Procedure +break; +case FN_Canvas: //Sub Procedure +break; +case FN_SetCanvasOffset: //Sub Procedure +break; +case FN_GetCanvasOffset: //Sub Procedure +break; +case FN_GetCanvasSize: //Sub Procedure +break; +case FN_ClearCanvas: //Sub Procedure +break; +case FN_SetCanvasAlpha: //Sub Procedure +break; +case FN_CanvasAlpha: //Number Function +break; +case FN_SetCanvasBlendMode: //Number Function +break; +case FN_CanvasBlendMode: //Number Function +break; +case FN_SetCanvasColorMod: //Number Function +break; +case FN_CanvasColorMod: //Number Function +break; +case FN_CopyCanvas: //Sub Procedure +break; +case FN_CloneCanvas: //Sub Procedure +break; +case FN_SetCanvasZ: //Sub Procedure +break; +case FN_CanvasZ: //Number Function +break; +case FN_CanvasClip: //Sub Procedure +break; +case FN_ActiveCanvas: //Number Function +break; +case FN_Box: //Sub Procedure +break; +case FN_BoxFill: //Sub Procedure +break; +case FN_Circle: //Sub Procedure +break; +case FN_CircleFill: //Sub Procedure +break; +case FN_Ellipse: //Sub Procedure +break; +case FN_EllipseFill: //Sub Procedure +break; +case FN_FloodFill: //Sub Procedure +break; +case FN_GetPixel: //Number Function +break; +case FN_SetColor: //Sub Procedure +break; +case FN_Line: //Sub Procedure +break; +case FN_Poly: //Sub Procedure +break; +case FN_PolyFill: //Sub Procedure +break; +case FN_Rect: //Sub Procedure +break; +case FN_RectFill: //Sub Procedure +break; +case FN_RoundRect: //Sub Procedure +break; +case FN_RoundRectFill: //Sub Procedure +break; +case FN_RGB: //Number Function +break; +case FN_RGBA: //Number Function +break; +case FN_PSet: //Sub Procedure +break; +case FN_LoadImage: //Sub Procedure +break; +case FN_LoadImage_Ex: //Sub Procedure +break; +case FN_ImageFromBuffer: //Sub Procedure +break; +case FN_ImageFromBuffer_Ex: //Sub Procedure +break; +case FN_BufferFromImage: //Sub Procedure +break; +case FN_ImageExists: //Number Function +break; +case FN_ColorKey: //Sub Procedure +break; +case FN_CopyImage: //Sub Procedure +break; +case FN_DeleteImage: //Sub Procedure +break; +case FN_SetImageAlpha: //Sub Procedure +break; +case FN_ImageAlpha: //Number Function +break; +case FN_GetImageSize: //Sub Procedure +break; +case FN_SetImageBlendMode: //Number Function +break; +case FN_ImageBlendMode: //Number Function +break; +case FN_SetImageColorMod: //Number Function +break; +case FN_ImageColorMod: //Number Function +break; +case FN_DrawImage: //Sub Procedure +break; +case FN_DrawImage_Blit: //Sub Procedure +break; +case FN_DrawImage_Blit_Ex: //Sub Procedure +break; +case FN_DrawImage_Rotate: //Sub Procedure +break; +case FN_DrawImage_Rotate_Ex: //Sub Procedure +break; +case FN_DrawImage_Zoom: //Sub Procedure +break; +case FN_DrawImage_Zoom_Ex: //Sub Procedure +break; +case FN_DrawImage_Rotozoom: //Sub Procedure +break; +case FN_DrawImage_Rotozoom_Ex: //Sub Procedure +break; +case FN_DrawImage_Flip: //Sub Procedure +break; +case FN_DrawImage_Flip_Ex: //Sub Procedure +break; +case FN_InKey: //Number Function +break; +case FN_Key: //Number Function +break; +case FN_WaitKey: //Number Function +break; +case FN_HideMouse: //Sub Procedure +break; +case FN_ShowMouse: //Sub Procedure +break; +case FN_MouseIsVisible: //Number Function +break; +case FN_GetMouse: //Sub Procedure +break; +case FN_MouseX: //Number Function +break; +case FN_MouseY: //Number Function +break; +case FN_MouseButton: //Number Function +break; +case FN_GetMouseWheel: //Sub Procedure +break; +case FN_MouseWheelX: //Number Function +break; +case FN_MouseWheelY: //Number Function +break; +case FN_SoundFromBuffer: //Sub Procedure +break; +case FN_LoadSound: //Sub Procedure +break; +case FN_LoadMusic: //Sub Procedure +break; +case FN_PlaySound: //Sub Procedure +break; +case FN_PlaySoundTimed: //Sub Procedure +break; +case FN_PlayMusic: //Sub Procedure +break; +case FN_PauseSound: //Sub Procedure +break; +case FN_ResumeSound: //Sub Procedure +break; +case FN_PauseMusic: //Sub Procedure +break; +case FN_ResumeMusic: //Sub Procedure +break; +case FN_DeleteSound: //Sub Procedure +break; +case FN_DeleteMusic: //Sub Procedure +break; +case FN_FadeMusicIn: //Sub Procedure +break; +case FN_FadeMusicOut: //Sub Procedure +break; +case FN_MusicExists: //Number Function +break; +case FN_SetMusicVolume: //Sub Procedure +break; +case FN_MusicVolume: //Number Function +break; +case FN_SetMusicPosition: //Sub Procedure +break; +case FN_MusicPosition: //Number Function +break; +case FN_RewindMusic: //Sub Procedure +break; +case FN_SetSoundChannels: //Sub Procedure +break; +case FN_NumSoundChannels: //Number Function +break; +case FN_SoundIsEnabled: //Number Function +break; +case FN_SoundExists: //Number Function +break; +case FN_SetChannelVolume: //Sub Procedure +break; +case FN_ChannelVolume: //Number Function +break; +case FN_SetSoundVolume: //Sub Procedure +break; +case FN_SoundVolume: //Number Function +break; +case FN_StopMusic: //Sub Procedure +break; +case FN_StopSound: //Sub Procedure +break; +case FN_SetChannelPanning: //Number Function +break; +case FN_SetChannelDistance: //Number Function +break; +case FN_ChannelIsPlaying: //Number Function +break; +case FN_ChannelIsPaused: //Number Function +break; +case FN_NumJoysticks: //Number Function +break; +case FN_NumJoyAxes: //Number Function +break; +case FN_NumJoyButtons: //Number Function +break; +case FN_NumJoyHats: //Number Function +break; +case FN_NumJoyTrackBalls: //Number Function +break; +case FN_JoyAxis: //Number Function +break; +case FN_JoyButton: //Number Function +break; +case FN_JoyHat: //Number Function +break; +case FN_GetJoyTrackBall: //Sub Procedure +break; +case FN_JoyName$: //String Function +break; +case FN_JoystickIsConnected: //Number Function +break; +case FN_GetCursor: //Sub Procedure +break; +case FN_PrintS: //Sub Procedure +break; +case FN_InputS$: //String Function +break; +case FN_ZoneInputS$: //String Function +break; +case FN_Locate: //Sub Procedure +break; +case FN_ReadInput_Start: //Sub Procedure +break; +case FN_ReadInput_Stop: //Sub Procedure +break; +case FN_ReadInput_Text$: //String Function +break; +case FN_ReadInput_SetText: //Sub Procedure +break; +case FN_ReadInput_ToggleBackspace: //Sub Procedure +break; +case FN_LoadFont: //Sub Procedure +break; +case FN_DeleteFont: //Sub Procedure +break; +case FN_FontIsLoaded: //Number Function +break; +case FN_Font: //Sub Procedure +break; +case FN_SetFontStyle: //Sub Procedure +break; +case FN_DrawText: //Sub Procedure +break; +case FN_DrawText_Shaded: //Sub Procedure +break; +case FN_DrawText_Blended: //Sub Procedure +break; +case FN_RenderText: //Sub Procedure +break; +case FN_GetTextSize: //Sub Procedure +break; +case FN_TouchPressure: //Number Function +break; +case FN_GetTouch: //Sub Procedure +break; +case FN_GetMultiTouch: //Sub Procedure +break; +case FN_GetTouchFinger: //Sub Procedure +break; +case FN_NumFingers: //Number Function +break; +case FN_CheckSockets: //Number Function +break; +case FN_TCP_SocketReady: //Number Function +break; +case FN_UDP_SocketReady: //Number Function +break; +case FN_TCP_SocketOpen: //Number Function +break; +case FN_TCP_SocketClose: //Sub Procedure +break; +case FN_TCP_RemoteHost: //Number Function +break; +case FN_TCP_RemotePort: //Number Function +break; +case FN_TCP_GetData: //Number Function +break; +case FN_TCP_SendData: //Sub Procedure +break; +case FN_TCP_AcceptSocket: //Number Function +break; +case FN_UDP_SocketOpen: //Number Function +break; +case FN_UDP_SocketClose: //Number Function +break; +case FN_UDP_GetData: //Number Function +break; +case FN_UDP_Length: //Number Function +break; +case FN_UDP_MaxLength: //Number Function +break; +case FN_UDP_RemoteHost$: //String Function +break; +case FN_UDP_RemotePort: //Number Function +break; +case FN_UDP_SendData: //Sub Procedure +break; +case FN_LoadVideo: //Sub Procedure +break; +case FN_PlayVideo: //Sub Procedure +break; +case FN_PauseVideo: //Sub Procedure +break; +case FN_StopVideo: //Sub Procedure +break; +case FN_SetVideoPosition: //Sub Procedure +break; +case FN_ResumeVideo: //Sub Procedure +break; +case FN_VideoPosition: //Number Function +break; +case FN_DeleteVideo: //Sub Procedure +break; +case FN_VideoIsPlaying: //Number Function +break; +case FN_VideoEnd: //Number Function +break; +case FN_GetVideoStats: //Sub Procedure +break; +case FN_SetVideoDrawRect: //Sub Procedure +break; +case FN_GetVideoDrawRect: //Sub Procedure +break; +case FN_GetVideoSize: //Sub Procedure +break; +case FN_VideoExists: //Number Function +break; +case FN_SetVideoAlpha: //Sub Procedure +break; +case FN_System: //Number Function +break; +case FN_OS$: //String Function +break; +case FN_Command$: //String Function +break; +case FN_NumCommands: //Number Function +break; +case FN_Env$: //String Function +break; +case FN_SetEnv: //Sub Procedure +break; +case FN_PrefPath$: //String Function +break; +case FN_Android_GetExternalStoragePath$: //String Function +break; +case FN_Android_GetExternalStorageState: //Number Function +break; +case FN_Android_GetInternalStoragePath$: //String Function +break; +case FN_Android_JNI_Message$: //String Function +break; +case FN_Runtime_Utility_Message$: //String Function +break; +case FN_ClipboardText$: //String Function +break; +case FN_SetClipboardText: //Sub Procedure +break; +case FN_HasClipboardText: //Number Function +break; +case FN_GetDesktopDisplayMode: //Sub Procedure +break; +case FN_DrawImage_Transform: //Sub Procedure +break; +case FN_GetPowerInfo: //Sub Procedure +break; +case FN_SystemRam: //Number Function +break; +case FN_SetRenderScaleQuality: //Number Function +break; +case FN_EvalJS$: //String Function +break; +case FN_GetRenderScaleQuality: //Number Function +break; +case FN_GetGlobalMouse: //Sub Procedure +break; +case FN_GlobalMouseX: //Number Function +break; +case FN_GlobalMouseY: //Number Function +break; +case FN_GetAccel: //Sub Procedure +break; +case FN_AccelName$: //String Function +break; +case FN_NumAccels: //Number Function +break; +case FN_GetGyro: //Sub Procedure +break; +case FN_GyroName$: //String Function +break; +case FN_NumGyros: //Number Function +break; +case FN_JoyRumblePlay: //Sub Procedure +break; +case FN_JoyRumbleStop: //Sub Procedure +break; +case FN_JoystickIsHaptic: //Number Function +break; +case FN_WriteByteBuffer: //Number Function +break; +case FN_ReadByteBuffer: //Number Function +break; +case FN_WindowEvent_Resize: //Number Function +break; +case FN_SetWindowAutoClose: //Sub Procedure +break; +case FN_SetWindowResizable: //Sub Procedure +break; +case FN_SystemReturnStdOut$: //String Function +break; +case FN_WindowMode: //Number Function +break; +case FN_WindowFlags: //Number Function +break; +case FN_RestoreWindow: //Sub Procedure +break; +case FN_UpdateAllWindows: //Sub Procedure +break; +case FN_QueryAudioSpec: //Number Function +break; +case FN_MusicIsPlaying: //Number Function +break; +case FN_DrawGeometry: //Number Function +break; +case FN_Size: //Number Function +break; +case FN_BufferFromString: //Number Function +break; +case FN_StringFromBuffer$: //String Function +break; +case FN_GrabInput: //Sub Procedure +break; +case FN_GrabbedWindow: //Number Function +break; +case FN_WarpMouse: //Sub Procedure +break; +case FN_WarpMouseGlobal: //Sub Procedure +break; +case FN_SetMouseZone: //Sub Procedure +break; +case FN_ClearMouseZone: //Sub Procedure +break; +case FN_SetWindowAlwaysOnTop: //Sub Procedure +break; +case FN_SetMouseRelative: //Sub Procedure +break; +case FN_SetWindowVSync: //Sub Procedure +break; +case FN_OpenURL: //Number Function +break; +case FN_APIVersion$: //String Function +break; +case FN_FlashWindow: //Number Function +break; +case FN_MessageBox: //Number Function +break; +case FN_NumberArrayCopy: //Sub Procedure +break; +case FN_StringArrayCopy: //Sub Procedure +break; +case FN_ArrayCopy: //Sub Procedure +break; +case FN_NumberArrayFill: //Sub Procedure +break; +case FN_StringArrayFill: //Sub Procedure +break; +case FN_ArrayFill: //Sub Procedure +break; +case FN_Runtime$: //String Function +break; +case FN_DimMatrix: //Sub Procedure +break; +case FN_AddMatrix: //Number Function +break; +case FN_AugmentMatrix: //Number Function +break; +case FN_CopyMatrix: //Sub Procedure +break; +case FN_InsertMatrixColumns: //Number Function +break; +case FN_InsertMatrixRows: //Number Function +break; +case FN_MultiplyMatrix: //Number Function +break; +case FN_CubeMatrix: //Number Function +break; +case FN_DeleteMatrixColumns: //Number Function +break; +case FN_DeleteMatrixRows: //Number Function +break; +case FN_ClearMatrix: //Sub Procedure +break; +case FN_ClearMatrixColumns: //Number Function +break; +case FN_ClearMatrixRows: //Number Function +break; +case FN_FillMatrix: //Sub Procedure +break; +case FN_FillMatrixColumns: //Number Function +break; +case FN_FillMatrixRows: //Number Function +break; +case FN_CopyMatrixColumns: //Number Function +break; +case FN_CopyMatrixRows: //Number Function +break; +case FN_IdentityMatrix: //Sub Procedure +break; +case FN_SolveMatrix: //Number Function +break; +case FN_IsEqualMatrix: //Number Function +break; +case FN_Determinant: //Number Function +break; +case FN_AdjointMatrix: //Number Function +break; +case FN_InvertMatrix: //Number Function +break; +case FN_MatrixFromBuffer: //Sub Procedure +break; +case FN_GetMatrix: //Sub Procedure +break; +case FN_RandomizeMatrix: //Sub Procedure +break; +case FN_MatrixValue: //Number Function +break; +case FN_SetMatrixValue: //Sub Procedure +break; +case FN_ScalarMatrix: //Sub Procedure +break; +case FN_ScalarMatrixColumns: //Number Function +break; +case FN_ScalarMatrixRows: //Number Function +break; +case FN_SquareMatrix: //Number Function +break; +case FN_SubMatrix: //Sub Procedure +break; +case FN_SubtractMatrix: //Number Function +break; +case FN_SwapMatrix: //Sub Procedure +break; +case FN_SwapMatrixColumn: //Number Function +break; +case FN_SwapMatrixRow: //Number Function +break; +case FN_TransposeMatrix: //Number Function +break; +case FN_UnAugmentMatrix: //Number Function +break; +case FN_ZeroMatrix: //Sub Procedure +break; +case FN_GetMatrixSize: //Sub Procedure +break; +case FN_SetMatrixProcess: //Number Function +break; +case FN_ProcessOpen: //Number Function +break; +case FN_SetProcessErrorMode: //Sub Procedure +break; +case FN_ProcessError: //Number Function +break; +case FN_ProcessWait: //Sub Procedure +break; +case FN_ProcessWaitAll: //Sub Procedure +break; +case FN_ProcessContinue: //Sub Procedure +break; +case FN_ProcessStop: //Sub Procedure +break; +case FN_ProcessClear: //Sub Procedure +break; +case FN_ProcessClose: //Number Function +break; +case FN_ProcessErrorMode: //Number Function +break; +case FN_ProcessSleep: //Sub Procedure +break; +case FN_ProcessExists: //Number Function +break; +case FN_ProcessStopAll: //Sub Procedure +break; +case FN_ProcessContinueAll: //Sub Procedure +break; +case FN_ProcessQueueSize: //Number Function +break; +case FN_NumCPUs: //Number Function +break; +case FN_GetProjectionGeometry: //Sub Procedure +break; +case FN_CalculateFaceZ: //Number Function +break; +case FN_SetChannelSpacePosition: //Number Function +break; +case FN_SaveBMP: //Number Function +break; +case FN_SavePNG: //Number Function +break; +case FN_SaveJPG: //Number Function +break; +case FN_GetLineIntersection: //Number Function +break; +case FN_Interpolate: //Number Function +break; +case FN_ATan2: //Number Function +break; +case FN_PointInQuad: //Number Function +break; +case FN_PointInTri: //Number Function +break; +case FN_Distance2D: //Number Function +break; +case FN_Distance3D: //Number Function +break; +case FN_GetCircleLineIntersection: //Number Function +break; +case FN_GetLinePlaneIntersection: //Number Function +break; +case FN_IncrementMatrixRows: //Sub Procedure +break; +case FN_IncrementMatrixColumns: //Sub Procedure +break; +case FN_JoinMatrixRows: //Sub Procedure +break; +case FN_JoinMatrixColumns: //Sub Procedure +break; +case FN_TypeArrayDim: //Number Function +break; +case FN_TypeArraySize: //Number Function +break; +case FN_TypeArrayCopy: //Sub Procedure +break; +case FN_TypeArrayFill: //Sub Procedure +break; diff --git a/rcbasic_build/rcbasic_dev4.txt b/rcbasic_build/rcbasic_dev4.txt new file mode 100644 index 0000000..3426a79 --- /dev/null +++ b/rcbasic_build/rcbasic_dev4.txt @@ -0,0 +1 @@ +create_type("empty"); diff --git a/rcbasic_build/vm_asm b/rcbasic_build/vm_asm index 00076f2..89dbee1 100644 --- a/rcbasic_build/vm_asm +++ b/rcbasic_build/vm_asm @@ -114,10 +114,10 @@ OBJ_CURRENT_TYPE 89 - clear_obj -90 - dim_type !id raw_number (user_type) -91 - dim_type1 !id raw_number (user type) n# (dim1) -92 - dim_type2 !id raw_number (user type) n# (dim1) n# (dim2) -93 - dim_type3 !id raw_number (user type) n# (dim1) n# (dim2) n# (dim3) +90 - dim_type !id !id (user_type) +91 - dim_type1 !id !id (user type) n# (dim1) +92 - dim_type2 !id !id (user type) n# (dim1) n# (dim2) +93 - dim_type3 !id !id (user type) n# (dim1) n# (dim2) n# (dim3) 94 - dim_num1 !id n# (dim1) 95 - dim_num2 !id n# (dim1) n# (dim2) @@ -258,12 +258,12 @@ OBJ_CURRENT_TYPE 173 - push_t_null -174 - delete_t !id +174 - delete_t !id !id (0 - top level, 1 - member) !id (0 - num, 1 - str, 2 - type) -175 - dim_type u# raw_number (user_type) -176 - dim_type1 u# raw_number (user type) n# (dim1) -177 - dim_type2 u# raw_number (user type) n# (dim1) n# (dim2) -178 - dim_type3 u# raw_number (user type) n# (dim1) n# (dim2) n# (dim3) +175 - dim_type u# !id (user_type) +176 - dim_type1 u# !id (user type) n# (dim1) +177 - dim_type2 u# !id (user type) n# (dim1) n# (dim2) +178 - dim_type3 u# !id (user type) n# (dim1) n# (dim2) n# (dim3) 179 - dim_tfield raw_number (user_type) raw_number (member_type) raw_number (member_index) raw_number (dimensions) n# (dim1) n# (dim2) n# (dim3) @@ -283,3 +283,29 @@ OBJ_CURRENT_TYPE 191 - preset_t3 !id raw_number (user_type) n# n# n# +192 - redim_type u# !id (user_type) +193 - redim_type1 u# !id (user type) n# (dim1) +194 - redim_type2 u# !id (user type) n# (dim1) n# (dim2) +195 - redim_type3 u# !id (user type) n# (dim1) n# (dim2) n# (dim3) + + +196 - redim_type_n !id +197 - redim_type_n1 !id n# (dim1) +198 - redim_type_n2 !id n# (dim1) n# (dim2) +199 - redim_type_n3 !id n# (dim1) n# (dim2) n# (dim3) + + +200 - redim_type_s !id +201 - redim_type_s1 !id n# (dim1) +202 - redim_type_s2 !id n# (dim1) n# (dim2) +203 - redim_type_s3 !id n# (dim1) n# (dim2) n# (dim3) + + +204 - redim_type !id !id (user_type) +205 - redim_type1 !id !id (user type) n# (dim1) +206 - redim_type2 !id !id (user type) n# (dim1) n# (dim2) +207 - redim_type3 !id !id (user type) n# (dim1) n# (dim2) n# (dim3) + +208 - redim_top + + diff --git a/rcbasic_runtime/main.cpp b/rcbasic_runtime/main.cpp index a83bb09..9edb8b7 100644 --- a/rcbasic_runtime/main.cpp +++ b/rcbasic_runtime/main.cpp @@ -81,12 +81,14 @@ string rcbasic_runtime_path = ""; struct n_value { - vector value; + vector value; + void * ref_parent; // This will be set by the obj_get instructions (ie. obj_get and obj_usr_get) }; struct s_value { - vector value; + vector value; + void * ref_parent; // This will be set by the obj_get instructions (ie. obj_get and obj_usr_get) }; struct rc_vm_n @@ -170,6 +172,8 @@ struct rc_usrId rc_usrId * var_ref; uint64_t var_ref_index; + rc_usrId* byref_ptr; + bool preset_init = false; #ifdef RCBASIC_DEBUG @@ -290,7 +294,9 @@ stack gosub_return_addr; rc_int readint_val; rc_double readdouble_val; -vector arr_ref_id(2); +vector arr_ref_id(2); + +bool redim_toplevel_flag = false; int rcbasic_exit_code = 0; @@ -1374,30 +1380,71 @@ void obj_usr_81(uint64_t uid) { //cout << "obj_usr " << uid << ": size = " << usr_object.obj_ref->uid_value[uid].uid_value.size() << endl; usr_object.index = 0; - usr_object.obj_ref = &usr_object.obj_ref->uid_value[uid].uid_value[0]; + + rc_usrId* tmp_usr_id = &usr_object.obj_ref->uid_value[uid]; + + usr_object.obj_ref = &usr_object.obj_ref->uid_value[uid].uid_value[0]; + + usr_object.obj_ref->byref_ptr = tmp_usr_id; + //usr_object.obj_ref->byref_ptr = &usr_object.obj_ref->uid_value[uid]; } void obj_usr1_82(uint64_t uid, int n1) { + //cout << "obj_usr2 " << uid << " " << (uint64_t)vm_n[n1].value << " " << (uint64_t)vm_n[n2].value << ": size = " << usr_object.obj_ref->uid_value.size() << endl; + //rc_usrId* tmp_usr_id = &usr_object.obj_ref->uid_value[uid]; + //usr_object.index = (uint64_t)vm_n[n1].value;; + //cout << "\n\nuid =" << uid << ", index = (" << usr_object.index << ") old_index = " << usr_object.index << endl << endl; + //cout << "\n\nusr index = " << usr_object.obj_ref->uid_value[uid].uid_value[usr_object.index].str_var.size() << endl << endl; + + //cout << "obj_usr1 " << uid << " " << (uint64_t)vm_n[n1].value << endl; //cout << " ---dbg[uid]: " << usr_object.obj_ref->uid_value[uid].uid_value[1].num_var[0].nid_value.value[0] << endl; //cout << " ---dbg[str]: " << usr_object.obj_ref->uid_value[uid].uid_value[0].str_var.size() << endl; usr_object.index = (uint64_t)vm_n[n1].value; - usr_object.obj_ref = &usr_object.obj_ref->uid_value[uid].uid_value[usr_object.index]; + + rc_usrId* tmp_usr_id = &usr_object.obj_ref->uid_value[uid]; + + usr_object.obj_ref = &usr_object.obj_ref->uid_value[uid].uid_value[usr_object.index]; + + usr_object.obj_ref->byref_ptr = tmp_usr_id; + //usr_object.obj_ref->byref_ptr = &usr_object.obj_ref->uid_value[uid]; } void obj_usr2_83(uint64_t uid, int n1, int n2) { //cout << "obj_usr2 " << uid << " " << (uint64_t)vm_n[n1].value << " " << (uint64_t)vm_n[n2].value << ": size = " << usr_object.obj_ref->uid_value.size() << endl; + //rc_usrId* tmp_usr_id = &usr_object.obj_ref->uid_value[uid]; + //usr_object.index = (uint64_t)vm_n[n1].value * usr_object.obj_ref->uid_value[uid].dim[1] + (uint64_t)vm_n[n2].value; + //cout << "\n\nuid =" << uid << ", index = (" << usr_object.index << ") old_index = " << usr_object.index << endl << endl; + //cout << "\n\nusr index = " << usr_object.obj_ref->uid_value[uid].uid_value.size() << endl << endl; + usr_object.index = (uint64_t)vm_n[n1].value * usr_object.obj_ref->uid_value[uid].dim[1] + (uint64_t)vm_n[n2].value; + + rc_usrId* tmp_usr_id = &usr_object.obj_ref->uid_value[uid]; + usr_object.obj_ref = &usr_object.obj_ref->uid_value[uid].uid_value[usr_object.index]; + + usr_object.obj_ref->byref_ptr = tmp_usr_id; + //usr_object.obj_ref->byref_ptr = &usr_object.obj_ref->uid_value[uid]; } void obj_usr3_84(uint64_t uid, int n1, int n2, int n3) { + //rc_usrId* tmp_usr_id = &usr_object.obj_ref->uid_value[uid]; + //cout << "obj_usr3 " << uid << " " << (uint64_t)vm_n[n1].value << " " << (uint64_t)vm_n[n2].value << " " << (uint64_t)vm_n[n3].value << endl; usr_object.index = ( (uint64_t)vm_n[n1].value * usr_object.obj_ref->uid_value[uid].dim[1] * usr_object.obj_ref->uid_value[uid].dim[2] ) + ((uint64_t)vm_n[n2].value * usr_object.obj_ref->uid_value[uid].dim[2]) + (uint64_t)vm_n[n3].value;; + + //----test + rc_usrId* tmp_usr_id = &usr_object.obj_ref->uid_value[uid]; + //------------------------------------------ + usr_object.obj_ref = &usr_object.obj_ref->uid_value[uid].uid_value[usr_object.index]; + + usr_object.obj_ref->byref_ptr = tmp_usr_id; + + //usr_object.obj_ref->byref_ptr = &usr_object.obj_ref->uid_value[uid]; } void obj_get_85(int n1) @@ -1409,7 +1456,9 @@ void obj_get_85(int n1) vm_n[n1].r = num_object.obj_val; //cout << "t2" << endl; vm_n[n1].r_index = num_object.index; - //cout << "t3" << endl; + //cout << "t3" << endl; + + num_object.obj_val->ref_parent = num_object.obj_val; #ifdef RCBASIC_DEBUG if(!num_var[num_object.nid].is_debug_var) @@ -1425,7 +1474,9 @@ void obj_getS_86(int s1) { vm_s[s1].value = str_object.obj_val[0].value[str_object.index]; vm_s[s1].r = str_object.obj_val; - vm_s[s1].r_index = str_object.index; + vm_s[s1].r_index = str_object.index; + + str_object.obj_val->ref_parent = str_object.obj_val; #ifdef RCBASIC_DEBUG if(!str_var[str_object.sid].is_debug_var) @@ -1449,7 +1500,7 @@ void clear_obj_89() { } -bool rc_dim_type(rc_usrId* parent, uint64_t udt_index, int num_dim, uint64_t d1, uint64_t d2, uint64_t d3) +bool rc_dim_type(rc_usrId* parent, uint64_t udt_index, int num_dim, uint64_t d1, uint64_t d2, uint64_t d3, uint64_t start_index = 0) { uint64_t dim_size = 0; switch(num_dim) @@ -1485,7 +1536,7 @@ bool rc_dim_type(rc_usrId* parent, uint64_t udt_index, int num_dim, uint64_t d1, //cout << "starting field: " << udt_index << " " << num_dim << " " << d1 << " " << d2 << " " << d3 << ": " << parent->uid_value.size() << endl; - for(uint64_t i = 0; i < dim_size; i++) + for(uint64_t i = start_index; i < dim_size; i++) { p_obj = &parent->uid_value[i]; @@ -2105,7 +2156,8 @@ void ptr_126(uint64_t nid, int n1) byref_addr_table.push(byref_id); byref_var_byref_offset.push(num_var[nid].byref_offset); num_var[nid].nref = vm_n[n1].r; - num_var[nid].byref_offset = vm_n[n1].r_index; + num_var[nid].byref_offset = vm_n[n1].r_index; + num_var[nid].nid_value.ref_parent = vm_n[n1].r->ref_parent; } void ptrS_127(uint64_t sid, int s1) @@ -2116,7 +2168,8 @@ void ptrS_127(uint64_t sid, int s1) byref_addr_table.push(byref_id); byref_var_byref_offset.push(str_var[sid].byref_offset); str_var[sid].sref = vm_s[s1].r; - str_var[sid].byref_offset = vm_s[s1].r_index; + str_var[sid].byref_offset = vm_s[s1].r_index; + str_var[sid].sid_value.ref_parent = vm_s[s1].r->ref_parent; } void rc_print_num(double n) @@ -2166,145 +2219,317 @@ void rc_push_str(string s_val) //current_s_stack_count++; } -uint64_t rc_string_array_dim(rc_strId s_var) +uint64_t rc_string_array_dim(rc_strId* s_var) { - return s_var.dimensions; + rc_strId* s = (rc_strId*)s_var->sid_value.ref_parent; + return s->dimensions; } -uint64_t rc_string_array_size(rc_strId s_var, int d_num) +uint64_t rc_string_array_size(rc_strId* s_var, int d_num) { switch(d_num) { case 1: - return s_var.dim[0]; + return s_var->dim[0]; break; case 2: - return s_var.dim[1]; + return s_var->dim[1]; break; case 3: - return s_var.dim[2]; + return s_var->dim[2]; break; } return 0; } -uint64_t rc_number_array_dim(rc_numId n_var) +uint64_t rc_number_array_dim(rc_numId* n_var) { - return n_var.dimensions; -} + rc_numId* n = (rc_numId*)n_var->nid_value.ref_parent; + return n->dimensions; +} + +uint64_t rc_type_array_dim(rc_usrId* u_var) +{ + return u_var->dimensions; +} + +uint64_t rc_type_array_size(rc_usrId* u_var, int d_num) +{ + switch(d_num) + { + case 1: + return u_var->dim[0]; + break; + case 2: + return u_var->dim[1]; + break; + case 3: + return u_var->dim[2]; + break; + } + return 0; +} + +void rc_type_array_copy(rc_usrId* src, rc_usrId* dst) +{ + //cout << "Copy Type" << endl; + rc_usrId* parent = dst; + + //cout << "freed up" << endl; + + //parent[0] = src[0]; + + //cout << "done" << endl; + + //return; + + + //cout << "db[1]" << endl; + parent->dimensions = src->dimensions; + //cout << "db[2]" << endl; + parent->dim[0] = src->dim[0]; + parent->dim[1] = src->dim[1]; + parent->dim[2] = src->dim[2]; + //cout << "db[3]" << endl; + + parent->byref_offset = 0; + //cout << "db[4]" << endl; + parent->uid_value.resize(src->uid_value.size()); + //cout << "db[5]" << endl; + + parent->var_ref = parent; + parent->var_ref_index = 0; + + + + rc_usrId* p_obj; + + uint64_t field_size = 0; + + rc_usrId* s_obj; + //cout << "starting field: " << endl; + + for(uint64_t i = 0; i < src->uid_value.size(); i++) + { + s_obj = &src->uid_value[i]; + p_obj = &parent->uid_value[i]; + + p_obj->byref_offset = 0; + p_obj->byref_ptr = parent; + p_obj->dim[0] = s_obj->dim[0]; + p_obj->dim[1] = s_obj->dim[1]; + p_obj->dim[2] = s_obj->dim[2]; + p_obj->dimensions = s_obj->dimensions; + p_obj->preset_init = s_obj->preset_init; + p_obj->udt_index = s_obj->udt_index; + p_obj->var_ref = p_obj; + p_obj->var_ref_index = 0; + + //cout << "num" << endl; + p_obj->num_var.resize(s_obj->num_var.size()); + for(int nfield = 0; nfield < s_obj->num_var.size(); nfield++) + { + p_obj->num_var[nfield] = s_obj->num_var[nfield]; + } + + //cout << "str" << endl; + p_obj->str_var.resize(s_obj->str_var.size()); + for(int sfield = 0; sfield < s_obj->str_var.size(); sfield++) + { + p_obj->str_var[sfield] = s_obj->str_var[sfield]; + } + + //cout << "copy uid field" << endl; + p_obj->uid_value.resize(s_obj->uid_value.size()); + for(int ufield = 0; ufield < s_obj->uid_value.size(); ufield++) + { + rc_type_array_copy(s_obj, p_obj); + } + } + + //cout << "done" << endl; + +} + +void rc_type_array_fill(rc_usrId* src, rc_usrId* fdata) +{ + rc_usrId* p_obj; + + for(int i = 0; i < src->uid_value.size(); i++) + { + p_obj = &src->uid_value[i]; + p_obj[0] = fdata[0]; + } + +} -uint64_t rc_number_array_size(rc_numId n_var, int d_num) + +uint64_t rc_number_array_size(rc_numId* n_var, int d_num) { switch(d_num) { case 1: - return n_var.dim[0]; + return n_var->dim[0]; break; case 2: - return n_var.dim[1]; + return n_var->dim[1]; break; case 3: - return n_var.dim[2]; + return n_var->dim[2]; break; } return 0; } -void rc_number_array_copy(uint64_t src_ref_id, uint64_t dst_ref_id) +void rc_number_array_copy(rc_numId* n_var, rc_numId* d_var) +{ + uint64_t src_dim, src_dim_size[3]; + rc_numId* src = (rc_numId*)n_var->nid_value.ref_parent; + src_dim = rc_number_array_dim( src ); + src_dim_size[0] = rc_number_array_size( src, 1); + src_dim_size[1] = rc_number_array_size( src, 2); + src_dim_size[2] = rc_number_array_size( src, 3); + + rc_numId* dst = (rc_numId*)d_var->nid_value.ref_parent; + + uint64_t total_size = 0; + + switch(src_dim) + { + case 1: + total_size = src_dim_size[0]; + dst->nref[0].value.resize(total_size); + //dst->dimensions = 1; + dst->dim[0] = src_dim_size[0]; + dst->dim[1] = 0; + dst->dim[2] = 0; + break; + case 2: + total_size = src_dim_size[0] * src_dim_size[1]; + dst->nref[0].value.resize(total_size); + //dst->dimensions = 2; + dst->dim[0] = src_dim_size[0]; + dst->dim[1] = src_dim_size[1]; + dst->dim[2] = 0; + break; + case 3: + total_size = src_dim_size[0] * src_dim_size[1] * src_dim_size[2]; + dst->nref[0].value.resize(total_size); + //dst->dimensions = 3; + dst->dim[0] = src_dim_size[0]; + dst->dim[1] = src_dim_size[1]; + dst->dim[2] = src_dim_size[2]; + break; + } + + int si = n_var->byref_offset; + int di = d_var->byref_offset; + + //cout << "debug: " << si << ", " << di << endl; + + for(; di < total_size; di++) + { + dst->nref[0].value[di] = src->nref[0].value[si]; + + si++; + } +} + +void rc_string_array_copy(rc_strId* s_var, rc_strId* d_var) { uint64_t src_dim, src_dim_size[3]; - src_dim = rc_number_array_dim( num_var[src_ref_id] ); - src_dim_size[0] = rc_number_array_size( num_var[src_ref_id], 1); - src_dim_size[1] = rc_number_array_size( num_var[src_ref_id], 2); - src_dim_size[2] = rc_number_array_size( num_var[src_ref_id], 3); + rc_strId* src = (rc_strId*)s_var->sid_value.ref_parent; + src_dim = rc_string_array_dim( src ); + src_dim_size[0] = rc_string_array_size( src, 1); + src_dim_size[1] = rc_string_array_size( src, 2); + src_dim_size[2] = rc_string_array_size( src, 3); + + rc_strId* dst = (rc_strId*)d_var->sid_value.ref_parent; uint64_t total_size = 0; - switch(src_dim) - { - case 1: - total_size = src_dim_size[0]; - num_var[dst_ref_id].nref[0].value.resize(total_size); - num_var[dst_ref_id].dimensions = 1; - num_var[dst_ref_id].dim[0] = src_dim_size[0]; - num_var[dst_ref_id].dim[1] = 0; - num_var[dst_ref_id].dim[2] = 0; - break; - case 2: - total_size = src_dim_size[0] * src_dim_size[1]; - num_var[dst_ref_id].nref[0].value.resize(total_size); - num_var[dst_ref_id].dimensions = 2; - num_var[dst_ref_id].dim[0] = src_dim_size[0]; - num_var[dst_ref_id].dim[1] = src_dim_size[1]; - num_var[dst_ref_id].dim[2] = 0; - break; - case 3: - total_size = src_dim_size[0] * src_dim_size[1] * src_dim_size[2]; - num_var[dst_ref_id].nref[0].value.resize(total_size); - num_var[dst_ref_id].dimensions = 3; - num_var[dst_ref_id].dim[0] = src_dim_size[0]; - num_var[dst_ref_id].dim[1] = src_dim_size[1]; - num_var[dst_ref_id].dim[2] = src_dim_size[2]; - break; + switch(src_dim) + { + case 1: + total_size = src_dim_size[0]; + dst->sref[0].value.resize(total_size); + //dst->dimensions = 1; + dst->dim[0] = src_dim_size[0]; + dst->dim[1] = 0; + dst->dim[2] = 0; + break; + case 2: + total_size = src_dim_size[0] * src_dim_size[1]; + dst->sref[0].value.resize(total_size); + //dst->dimensions = 2; + dst->dim[0] = src_dim_size[0]; + dst->dim[1] = src_dim_size[1]; + dst->dim[2] = 0; + break; + case 3: + total_size = src_dim_size[0] * src_dim_size[1] * src_dim_size[2]; + dst->sref[0].value.resize(total_size); + //dst->dimensions = 3; + dst->dim[0] = src_dim_size[0]; + dst->dim[1] = src_dim_size[1]; + dst->dim[2] = src_dim_size[2]; + break; } - for(int i = 0; i < total_size; i++) + int si = s_var->byref_offset; + int di = d_var->byref_offset; + + //cout << "debug: " << si << ", " << di << endl; + + for(; di < total_size; di++) { - num_var[dst_ref_id].nref[0].value[i] = num_var[src_ref_id].nref[0].value[i]; + dst->sref[0].value[di] = src->sref[0].value[si]; + + si++; } } -void rc_string_array_copy(uint64_t src_ref_id, uint64_t dst_ref_id) +void rc_number_array_fill(rc_numId* n_var, double n) +{ + uint64_t src_dim, src_dim_size[3]; + rc_numId* src = (rc_numId*)n_var->nid_value.ref_parent; + src_dim = rc_number_array_dim( src ); + src_dim_size[0] = rc_number_array_size( src, 1); + src_dim_size[1] = rc_number_array_size( src, 2); + src_dim_size[2] = rc_number_array_size( src, 3); + + uint64_t total_size = 0; + + switch(src_dim) + { + case 1: + total_size = src_dim_size[0]; + break; + case 2: + total_size = src_dim_size[0] * src_dim_size[1]; + break; + case 3: + total_size = src_dim_size[0] * src_dim_size[1] * src_dim_size[2]; + break; + } + + //cout << "cp 1: " << src->sid_value.value.size() << " " << s_var->byref_offset << endl; + + for(int i = n_var->byref_offset; i < total_size; i++) + { + src->nref[0].value[i] = n; + } +} + + +void rc_string_array_fill(rc_strId* s_var, string s) { - uint64_t src_dim, src_dim_size[3]; - src_dim = rc_string_array_dim( str_var[src_ref_id] ); - src_dim_size[0] = rc_string_array_size( str_var[src_ref_id], 1); - src_dim_size[1] = rc_string_array_size( str_var[src_ref_id], 2); - src_dim_size[2] = rc_string_array_size( str_var[src_ref_id], 3); - - uint64_t total_size = 0; - - switch(src_dim) - { - case 1: - total_size = src_dim_size[0]; - str_var[dst_ref_id].sref[0].value.resize(total_size); - str_var[dst_ref_id].dimensions = 1; - str_var[dst_ref_id].dim[0] = src_dim_size[0]; - str_var[dst_ref_id].dim[1] = 0; - str_var[dst_ref_id].dim[2] = 0; - break; - case 2: - total_size = src_dim_size[0] * src_dim_size[1]; - str_var[dst_ref_id].sref[0].value.resize(total_size); - str_var[dst_ref_id].dimensions = 2; - str_var[dst_ref_id].dim[0] = src_dim_size[0]; - str_var[dst_ref_id].dim[1] = src_dim_size[1]; - str_var[dst_ref_id].dim[2] = 0; - break; - case 3: - total_size = src_dim_size[0] * src_dim_size[1] * src_dim_size[2]; - str_var[dst_ref_id].sref[0].value.resize(total_size); - str_var[dst_ref_id].dimensions = 3; - str_var[dst_ref_id].dim[0] = src_dim_size[0]; - str_var[dst_ref_id].dim[1] = src_dim_size[1]; - str_var[dst_ref_id].dim[2] = src_dim_size[2]; - break; - } - - for(int i = 0; i < total_size; i++) - { - str_var[dst_ref_id].sref[0].value[i] = str_var[src_ref_id].sref[0].value[i]; - } -} - -void rc_number_array_fill(uint64_t src_ref_id, double n) -{ - uint64_t src_dim, src_dim_size[3]; - src_dim = rc_number_array_dim( num_var[src_ref_id] ); - src_dim_size[0] = rc_number_array_size( num_var[src_ref_id], 1); - src_dim_size[1] = rc_number_array_size( num_var[src_ref_id], 2); - src_dim_size[2] = rc_number_array_size( num_var[src_ref_id], 3); + uint64_t src_dim, src_dim_size[3]; + rc_strId* src = (rc_strId*)s_var->sid_value.ref_parent; + src_dim = rc_string_array_dim( src ); + src_dim_size[0] = rc_string_array_size( src, 1); + src_dim_size[1] = rc_string_array_size( src, 2); + src_dim_size[2] = rc_string_array_size( src, 3); uint64_t total_size = 0; @@ -2319,40 +2544,13 @@ void rc_number_array_fill(uint64_t src_ref_id, double n) case 3: total_size = src_dim_size[0] * src_dim_size[1] * src_dim_size[2]; break; - } + } + + //cout << "cp 1: " << src->sid_value.value.size() << " " << s_var->byref_offset << endl; - for(int i = 0; i < total_size; i++) + for(int i = s_var->byref_offset; i < total_size; i++) { - num_var[src_ref_id].nref[0].value[i] = n; - } -} - -void rc_string_array_fill(uint64_t src_ref_id, string s) -{ - uint64_t src_dim, src_dim_size[3]; - src_dim = rc_string_array_dim( str_var[src_ref_id] ); - src_dim_size[0] = rc_string_array_size( str_var[src_ref_id], 1); - src_dim_size[1] = rc_string_array_size( str_var[src_ref_id], 2); - src_dim_size[2] = rc_string_array_size( str_var[src_ref_id], 3); - - uint64_t total_size = 0; - - switch(src_dim) - { - case 1: - total_size = src_dim_size[0]; - break; - case 2: - total_size = src_dim_size[0] * src_dim_size[1]; - break; - case 3: - total_size = src_dim_size[0] * src_dim_size[1] * src_dim_size[2]; - break; - } - - for(int i = 0; i < total_size; i++) - { - str_var[src_ref_id].sref[0].value[i] = s; + src->sref[0].value[i] = s; } } @@ -2371,19 +2569,19 @@ void func_130(uint64_t fn) rc_push_str( rc_input(INPUT$_PROMPT$) ); break; case FN_StringArrayDim: - rc_push_num( rc_string_array_dim( str_var[arr_ref_id[0]] ) ); + rc_push_num( rc_string_array_dim( (rc_strId*) str_var[0].sid_value.ref_parent ) ); arr_ref_id.clear(); break; case FN_NumberArrayDim: - rc_push_num( rc_number_array_dim( num_var[arr_ref_id[0]] ) ); + rc_push_num( rc_number_array_dim( (rc_numId*)num_var[0].nid_value.ref_parent ) ); arr_ref_id.clear(); break; case FN_StringArraySize: - rc_push_num( rc_string_array_size( str_var[arr_ref_id[0]], STRINGARRAYSIZE_ARRAY_DIM)); + rc_push_num( rc_string_array_size( (rc_strId*) str_var[0].sid_value.ref_parent, STRINGARRAYSIZE_ARRAY_DIM)); arr_ref_id.clear(); break; case FN_NumberArraySize: - rc_push_num( rc_number_array_size( num_var[arr_ref_id[0]], NUMBERARRAYSIZE_ARRAY_DIM)); + rc_push_num( rc_number_array_size( (rc_numId*)num_var[0].nid_value.ref_parent, NUMBERARRAYSIZE_ARRAY_DIM)); arr_ref_id.clear(); break; case FN_Abs: @@ -3554,19 +3752,19 @@ void func_130(uint64_t fn) rc_push_num( rc_media_messageBox(MESSAGEBOX_TITLE$, MESSAGEBOX_MSG$)); break; case FN_NumberArrayCopy: //Sub Procedure - rc_number_array_copy(arr_ref_id[0], arr_ref_id[1]); + rc_number_array_copy( &num_var[0], &num_var[1]); arr_ref_id.clear(); break; case FN_StringArrayCopy: //Sub Procedure - rc_string_array_copy(arr_ref_id[0], arr_ref_id[1]); + rc_string_array_copy( &str_var[0], &str_var[1]); arr_ref_id.clear(); break; case FN_NumberArrayFill: //Sub Procedure - rc_number_array_fill(arr_ref_id[0], NUMBERARRAYFILL_FDATA); + rc_number_array_fill( &num_var[0], NUMBERARRAYFILL_FDATA); arr_ref_id.clear(); break; case FN_StringArrayFill: //Sub Procedure - rc_string_array_fill(arr_ref_id[0], STRINGARRAYFILL_FDATA$); + rc_string_array_fill( &str_var[0], STRINGARRAYFILL_FDATA$); arr_ref_id.clear(); break; case FN_Runtime$: //String Function @@ -4030,6 +4228,25 @@ void func_130(uint64_t fn) case FN_JoinMatrixColumns: //Sub Procedure JoinMatrixColumns(JOINMATRIXCOLUMNS_MA, JOINMATRIXCOLUMNS_MB, JOINMATRIXCOLUMNS_MC); break; + + case FN_TypeArrayDim: //Number Function + rc_push_num( rc_type_array_dim( TYPEARRAYDIM_ID ) ); + arr_ref_id.clear(); + break; + case FN_TypeArraySize: //Number Function + rc_push_num( rc_type_array_size( TYPEARRAYSIZE_ID, TYPEARRAYSIZE_ARRAY_DIM ) ); + arr_ref_id.clear(); + break; + case FN_TypeArrayCopy: //Sub Procedure + //cout << "TAS: " << TYPEARRAYCOPY_SRC->uid_value.size() << endl; + //cout << "TAD: " << TYPEARRAYCOPY_DST->uid_value.size() << endl; + rc_free_type(TYPEARRAYCOPY_DST); //cout << "TA[2]: " << TYPEARRAYCOPY_DST->uid_value.size() << endl; + rc_type_array_copy( TYPEARRAYCOPY_SRC, TYPEARRAYCOPY_DST ); + break; + case FN_TypeArrayFill: //Sub Procedure + //cout << "test type fill" << endl; + rc_type_array_fill( TYPEARRAYFILL_SRC, &TYPEARRAYFILL_FDATA ); + break; } @@ -4380,6 +4597,8 @@ void obj_usr_get_164(int n1) vm_n[n1].value = usr_object.num_ref->nref[0].value[usr_object.index]; vm_n[n1].r = usr_object.num_ref->nref; vm_n[n1].r_index = usr_object.index; + + usr_object.num_ref->nid_value.ref_parent = usr_object.num_ref; //cout << "obj_usr_get_N done: " << vm_n[n1].r[0].value[vm_n[n1].r_index] << endl; } @@ -4388,19 +4607,33 @@ void obj_usr_get_165(int s1) vm_s[s1].value = usr_object.str_ref->sref[0].value[usr_object.index]; vm_s[s1].r = usr_object.str_ref->sref; vm_s[s1].r_index = usr_object.index; + + usr_object.str_ref->sid_value.ref_parent = usr_object.str_ref; + //cout << "obj_usr_get -- " << usr_object.str_ref->dimensions << " --> " << usr_object.str_ref->dim[0] << ", " << usr_object.str_ref->dim[1] << endl; } void obj_usr_get_166(int u1) { //cout << "obj_usr_get start u" << u1 << endl; + //rc_usrId * tmp_usr_id = usr_object.obj_ref->byref_ptr; + //cout << "tmp check = " << usr_object.obj_ref->byref_ptr->dimensions << endl; + rc_free_type(&vm_u[u1]); //this should free any memory previously allocated in u1 + + //cout << "tmp check[2] = " << usr_object.obj_ref->byref_ptr->dimensions << endl; + //cout << "mem free: " << usr_object.obj_ref->dimensions << endl; vm_u[u1] = usr_object.obj_ref[0]; //cout << "1: " << usr_object.obj_ref[0].uid_value.size() << endl; vm_u[u1].var_ref = usr_object.obj_ref; //cout << "2" << endl; - vm_u[u1].var_ref_index = 0 ; //usr_object.index; This has become unnecessary because var_ref points to the correct index + vm_u[u1].var_ref_index = usr_object.index; //usr_object.index; + //cout << "obj_usr_get end" << endl; + + //cout << "tmp check[3] = " << vm_u[u1].var_ref->byref_ptr->dimensions << endl; + + //cout << "bcheck = " << tmp_usr_id->dimensions << endl; } void uref_ptr_167(uint64_t uid, int u1) @@ -4412,8 +4645,17 @@ void uref_ptr_167(uint64_t uid, int u1) byref_addr_table.push(byref_id); byref_var_byref_offset.push(usr_var[uid].var_ref_index); - usr_var[uid].var_ref = vm_u[u1].var_ref; - usr_var[uid].var_ref_index = vm_u[u1].var_ref_index; + //cout << "start index = " << usr_var[uid].var_ref_index << endl; + + int i = vm_u[u1].var_ref_index; + + usr_var[uid].var_ref = vm_u[u1].var_ref->byref_ptr; + usr_var[uid].var_ref_index = i; //vm_u[u1].var_ref_index; + + //int i = vm_u[u1].var_ref_index; + //cout << "index = " << usr_var[uid].var_ref_index << endl; + //cout << "uref end: " << usr_var[uid].var_ref->uid_value.size() << endl; + //cout << "debug out = " << usr_var[uid].var_ref->uid_value[i].str_var[0].sid_value.value[3] << endl; } void mov_type_168(uint64_t uid, int u1) @@ -4463,9 +4705,47 @@ void push_t_null_173() //I will need to do something with this } -void delete_t_174(uint64_t uid) +void delete_t_174(uint64_t oid, uint64_t top_level_flag, uint64_t obj_type) { - rc_free_type(&usr_object.obj_ref->uid_value[uid]); + //cout << "DEBUG: " << oid << ", " << top_level_flag << ", " << obj_type << endl; + //cout << "Delete Object: " << usr_object.obj_ref->str_var[1].dim[0] << endl; + if(top_level_flag == 0) + { + //cout << "[START] USR TL: " << usr_var[oid].uid_value[0].str_var.size() << endl; + rc_free_type(&usr_var[oid]); + //cout << "[END] USR TL: " << usr_var[oid].uid_value[0].str_var.size() << endl; + } + else + { + switch(obj_type) + { + case 0: + //cout << "DBG NDATA: " << usr_object.obj_ref->num_var[oid].dim[0] << endl; + usr_object.obj_ref->num_var[oid].nid_value.value.clear(); + usr_object.obj_ref->num_var[oid].nid_value.value.shrink_to_fit(); + usr_object.obj_ref->num_var[oid].dimensions = 0; + usr_object.obj_ref->num_var[oid].dim[0] = 0; + usr_object.obj_ref->num_var[oid].dim[1] = 0; + usr_object.obj_ref->num_var[oid].dim[2] = 0; + break; + + case 1: + //cout << "DBG SDATA: " << usr_object.obj_ref->str_var[oid].dim[0] << endl; + usr_object.obj_ref->str_var[oid].sid_value.value.clear(); + usr_object.obj_ref->str_var[oid].sid_value.value.shrink_to_fit(); + usr_object.obj_ref->str_var[oid].dimensions = 0; + usr_object.obj_ref->str_var[oid].dim[0] = 0; + usr_object.obj_ref->str_var[oid].dim[1] = 0; + usr_object.obj_ref->str_var[oid].dim[2] = 0; + break; + + case 2: + //cout << "DBG UDATA: " << usr_object.obj_ref->uid_value[oid].dim[0] << endl; + rc_free_type(&usr_object.obj_ref->uid_value[oid]); + break; + } + } + //cout << "Done" << endl; } void dim_type_175(int u1, int udt_index) @@ -4506,15 +4786,25 @@ void obj_usr_init_180(uint64_t uid) { //cout << "obj_usr_init " << uid << endl; usr_object.index = 0; + + usr_object.index += usr_var[uid].var_ref_index; + usr_object.obj_ref = &usr_var[uid].var_ref->uid_value[usr_object.index]; //need to switch to var_ref //cout << "obj_usr_init done: " << usr_object.obj_ref[0].uid_value.size() << endl; + + usr_object.obj_ref->byref_ptr = usr_var[uid].var_ref; } void obj_usr_init1_181(uint64_t uid, int n1) { //cout << "obj_usr_init1 " << uid << endl; usr_object.index = (uint64_t)vm_n[n1].value; + + usr_object.index += usr_var[uid].var_ref_index; + usr_object.obj_ref = &usr_var[uid].var_ref->uid_value[usr_object.index]; + + usr_object.obj_ref->byref_ptr = usr_var[uid].var_ref; } void obj_usr_init2_182(uint64_t uid, int n1, int n2) @@ -4525,14 +4815,27 @@ void obj_usr_init2_182(uint64_t uid, int n1, int n2) //d[2] = usr_var[uid].dim[2]; //cout << "obj_usr_init2: " << uid << " --dim=[" << d[0] << ", " << d[1] << ", " << d[2] << "]" << endl; usr_object.index = (uint64_t)vm_n[n1].value * usr_var[uid].dim[1] + (uint64_t)vm_n[n2].value; + + usr_object.index += usr_var[uid].var_ref_index; + usr_object.obj_ref = &usr_var[uid].var_ref->uid_value[usr_object.index]; + + usr_object.obj_ref->byref_ptr = usr_var[uid].var_ref; + + //cout << "dimbr = " << uid << " " << n1 << " " << n2 << " " << usr_object.obj_ref->byref_ptr->dimensions << endl; + //cout << "d2_dbg = " << usr_var[uid].var_ref->uid_value.size() << " --- " << usr_object.index << endl; } void obj_usr_init3_183(uint64_t uid, int n1, int n2, int n3) { //cout << "obj_usr_init3 " << uid << endl; usr_object.index = ( (uint64_t)vm_n[n1].value * usr_var[uid].dim[1] * usr_var[uid].dim[2] ) + ((uint64_t)vm_n[n2].value * usr_var[uid].dim[2]) + (uint64_t)vm_n[n3].value;; + + usr_object.index += usr_var[uid].var_ref_index; + usr_object.obj_ref = &usr_var[uid].var_ref->uid_value[usr_object.index]; + + usr_object.obj_ref->byref_ptr = usr_var[uid].var_ref; } @@ -4663,7 +4966,150 @@ void preset_t3_191(uint64_t uid, uint64_t utype, int n1, int n2, int n3) { rc_preset_type(&usr_var[uid]); } -} +} + + +void redim_type_192(int u1, int udt_index) +{ + // Currently unused +} + +void redim_type1_193(int u1, int udt_index, int n1) +{ + // Currently unused +} + +void redim_type2_194(int u1, int udt_index, int n1, int n2) +{ + // Currently unused +} + +void redim_type3_195(int u1, int udt_index, int n1, int n2, int n3) +{ + // Currently unused +} + + +void redim_type_n_196(uint64_t nid) +{ + usr_object.obj_ref->num_var[nid].nid_value.value.resize(1); + usr_object.obj_ref->num_var[nid].dimensions = 0; + usr_object.obj_ref->num_var[nid].dim[0] = 0; + usr_object.obj_ref->num_var[nid].dim[1] = 0; + usr_object.obj_ref->num_var[nid].dim[2] = 0; +} + +void redim_type_n1_197(uint64_t nid, int n1) +{ + usr_object.obj_ref->num_var[nid].nid_value.value.resize((uint64_t)vm_n[n1].value); + usr_object.obj_ref->num_var[nid].dimensions = 1; + usr_object.obj_ref->num_var[nid].dim[0] = (uint64_t)vm_n[n1].value; + usr_object.obj_ref->num_var[nid].dim[1] = 0; + usr_object.obj_ref->num_var[nid].dim[2] = 0; +} + +void redim_type_n2_198(uint64_t nid, int n1, int n2) +{ + usr_object.obj_ref->num_var[nid].nid_value.value.resize((uint64_t)(vm_n[n1].value * vm_n[n2].value)); + usr_object.obj_ref->num_var[nid].dimensions = 2; + usr_object.obj_ref->num_var[nid].dim[0] = (uint64_t)vm_n[n1].value; + usr_object.obj_ref->num_var[nid].dim[1] = (uint64_t)vm_n[n2].value; + usr_object.obj_ref->num_var[nid].dim[2] = 0; +} + +void redim_type_n3_199(uint64_t nid, int n1, int n2, int n3) +{ + usr_object.obj_ref->num_var[nid].nid_value.value.resize((uint64_t)(vm_n[n1].value * vm_n[n2].value * vm_n[n3].value)); + usr_object.obj_ref->num_var[nid].dimensions = 3; + usr_object.obj_ref->num_var[nid].dim[0] = (uint64_t)vm_n[n1].value; + usr_object.obj_ref->num_var[nid].dim[1] = (uint64_t)vm_n[n2].value; + usr_object.obj_ref->num_var[nid].dim[2] = (uint64_t)vm_n[n3].value; +} + + +void redim_type_s_200(uint64_t sid) +{ + usr_object.obj_ref->str_var[sid].sid_value.value.resize(1); + usr_object.obj_ref->str_var[sid].dimensions = 0; + usr_object.obj_ref->str_var[sid].dim[0] = 0; + usr_object.obj_ref->str_var[sid].dim[1] = 0; + usr_object.obj_ref->str_var[sid].dim[2] = 0; +} + +void redim_type_s1_201(uint64_t sid, int n1) +{ + usr_object.obj_ref->str_var[sid].sid_value.value.resize((uint64_t)vm_n[n1].value); + usr_object.obj_ref->str_var[sid].dimensions = 1; + usr_object.obj_ref->str_var[sid].dim[0] = (uint64_t)vm_n[n1].value; + usr_object.obj_ref->str_var[sid].dim[1] = 0; + usr_object.obj_ref->str_var[sid].dim[2] = 0; +} + +void redim_type_s2_202(uint64_t sid, int n1, int n2) +{ + usr_object.obj_ref->str_var[sid].sid_value.value.resize((uint64_t)(vm_n[n1].value * vm_n[n2].value)); + usr_object.obj_ref->str_var[sid].dimensions = 2; + usr_object.obj_ref->str_var[sid].dim[0] = (uint64_t)vm_n[n1].value; + usr_object.obj_ref->str_var[sid].dim[1] = (uint64_t)vm_n[n2].value; + usr_object.obj_ref->str_var[sid].dim[2] = 0; +} + +void redim_type_s3_203(uint64_t sid, int n1, int n2, int n3) +{ + usr_object.obj_ref->str_var[sid].sid_value.value.resize((uint64_t)(vm_n[n1].value * vm_n[n2].value * vm_n[n3].value)); + usr_object.obj_ref->str_var[sid].dimensions = 3; + usr_object.obj_ref->str_var[sid].dim[0] = (uint64_t)vm_n[n1].value; + usr_object.obj_ref->str_var[sid].dim[1] = (uint64_t)vm_n[n2].value; + usr_object.obj_ref->str_var[sid].dim[2] = (uint64_t)vm_n[n3].value; +} + +void redim_type_204(uint64_t uid, int udt_index) +{ + if(redim_toplevel_flag) + rc_dim_type(&usr_var[uid], udt_index, 0, 0, 0, 0, 0); + else + rc_dim_type(&usr_object.obj_ref->uid_value[uid], udt_index, 0, 0, 0, 0, 0); + + redim_toplevel_flag = false; +} + +void redim_type1_205(uint64_t uid, int udt_index, int n1) +{ + if(redim_toplevel_flag) + rc_dim_type(&usr_var[uid], udt_index, 1, (uint64_t)vm_n[n1].value, 0, 0, usr_var[uid].uid_value.size()); + else + rc_dim_type(&usr_object.obj_ref->uid_value[uid], udt_index, 1, (uint64_t)vm_n[n1].value, 0, 0, usr_object.obj_ref->uid_value[uid].uid_value.size()); + + redim_toplevel_flag = false; +} + +void redim_type2_206(uint64_t uid, int udt_index, int n1, int n2) +{ + if(redim_toplevel_flag) + rc_dim_type(&usr_var[uid], udt_index, 2, (uint64_t)vm_n[n1].value, (uint64_t)vm_n[n2].value, 0, usr_var[uid].uid_value.size()); + else + rc_dim_type(&usr_object.obj_ref->uid_value[uid], udt_index, 2, (uint64_t)vm_n[n1].value, (uint64_t)vm_n[n2].value, 0, usr_object.obj_ref->uid_value[uid].uid_value.size()); + + //cout << "test tl: " << redim_toplevel_flag << " -- " << usr_var[uid].uid_value.size() << endl; + + redim_toplevel_flag = false; +} + +void redim_type3_207(uint64_t uid, int udt_index, int n1, int n2, int n3) +{ + if(redim_toplevel_flag) + rc_dim_type(&usr_var[uid], udt_index, 3, (uint64_t)vm_n[n1].value, (uint64_t)vm_n[n2].value, (uint64_t)vm_n[n3].value, usr_var[uid].uid_value.size()); + else + rc_dim_type(&usr_object.obj_ref->uid_value[uid], udt_index, 3, (uint64_t)vm_n[n1].value, (uint64_t)vm_n[n2].value, (uint64_t)vm_n[n3].value, usr_object.obj_ref->uid_value[uid].uid_value.size()); + + redim_toplevel_flag = false; +} + +void redim_top_208() +{ + redim_toplevel_flag = true; +} + bool rcbasic_run() { @@ -5371,7 +5817,9 @@ bool rcbasic_run() break; case 174: i[0] = readInt(); - delete_t_174(i[0]); + i[1] = readInt(); + i[2] = readInt(); + delete_t_174(i[0], i[1], i[2]); break; case 175: i[0] = readInt(); @@ -5478,6 +5926,105 @@ bool rcbasic_run() i[3] = readInt(); i[4] = readInt(); preset_t3_191(i[0], i[1], i[2], i[3], i[4]); + break; + case 192: + i[0] = readInt(); + i[1] = readInt(); + redim_type_192(i[0], i[1]); + break; + case 193: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + redim_type1_193(i[0], i[1], i[2]); + break; + case 194: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + i[3] = readInt(); + redim_type2_194(i[0], i[1], i[2], i[3]); + break; + case 195: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + i[3] = readInt(); + i[4] = readInt(); + redim_type3_195(i[0], i[1], i[2], i[3], i[4]); + break; + case 196: + i[0] = readInt(); + redim_type_n_196(i[0]); + break; + case 197: + i[0] = readInt(); + i[1] = readInt(); + redim_type_n1_197(i[0], i[1]); + break; + case 198: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + redim_type_n2_198(i[0], i[1], i[2]); + break; + case 199: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + i[3] = readInt(); + redim_type_n3_199(i[0], i[1], i[2], i[3]); + break; + case 200: + i[0] = readInt(); + redim_type_s_200(i[0]); + break; + case 201: + i[0] = readInt(); + i[1] = readInt(); + redim_type_s1_201(i[0], i[1]); + break; + case 202: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + redim_type_s2_202(i[0], i[1], i[2]); + break; + case 203: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + i[3] = readInt(); + redim_type_s3_203(i[0], i[1], i[2], i[3]); + break; + case 204: + i[0] = readInt(); + i[1] = readInt(); + redim_type_204(i[0], i[1]); + break; + case 205: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + redim_type1_205(i[0], i[1], i[2]); + break; + case 206: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + i[3] = readInt(); + redim_type2_206(i[0], i[1], i[2], i[3]); + break; + case 207: + i[0] = readInt(); + i[1] = readInt(); + i[2] = readInt(); + i[3] = readInt(); + i[4] = readInt(); + redim_type3_207(i[0], i[1], i[2], i[3], i[4]); + break; + case 208: + redim_top_208(); break; default: cout << "invalid cmd: " << rcbasic_cmd << endl; @@ -5569,7 +6116,7 @@ int main(int argc, char * argv[]) if(rc_filename.compare("--version")==0) { - cout << "RCBASIC Runtime v4.0a1" << endl; + cout << "RCBASIC Runtime v4.0a" << endl; return 0; } diff --git a/rcbasic_runtime/rc_defines.h b/rcbasic_runtime/rc_defines.h index 44c7403..c3f29dd 100644 --- a/rcbasic_runtime/rc_defines.h +++ b/rcbasic_runtime/rc_defines.h @@ -1415,3 +1415,14 @@ #define JOINMATRIXCOLUMNS_MA num_var[0].nid_value.value[ num_var[0].byref_offset ] #define JOINMATRIXCOLUMNS_MB num_var[1].nid_value.value[ num_var[1].byref_offset ] #define JOINMATRIXCOLUMNS_MC num_var[2].nid_value.value[ num_var[2].byref_offset ] +#define FN_TypeArrayDim 471 +#define TYPEARRAYDIM_ID usr_var[0].var_ref +#define FN_TypeArraySize 472 +#define TYPEARRAYSIZE_ID usr_var[0].var_ref +#define TYPEARRAYSIZE_ARRAY_DIM num_var[0].nid_value.value[ num_var[0].byref_offset ] +#define FN_TypeArrayCopy 473 +#define TYPEARRAYCOPY_SRC usr_var[0].var_ref +#define TYPEARRAYCOPY_DST usr_var[1].var_ref +#define FN_TypeArrayFill 474 +#define TYPEARRAYFILL_SRC usr_var[0].var_ref +#define TYPEARRAYFILL_FDATA usr_var[1].var_ref->uid_value[0]