physic floating boat

Post » Sun Nov 18, 2012 12:59 pm

How to creat a floating boat with physic (no static)

The possibility for an objet to float is write in nif file or it's making with creation kit?
User avatar
James Baldwin
 
Posts: 3366
Joined: Tue Jun 05, 2007 11:11 am

Post » Sun Nov 18, 2012 11:47 am

I'm sorry but I believe there is no simple answer to this. As far as I know, there is no special button to make something "floatable". I remember one user of these forums mentioned that they were working on a boat mod, but I believe it involved some advanced scripting and math to get it to work

- Hypno
User avatar
Emily Jones
 
Posts: 3425
Joined: Mon Jul 17, 2006 3:33 pm

Post » Sun Nov 18, 2012 10:33 am

Scripting is not the probleme, i already made a boat mod for oblivion using lot of mathematic function and a static boat. With OBSE i had all fucntion nedding for simulation. SKSE is actually poor with new function so i planning using Skyrim physic function tu push the boat in a direction

If i can't get the 3D modele, it's a probleme :(
User avatar
loste juliana
 
Posts: 3417
Joined: Sun Mar 18, 2007 7:37 pm

Post » Sun Nov 18, 2012 3:51 pm

I'd guess it would be impossible to make a floating boat without some heavy-duty scripting and Havok trickery.

It may be possible to create an object that has a havok weight of zero, or less than zero, and could thus be used to create a thruster or perhaps even a zeppelin effect*, but you'd still need some major scripting to move it around in a realistic way, not to mention the fact that moving a platform that anyone other than the player is standing on send them flying off into space.

It IS possible to levitate objects by applying repeated havok impulses to them, but this requires fairly precise timing, which is not a strong point of Papyrus. It works great for doing chaotic movement like picking up actors and spinning them around a vortex, but for moving larger, non-actor meshes in a controlled manner... very, very difficult, probably impossible.

You'd be better off ignoring the physics engine and just using TranslateTo functions.

* I am wildly ignorant on the subject of Havok and this is pure speculation.
User avatar
Kelly John
 
Posts: 3413
Joined: Tue Jun 13, 2006 6:40 am

Post » Sun Nov 18, 2012 4:28 pm

Replacing the horse model with a boat? :cool:
User avatar
bonita mathews
 
Posts: 3405
Joined: Sun Aug 06, 2006 5:04 am

Post » Sun Nov 18, 2012 5:48 am

1: there _is_ a floating boat among the vanilla objects already, misc i think (most definitely, am using it myself in a mod)
2: there is a mod on steam featuring a usable boat, maybe you can look stg up there?
User avatar
Natasha Callaghan
 
Posts: 3523
Joined: Sat Dec 09, 2006 7:44 pm

Post » Sun Nov 18, 2012 2:57 pm

S7o where is located this vanilla boat?

the actual driving boat just attach a boat modele to player and make him running on water
User avatar
mimi_lys
 
Posts: 3514
Joined: Mon Apr 09, 2007 11:17 am

Post » Sun Nov 18, 2012 5:53 am

S7o where is located this vanilla boat?
the name is "ShipRowBoatAnim010000"
correctly animates with the water (if put on some in ck)

edit: hope it was actually a _boat_ you were looking for, not a _ship_ :-)
User avatar
Chrissie Pillinger
 
Posts: 3464
Joined: Fri Jun 16, 2006 3:26 am

Post » Sun Nov 18, 2012 3:46 pm

ShipRowBoatAnim010000 is a static boat, it have no physic
User avatar
Austin Suggs
 
Posts: 3358
Joined: Sun Oct 07, 2007 5:35 pm

Post » Sun Nov 18, 2012 4:37 pm

ShipRowBoatAnim010000 is a static boat, it have no physic
You're never going to get water physics because it doesn't exist in Skyrim. You could possibly bake some animation data to a script, and store the translation and rotation in some faked multidimensional arrays, and walk through those arrays each frame. Unfortunately arrays have a max length of 128 I believe. I doubt a 2 second animation (assuming 60FPS) is long enough. Maybe if you made it a 15FPS animation, 8 seconds would be enough for a bobbing animation. Even then Papyrus may choke and die on it.
User avatar
Marina Leigh
 
Posts: 3339
Joined: Wed Jun 21, 2006 7:59 pm

Post » Sun Nov 18, 2012 5:46 pm

ShipRowBoatAnim010000 is a static boat, it have no physic
well you wanted "animation", not "physics" :-)
anyhow, maybe you can just make it a ol_clutter or something in nifskope (no idea what that'd do the animation though) and assign it a weight etc (or maybe it'd even do to just pick any misc- or movable-static-item with physics similar to what you want and assign them the boat-model instead)
User avatar
Tyrel
 
Posts: 3304
Joined: Tue Oct 30, 2007 4:52 am

Post » Sun Nov 18, 2012 3:13 am

You're never going to get water physics because it doesn't exist in Skyrim. You could possibly bake some animation data to a script, and store the translation and rotation in some faked multidimensional arrays, and walk through those arrays each frame. Unfortunately arrays have a max length of 128 I believe. I doubt a 2 second animation (assuming 60FPS) is long enough. Maybe if you made it a 15FPS animation, 8 seconds would be enough for a bobbing animation. Even then Papyrus may choke and die on it.
???

He is not asking for water physics, he is asking how to make an object that floats in water. There are items that float in the water in Skyrim.
User avatar
Kellymarie Heppell
 
Posts: 3456
Joined: Mon Jul 24, 2006 4:37 am

Post » Sun Nov 18, 2012 12:18 pm

???

He is not asking for water physics, he is asking how to make an object that floats in water. There are items that float in the water in Skyrim.
?????????????!!!!!!!!!!!!!!!!!!!!!!!!1234567890!@#$%^&*()_+

Well, if you read the title, his posts, and any replies you would see that physics is mentioned 12 times (before your post) and Havok is mentioned 4 times. It's called buoyancy, and to simulate a buoyant object you need some kind of "physics". So an "object that floats in water" would indeed need physical simulation on the object and to recognize it is in water. Hence, "water physics". Anyway, enough of dealing with your unnecessary and unhelpful reply / attempt to call me out.



What I learned is that indeed, some Havoked objects do float in water. I've never seen it as none of the objects I've ever dropped float. What that tells me is that Bethesda didn't spend a lot of time on making objects float that should, because if I drop certain objects that I expect to float, they sink like a rock. And certainly no boats in the game are Havoked... they are all completely static.

I found a http://niftools.sourceforge.net/forum/viewtopic.php?f=38&t=3274&start=0 and the person got somewhere with it. I went ahead and attempted myself by leaving the collision the boat already had intact, and adding my own collision that would stay below the boat and not interact with the player or any objects in the boat. The author of that topic had many problems, like the boat damaging the player, or adding a cabbage would sink the boat. The boat would also stop dead in its tracks if it ran into a fish. Anyway, after a lot of messing with the collision settings, I found that I had to up the mass, up the angular damping tremendously, and lower the max angular velocity and linear velocity. Otherwise it was severely unstable and would capsize or react violently to the fish or the player touching the bottom. My attempt so far still reacts to the water current but it moves slowly. In the thread I linked he had to choose between damaging the player or the boat sinking, or not reacting to the current. Since I added my own collision to the root node in NifSkope this isn't an issue.

I may upload a video sometime of my test. Just from my testing though it doesn't seem like it'll ever be stable enough for a mod... When I save the game in the boat and then reload, it'll be in the wrong place. Or if I reload and try to move the boat again the collision will go funky. It seems like I can only place a boat at me once in a new save and then after that the collision goes wonky. It's possible using a different OL_LAYER, Motion System, or Quality Type may provide better results but I don't really know if I'm going to spend more time on it. I also have no idea what would happen with NPCs in the boat. The static boats can have sit activators placed, but I doubt that's possible on a moving boat. Unless of course you can somehow move the activators along with the boat...

