void Slice::GetArrayBounds(ArrayKey& lo, ArrayKey& hi) const { if (bIsString) { lo = ArrayKey(m_lowerStr); hi = ArrayKey(m_upperStr); } else { lo = ArrayKey(m_lower); hi = ArrayKey(m_upper); } }
static bool Cmd_GetCreatureModelPaths_Execute(COMMAND_ARGS) { UInt32 arrID = g_ArrayMap.Create(kDataType_Numeric, true, scriptObj->GetModIndex()); *result = arrID; TESActorBase* actorBase = NULL; if (ExtractArgs(PASS_EXTRACT_ARGS, &actorBase)) { if (!actorBase && thisObj) actorBase = OBLIVION_CAST(thisObj->baseForm, TESForm, TESActorBase); if (actorBase) { TESCreature* crea = OBLIVION_CAST(actorBase, TESActorBase, TESCreature); if (crea) { UInt32 idx = 0; for (TESModelList::Entry* cur = &crea->modelList.modelList; cur && cur->nifPath; cur = cur->next) { g_ArrayMap.SetElementString(arrID, ArrayKey(idx), cur->nifPath); idx++; } } } } return true; }