Mathematics, and axes that are offset, and scripting pivotti

Post » Mon Dec 05, 2011 11:25 am

I'm not normally one to discard maths but have you tried setting the beam up as a projectile (e.g. a laser), and flagging it as embedded and using the node Camera01 or Head or something? If it works...
E: Yeah, Bip01 Head works in 1st/3rd.


Somebody else out there might know different (I'm hoping they do), but as far as I know objects attached to the camera01 node will not render in 1st person, they have to be attached to an arm node. Also, anything that's a part of the player model seems to render separately from the rest of the game world. Ever notice how your gun never clips through walls? Its rendered separate and overlayed (the 1st person model even has its own field of view setting). That means that if implemented that way, the light beam might look ok from the player's perspective, but it wouldn't illuminate anything (kind of get the feeling I"m repeating myself...)
User avatar
Marnesia Steele
 
Posts: 3398
Joined: Thu Aug 09, 2007 10:11 pm

Post » Mon Dec 05, 2011 3:42 am

That's why you fire a projectile from an unrendered node. It /does/ render.
User avatar
Jessica Phoenix
 
Posts: 3420
Joined: Sat Jun 24, 2006 8:49 am

Post » Mon Dec 05, 2011 5:37 pm

When an object is rotated with setangle, it's rotated around the origin specified in Nifscope. So if you're trying to rotate something around an axis that's offset from its visual center, you can either do trig like you're attempting, or open up the object in nifscope and move its origin (or move its model away from the origin, actually.) Then you just rotate, no trig needed, and its easier on the processor. If you want it to rotate about several different radii, though, you'll need to create multiple versions of the model.



Thanks a lot, I didn't realize you could do that in nifskope, but I figured it out with a little experimenting, not difficult at all really. And it's working great.
User avatar
Charlotte X
 
Posts: 3318
Joined: Thu Dec 07, 2006 2:53 am

Post » Mon Dec 05, 2011 9:35 am

That's why you fire a projectile from an unrendered node. It /does/ render.


Yup, realized I hadn't fully understood your post shortly after I wrote my response. Wonder how well an offset added to the projectile model in nifskope would work - the camera01 node points in the right direction, but it's located at about your adams apple.
User avatar
Bee Baby
 
Posts: 3450
Joined: Sun Jun 18, 2006 4:47 am

Post » Mon Dec 05, 2011 4:35 pm

It's unfortunately not a useful node as it's pointing directly upwards, so if you fire a projectile out it just points towards the ceiling. Head is conveniently closer to the right place, facing forwards, and is present in the 1st and 3rd person skeletons in roughly the same position so you don't have to change the script depending on POV.

Pretty sure you can just add translation in NifSkope?
User avatar
Lance Vannortwick
 
Posts: 3479
Joined: Thu Sep 27, 2007 5:30 pm

Post » Mon Dec 05, 2011 1:19 pm

Pretty sure you can just add translation in NifSkope?


I would think. It might take some trial and error. I experimented with the Camera01 node, and, apart from it being at neck height in 3rd person, it fires in the right direction. What's funny is that it doesn't seem to take player scale into account - I have another mod that sets the player scale to about 5, and if I try to fire something from a head node it comes out of the, er, belly button.
User avatar
YO MAma
 
Posts: 3321
Joined: Thu Dec 21, 2006 8:24 am

Previous

Return to Fallout 3