prideslayer Posted January 2, 2014 Posted January 2, 2014 NVSE looks like it loaded correctly. Check nvse_extender.log as well -- nvse_extender_ng.log is normal, ng in this context means "nogore", which is the German version (and perhaps others?).
prideslayer Posted January 2, 2014 Posted January 2, 2014 Actually nevermind that, it obviously loaded correctly, as you got the function list. RegisterCommand NX_GetVersion (2140) RegisterCommand NX_IsUsingSkeleton (2141) RegisterCommand NX_IsInList (2142) RegisterCommand NX_SetEVFl (2143) RegisterCommand NX_GetEVFl (2144) RegisterCommand NX_SetEVFo (2145) RegisterCommand NX_GetEVFo (2146) RegisterCommand NX_GetConversationPartner (2147) RegisterCommand NX_ClrEVFl (2148) RegisterCommand NX_ClrEVFo (2149) RegisterCommand NX_GetQVEVFl (214A) RegisterCommand NX_SetEVSt (214B) RegisterTypedCommand NX_GetEVSt (214C) RegisterCommand NX_ClrEVSt (214D) RegisterTypedCommand NX_GetEVFlAr (214E) RegisterTypedCommand NX_GetEVFoAr (214F) RegisterTypedCommand NX_GetEVStAr (2150) So there must be a typo in your script in the GECK.
nyaalich Posted January 2, 2014 Posted January 2, 2014 Got the nvse loading into the GECK properly now.Ā Corrected the ref call and compiled it.Ā Now to get it to work... Ā Figured out that the variable should be set similar to this format rActorA.NX_GetEVFo "Sexout:Core:Partners:A" However, is the actual "Sexout:Core:Partners:A" correct, though?Ā My values keep coming up as 0.Ā I wish that I knew how to interpret the string, but I don't.Ā I get that these are objects in the object-oriented sense, but I don't know where to find those values. Ā Observation: Running non-TTW NV, Sexout Sex will allow you to have sex with characters < size 1 but not > size 1.Ā I'm assuming it's from Sexout Sex as that the dialogue options are how I'm testing it out.
prideslayer Posted January 2, 2014 Posted January 2, 2014 You should read this thread if you haven't yet. http://www.loverslab.com/topic/6982-the-sexoutng-api-how-to-for-modders/ Ā That far is correct. If it's 0, you're looking at it either before it's been set, or after it's been cleared. You should only be trying to look at those values in the context of a sexout callback. Ā When are you trying to read it/them?
nyaalich Posted January 3, 2014 Posted January 3, 2014 Ideally, the script would perform the change the moment the animation starts so that when you're in initial 3rd person, you don't see the partner magically grow/shrink.Ā The check was supposed to be based on the char having the SexoutNGTargetToken in inventory.Ā Not that I know exactly when it's added during initialization pre-animation.Ā I think that I read somewhere that there were plans to eventually get away from using the token method. Ā Third thorough read-through is a charm?Ā Except for the whole taking in too much information at once.Ā It's things like "Sexout:Core:Partners" that gets me.Ā I went to SourceForge, grabbed the current files, and looked at the cpp.Ā nvse 4 1 doesn't have source files in it.Ā Is that where I'd find stuff like that?Ā Otherwise, it's trying to decompile dlls, or am I totally wrong? Ā I swear to god that I'm trying.Ā :*| Ā Ā Ā Is the better approach for this mod the following: Ā Create two form lists. Add it to to monitor SexoutNGFLGlobalStart for A, V, O as well as GlobalEnd. Check in the Quest script if the Start list has been populated. Activate the scale change in the script.Ā (Am I missing the purpose of the spell you mentioned in the API post?) Trigger the end/reset the script when the actors appear in the form list that was added to SexoutNGFLGlobalEnd for A, V, or O. Clear both form lists. Ā Thank you for your patience.Ā I'm trying.Ā : \
jaam Posted January 3, 2014 Posted January 3, 2014 NVSE 4.1 sources are available on the Beth forum download for NVSE 4.1 But all NX stuff are part ofĀ the nvse extender. Ā Your todo list seems ok at first glance...
DoctaSax Posted January 3, 2014 Posted January 3, 2014 Is the better approach for this mod the following: Create two form lists. Add it to to monitor SexoutNGFLGlobalStart for A, V, O as well as GlobalEnd. Check in the Quest script if the Start list has been populated. Activate the scale change in the script.Ā (Am I missing the purpose of the spell you mentioned in the API post?) Trigger the end/reset the script when the actors appear in the form list that was added to SexoutNGFLGlobalEnd for A, V, or O. Clear both form lists. Thank you for your patience.Ā I'm trying.Ā : \Ā The start and end hook spells serve as notification for you to do something. You add them to SexoutNGFLGlobalCBStartS & the other one with ListAddForm in a GetGameLoaded/GetGameRestarted block in your quest script. That way you only loop through the formlists that sexout adds the actors to when it's needed, instead of all the time in your quest script. If you stick their previous scale on the actors as an NX float (EVFL), and SetScale them back to that in your end hook spell if you detect that var, that's pretty much all you need. The code I mentioned earlier on is just to detect the involved actors in the start hook spell rightaway, no more. In order to track them it's either formlists or arrays, because copying them to ref vars in your quest script doesn't address the issue that multiple acts may be happening at the same time. The same goes for copying the scale to quest vars.
nyaalich Posted January 4, 2014 Posted January 4, 2014 Admit it:Ā You were sad that you didn't hear from me yesterday. Ā Good News:Ā I officially understand NX variables now thanks to one of your previous posts, DoctaSax.Ā While the API post is greatly informative, I think that you or others should definitely link beginners to http://www.loverslab.com/topic/22270-fnv-scripting-nx-variables/ before that.Ā The strings seemed like mysterious juju before that. Ā FWIW, once I #%*$( finish this, I'll try to compile a thread or post that culls all useful intro to Sexout modding links for beginners.Ā Part of my problem was only searching the Sexout forum for info.Ā The above link was actually in the Fallout 3/NV Tech Support forum.Ā Assumptions, etc.Ā I document stuff for a living, so the instinct is in the blood. Ā Onto the script's progress. Ā I've confirmed that my form lists are populating correctly (iCnt list nth form until empty).Ā However, it seems like the spell/effect is only being cast on Actor B.Ā I thought that you used the specific StartFL V, A, and O form lists instead of the generic begin sex form list because that one ends up only casting the effect on Actor B.Ā Is that also the way that they work?Ā Ā For the base effect, I've got Self and Painless enabled. Ā I put the only running parts of the script in the spoiler. Ā Ā Ā Ā Begin GameMode Set Counter to Counter + 1 if (Counter > 3) if (DoOnce == 0) ;Per Halstrom's advice in another thread, Counter makes ;sure that the script has a second to get everything together. ;Sometimes my Messages would have rZActor show up as <no name>, ;which I *think* always referred to the player. Set rZActor to GetSelf Set fSize to rZActor.getscale MessageBoxEx "rZActor is %n and is scale %.2f" rZActor fSize rZActor.NX_SetEVFL "SexoutCharResize::ActorSize" fSize Set fTest to rZActor.NX_GetEVFL "SexoutCharResize::ActorSize" MessageBoxEx "NX size var set to %.2f" fTest Set DoOnce to 1 Dispel SexoutCharResizeEFFStart ;I don't know if it matters if I Dispel before or after ;DoOnce is set to 1. I figured that it's okay since the if ;statement should finish executing regardless. endif endif end Ā Ā Ā What I'm not doing on purpose in the script right now: Actually changing a char's scale.Ā It was giving some weird results, but I've been in and out of the GECK/Game so much that I don't recall what test case I was using at the time. Emptying the form.Ā I've got it setup and working in commented out code. Ā To try to deal with what seems to be the Actor B only conundrum, I tried this variation, but nothing happens. Ā Ā Ā Set Counter to Counter + 1 if (Counter > 3) if (DoOnce == 0) Set iCnt to ListGetCount SexoutCharResizeStart Label 1 Set rZActor to ListGetNthForm SexoutCharResizeStart iCnt if ((iCnt > -1)&&rZActor) Set fSize to rZActor.getscale MessageBoxEx "rZActor is %n and is scale %.2f" rZActor fSize rZActor.NX_SetEVFL "SexoutCharResize::ActorSize" fSize Set fTest to rZActor.NX_GetEVFL "SexoutCharResize::ActorSize" MessageBoxEx "%n's NX size var set to %.2f" rZActor fTest Set iCnt to iCnt - 1 Goto 1 endif Set DoOnce to 1 Dispel SexoutCharResizeEFFStart endif endif Ā Ā
Halstrom Posted January 4, 2014 Posted January 4, 2014 You may need a space between && and rZActor, not sure you really need the extra bracketing around iCnt > -1 if you don't have it around rZActor too Ā Also your counter is goung to eventually hit the maximum number for an int (35565 or something), not sure if that means it blows up or freezes the scriptĀ Ā %.2f may be a no-no, I'd do %1.2f or maybe %0.2f, stupid little things like that have been known to cause CTD's or script freezes Ā You may find shoving a number into a NX variable, it may need a micro second or 2 time to get there andĀ not be there yet to read it till the next run of the block. I would use a local script variable or make sure there was a fair bit of code in between the write & read. But having said that in this situation I probably should at least show the fsize from the last run. Ā Add DebugPrint "iCnt %1.0f"Ā iCnt in a line just after Label 1 with debugging turned on and see how that goes in the console Ā You turn debugging on by adding SetDebugMode 1 to the top of your main script, it turns debugging on for all scripts in your plugin Ā <No Name> usually means <NULL> which is bad because trying to doĀ things like NULL.SetActorValue Strength 5 etc will probably cause crashing or freezing
nyaalich Posted January 5, 2014 Posted January 5, 2014 From what I can tell, it appears that <No Name> is returned because the form list operations return the BASE id as opposed to the REF id, and the player has no name set for the base form.Ā Conversely, that's why using GetSelf actually returns the player's name. Ā I have searched my little heart out, and I do not see how to get a ref id from a base id (gbo being the exact opposite of what I need).Ā I see tons of places in sexout scripts where the ListGetNthForm is used.Ā What am I missing? Ā The only other thing besides a token system that I can think of is to walk ref the cell and check to see if the base of the reference is in the resize formlist. Ā I realize that this is ludicrously complicated for something that can be accomplished in about 2 seconds in the console, but it became a learning exercise.Ā : P
prideslayer Posted January 5, 2014 Posted January 5, 2014 You can't "get" a ref from a base object. Ā In the object oriented coding world, all apples are an 'Apple', but only one apple is 'ThisApple'. Ā When you have 'ThisApple' (a ref), you can look up it's base type ('Apple'), however, when you have a base type you cannot look up an instance, because there could be an infinite number of them and there's no telling which one you want.
nyaalich Posted January 5, 2014 Posted January 5, 2014 So if the spell is only cast on Actor B, how do I get to cast it on or apply it to other actors if I can only pull base ids from the form lists?Ā Obviously, GetSelf works to ID Actor B.Ā Is this possible outside of a ref walk/token system?
prideslayer Posted January 5, 2014 Posted January 5, 2014 I have not been keeping up on this, I'll have to go back and look, but: Ā 1. Where did you get actorB from in the first place? NX? A callback formlist? 2. Formlists can hold refs, not just base IDs -- this is how the sexout scanner and all the callbacks work. Ā During an act, every actor has an NX 'spelltarget' var that tells you who the SexoutBegin spell was cast on. That actor is always guaranteed to have a full list of the involved actors. Ā So for example, in a callback spell, you would do something like this: int init ref tgt ref actorA ref actorB ref actorC begin ScriptEffectStart if (0 == init) set init to 1 set tgt to NX_GetEVFo "Sexout:Start::spellTarget" if (0 != tgt) set actorA to tgt.NX_GetEVFo "Sexout:Sttart::actorA" set actorB to tgt.NX_GetEVFo "Sexout:Sttart::actorB" set actorC to tgt.NX_GetEVFo "Sexout:Sttart::actorC" if (0 != actorA) // actorA is valid, cast your custom spell on it actorA.cios SomeSpell endif if (0 != actorB) // actorB is valid, cast your custom spell on it actorB.cios SomeSpell endif if (0 != actorC) // actorC is valid, cast your custom spell on it actorC.cios SomeSpell endif endif endif end begin ScriptEffectUpdate if (1 == init) set init to 2 Dispel TheNameOfThisSpell ; Not the name of the spell above, the name of this one! endif end
nyaalich Posted January 9, 2014 Posted January 9, 2014 pride:Ā That template was the missing piece to my understanding.Ā Thank you so much. Ā Status:Ā The mod is doing what it is supposed to do.Ā I can't always get it to trigger reliably, but sometimes when I'm setting the chars to different sizes manually, I get 'sploded. Player or NPC > 1.5:Ā Nope Player 1.3 and NPC .7 = Nope Player .7 and NPC 1.3 = Okay I haven't gone through all of the SO/SCR scripts (it just feels that way), but the only reference to scale that I saw was setting an fscale var for an actor for a default creature animation.Ā Are there Actor size limitations/bans that I just haven't seen yet, or is this Gamebryo making its own decisions? Ā Regarding child body replacers, I did a bit of research into Shojo and CotW, and it appears that their scale is still set at one.Ā Players actually have to set the scale to 1.2 or so to see their character in the race menu.Ā Ā Semi-related (in that it may reduce the amount of questions that I ask):Ā Is there a way to run a search in FNVEdit to look for a variable in a script (i.e., it searches the data in various records, searches the data value string of a script that has the entirety of the script, and returns the record because the fscale var was found in that string)?Ā Hopefully that made sense.Ā I looked at the pdf tutorial, but I didn't see it addressed.
prideslayer Posted January 9, 2014 Posted January 9, 2014 I haven't run into any. Sexout itself does save the current character scale and then scale them to 0.8 in the case of creature sex, but only for sex with bighorners.
prideslayer Posted January 9, 2014 Posted January 9, 2014 As for the search, I'm not sure if fnvedit can do that, but the geck can. What you want to search for though is setScale, not fScale. That's just a variable name (fScaleA, B, C actually) that may change or be different in another script.
Halstrom Posted January 9, 2014 Posted January 9, 2014 I use Setscale in SexoutPregnancy / SexoutOffSpring to grow the childrenĀ and GetBaseObject seems to work well for me for determining the race of the actor in them, might be what you want.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now