Jump to content

[Modder's Resource] Spawnable Triggerboxes


ThreeTen

Recommended Posts

Yep, I know where your coming from, basically it's like that with anything to do with skyrim modding, CK, Scripting, nif etc in general.

 

By the time you explain it it's like you could have just done it in a 20th of the time.

 

Nif I'm pretty clueless with, some basic stuff I find easy, but anything to do with more then a simple static, marker etc, then I'm in the dummy category.

 

When i get the urge, I'll sit down and work out what I'm after and i don't usually need to ask questions to work things out (most the time anyway).

just read documentation text (no video bs), experiment untile i understand what I'm after, is most of how i work things out in general.

 

On topic for op:

Here's my test 128x128 template, I used the vanilla \Meshes\Traps\TriggerBox256x128.nif

Scaled it in NifSkope and updated it's radius and collision.

 

It's actually 1Kb smaller in file size then your 14x14 version.

I gather it must be some extraneous data in your nif as I saw some of your data is different to the vanilla game version.

(flags and some byte arrays, I have no idea what they are for, left well enough alone.)

 

It spawns and scales bigger fine via script (obviously only scales on all axis, not on individual axis).

I didn't test if it scales smaller though.. but meh

 

Edited by sLoPpYdOtBiGhOlE
Link to comment
Share on other sites

The units in nifscope are the exact units used in skyrim, :tongue:

 

Also, you can add a nicontroller manager with specific animations to upscale the box or re-size it to as many set dimensions as you want, that would be more useful methinks as a resource than re-sizing it yourself :tongue:

 

Just need a nicontrollermanager blah blah then you can name w/e you want and call a gamebryo animation on it as it spawns etc to set the size. Could literally just do a shitton, make normal box a 100 unit square and could go from there, could even add different meshes and collision inside the node, IE you could have all of them set to 0 and call a animation that expands the circle, or rectangle or square, then one of each scaling it up.

 

Just some thoughts, it's usable as is but a dynamic nif could be cool :smile:

Why don't you talk like this all the time? s#*!, even I can follow this speak...:armscrossed: ;)

Link to comment
Share on other sites

 

On topic for op:

Here's my test 128x128 template, I used the vanilla \Meshes\Traps\TriggerBox256x128.nif

Scaled it in NifSkope and updated it's radius and collision.

 

It's actually 1Kb smaller in file size then your 14x14 version.

I gather it must be some extraneous data in your nif as I saw some of your data is different to the vanilla game version.

(flags and some byte arrays, I have no idea what they are for, left well enough alone.)

 

It spawns and scales bigger fine via script (obviously only scales on all axis, not on individual axis).

I didn't test if it scales smaller though.. but meh

http://forums.nexusmods.com/public/style_images/underground/attachicon.gifTriggerBox_Template_128x128.zip

 

Thanks for this, Ill add it to the resource page As for it being smaller, I sort of did the edison route, where I just searched through all of the activators which bethesda made and had OnTrigger events inside of their scripts. Then I saw if a triggerbox itself was made through CK or not. (turns out there is only one nif in the entire game which has a triggerbox embedded into the nif file itself) and copied over the relevant branches. Chances are I probably copied over some extra info which wasn't needed.

Link to comment
Share on other sites

I just looked in the object window -> WorldObjects -> Activator using the filter word "trigger"

 

Then I looked down the list at the file column, you see most the normal triggers that don't use a model but there's probably a dozen or so that do use a model.

From there just opened a nif in nifskope.

 

Didn't need to copy and paste any sections or merge multiple nif sections into a new nif at all.

 

That's the way I found what nifs were flagged with bhk phantom.

It was your original nif that allowed me to know what I was looking for :smile:

 

OL_UNKNOWN1 also sends trigger events (basically i tested nearly every OL_xxxx in the enumerated list seeing what works for other layers with that type of collision).

 

Damn I wish there was an OL_NAVCUT that could be set in a nif, now that would rock hardcore.

But there's not :sad:

Edited by sLoPpYdOtBiGhOlE
Link to comment
Share on other sites

I think I am getting the idea of nicontrolmanager. Its just technically a bunch of "checkpoints" in an animation timeline that can be linked to a keyword. Call the keyword -> goto that place in the animation timeline.

 

So if your animation is quite literally scaling a box up from being X size to Y size over Z amount of keyframes, you can then name each keyframe and call a "goto keyframe name" to get the size you want. That makes sense.

the question now becomes, can those "checkpoints" which you call be nicontroller specific. Say you have a nicontroller which only scales the X value of an object, and another nicontroller which only scales the Y value of an object. Can you set the checkpoint for each nicontroller independently through calling two specific keywords? or can you only make a checkpoint of an objects overall state in its animation.

 

(im probably botching the names up, but I think you get the idea)

Link to comment
Share on other sites

I just looked in the object window -> WorldObjects -> Activator using the filter word "trigger"

 

Then I looked down the list at the file column, you see most the normal triggers that don't use a model but there's probably a dozen or so that do use a model.

 

Nice! well i'm glad there is more than one. I remember doing something similar, but I encountered some with the name trigger that actually weren't true triggerboxes when looking at the attached script so I ended up not trusting that.

 

Instead I went about it by making an xedit script which parses through all of the activators with a model and their attached scripts.

For each attached script, it took a look inside of the actual .psc file for a matching OnTriggerEnter() string.

If found, the script then looks at all of the references which use that activator and checks if a primitive was attached to it.

If there was a primitive then a Triggerbox was made in CK. If not, then the triggerbox must come from the nif itself.

Link to comment
Share on other sites

  • Recently Browsing   0 members

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