SUBSIM Radio Room Forums



SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997

Go Back   SUBSIM Radio Room Forums > Silent Hunter 3 - 4 - 5 > SH4 Mods Workshop
Forget password? Reset here

Reply
 
Thread Tools Display Modes
Old 09-05-10, 06:34 AM   #1
keltos01
Silent Hunter
 
Join Date: Feb 2008
Location: Milan Italy
Posts: 4,999
Downloads: 114
Uploads: 18
Default [needed] how do you make an AI submarine ?

I'd like to add a sub as an AI one, so as not to be so lonely outthere, does anyone know how ?

keltos
__________________
"Honorable Builder of Sinking Ships"

keltos01 is offline   Reply With Quote
Old 09-05-10, 06:46 AM   #2
Hitman
Pacific Aces Dev Team
 
Hitman's Avatar
 
Join Date: Sep 2002
Location: Spain
Posts: 6,109
Downloads: 109
Uploads: 2


Default

IIRC it's the same process as for creating any other AI ship, you are in fact creating a DD with the looks and armament of a submarine (Except the torpedoes). Clone a DD, modify all IDs and use the submarine model.
__________________
One day I will return to sea ...
Hitman is offline   Reply With Quote
Old 09-05-10, 08:18 AM   #3
keltos01
Silent Hunter
 
Join Date: Feb 2008
Location: Milan Italy
Posts: 4,999
Downloads: 114
Uploads: 18
Default

never done that before !
__________________
"Honorable Builder of Sinking Ships"

keltos01 is offline   Reply With Quote
Old 09-05-10, 08:45 AM   #4
Hitman
Pacific Aces Dev Team
 
Hitman's Avatar
 
Join Date: Sep 2002
Location: Spain
Posts: 6,109
Downloads: 109
Uploads: 2


Default

AFAIK it's done the same as what you did to clone the cachalot from the Perch, but with an AI unit.

EDIT:

Are you really keltos?

Who are you?

And what did you do with his body?

I should call the police!


j/j .....
__________________
One day I will return to sea ...
Hitman is offline   Reply With Quote
Old 09-05-10, 09:22 AM   #5
tater
Navy Seal
 
Join Date: Mar 2007
Location: New Mexico, USA
Posts: 9,023
Downloads: 8
Uploads: 2
Default

Can't you just place any sub in the mission editor, and not check the "player sub" box?

That's what you'd do to place subs in port, for example.
tater is offline   Reply With Quote
Old 09-05-10, 10:34 AM   #6
keltos01
Silent Hunter
 
Join Date: Feb 2008
Location: Milan Italy
Posts: 4,999
Downloads: 114
Uploads: 18
Default

Quote:
Originally Posted by Hitman View Post
AFAIK it's done the same as what you did to clone the cachalot from the Perch, but with an AI unit.
done
EDIT:

Are you really keltos?
yes
Who are you?
keltos
And what did you do with his body?
deep sixed it why ?
I should call the police!
you have no proof

j/j .....
ok that's done, it's now AI_L55, now to try if it works in a singlemission..

Thanks to Lou and Dagon for letting me use it

Keltos
__________________
"Honorable Builder of Sinking Ships"

keltos01 is offline   Reply With Quote
Old 09-05-10, 12:26 PM   #7
peabody
Admiral
 
Join Date: Jan 2008
Location: New York State, USA
Posts: 2,390
Downloads: 126
Uploads: 7
Default

Quote:
Originally Posted by keltos01 View Post
ok that's done, it's now AI_L55, now to try if it works in a singlemission..

Thanks to Lou and Dagon for letting me use it

Keltos
You can do it Hitman's way but there is a much easier way to do it. I am assuming you are starting with a 'playable' sub? (actually it does not need to be a playable sub, the process is the same)

Clone the sub, same as you would any other sub, then in the .sim file make it a ship. It will follow waypoints and shoot guns at you. But to put men on deck the normal "DeckWatch" crew will not work. As you will note in the Sea folder, ships don't have upc/upcge files. So you would put P01 nodes (I think, it has been a while) to place men on it.

If you do as Hitman suggests it will work, but you have to deal with changing all the guns, men, 3D model for rudders and propellers etc, the 3D damage won't be right etc. It is just much harder to do.

Tater's way you can use it as eye candy in a port, but it won't go anywhere and will not shoot at you. So it depends what you want to do with it. In fact Tater's way you don't have to clone it since it will not conflict with another sub of the same kind. If you put one in with a speed it will move a short distance, but if you check, you will find the propellers are not turning, so it will eventually come to a stop.

