optimized FindWorldItem()
This commit is contained in:
parent
71ba27184b
commit
b109f6c4f1
4 changed files with 91 additions and 67 deletions
|
|
@ -833,12 +833,6 @@ function CheckAdditionalThings(divId, dataObject, playerData, worldData, sceneDa
|
|||
case "loveKey":
|
||||
(playerData.hasLoveKey === true || playerData.openedLoveDoor === true) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "simpleKeyCityOfTears": // #2
|
||||
(FindWorldItem("Shiny Item", "Ruins1_17")) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "simpleKeyAncientBasin": // #3
|
||||
(FindWorldItem("Shiny Item Stand", "Abyss_20")) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "gotLurkerKey":
|
||||
case "nightmareLanternLit":
|
||||
case "killedPaleLurker":
|
||||
|
|
@ -861,23 +855,19 @@ function CheckAdditionalThings(divId, dataObject, playerData, worldData, sceneDa
|
|||
}
|
||||
(playerData[i] === true) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "paleOreAncientBasin": // #1
|
||||
(FindWorldItem("Battle Scene Ore", "Abyss_17")) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "paleOreSeer": // #2
|
||||
(playerData.dreamReward2 === true) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
/* -------------------- Interactables ------------------------------- */
|
||||
case "simpleKeyCityOfTears": // #2
|
||||
case "simpleKeyAncientBasin": // #3
|
||||
case "paleOreAncientBasin": // #1
|
||||
case "paleOreCrystalPeak": // #3
|
||||
(FindWorldItem("Shiny Item Stand", "Mines_34")) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "paleOreDeepnest": // #4
|
||||
(FindWorldItem("Shiny Item Stand", "Deepnest_32")) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "paleOreGrubfather": // #5
|
||||
(FindWorldItem("Shiny Item Ore", "Crossroads_38")) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "paleOreColosseum": // #6
|
||||
(FindWorldItem("Shiny Item", "Room_Colosseum_Silver")) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
case "pantheonSoulWarrior":
|
||||
(FindWorldItem(dataObject[i].id, dataObject[i].sceneName)) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
case "relicsWandererJournal":
|
||||
case "relicsHallownestSeal":
|
||||
|
|
@ -999,9 +989,6 @@ function CheckAdditionalThings(divId, dataObject, playerData, worldData, sceneDa
|
|||
case "mrMushroomState":
|
||||
sFillText += CheckMrMushroomState(divId, dataObject[i], playerData[i]);
|
||||
break;
|
||||
case "pantheonSoulWarrior":
|
||||
(FindWorldItem(dataObject[i].id, dataObject[i].sceneName)) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
break;
|
||||
default:
|
||||
(playerData[i] === true) ? CurrentDataTrue(): CurrentDataFalse();
|
||||
} // end switch (i)
|
||||
|
|
@ -1025,10 +1012,9 @@ function CheckAdditionalThings(divId, dataObject, playerData, worldData, sceneDa
|
|||
for (let i = 0, length = worldData.length; i < length; i++) {
|
||||
if (worldData[i].id === idText && worldData[i].sceneName === sceneNameText && worldData[i].activated === true) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -913,11 +913,15 @@ const HK = {
|
|||
simpleKeyCityOfTears: {
|
||||
name: "Simple Key #2",
|
||||
spoiler: "City of Tears, below west Stag Station",
|
||||
id: "Shiny Item",
|
||||
sceneName: "Ruins1_17",
|
||||
wiki: "Simple_Key#How_to_Acquire"
|
||||
},
|
||||
simpleKeyAncientBasin: {
|
||||
name: "Simple Key #3",
|
||||
spoiler: "Ancient Basin, below Broken Vessel",
|
||||
id: "Shiny Item Stand",
|
||||
sceneName: "Abyss_20",
|
||||
wiki: "Simple_Key#How_to_Acquire"
|
||||
},
|
||||
gotLurkerKey: {
|
||||
|
|
@ -928,6 +932,8 @@ const HK = {
|
|||
paleOreAncientBasin: {
|
||||
name: "Pale Ore #1",
|
||||
spoiler: "Ancient Basin, near Cloth location",
|
||||
id: "Battle Scene Ore",
|
||||
sceneName: "Abyss_17",
|
||||
wiki: "Pale_Ore"
|
||||
},
|
||||
paleOreSeer: {
|
||||
|
|
@ -938,21 +944,29 @@ const HK = {
|
|||
paleOreCrystalPeak: {
|
||||
name: "Pale Ore #3",
|
||||
spoiler: "Crystal Peak: Hallownest's Crown",
|
||||
id: "Shiny Item Stand",
|
||||
sceneName: "Mines_34",
|
||||
wiki: "Pale_Ore#How_to_Acquire"
|
||||
},
|
||||
paleOreDeepnest: {
|
||||
name: "Pale Ore #4",
|
||||
spoiler: "Deepnest, Nosk reward",
|
||||
id: "Shiny Item Stand",
|
||||
sceneName: "Deepnest_32",
|
||||
wiki: "Pale_Ore#How_to_Acquire"
|
||||
},
|
||||
paleOreGrubfather: {
|
||||
name: "Pale Ore #5",
|
||||
spoiler: "Grubfather: 31 Grubs rescued",
|
||||
id: "Shiny Item Ore",
|
||||
sceneName: "Crossroads_38",
|
||||
wiki: "Pale_Ore#How_to_Acquire"
|
||||
},
|
||||
paleOreColosseum: {
|
||||
name: "Pale Ore #6",
|
||||
spoiler: "Colosseum of Fools: Trial of the Conqueror",
|
||||
id: "Shiny Item",
|
||||
sceneName: "Room_Colosseum_Silver",
|
||||
wiki: "Pale_Ore#How_to_Acquire"
|
||||
},
|
||||
waterwaysAcidDrained: {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue