| 450 | void FillVar(VarStorage& new_var, const char* name, int type_id, void* ptr, std::list<ScriptObjectInstance>& handle_var_list, asIScriptModule* module); |
| 451 | |
| 452 | void ScriptObject::Populate(asIScriptObject* obj, std::list<ScriptObjectInstance>& handle_var_list, asIScriptModule* module) { |
| 453 | int c = obj->GetPropertyCount(); |
| 454 | for (int n = 0; n < c; n++) { |
| 455 | const char* name = obj->GetPropertyName(n); |
| 456 | int type_id = obj->GetPropertyTypeId(n); |
| 457 | void* ptr = obj->GetAddressOfProperty(n); |
| 458 | VarStorage new_var; |
| 459 | FillVar(new_var, name, type_id, ptr, handle_var_list, module); |
| 460 | storage.push_back(new_var); |
| 461 | } |
| 462 | } |
| 463 | |
| 464 | void ScriptObject::destroy() { |
| 465 | std::list<VarStorage>::iterator iter = storage.begin(); |
no test coverage detected