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 > SH5 Mods Workshop
Forget password? Reset here

Reply
 
Thread Tools Display Modes
Old 02-20-10, 04:18 AM   #1
Nisgeis
Ocean Warrior
 
Join Date: Jan 2008
Posts: 2,909
Downloads: 77
Uploads: 11
Default [REQ] Python Scripting Tutorials / Docs

As it's core to the menu / interface system, it seems like a good idea to see if anyone has any links to any good python scripting sites / tutorials / documentation for those of us, me included, who've not used it before. Thanks!
__________________
--------------------------------
This space left intentionally blank.
Nisgeis is offline   Reply With Quote
Old 02-20-10, 11:31 AM   #2
martes86
Grey Wolf
 
Join Date: Jun 2004
Location: The Colourful Seville - Spain
Posts: 971
Downloads: 18
Uploads: 0
Default

This one would be the first and most logical step: http://docs.python.org/tutorial/

martes86 is offline   Reply With Quote
Old 02-23-10, 02:01 PM   #3
Hawk66
Commodore
 
Join Date: Sep 2006
Location: Germany
Posts: 609
Downloads: 36
Uploads: 0
Default

SH5 is moddable via Python? That's cool...my favorite language although usually I am not so interested in a WWII sim.

Does anybody know if other parts of the sim are also moddable via Python? For example the AI?
Hawk66 is offline   Reply With Quote
Old 02-23-10, 02:03 PM   #4
piri_reis
Seasoned Skipper
 
Join Date: Aug 2005
Location: Istanbul, Turkiye
Posts: 715
Downloads: 115
Uploads: 0
Default

Quote:
Originally Posted by Hawk66 View Post
Does anybody know if other parts of the sim are also moddable via Python? For example the AI?
The devs have said many aspects of the game including the AI is moddable.
__________________

Lt.z.S. Barbaros Hayreddin, U-35, 2nd Flot/Kiel, Type VIIB
Oct.29.1939, 2nd Patrol Eastern English Waters
Running SH5/TWOS
piri_reis is offline   Reply With Quote
Old 02-23-10, 02:11 PM   #5
Nisgeis
Ocean Warrior
 
Join Date: Jan 2008
Posts: 2,909
Downloads: 77
Uploads: 11
Default

Quote:
Originally Posted by piri_reis View Post
The devs have said many aspects of the game including the AI is moddable.
Cool, might be time to dust off my degree.

Thanks for the link Martes!
__________________
--------------------------------
This space left intentionally blank.
Nisgeis is offline   Reply With Quote
Old 02-23-10, 06:42 PM   #6
martes86
Grey Wolf
 
Join Date: Jun 2004
Location: The Colourful Seville - Spain
Posts: 971
Downloads: 18
Uploads: 0
Default

Quote:
Originally Posted by piri_reis View Post
The devs have said many aspects of the game including the AI is moddable.
The UI is the main thing I know for sure was moddable already in the preview version for Copenhaguen. I also had a glance at some other stuff, like waypoint info, animations info, and I think AI too. Not sure if those will be moddable via Python as well, or with any other methods (those said "modding tools" to add to the mission editor come to mind).
If we had been allowed to take pics/videos, I'd be able to show you exactly what there was (I had a mini tripod with the camera for static recording) because the devs opened some folders, even a Python source file, but taking notes was the closest I could get, and it was damn fast so to not forget anything hehe.

Cheers

EDIT: Didn't realize Longam's post (too late in the night, I see blurry already lol), sorry for the repeated info.
martes86 is offline   Reply With Quote
Old 02-25-10, 04:19 PM   #7
jazman
Commander
 
Join Date: Jul 2007
Location: Crush Depth
Posts: 449
Downloads: 50
Uploads: 0
Default

Freezing out us Perl geeks....
__________________
"The true soldier fights not because he hates what is in front of him, but because he loves what is behind him."
-- Chesterton
jazman is offline   Reply With Quote
Old 02-23-10, 06:32 PM   #8
longam
Admiral
 
Join Date: Jun 2005
Posts: 2,014
Downloads: 26
Uploads: 0
Default

Quote:
Originally Posted by Hawk66 View Post
SH5 is moddable via Python? That's cool...my favorite language although usually I am not so interested in a WWII sim.

Does anybody know if other parts of the sim are also moddable via Python? For example the AI?
One of the things I remember was the replacing of the ini files with this. I hope it solves many problems with over writing the file with other mod ini files.

Quote:
IMPORTANT

I think this is the first time that this is being mentioned (anywhere): big parts of the interface are being scripted, so there will be some quality modding on the interface (the kind of quality that can be seen in World of Warcraft mods).

The syntax being used is the one from Python.
The script will access the game through a SDK. Also, the scripted code can access the whole of .Net Framework classes (though it's not that necessary).
The editing of the scripts is done inside a special window, that allows the editing of the scripts while the game is running (edit & continue) with text auto-complete and jumping to function definitions, the inspection of the game variables in real time (through a property grid) and the complete description of all the exported classes (inheritance, properties, methods, events, inner types (enums, other classes)). Please note that not ALL game classes have been exported to the scripts.
Also, please note that not ALL the interface has been scripted, due to game (and time) limitations.

But the road has been opened for you to unleash your imagination and talent.

And, as always, there is the Mission Editor for single missions and dynamic campaigns.

At last, but not least, the way the AI thinks has been scripted and is being stored in text files (in a custom format). So that has also been opened for modding.
http://www.subsim.com/radioroom/show...ghlight=python
longam 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 08:20 PM.


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.