Jump to content

how can i check if there's ANY item in a container?


stevie70

Recommended Posts

if GetContainerInventoryCount > 0

 

It's a new function (was added with the 1.3 patch I think)

cool, thanks a lot - & very nice of bethesda to imply exactly the commands i need exactly when i need them... :-))

 

p.s.: please, dear bethesda, something like "IsModInstalled" (without nvse) would be nice next, thanks in advance :-)

Link to comment
Share on other sites

p.s.: please, dear bethesda, something like "IsModInstalled" (without nvse) would be nice next, thanks in advance :-)

 

They do have something like that already (IsDLCInstalled), but I'm not sure exactly how it works.

The snippet below is from the script VDLCPackQuestSCRIPT

 

 

if (bTribalInstalledOnce && IsDLCInstalled "Tribal Pack" != 1)
	set bTribalUninstalled to 1;
endif
if (bCaravanInstalledOnce && IsDLCInstalled "Caravan Pack" != 1)
	set bCaravanUninstalled to 1;
endif
if (bMercenaryInstalledOnce && IsDLCInstalled "Mercenary Pack" != 1)
	set bMercenaryUninstalled to 1;
endif
if (bClassicInstalledOnce && IsDLCInstalled "Classic Pack" != 1)
	set bClassicUninstalled to 1;
endif

 

 

 

I don't have any of those pre-order packs so I don't know if they are reading those strings from the esm files.

Those strings are in the exe file, so the function may be hardcoded for the prepacks only.

The names of all 4 expansions are in the exe too though. (ie. OldWorldBlues & LonesomeRoad are there already)

Link to comment
Share on other sites

They do have something like that already (IsDLCInstalled), but I'm not sure exactly how it works.

The snippet below is from the script VDLCPackQuestSCRIPT

[...]

hey, coool - thanks for the hint, gonna try if i can gat any of those to do anything with some own mods :-))

Link to comment
Share on other sites

  • 1 month later...

They do have something like that already (IsDLCInstalled), but I'm not sure exactly how it works.

The snippet below is from the script VDLCPackQuestSCRIPT

if (bClassicInstalledOnce && IsDLCInstalled "Classic Pack" != 1)
	set bClassicUninstalled to 1;
endif

 

I don't have any of those pre-order packs so I don't know if they are reading those strings from the esm files.

Those strings are in the exe file, so the function may be hardcoded for the prepacks only.

The names of all 4 expansions are in the exe too though. (ie. OldWorldBlues & LonesomeRoad are there already)

i just can't figure out how that works.

i tried all of the following using IsDLCInstalled:

( O ) i queried my mod by filename - - - > nothing.

( O ) i found the original dlc's come with a *.nam file, named like the file and containing the name, so i did the same for my mod and tried querying the name contained in my nam-file - - - > nothing.

( O ) i tried both of the above with an esm-version (using fnv-edit) of my mod - - - > nothing.

( O ) to get a clue if it only works with vanilla dlc's, i tried querying the classic pack (only one i have) the same way as in the vanilla script quoted above - - - > nothing. (that's the part i REALLY find weird).

 

the scripts i used should have (v1) displayed a note or (v2) enabled an item, i've tried both onLoad and onActivate (to make sure to let enough time pass so that the plugin has already been loaded when i coc into my testcell), all of the scripts compiled fine and did exactly what they should when i ran them on any other variables.

 

one thing i haven't tried yet (because it just came to my mind) is, the vanilla script uses IsDLCInstalled in a GameMode block (i'll try it, but i somehow can't really imagine what this should have to do with it)

 

ah yes and i've tried looking it up in the geck-wiki, but (apart from the database query being disfunctional for weeks now) according to it, the command apparently doesn't exist at all... :-)

 

any more ideas anyone maybe...?

Link to comment
Share on other sites

The function parameters are hardcoded into the game, you need NVSE to do this.

i don't really see how that would explain why i can't even query the classic pack...?

(and if i really _do_ need nvse here is just what i'm trying to find out, because what i'm looking for are ways of mod interaction _without_ nvse).

Edited by stevie70
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...