Jump to content

Master file removel help please.


RunningBare

Recommended Posts

Sorry, I forgot to ask, can I obtain global variables from the other mod in the same way?

 

I'm going to state that it's impossible with the hope that somebody will come along and prove me wrong :)

 

Another similar problem, is building a ref to a quest, and then accessing the quest vars somehow. I don't think the actual variable names are used ingame. They seem to be hardcoded in scripts using the offset - so that's probably not possible either.

 

(If the 'other mod' is yours too, then you can write it in a way to workaround these problems.)

Link to comment
Share on other sites

 

I'm going to state that it's impossible with the hope that somebody will come along and prove me wrong :)

 

(If the 'other mod' is yours too, then you can write it in a way to workaround these problems.)

And you are probably correct, I attempted multiple various ways to access numeric variables, I could not find any way to get it to work.

 

Unfortunately the other mod is not mine but I have been given permission to upload it when the time comes to upload mine.

 

I've run across another issue that I cannot seem to correct, the dreaded navmesh, my mod is set in an external cell, but I noticed when crossing from a neighboring cell the companions stop walking and start clipping across the surface trying to keep up, it's like they cannot find the navmesh path, I've gone through the navmesh in Geck with a fine tooth comb, made sure it was flush against neighboring cells(both horizontal and vertical), the check navmesh reports no errors, and yet in game there is obviously a navmesh error, the only time I've witnessed companion behavior like this before is when there has been no navmesh, yet geck clearly shows I have navmesh laid down, if anyone has any suggestions I would be grateful, thanks in advance.

Link to comment
Share on other sites

Have you clicked the 'finalize navemesh' button? Also, have you tested it with the esm flag set?

If you are creating new areas with a navemesh, you should release it as an esm.

Link to comment
Share on other sites

Have you clicked the 'finalize navemesh' button? Also, have you tested it with the esm flag set?

If you are creating new areas with a navemesh, you should release it as an esm.

Yes, I've finalized, no it's not a new area, as for esm, that's not possible, my mod needs to come after the other mod in the load order, the other mod is an esp, thanks for the quick reply.
Link to comment
Share on other sites

I'm going to state that it's impossible with the hope that somebody will come along and prove me wrong :)

And I will state that it is indeed possible. This handy snippet of code here:

if IsModLoaded "Project Nevada - Rebalance.esp"
set iIndex to GetModIndex "Project Nevada - Rebalance.esp"
set iRef to 2048
set rBuilt to BuildRef iIndex iRef

;printc "checking validity of %i" rBuilt
if isFormValid rBuilt
	set iTemp to GetGlobalValue rBuilt
	set NCENukaColaHeals to iTemp
	;printc "NCENukaColaHeals set to %.0f" NCENukaColaHeals
endif
endif

Allows me to build a global from Project Nevada (in my case, the global for food healing) and then set my own local global to that value. If you want to see it in action, go download my Wonder Meat mod and load it along with PN. Once in game, type:

GetGlobalValue xx001CA1

It should return a 1 or a 0, but in my test, I set the PNxFoodHeals global value to 5 so I could make sure my script was indeed returning the actual value of the global.

 

So yes, it is possible to get values from other mods without need masters. I know the wiki states that GetGlobalRef is a condition function, but hey, nothing ventured nothing gained (in this instance it worked out fine).

 

 

Another note to take from this though, is that, while you can also build placed refs (the world version of a base form), they have to either be flagged persistent, or loaded in the current cell in order to be done anything with. At least, as far as making them run scripts. I found this out (and it seems pretty obvious) when trying to activate the bobblehead stands in Bobblehung mod from a remote location (my own custom BuildRef using bobblehead stand).

 

Another similar problem, is building a ref to a quest, and then accessing the quest vars somehow. I don't think the actual variable names are used ingame. They seem to be hardcoded in scripts using the offset - so that's probably not possible either.

 

(If the 'other mod' is yours too, then you can write it in a way to workaround these problems.)

This one is, to my knowledge (and tests) impossible. It's unfortunate, but can be bypassed if the second mod does not need to communicate with the first mod. Someone on here did come up with a method, but it's not the most practical and requires both files to be written to support it.

Link to comment
Share on other sites

 

And I will state that it is indeed possible. This handy snippet of code here:

Allows me to build a global from Project Nevada (in my case, the global for food healing) and then set my own local global to that value. If you want to see it in action, go download my Wonder Meat mod and load it along with PN. Once in game, type:

 

It should return a 1 or a 0, but in my test, I set the PNxFoodHeals global value to 5 so I could make sure my script was indeed returning the actual value of the global.

 

So yes, it is possible to get values from other mods without need masters. I know the wiki states that GetGlobalRef is a condition function, but hey, nothing ventured nothing gained (in this instance it worked out fine).

Thank you, very helpful, it's only the condition I'm after, can you please give me a link to the wiki, I am unable to find anything with a search of geckwiki.
Link to comment
Share on other sites

Nice find Gribbles :thumbsup:

 

@RB

The wiki page for GetGlobalValue.

If the other mod is not a dependency though, the Global name will not be selectable in the dropdown boxes. So...

 

You could use Gribbles code above to set a float or int variable in one of the scripts local to your mod.

This will give you a copy of the other mods Global value.

Then you can use either GetQuestVariable or GetScriptVariable to refer to that value in a condition.

[links to those funcs are in the See Also section of GetGlobalValue]

Link to comment
Share on other sites

  • Recently Browsing   0 members

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