| 1300 | } |
| 1301 | |
| 1302 | void ASModule::GetGlobalVars(std::list<VarStorage>& storage, std::list<ScriptObjectInstance>& handle_var_list) { |
| 1303 | int c = module_->GetGlobalVarCount(); |
| 1304 | for (int n = 0; n < c; n++) { |
| 1305 | const char* name; |
| 1306 | const char** name_hdl = &name; |
| 1307 | int type_id; |
| 1308 | bool is_const; |
| 1309 | module_->GetGlobalVar(n, name_hdl, 0, &type_id, &is_const); |
| 1310 | if (is_const) { |
| 1311 | continue; |
| 1312 | } |
| 1313 | void* ptr = module_->GetAddressOfGlobalVar(n); |
| 1314 | VarStorage new_var; |
| 1315 | FillVar(new_var, name, type_id, ptr, handle_var_list, module_); |
| 1316 | storage.push_back(new_var); |
| 1317 | } |
| 1318 | } |
| 1319 | |
| 1320 | void ASModule::SaveGlobalVars() { |
| 1321 | GetGlobalVars(saved_vars_, saved_handle_vars_); |
nothing calls this directly
no test coverage detected