So as I stated it depends what you want it for.

Peabody
__________________

System Spec: Gigabyte GA-965P-DS3, PentiumD Dual Core Presler 945 3.4Ghz, Gigabyte Geforce 7600GS, 2-1GB Corsair XMS2 800Mhz in Dual Channel, 2-WD 250 SATA 3Gb/s, Onboard Realtek HD 7.1 Audio, DVD ROM, DVD burner, Hiper 580 Watt Power supply, WinXP SP2.

peabody is offline   Reply With Quote
Old 09-06-10, 08:35 PM   #8
Madox58
Stowaway
 
Posts: n/a
Downloads:
Uploads:
Default

I'll agree to all the above except you don't need to name the nodes P0x
Any name for a node will do.
They are after all just placement nodes and care less about what you call them.
They are only used in the manor they are to make things easy to follow
when working on stuff at build time.

And to make another thing very clear?
AI Subs done as Ships in the sim file can be made to dive!
I never finished the final work on this as GWX priorities at that time,
demanded I put that work aside.

I am back into that work for several reasons now.
  Reply With Quote
Old 09-06-10, 08:45 PM   #9
rein1705
Samurai Navy
 
Join Date: Mar 2010
Location: somewhere in the Past.
Posts: 582
Downloads: 541
Uploads: 0
Default

all you smart people talking your smartness.... but i'll add that i would love to have a companion sub that might follow and work with you or accept recon orders or.... give you fuel and stores while on long missions would be great!
__________________

"Diesel Pig"

Not so long ago...
rein1705 is offline   Reply With Quote
Old 09-06-10, 08:47 PM   #10
peabody
Admiral
 
Join Date: Jan 2008
Location: New York State, USA
Posts: 2,390
Downloads: 126
Uploads: 7
Default

Quote:
Originally Posted by privateer View Post
I'll agree to all the above except you don't need to name the nodes P0x
Any name for a node will do.

I agree, just that is was easier to explain what I meant since they know what a "normal" P01 node is on a ship.

And I will be the first to admit you know 1.000 times more about this than I do.....Someday I will tell you something you don't know......I just don't feel like doing it today.

Peabody
__________________

System Spec: Gigabyte GA-965P-DS3, PentiumD Dual Core Presler 945 3.4Ghz, Gigabyte Geforce 7600GS, 2-1GB Corsair XMS2 800Mhz in Dual Channel, 2-WD 250 SATA 3Gb/s, Onboard Realtek HD 7.1 Audio, DVD ROM, DVD burner, Hiper 580 Watt Power supply, WinXP SP2.

peabody is offline   Reply With Quote
Old 09-06-10, 09:54 PM   #11
tater
Navy Seal
 
Join Date: Mar 2007
Location: New Mexico, USA
Posts: 9,023
Downloads: 8
Uploads: 2
Default

Some of the nodes do seem to have specific, hard-coded functions. The K node, for example. Changing them is trivial inS3d so why not make it consistent
tater is offline   Reply With Quote
Old 09-07-10, 03:22 PM   #12
Ducimus
Rear Admiral
 
Ducimus's Avatar
 
Join Date: May 2005
Posts: 12,987
Downloads: 67
Uploads: 2


Default

Skimmed through the thread, sounds like other have pretty much covered it. Though i'll add:

- It is VITAL that the AI subs do not use ANY of the same sensory nodes, equipment, etc that the player uses. AT ALL, EVER. Not even a TAR node. (you'll know this happen if you notice all the dial needles stuck in the 12 O'clock position in the interior. Possibly super large file sizes for save games too, like 500 MB saves)

- You'll need to redo damage zones so they sink correctly. Admittidly, i cheesed, and just changed one zone into a BB keel zone and ran it the length of the boat. Does the job, but certainly not elegant.
Ducimus is offline   Reply With Quote
Old 09-08-10, 08:45 AM   #13
keltos01
Silent Hunter
 
Join Date: Feb 2008
Location: Milan Italy
Posts: 4,999
Downloads: 114
Uploads: 18
Default

Quote:
Originally Posted by privateer View Post

And to make another thing very clear?
AI Subs done as Ships in the sim file can be made to dive!
How ??? pm me if you don't want this public knowledge

keltos
__________________
"Honorable Builder of Sinking Ships"

