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 > Silent Hunter 5
Forget password? Reset here

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 09-24-09, 01:09 PM   #11
haegemon
Medic
 
Join Date: May 2007
Posts: 165
Downloads: 12
Uploads: 0
Default

Don't worry modders will do de job


The feedback...about the interface they can add a parameter to the submarine object, and use as interface a rudder "image" with two levers where people clicks on the levers directly.
And how to compensate de propulsion. They would need a block of program code for every kind of simulation (one or two helix, rotation to the left or to the right).

I'll post it in programmer argot an example of how it could work:

twin_drive = [On=1 /Off=0]
var_lever1 (interface imputs)
var_lever2 (interface imputs)
var_helix1 (propeller)
var_helix2 (propeller)
controller_code1 (for nomal subs impulse)
controller_code2 (for twin helix submarines)


*state variable defaults

var_lever1_visible = 1
var_lever2_visible = 1
var_helix1 = var_lever1
var_helix2 = var_lever2
twin drive = 1
var_controller = controller_code2


[Controller_code1]

more code....
var_helix1 = var_lever1
var_helix2 = var_lever1
var_lever2 = 0


[Controller_code2]

more code....
var_helix1 = var_lever1
var_helix2 = var_lever2
var_lever2 = 1

-----------------

if twin_drive = 1
var_controller = Controller_code2
elseif
var_controller = Controller_code1
elseif
...
...
end if

Programmers will know how it's their engine and why if they can't apply this logic or how to do it.

Last edited by haegemon; 09-25-09 at 11:19 AM.
haegemon is offline   Reply With Quote
 


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 10:33 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.