Edit: I don't know much about scripting so it's kind of wonky, but I attached a script to the boat that blocks the normal activation (so it doesn't go into my inventory) and instead applies a Havok impulse to the boat. So if I spam the activate key I can make the boat go forward more than what the water current provides. Unfortunately still when you load the savegame and such and you were in the boat, it'll be "sunken" and then rise up out of the water until it decides that it's buoyant, so what I effectively made is a "hoverboat". If I used the ship static I guess I would have an airship, hah. :) Of course there are probably better ways of providing Havok impulses to the boat rather than hitting "E" constantly. But I don't know enough about scripting.
User avatar
Donatus Uwasomba
 
Posts: 3361
Joined: Sun May 27, 2007 7:22 pm

Post » Sun Nov 18, 2012 12:24 pm

?????????????!!!!!!!!!!!!!!!!!!!!!!!!1234567890!@#$%^&*()_+
Spoiler

Well, if you read the title, his posts, and any replies you would see that physics is mentioned 12 times (before your post) and Havok is mentioned 4 times. It's called buoyancy, and to simulate a buoyant object you need some kind of "physics". So an "object that floats in water" would indeed need physical simulation on the object and to recognize it is in water. Hence, "water physics". Anyway, enough of dealing with your unnecessary and unhelpful reply / attempt to call me out.



What I learned is that indeed, some Havoked objects do float in water. I've never seen it as none of the objects I've ever dropped float. What that tells me is that Bethesda didn't spend a lot of time on making objects float that should, because if I drop certain objects that I expect to float, they sink like a rock. And certainly no boats in the game are Havoked... they are all completely static.

I found a http://niftools.sourceforge.net/forum/viewtopic.php?f=38&t=3274&start=0 and the person got somewhere with it. I went ahead and attempted myself by leaving the collision the boat already had intact, and adding my own collision that would stay below the boat and not interact with the player or any objects in the boat. The author of that topic had many problems, like the boat damaging the player, or adding a cabbage would sink the boat. The boat would also stop dead in its tracks if it ran into a fish. Anyway, after a lot of messing with the collision settings, I found that I had to up the mass, up the angular damping tremendously, and lower the max angular velocity and linear velocity. Otherwise it was severely unstable and would capsize or react violently to the fish or the player touching the bottom. My attempt so far still reacts to the water current but it moves slowly. In the thread I linked he had to choose between damaging the player or the boat sinking, or not reacting to the current. Since I added my own collision to the root node in NifSkope this isn't an issue.

I may upload a video sometime of my test. Just from my testing though it doesn't seem like it'll ever be stable enough for a mod... When I save the game in the boat and then reload, it'll be in the wrong place. Or if I reload and try to move the boat again the collision will go funky. It seems like I can only place a boat at me once in a new save and then after that the collision goes wonky. It's possible using a different OL_LAYER, Motion System, or Quality Type may provide better results but I don't really know if I'm going to spend more time on it. I also have no idea what would happen with NPCs in the boat. The static boats can have sit activators placed, but I doubt that's possible on a moving boat. Unless of course you can somehow move the activators along with the boat...

Edit: I don't know much about scripting so it's kind of wonky, but I attached a script to the boat that blocks the normal activation (so it doesn't go into my inventory) and instead applies a Havok impulse to the boat. So if I spam the activate key I can make the boat go forward more than what the water current provides. Unfortunately still when you load the savegame and such and you were in the boat, it'll be "sunken" and then rise up out of the water until it decides that it's buoyant, so what I effectively made is a "hoverboat". If I used the ship static I guess I would have an airship, hah. :smile: Of course there are probably better ways of providing Havok impulses to the boat rather than hitting "E" constantly. But I don't know enough about scripting.

Okay, sorry, "water physics" just makes me think of physics applied to actual water objects, simulating their flow and displacement.

I am also interested in making a working boat though, so do you think you could upload what you've done so far? I've thought of good ways for the player to control it, but the problem I've always had is detecting ground collision.
User avatar
tegan fiamengo
 
Posts: 3455
Joined: Mon Jan 29, 2007 9:53 am

Post » Sun Nov 18, 2012 3:15 pm

adding a cabbage would sink the boat. The boat would also stop dead in its tracks if it ran into a fish.
:-)))
User avatar
Sxc-Mary
 
Posts: 3536
Joined: Wed Aug 23, 2006 12:53 pm


Return to V - Skyrim