keltos01 is offline   Reply With Quote
Old 09-08-10, 01:48 PM   #14
peabody
Admiral
 
Join Date: Jan 2008
Location: New York State, USA
Posts: 2,390
Downloads: 126
Uploads: 7
Default

Quote:
Originally Posted by Ducimus View Post
Skimmed through the thread, sounds like other have pretty much covered it. Though i'll add:

- It is VITAL that the AI subs do not use ANY of the same sensory nodes, equipment, etc that the player uses. AT ALL, EVER. Not even a TAR node. (you'll know this happen if you notice all the dial needles stuck in the 12 O'clock position in the interior. Possibly super large file sizes for save games too, like 500 MB saves)

- You'll need to redo damage zones so they sink correctly. Admittidly, i cheesed, and just changed one zone into a BB keel zone and ran it the length of the boat. Does the job, but certainly not elegant.
I did play with the zones on the two I made. They were sinking like helium balloons. And a minimum of two torpedoes to sink them. So that part I do understand.

I did NOT know about the sensory nodes, equipment etc. Now mine were the Porpoise and the Tambor, and Keltos used German subs to create the IJN subs. Do you know if this will encounter the same problems? I am not asking you to test it, only if you know the answer. I didn't notice any problems with dial in the sub not working. Possibly because we are using German "equipment" ??? I will check the file sized the next time I have them loaded in the game.
The other question is you say the "same Sensory nodes", does that mean we have to rename the node. for example change the H01 to F01 or we have to actually remove the Hydrophones from the sub, and use 'ship' equipment instead of 'sub' equipment?
There is so much I need to learn, thank you for the information. I NEVER would have figured that one out.
In fact if you are busy (you are always busy!!!) I can check your AI sub in TMO and see what you did and maybe figure out at least some of it.

Thanks again for the information.

Peabody
__________________

System Spec: Gigabyte GA-965P-DS3, PentiumD Dual Core Presler 945 3.4Ghz, Gigabyte Geforce 7600GS, 2-1GB Corsair XMS2 800Mhz in Dual Channel, 2-WD 250 SATA 3Gb/s, Onboard Realtek HD 7.1 Audio, DVD ROM, DVD burner, Hiper 580 Watt Power supply, WinXP SP2.

peabody is offline   Reply With Quote
Old 09-08-10, 03:10 PM   #15
Ducimus
Rear Admiral
 
Ducimus's Avatar
 
Join Date: May 2005
Posts: 12,987
Downloads: 67
Uploads: 2


Default

Quote:
Originally Posted by keltos01 View Post
How ??? pm me if you don't want this public knowledge

keltos
I know you can make a submerged and surfaced version of the same submarine. Just set its draft to run below the surface. (sim and/or cfg file tweaks, i forget). You can also make "fake" torpeo's too. Clone a new gun, make it invisible. Take the node for this gun mount on the parent object and offset it so its above the surface. Tweak the gun's rotation and reload specs, and there you go. Someone thought this up way back in the day in SH3, i forget who. Anywho I should probably get off my lazy as and do this at some point.

Quote:
Originally Posted by peabody View Post
I did NOT know about the sensory nodes, equipment etc. Now mine were the Porpoise and the Tambor, and Keltos used German subs to create the IJN subs. Do you know if this will encounter the same problems?
The problem comes when the game has to instantiate two player objects at the same time. (parent or child objects). If your using it, and the game has to start a new instance of it while it's in use, the game gets confused i guess. Now mind you, the game has to start the instance for the error to occur. Just having it in the campaign files isnt enough.

You can totally clone the player object in every detail, but the game won't have a tizzy, UNTIL IT TRIES TO RENDER IT. (usually within 30 KM or so.). Which makes tracking down this error really hard. Sometimes there was an AI sub around and you didn't know it. Lucky for you, others have already done hours of this: ( ) so you don't have to.

Quote:
The other question is you say the "same Sensory nodes", does that mean we have to rename the node.
No, I meant if its an AI object, you should use AI sensors. If your watch crew is using something like "crewWatchVisual" and the AI is using "AI_visual", then use "AI_Visual". Same for radar and hydrophones, etc.

edit: Some nodes are player specific and never used by the AI. TAR node for example. I mention this specifically because it was giving me issues. I let this one node slip by not realizing the game was trying to insantiate two instances of this player specific node. (its for submarine coatings)
Ducimus is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 11:21 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 1995- 2025 Subsim®
"Subsim" is a registered trademark, all rights reserved.