Prepare for the lags then. Couple this with the HawaiitoSoCal map and meet Gaben, because the earthquakes and the lags will make you want to axe your comp in two.TB1 wrote:I feel a HAVA painted version of this plane should be done, it looks INCREDIBLE.
Decaff's Garage
- Shiny Rice
- 57th Polyvalent Sq
- Posts: 1389
- Joined: Wed Apr 27, 2011 3:28 pm
- Favorite Aircraft: Su-35
- Has thanked: 28 times
- Been thanked: 42 times
Re: Decaff's Garage
"We rip those clouds apart so you can see the sun!"
Now 100% more decomissioned!
- Gunny
- Business Class Membership
- Posts: 3231
- Joined: Sun Feb 06, 2011 6:17 pm
- Favorite Aircraft: Any thing with a prop.
- Location: New Iberia.LA.
- OS: Windows XP SP3
- Has thanked: 577 times
- Been thanked: 754 times
Re: Decaff's Garage


- tigershark
- Modding Team
- Posts: 1445
- Joined: Mon Feb 14, 2011 10:07 pm
- Favorite Aircraft: uk & germany fighter
- Location: gateshead/newcastle
- Has thanked: 213 times
- Been thanked: 568 times
- Contact:
Re: Decaff's Garage
-
- Senior Veteran
- Posts: 1848
- Joined: Tue Feb 07, 2012 10:00 am
- Favorite Aircraft: .
- OS: windoze 10 64-bit
- Has thanked: 566 times
- Been thanked: 614 times
- decaff_42
- Staff
- Posts: 3644
- Joined: Sat Oct 29, 2011 7:23 pm
- Favorite Aircraft: SR-71 Blackbird
- Location: Eastern United States
- OS: Mac OSX
- Has thanked: 713 times
- Been thanked: 1481 times
- Contact:
Re: Decaff's Garage
I'm probably going to to go in and reduce the vertices and the some of the 3D things. Still have to add in all the lighting properties, but that shouldn't take too long. I hope to get the file size to 1.5 mb which was about the 727 file size.



I have the dat file mostly done, so woo for that.

I also have the coarse model done!

With all my schoolwork done, I can get some more modeling and tutorialing in. Looking forward to completing more on the 727. I tried to get a test flight in, but it couldn't find the aircraft when I searched for it. The IDENTIFY line has way less than 32 characters, and the air.lst loaded up just fine...*sigh* I guess I'll have to try to find out what went wrong...
Visit by Bitbucket page for Python codes: https://bitbucket.org/decaff42/
Server Flight Log
Addon Database Submit Addon To Database
-
- Senior Veteran
- Posts: 1848
- Joined: Tue Feb 07, 2012 10:00 am
- Favorite Aircraft: .
- OS: windoze 10 64-bit
- Has thanked: 566 times
- Been thanked: 614 times
Re: Decaff's Garage

As for YS not loading the plane, have you added a collision file? Without one, YS will simply ignore the files and not load the aircraft.
- TB1
- Veteran
- Posts: 868
- Joined: Fri Feb 18, 2011 11:51 am
- Favorite Aircraft: 202 SQ RAF Sea King
- Location: VATSIM.
- Has thanked: 19 times
- Been thanked: 16 times
- Contact:
Re: Decaff's Garage
As am I, that cockpit looks HOT.Dan wrote:Really good job Decaff, looking forward to seeing this when completed.

- Gunny
- Business Class Membership
- Posts: 3231
- Joined: Sun Feb 06, 2011 6:17 pm
- Favorite Aircraft: Any thing with a prop.
- Location: New Iberia.LA.
- OS: Windows XP SP3
- Has thanked: 577 times
- Been thanked: 754 times
Re: Decaff's Garage

- decaff_42
- Staff
- Posts: 3644
- Joined: Sat Oct 29, 2011 7:23 pm
- Favorite Aircraft: SR-71 Blackbird
- Location: Eastern United States
- OS: Mac OSX
- Has thanked: 713 times
- Been thanked: 1481 times
- Contact:
Re: Decaff's Garage
Her foot is, going thru the base of the instrument panels, but not the outer wall of the cockpit, which is nearly the outer surface. Thanks for the notice though!Gunny wrote:Decaff you might want to move the seat and engineer back a couple of notches.It looks like her foot might be protruding though the bulkhead.

Visit by Bitbucket page for Python codes: https://bitbucket.org/decaff42/
Server Flight Log
Addon Database Submit Addon To Database
- flyingfisch
- Contributor
- Posts: 167
- Joined: Wed Aug 29, 2012 10:50 pm
- Favorite Aircraft: Saab Gripen
- Has thanked: 1 time
- Been thanked: 5 times
- Contact:
-
- Modding Team
- Posts: 1085
- Joined: Fri Dec 16, 2011 12:42 am
- Favorite Aircraft: McDonnell Douglas
- Has thanked: 1319 times
- Been thanked: 514 times
Re: Decaff's Garage

- ForeverYMonster
- Contributor
- Posts: 240
- Joined: Tue Dec 03, 2013 5:39 pm
- Favorite Aircraft: Su-35/Su-37
- Has thanked: 4 times
- Been thanked: 7 times
- decaff_42
- Staff
- Posts: 3644
- Joined: Sat Oct 29, 2011 7:23 pm
- Favorite Aircraft: SR-71 Blackbird
- Location: Eastern United States
- OS: Mac OSX
- Has thanked: 713 times
- Been thanked: 1481 times
- Contact:
Re: Decaff's Garage
Not for a while. There is soo much left to do.ReverseFate wrote:So how soon would you think it would be released
I was planning on FedEx, DHL, PAVA, HAVA Lufthansa, AA. there will probably be more as I go on. I still need to finish the blank up and test it thuroghly. Then I can start painting.flyingfisch wrote:What liveries are you planning on releasing this with? AA?
Visit by Bitbucket page for Python codes: https://bitbucket.org/decaff42/
Server Flight Log
Addon Database Submit Addon To Database
- ForeverYMonster
- Contributor
- Posts: 240
- Joined: Tue Dec 03, 2013 5:39 pm
- Favorite Aircraft: Su-35/Su-37
- Has thanked: 4 times
- Been thanked: 7 times
Re: Decaff's Garage

- decaff_42
- Staff
- Posts: 3644
- Joined: Sat Oct 29, 2011 7:23 pm
- Favorite Aircraft: SR-71 Blackbird
- Location: Eastern United States
- OS: Mac OSX
- Has thanked: 713 times
- Been thanked: 1481 times
- Contact:
Re: Decaff's Garage

I've been putting some work into my Excel DAT File maker. Here's the code so far. It only writes 50 lines of the DAT file, but I've got a good framework going which is helping it go a little faster now that I've written several of the for-loops.
I've got approximately 560 lines of code here.
Code: Select all
'This Script will compile a fully functional DAT file from the inputs provided throughout the excel file.
'First it will check to make sure that all the pages are filled correctly.
'Then it will begin to compile the dat file and paste it into
Public row As Integer 'This variable is the row that strings will be pasted into for the DAT File
Public Sheet2 As String
Sub CallInOrder()
Sheet2 = "Test"
Call CheckAllSheetsAreDone
Call DatFileHeaderBuild
Call FuelAndWeightBuild
Call F1Viewpoints
Call InstumentPanel
Call LandingGear
Call Arrester
Call MachineGuns
Call SmokeGen
Call Vapor
Call Strength
Call Critical1
End Sub
Sub CheckAllSheetsAreDone()
'This macro checks to see if all the sheets are complete.
'Dat File header sheet
If Sheets("Dat File Header").Range("J12").Value = "NO" Then
MsgBox ("Dat File Header Section not checked off.")
Exit Sub
End If
'Fuel & weight Sheet
If Sheets("Fuel and Weights").Range("J12").Value = "NO" Then
MsgBox ("Fuel and Weights Section not checked off.")
Exit Sub
End If
'F1 Viewpoints Sheet
If Sheets("F1 Viewpoints").Range("J12").Value = "NO" Then
MsgBox ("F1 Viewpoints Section not checked off.")
Exit Sub
End If
'Landing Gear Sheet
If Sheets("Landing Gear").Range("J12").Value = "NO" Then
MsgBox ("Landing Gear Section not checked off.")
Exit Sub
End If
'Landing Gear Sheet
If Sheets("Smoke Generation").Range("J12").Value = "NO" Then
MsgBox ("Smoke Generation Section not checked off.")
Exit Sub
End If
'Variable Geometry Wings Sheet
If Sheets("Variable Geometry Wings").Range("J12").Value = "NO" Then
MsgBox ("Variable Geometry Wings Section not checked off.")
Exit Sub
End If
'Custom Instrument Panel Wings Sheet
If Sheets("Custom Instrument Panel").Range("J12").Value = "NO" Then
MsgBox ("Custom Instrument Panel Section not checked off.")
Exit Sub
End If
'Brake Parameters Sheet
If Sheets("Brake Parameters").Range("J12").Value = "NO" Then
MsgBox ("Brake Parameters Panel Section not checked off.")
Exit Sub
End If
'Strength Parameters Sheet
If Sheets("Strength").Range("J12").Value = "NO" Then
MsgBox ("Strength Parameters Panel Section not checked off.")
Exit Sub
End If
'Machine Guns
If Sheets("Machine Guns").Range("J12").Value = "NO" Then
MsgBox ("Machine Guns Panel Section not checked off.")
Exit Sub
End If
'Put the rest of the sheets here as they become available
End Sub
Sub DatFileHeaderBuild()
'This Macro will build the Dat File Header Page's Dat parameters.
'It assumes that any cells that are left blank means that parameter is supposed to be blank.
Dim Sheet1 As String
Dim Num As Integer
Dim i As Integer
Sheet1 = "Dat File Header"
Sheets(Sheet2).Range("A1:B100").Clear
Num = WorksheetFunction.CountA(Sheets(Sheet1).Range("C11:C15"))
For i = 1 To Num
row = i
Sheets(Sheet2).Cells(row, 1).Value = "REM" & " " & Sheets(Sheet1).Cells(10 + i, 3).Value
Next
row = row + 2
Sheets(Sheet2).Cells(row, 1).Value = "IDENTIFY" & " " & Sheets(Sheet1).Range("C22").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "SUBSTNAM" & " " & Sheets(Sheet1).Range("C31").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CATEGORY" & " " & Sheets(Sheet1).Range("C38").Value
row = row + 1
If Sheets(Sheet1).Range("C44").Value = "" Then
row = row
Else: Sheets(Sheet2).Cells(row, 1).Value = "AIRCLASS" & " " & Sheets(Sheet1).Range("C44").Value
End If
row = row + 2
Sheets("Test").Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub FuelAndWeightBuild()
'This macro builds the Fuel and Weight section after the Dat file Header section
Dim Sheet1 As String
Sheet1 = "Fuel And Weights"
row = Sheets(Sheet2).Range("B1").Value
Sheets(Sheet2).Cells(row, 1).Value = "AFTBURNR" & " " & UCase(Sheets(Sheet1).Range("C11").Value)
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
If Sheets(Sheet1).Range("F11").Value = "NO" Then
Call JetThrust
Else: Call PropThrust
End If
'Weights
Sheets(Sheet2).Cells(row, 1).Value = "WEIGHCLN" & " " & Sheets(Sheet1).Range("C38").Value & Sheets(Sheet1).Range("G38").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "WEIGFUEL" & " " & Sheets(Sheet1).Range("C39").Value & Sheets(Sheet1).Range("G39").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "WEIGLOAD" & " " & Sheets(Sheet1).Range("C40").Value & Sheets(Sheet1).Range("G40").Value
row = row + 1
If Sheets(Sheet1).Range("F11").Value = "NO" Then
Call JetFuel
Else: Call PropFuel
End If
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub F1Viewpoints()
'This macro will write the F1 Viewpoints into the DAT file
Dim Sheet1 As String
Dim Num As Integer
Dim rowtarget As Integer
Dim i As Integer
Sheet1 = "F1 Viewpoints"
'Pilot's Viewpoint
Sheets(Sheet2).Cells(row, 1).Value = "COCKPITP" & " " & Sheets(Sheet1).Range("E13").Value & "m " & Sheets(Sheet1).Range("E14").Value & "m " & Sheets(Sheet1).Range("E15").Value & "m"
row = row + 1
'Other Viewpoints
Num = WorksheetFunction.CountA(Sheets(Sheet1).Range("D25,D31,D37,D43,D49"))
rowtarget = 25
For i = 1 To Num
Sheets(Sheet2).Cells(row, 1).Value = "EXCAMERA" & " " & Chr(34) & Sheets(Sheet1).Cells(rowtarget, 4).Value & Chr(34) & " " & Sheets(Sheet1).Cells(rowtarget + 3, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 4, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 3, 8).Value & "deg" & " " & Sheets(Sheet1).Cells(rowtarget + 4, 8).Value & "deg" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 8).Value & "deg"
row = row + 1
rowtarget = rowtarget + 6
Next
row = row
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub InstumentPanel()
'This macro will write any and all code about a custom instrument panel to the DAT File.
Dim Sheet1 As String
Sheet1 = "Custom Instrument Panel"
If Sheets(Sheet1).Range("D9").Value = "NO" Then
Exit Sub
End If
Sheets(Sheet2).Cells(row, 1).Value = "INSTPANL" & " " & Sheets(Sheet1).Range("C16").Value
row = row + 1
'Panel Position
If WorksheetFunction.CountA(Sheets(Sheet1).Range("E24")) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "ISPNLPOS" & " " & Sheets(Sheet1).Range("E25").Value & "m" & " " & Sheets(Sheet1).Range("E26").Value & "m" & " " & Sheets(Sheet1).Range("E24").Value & "m"
row = row + 1
End If
'Panel Rotation
If WorksheetFunction.CountA(Sheets(Sheet1).Range("D34")) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "ISPNLATT" & " " & Sheets(Sheet1).Range("D35").Value & "deg" & " " & Sheets(Sheet1).Range("D36").Value & "deg" & " " & Sheets(Sheet1).Range("D34").Value & "deg"
row = row + 1
End If
'Scaling Factor
If WorksheetFunction.CountA(Sheets(Sheet1).Range("D42")) = 1 And Sheets(Sheet1).Range("D42").Value < 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "ISPNLSCL" & " " & Sheets(Sheet1).Range("D42").Value
row = row + 1
End If
'HUD with Instrument Panel?
If WorksheetFunction.CountA(Sheets(Sheet1).Range("D48")) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "ISPNLHUD" & " " & UCase(Sheets(Sheet1).Range("D48").Value)
row = row + 1
End If
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub LandingGear()
'This Sub writes the landing Gear Location to the DAT File.
Dim Sheet1 As String
Sheet1 = "Landing Gear"
Sheets(Sheet2).Cells(row, 1).Value = "LEFTGEAR" & " " & Sheets(Sheet1).Range("E21").Value & "m" & " " & Sheets(Sheet1).Range("E22").Value & "m" & " " & Sheets(Sheet1).Range("E20").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "RIGHGEAR" & " " & Sheets(Sheet1).Range("E26").Value & "m" & " " & Sheets(Sheet1).Range("E27").Value & "m" & " " & Sheets(Sheet1).Range("E25").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "NOSEGEAR" & " " & Sheets(Sheet1).Range("E16").Value & "m" & " " & Sheets(Sheet1).Range("E17").Value & "m" & " " & Sheets(Sheet1).Range("E15").Value & "m"
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Arrester()
'This macro writes the location of the arrester into the DAT File
Dim Sheet1 As String
Sheet1 = "Brake Parameters"
If Sheets(Sheet1).Range("D9").Value = "YES" Then
Sheets(Sheet2).Cells(row, 1).Value = "ARRESTER" & " " & Sheets(Sheet1).Range("E18").Value & "m" & " " & Sheets(Sheet1).Range("E19").Value & "m" & " " & Sheets(Sheet1).Range("E17").Value & "m"
row = row + 1
End If
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub MachineGuns()
'This Macro writes in the number of fixed machine guns and the firing interval into the DAT File.
Dim Sheet1 As String
Dim Num As Integer
Dim rowtarget As Integer
Dim i As Integer
Sheet1 = "Machine Guns"
If Sheets(Sheet1).Range("D10").Value = "NO" Then
Exit Sub
End If
Sheets(Sheet2).Cells(row, 1).Value = "MACHNGUN" & " " & Sheets(Sheet1).Range("F26").Value & "m" & " " & Sheets(Sheet1).Range("F27").Value & "m" & " " & Sheets(Sheet1).Range("F25").Value & "m"
row = row + 1
If WorksheetFunction.CountA(Sheets(Sheet1).Range("D16")) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "GUNINTVL" & " " & Sheets(Sheet1).Range("D16").Value
row = row + 1
End If
Num = WorksheetFunction.CountA(Sheets(Sheet1).Range("D25,D31,D37,D43,D49,D55"))
rowtarget = 31
For i = 2 To Num
Sheets(Sheet2).Cells(row, 1).Value = "MACHNGN" & i & " " & Sheets(Sheet1).Cells(rowtarget + 1, 6).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 6).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget, 6).Value & "m"
row = row + 1
rowtarget = rowtarget + 6
Next
row = row
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub SmokeGen()
'This macro will write in all of your Smoke generation points for your aircraft.
Dim Sheet1 As String
Dim Num As Integer
Dim rowtarget As Integer
Dim i As Integer
Sheet1 = "Smoke Generation"
Num = Sheets(Sheet1).Range("D10").Value
rowtarget = 18
For i = 1 To Num
Sheets(Sheet2).Cells(row, 1).Value = "SMOKEGEN" & " " & Sheets(Sheet1).Cells(rowtarget + 1, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget, 5).Value & "m"
row = row + 1
rowtarget = rowtarget + 5
Next
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Vapor()
'This macro writes the vapor positions of the wingtips.
Dim Sheet1 As String
Sheet1 = "Variable Geometry Wings"
If Sheets(Sheet1).Range("C12").Value = "FALSE" Then
Sheets(Sheet2).Cells(row, 1).Value = "VAPORPO0" & " " & Sheets(Sheet1).Range("E22").Value & "m" & " " & Sheets(Sheet1).Range("E23").Value & "m" & " " & Sheets(Sheet1).Range("E21").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "VAPORPO1" & " " & Sheets(Sheet1).Range("E22").Value & "m" & " " & Sheets(Sheet1).Range("E23").Value & "m" & " " & Sheets(Sheet1).Range("E21").Value & "m"
row = row + 1
End If
Sheets(Sheet2).Cells(row, 1).Value = "VAPORPO0" & " " & Sheets(Sheet1).Range("E22").Value & "m" & " " & Sheets(Sheet1).Range("E23").Value & "m" & " " & Sheets(Sheet1).Range("E21").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "VAPORPO1" & " " & Sheets(Sheet1).Range("E27").Value & "m" & " " & Sheets(Sheet1).Range("E28").Value & "m" & " " & Sheets(Sheet1).Range("E26").Value & "m"
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Strength()
'This macro writes the hit radius and strength of the aircraft into the DAT file.
Dim Sheet1 As String
Sheet1 = "Strength"
Sheets(Sheet2).Cells(row, 1).Value = "HTRADIUS" & " " & Sheets(Sheet1).Range("D11").Value
row = row + 3
Sheets(Sheet2).Cells(row, 1).Value = "STRENGTH" & " " & Sheets(Sheet1).Range("D17").Value
row = row + 3
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Critical1()
'This macro writes the min/Max AoA and critical speed and max speed of the aircraft
Dim Sheet1 As String
Sheet1 = "Flight Parameters"
Sheets(Sheet2).Cells(row, 1).Value = "CRITAOAP" & " " & Sheets(Sheet1).Range("D11").Value & "deg"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CRITAOAP" & " " & Sheets(Sheet1).Range("G11").Value & "deg"
row = row + 2
Sheets(Sheet2).Cells(row, 1).Value = "CRITSPED" & " " & Sheets(Sheet1).Range("D17").Value & Sheets(Sheet1).Range("E17").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CRITSPED" & " " & Sheets(Sheet1).Range("D18").Value & Sheets(Sheet1).Range("E18").Value
row = row + 1
End Sub
Sub CLAactive()
End Sub
Sub JetFuel()
'This Macro writes the fuel consumption for jet engines into the dat file
Dim Sheet1 As String
Dim Sheet2 As String
Sheet1 = "Fuel And Weights"
Sheet2 = "Test"
Sheets(Sheet2).Cells(row, 1).Value = "FUELABRN" & " " & Sheets(Sheet1).Range("G50").Value & Sheets(Sheet1).Range("F50").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "FUELMILI" & " " & Sheets(Sheet1).Range("G51").Value & Sheets(Sheet1).Range("F51").Value
row = row + 2
End Sub
Sub PropFuel()
'This macro writes the fuel consumption for propeller engines into the dat file
Dim Sheet1 As String
Dim Sheet2 As String
Sheet1 = "Fuel And Weights"
Sheet2 = "Test"
Sheets(Sheet2).Cells(row, 1).Value = "FUELABRN" & " " & "0.00kg"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "FUELMILI" & " " & Sheets(Sheet1).Range("D53").Value & Sheets(Sheet1).Range("E53").Value
row = row + 2
End Sub
Sub JetThrust()
Dim Sheet1 As String
Dim Sheet2 As String
Sheet1 = "Fuel And Weights"
Sheet2 = "Test"
Sheets(Sheet2).Cells(row, 1).Value = "THRAFTBN" & " " & Sheets(Sheet1).Range("C19").Value & Sheets(Sheet1).Range("G19").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "THRMILIT" & " " & Sheets(Sheet1).Range("C20").Value & Sheets(Sheet1).Range("G20").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "THRSTREV" & " " & Sheets(Sheet1).Range("C21").Value & Sheets(Sheet1).Range("G21").Value
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
End Sub
Sub PropThrust()
Dim Sheet1 As String
Dim Sheet2 As String
Sheet1 = "Fuel And Weights"
Sheet2 = "Test"
Sheets(Sheet2).Cells(row, 1).Value = "PROPELLR" & " " & Sheets(Sheet1).Range("C29").Value & Sheets(Sheet1).Range("G29").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "PROPEFCY" & " " & Sheets(Sheet1).Range("C30").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "PROPVMIN" & " " & Sheets(Sheet1).Range("C31").Value & Sheets(Sheet1).Range("G31").Value
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
End Sub
Sub FindLastCell()
'This Macro finds the last cell in the DAT file Worksheet
Dim Sheet As String
Dim i As Integer 'Row Counter
Sheet = "Test"
Sheets(Sheet).Select
Worksheets(Sheet).Cells(Rows.Count, 1).End(xlUp).Select
i = ActiveCell.row
i = i + 1
Sheets(Sheet).Range("B1").Value = i
End Sub
Visit by Bitbucket page for Python codes: https://bitbucket.org/decaff42/
Server Flight Log
Addon Database Submit Addon To Database
-
- Senior Veteran
- Posts: 1848
- Joined: Tue Feb 07, 2012 10:00 am
- Favorite Aircraft: .
- OS: windoze 10 64-bit
- Has thanked: 566 times
- Been thanked: 614 times
Re: Decaff's Garage
I could help with the dat.decaff_42 wrote:Just got the Prototype into YS Flight. Lots of DAT errors, and it wouldn't take off, but the animations worked...so I got that going for me.![]()
- decaff_42
- Staff
- Posts: 3644
- Joined: Sat Oct 29, 2011 7:23 pm
- Favorite Aircraft: SR-71 Blackbird
- Location: Eastern United States
- OS: Mac OSX
- Has thanked: 713 times
- Been thanked: 1481 times
- Contact:
Re: Decaff's Garage
That would be appreciated. I'll send a link in a little while.NightRaven wrote: I could help with the dat.
Well, I got to nearly 1200 lines of code, and Things are coming along swimmingly. Still a bit rough around the edges, but the excel file is generating a ~60-80% of a DAT file...

Code: Select all
'This Script will compile a fully functional DAT file from the inputs provided throughout the excel file.
'First it will check to make sure that all the pages are filled correctly.
'Then it will begin to compile the dat file and paste it into
Public row As Integer 'This variable is the row that strings will be pasted into for the DAT File
Public Sheet2 As String
Sub CallInOrder()
Sheet2 = "Test"
row = 1
Call Copyright
Call CheckAllSheetsAreDone
Call DatFileHeaderBuild
Call FuelAndWeightBuild
Call F1Viewpoints
Call InstumentPanel
Call LandingGear
Call Arrester
Call MachineGuns
Call SmokeGen
Call Vapor
Call Strength
Call Critical1
Call CLAactive
Call ThrustVector
Call Coefficients
Call WingArea
Call Maxinput
Call Controlability
Call MoveControl
Call InitialFlightConditions
Call HardPoints
Call BombBay
Call WeaponSkins
End Sub
Sub CheckAllSheetsAreDone()
'This macro checks to see if all the sheets are complete.
'Dat File header sheet
If Sheets("Dat File Header").Range("J12").Value = "NO" Then
MsgBox ("Dat File Header Section not checked off.")
Exit Sub
End If
'Fuel & weight Sheet
If Sheets("Fuel and Weights").Range("J12").Value = "NO" Then
MsgBox ("Fuel and Weights Section not checked off.")
Exit Sub
End If
'F1 Viewpoints Sheet
If Sheets("F1 Viewpoints").Range("J12").Value = "NO" Then
MsgBox ("F1 Viewpoints Section not checked off.")
Exit Sub
End If
'Landing Gear Sheet
If Sheets("Landing Gear").Range("J12").Value = "NO" Then
MsgBox ("Landing Gear Section not checked off.")
Exit Sub
End If
'Custom Instrument Panel
If Sheets("Custom Instrument Panel").Range("J12").Value = "NO" Then
MsgBox ("Custom Instrument Panel Section not checked off.")
Exit Sub
End If
'Smoke Generation Sheet
If Sheets("Smoke Generation").Range("J12").Value = "NO" Then
MsgBox ("Smoke Generation Section not checked off.")
Exit Sub
End If
'Variable Geometry Wings Sheet
If Sheets("Variable Geometry Wings").Range("J12").Value = "NO" Then
MsgBox ("Variable Geometry Wings Section not checked off.")
Exit Sub
End If
'Brake Parameters Sheet
If Sheets("Thrust Vectoring").Range("J12").Value = "NO" Then
MsgBox ("Thrust Vectoring Section not checked off.")
Exit Sub
End If
'Thrust Vectoring Parameters Sheet
If Sheets("Brake Parameters").Range("J12").Value = "NO" Then
MsgBox ("Brake Parameters Section not checked off.")
Exit Sub
End If
'Flaps Sheet
If Sheets("Flaps").Range("J12").Value = "NO" Then
MsgBox ("Flaps Section not checked off.")
Exit Sub
End If
'Machine Guns
If Sheets("Machine Guns").Range("J12").Value = "NO" Then
MsgBox ("Machine Guns Section not checked off.")
Exit Sub
End If
'Hard Points
If Sheets("Hardpoints").Range("J12").Value = "NO" Then
MsgBox ("Hardpoints Section not checked off.")
Exit Sub
End If
'Bomb bay
'Strength Parameters Sheet
If Sheets("Strength").Range("J12").Value = "NO" Then
MsgBox ("Strength Parameters Section not checked off.")
Exit Sub
End If
'Flight Parameters
'Aircraft Parameters
'Default Start Parameters
End Sub
Sub Copyright()
'This macro pastes in Decaff_42's copyright notice at the top of the DAT File
Sheets(Sheet2).Range("A1").Value = "REM" & " " & "This Dat file was created using Decaff_42's DAT File Excel Tool."
End Sub
Sub DatFileHeaderBuild()
'This Macro will build the Dat File Header Page's Dat parameters.
'It assumes that any cells that are left blank means that parameter is supposed to be blank.
Dim Sheet1 As String
Dim NUM As Integer
Dim i As Integer
Sheets(Sheet2).Range("A2:B200").Clear
Sheet1 = "Dat File Header"
NUM = WorksheetFunction.CountA(Sheets(Sheet1).Range("C11:C15"))
For i = 1 To NUM
row = i + 2
Sheets(Sheet2).Cells(row, 1).Value = "REM" & " " & Sheets(Sheet1).Cells(10 + i, 3).Value
Next
row = row + 2
Sheets(Sheet2).Cells(row, 1).Value = "IDENTIFY" & " " & Sheets(Sheet1).Range("C22").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "SUBSTNAM" & " " & Sheets(Sheet1).Range("C31").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CATEGORY" & " " & Sheets(Sheet1).Range("C38").Value
row = row + 1
If Sheets(Sheet1).Range("C44").Value = "" Then
row = row
Else: Sheets(Sheet2).Cells(row, 1).Value = "AIRCLASS" & " " & Sheets(Sheet1).Range("C44").Value
End If
row = row + 2
Sheets("Test").Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub FuelAndWeightBuild()
'This macro builds the Fuel and Weight section after the Dat file Header section
Dim Sheet1 As String
Sheet1 = "Fuel And Weights"
row = Sheets(Sheet2).Range("B1").Value
Sheets(Sheet2).Cells(row, 1).Value = "AFTBURNR" & " " & UCase(Sheets(Sheet1).Range("C11").Value)
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
If Sheets(Sheet1).Range("F11").Value = "NO" Then
Call JetThrust
Else: Call PropThrust
End If
'Weights
Sheets(Sheet2).Cells(row, 1).Value = "WEIGHCLN" & " " & Sheets(Sheet1).Range("C38").Value & Sheets(Sheet1).Range("G38").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "WEIGFUEL" & " " & Sheets(Sheet1).Range("C39").Value & Sheets(Sheet1).Range("G39").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "WEIGLOAD" & " " & Sheets(Sheet1).Range("C40").Value & Sheets(Sheet1).Range("G40").Value
row = row + 1
If Sheets(Sheet1).Range("F11").Value = "NO" Then
Call JetFuel
Else: Call PropFuel
End If
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub F1Viewpoints()
'This macro will write the F1 Viewpoints into the DAT file
Dim Sheet1 As String
Dim NUM As Integer
Dim rowtarget As Integer
Dim i As Integer
Sheet1 = "F1 Viewpoints"
'Pilot's Viewpoint
Sheets(Sheet2).Cells(row, 1).Value = "COCKPITP" & " " & Sheets(Sheet1).Range("E13").Value & "m " & Sheets(Sheet1).Range("E14").Value & "m " & Sheets(Sheet1).Range("E15").Value & "m"
row = row + 1
'Other Viewpoints
NUM = WorksheetFunction.CountA(Sheets(Sheet1).Range("D25,D31,D37,D43,D49"))
rowtarget = 25
For i = 1 To NUM
Sheets(Sheet2).Cells(row, 1).Value = "EXCAMERA" & " " & Chr(34) & Sheets(Sheet1).Cells(rowtarget, 4).Value & Chr(34) & " " & Sheets(Sheet1).Cells(rowtarget + 3, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 4, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 3, 8).Value & "deg" & " " & Sheets(Sheet1).Cells(rowtarget + 4, 8).Value & "deg" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 8).Value & "deg"
row = row + 1
rowtarget = rowtarget + 6
Next
row = row
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub InstumentPanel()
'This macro will write any and all code about a custom instrument panel to the DAT File.
Dim Sheet1 As String
Sheet1 = "Custom Instrument Panel"
If Sheets(Sheet1).Range("D9").Value = "NO" Then
Exit Sub
End If
Sheets(Sheet2).Cells(row, 1).Value = "INSTPANL" & " " & Sheets(Sheet1).Range("C16").Value
row = row + 1
'Panel Position
If WorksheetFunction.CountA(Sheets(Sheet1).Range("E24")) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "ISPNLPOS" & " " & Sheets(Sheet1).Range("E25").Value & "m" & " " & Sheets(Sheet1).Range("E26").Value & "m" & " " & Sheets(Sheet1).Range("E24").Value & "m"
row = row + 1
End If
'Panel Rotation
If WorksheetFunction.CountA(Sheets(Sheet1).Range("D34")) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "ISPNLATT" & " " & Sheets(Sheet1).Range("D35").Value & "deg" & " " & Sheets(Sheet1).Range("D36").Value & "deg" & " " & Sheets(Sheet1).Range("D34").Value & "deg"
row = row + 1
End If
'Scaling Factor
If WorksheetFunction.CountA(Sheets(Sheet1).Range("D42")) = 1 And Sheets(Sheet1).Range("D42").Value < 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "ISPNLSCL" & " " & Sheets(Sheet1).Range("D42").Value
row = row + 1
End If
'HUD with Instrument Panel?
If WorksheetFunction.CountA(Sheets(Sheet1).Range("D48")) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "ISPNLHUD" & " " & UCase(Sheets(Sheet1).Range("D48").Value)
row = row + 1
End If
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub LandingGear()
'This Sub writes the landing Gear Location to the DAT File.
Dim Sheet1 As String
Sheet1 = "Landing Gear"
Sheets(Sheet2).Cells(row, 1).Value = "LEFTGEAR" & " " & Sheets(Sheet1).Range("E21").Value & "m" & " " & Sheets(Sheet1).Range("E22").Value & "m" & " " & Sheets(Sheet1).Range("E20").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "RIGHGEAR" & " " & Sheets(Sheet1).Range("E26").Value & "m" & " " & Sheets(Sheet1).Range("E27").Value & "m" & " " & Sheets(Sheet1).Range("E25").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "NOSEGEAR" & " " & Sheets(Sheet1).Range("E16").Value & "m" & " " & Sheets(Sheet1).Range("E17").Value & "m" & " " & Sheets(Sheet1).Range("E15").Value & "m"
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Arrester()
'This macro writes the location of the arrester into the DAT File
Dim Sheet1 As String
Sheet1 = "Brake Parameters"
If Sheets(Sheet1).Range("D9").Value = "YES" Then
Sheets(Sheet2).Cells(row, 1).Value = "ARRESTER" & " " & Sheets(Sheet1).Range("E18").Value & "m" & " " & Sheets(Sheet1).Range("E19").Value & "m" & " " & Sheets(Sheet1).Range("E17").Value & "m"
row = row + 1
End If
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub MachineGuns()
'This Macro writes in the number of fixed machine guns and the firing interval into the DAT File.
Dim Sheet1 As String
Dim NUM As Integer
Dim rowtarget As Integer
Dim i As Integer
Sheet1 = "Machine Guns"
If Sheets(Sheet1).Range("D10").Value = "NO" Then
Exit Sub
End If
Sheets(Sheet2).Cells(row, 1).Value = "MACHNGUN" & " " & Sheets(Sheet1).Range("F26").Value & "m" & " " & Sheets(Sheet1).Range("F27").Value & "m" & " " & Sheets(Sheet1).Range("F25").Value & "m"
row = row + 1
If WorksheetFunction.CountA(Sheets(Sheet1).Range("D16")) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "GUNINTVL" & " " & Sheets(Sheet1).Range("D16").Value
row = row + 1
End If
NUM = WorksheetFunction.CountA(Sheets(Sheet1).Range("D25,D31,D37,D43,D49,D55"))
rowtarget = 31
For i = 2 To NUM
Sheets(Sheet2).Cells(row, 1).Value = "MACHNGN" & i & " " & Sheets(Sheet1).Cells(rowtarget + 1, 6).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 6).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget, 6).Value & "m"
row = row + 1
rowtarget = rowtarget + 6
Next
row = row
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub SmokeGen()
'This macro will write in all of your Smoke generation points for your aircraft.
Dim Sheet1 As String
Dim NUM As Integer
Dim rowtarget As Integer
Dim i As Integer
Sheet1 = "Smoke Generation"
NUM = Sheets(Sheet1).Range("D10").Value
rowtarget = 18
For i = 1 To NUM
Sheets(Sheet2).Cells(row, 1).Value = "SMOKEGEN" & " " & Sheets(Sheet1).Cells(rowtarget + 1, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 5).Value & "m" & " " & Sheets(Sheet1).Cells(rowtarget, 5).Value & "m"
row = row + 1
rowtarget = rowtarget + 5
Next
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Vapor()
'This macro writes the vapor positions of the wingtips.
Dim Sheet1 As String
Sheet1 = "Variable Geometry Wings"
If Sheets(Sheet1).Range("C12").Value = "FALSE" Then
Sheets(Sheet2).Cells(row, 1).Value = "VAPORPO0" & " " & Sheets(Sheet1).Range("E22").Value & "m" & " " & Sheets(Sheet1).Range("E23").Value & "m" & " " & Sheets(Sheet1).Range("E21").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "VAPORPO1" & " " & Sheets(Sheet1).Range("E22").Value & "m" & " " & Sheets(Sheet1).Range("E23").Value & "m" & " " & Sheets(Sheet1).Range("E21").Value & "m"
row = row + 1
End If
Sheets(Sheet2).Cells(row, 1).Value = "VAPORPO0" & " " & Sheets(Sheet1).Range("E22").Value & "m" & " " & Sheets(Sheet1).Range("E23").Value & "m" & " " & Sheets(Sheet1).Range("E21").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "VAPORPO1" & " " & Sheets(Sheet1).Range("E27").Value & "m" & " " & Sheets(Sheet1).Range("E28").Value & "m" & " " & Sheets(Sheet1).Range("E26").Value & "m"
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Strength()
'This macro writes the hit radius and strength of the aircraft into the DAT file.
Dim Sheet1 As String
Sheet1 = "Strength"
Sheets(Sheet2).Cells(row, 1).Value = "HTRADIUS" & " " & Sheets(Sheet1).Range("D11").Value
row = row + 3
Sheets(Sheet2).Cells(row, 1).Value = "STRENGTH" & " " & Sheets(Sheet1).Range("D18").Value
row = row + 3
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Critical1()
'This macro writes the min/Max AoA and critical speed and max speed of the aircraft
Dim Sheet1 As String
Sheet1 = "Flight Parameters"
Sheets(Sheet2).Cells(row, 1).Value = "CRITAOAP" & " " & Sheets(Sheet1).Range("D11").Value & "deg"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CRITAOAP" & " " & Sheets(Sheet1).Range("G11").Value & "deg"
row = row + 2
Sheets(Sheet2).Cells(row, 1).Value = "CRITSPED" & " " & Sheets(Sheet1).Range("D17").Value & Sheets(Sheet1).Range("E17").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CRITSPED" & " " & Sheets(Sheet1).Range("D18").Value & Sheets(Sheet1).Range("E18").Value
row = row + 2
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub CLAactive()
'This macro writes the CLA activation lines into the DAT File.
Sheets(Sheet2).Cells(row, 1).Value = "HASSPOIL" & " " & UCase(Sheets("Brake Parameters").Range("D25").Value)
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "RETRGEAR" & " " & UCase(Sheets("Landing Gear").Range("D33").Value)
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "VARGEOMW" & " " & UCase(Sheets("Variable Geometry Wings").Range("C12").Value)
row = row + 2
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub ThrustVector()
'This Macro writes the thrust vectoring parameters of the aircraft if any exist.
Dim Sheet1 As String
Sheet1 = "Thrust Vectoring"
If Sheets(Sheet1).Range("D10").Value = "True" Then
Exit Sub
End If
Sheets(Sheet2).Cells(row, 1).Value = "TRSTVCTR" & " " & "TRUE"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "TRSTDIR0" & " " & Sheets(Sheet1).Range("C22").Value & "m" & " " & Sheets(Sheet1).Range("C23").Value & "m" & " " & Sheets(Sheet1).Range("C21").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "TRSTDIR1" & " " & Sheets(Sheet1).Range("C27").Value & "m" & " " & Sheets(Sheet1).Range("C28").Value & "m" & " " & Sheets(Sheet1).Range("C26").Value & "m"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "PSTMPTCH" & " " & Sheets(Sheet1).Range("E30").Value & "deg"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "PSTMYAW_" & " " & Sheets(Sheet1).Range("E31").Value & "deg"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "PSTMROLL" & " " & Sheets(Sheet1).Range("E32").Value & "deg"
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Coefficients()
'This macro writes in the effects of various surfaces to the lift and drag.
If Sheets("Variable Geometry Wings").Range("C12").Value = "False" Then
Sheets(Sheet2).Cells(row, 1).Value = "CLVARGEO" & " " & "0.0"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CDVARGEO" & " " & "0.0"
row = row + 1
Else
Sheets(Sheet2).Cells(row, 1).Value = "CLVARGEO" & " " & Sheets("Variable Geometry Wings").Range("D40").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CDVARGEO" & " " & Sheets("Variable Geometry Wings").Range("D34").Value
row = row + 1
End If
If Sheets("Flaps").Range("C9").Value = "No" Then
Sheets(Sheet2).Cells(row, 1).Value = "CLBYFLAP" & " " & "0.0"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CDBYFLAP" & " " & "0.0"
row = row + 1
Else
Sheets(Sheet2).Cells(row, 1).Value = "CLBYFLAP" & " " & Sheets("Flaps").Range("D21").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CDBYFLAP" & " " & Sheets("Flaps").Range("D15").Value
row = row + 1
End If
If Sheets("Landing Gear").Range("D33").Value = "False" Then
Sheets(Sheet2).Cells(row, 1).Value = "CDBYGEAR" & " " & "0.0"
row = row + 1
Else
Sheets(Sheet2).Cells(row, 1).Value = "CDBYGEAR" & " " & Sheets("Landing Gear").Range("D39").Value
row = row + 1
End If
If Sheets("Brake Parameters").Range("D25").Value = "False" Then
Sheets(Sheet2).Cells(row, 1).Value = "CDSPOILR" & " " & "0.0"
row = row + 1
Else
Sheets(Sheet2).Cells(row, 1).Value = "CDSPOILR" & " " & Sheets("Brake Parameters").Range("D31").Value
row = row + 1
End If
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub WingArea()
'This macro inserts the wing area into the DAT File.
Sheets(Sheet2).Cells(row, 1).Value = "WINGAREA" & " " & Sheets("Aircraft Parameters").Range("F11").Value & "m^2"
row = row + 2
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Maxinput()
'This macro writes the maximum inputs into the DAT File.
Dim Sheet1 As String
Sheet1 = "Aircraft Parameters"
Sheets(Sheet2).Cells(row, 1).Value = "MXIPTAOA" & " " & Sheets(Sheet1).Range("D17").Value & "deg"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "MXIPTSSA" & " " & Sheets(Sheet1).Range("D18").Value & "deg"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "MXIPTROL" & " " & Sheets(Sheet1).Range("D19").Value & "deg"
row = row + 2
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub Controlability()
'This macro defines the controlability parameters for the aircraft.
Dim Sheet1
Sheet1 = "Flight Parameters"
'Default DAT File Comments
Sheets(Sheet2).Cells(row, 1).Value = "REM CPITMANE corresponds to Spring Constant K"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "REM CPITSTAB corresponds to Damper Constant B"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "REM To be critically damped, B=2*sqrt(K)"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "REM 2% Settling Time=??"
row = row + 2
'Inputs
Sheets(Sheet2).Cells(row, 1).Value = "MANESPD1" & " " & Sheets(Sheet1).Range("E32").Value & Sheets(Sheet1).Range("F32").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "MANESPD2" & " " & Sheets(Sheet1).Range("E33").Value & Sheets(Sheet1).Range("F33").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CPITMANE" & " " & Sheets(Sheet1).Range("E34").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CPITSTAB" & " " & Sheets(Sheet1).Range("E35").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CYAWMANE" & " " & Sheets(Sheet1).Range("E36").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CYAWSTAB" & " " & Sheets(Sheet1).Range("E37").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CROLLMAN" & " " & Sheets(Sheet1).Range("E38").Value
row = row + 2
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub MoveControl()
'This macro writes the control parameter for the various DAT-affected CLA's.
Sheets(Sheet2).Cells(row, 1).Value = "CTLLDGEA TRUE"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CTLBRAKE FALSE"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CTLSPOIL 0.0"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CTLABRNR FALSE"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CTLTHROT 0.0"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CTLIFLAP 0.0"
row = row + 1
If Sheets("Variable Geometry Wings").Range("C12").Value = "True" Then
Sheets(Sheet2).Cells(row, 1).Value = "CTLINVGW 1.0"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CTLATVGW TRUE"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "VGWSPED1" & " " & Sheets("Variable Geometry Wings").Range("D47").Value & Sheets("Variable Geometry Wings").Range("E47").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "VGWSPED2" & " " & Sheets("Variable Geometry Wings").Range("D54").Value & Sheets("Variable Geometry Wings").Range("E54").Value
row = row + 2
Else
Sheets(Sheet2).Cells(row, 1).Value = "CTLINVGW 0.0"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "CTLATVGW FALSE"
row = row + 2
End If
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub InitialFlightConditions()
'This Macro will write the initial flight conditions relative to the start point.
Dim Sheet1 As String
Sheet1 = "Default Start Parameters"
'Position
Sheets(Sheet2).Cells(row, 1).Value = "POSITION" & " " & Sheets(Sheet1).Range("C13").Value & Sheets(Sheet1).Range("D13").Value & " " & _
Sheets(Sheet1).Range("C14").Value & Sheets(Sheet1).Range("D14").Value & " " & _
Sheets(Sheet1).Range("C12").Value & Sheets(Sheet1).Range("D12").Value
row = row + 1
'Attitude
If Sheets(Sheet1).Range("C21").Value = 0 And Sheets(Sheet1).Range("C20").Value = 0 And Sheets(Sheet1).Range("C22").Value = 0 Then
Sheets(Sheet2).Cells(row, 1).Value = "ATTITUDE 0deg 0deg 0deg"
row = row + 1
Else
Sheets(Sheet2).Cells(row, 1).Value = "ATTITUDE" & " " & Sheets(Sheet1).Range("C21").Value & "deg" & " " & _
Sheets(Sheet1).Range("C22").Value & "deg" & " " & _
Sheets(Sheet1).Range("C20").Value & "deg"
row = row + 1
End If
'Initial Fuel
Sheets(Sheet2).Cells(row, 1).Value = "INITFUEL" & " " & Sheets(Sheet1).Range("D28").Value & "%"
row = row + 1
'Initial Payload
Sheets(Sheet2).Cells(row, 1).Value = "INITLOAD" & " " & Sheets(Sheet1).Range("D35").Value & Sheets(Sheet1).Range("E35").Value
row = row + 1
'Initial Speed
Sheets(Sheet2).Cells(row, 1).Value = "INITSPED" & " " & Sheets(Sheet1).Range("D44").Value
row = row + 1
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub HardPoints()
'This macro writes the Hardpoints section of the DAT File
Dim Sheet1 As String
Dim NUM As Integer
Dim i As Integer
Dim rowtarget As Integer
Sheet1 = "Hardpoints"
NUM = WorksheetFunction.CountA(Sheets(Sheet1).Range("C39, C51, C63, C75, C87, C99, C111, C123, C135, C147, C159"))
rowtarget = 39
Sheets(Sheet2).Cells(row, 1).Value = "REM Slots must come before Inits."
row = row + 1
For i = 1 To NUM
Dim Internal As String
Dim AIM120 As Integer
Dim AIM9 As Integer
Dim AIM9X As Integer
Dim AGM65 As Integer
Dim B250 As Integer
Dim B500 As Integer
Dim B500HD As Integer
Dim RKT As Integer
Dim FLR As Integer
Dim FUEL As Integer
'Find Values for the parts of the hardpoint line.
If Sheets(Sheet1).Cells(rowtarget + 4, 4) = "YES" Then
Internal = "$INTERNAL "
Else
Internal = ""
End If
If Sheets(Sheet1).Cells(rowtarget + 1, 7) > 0 Then
AIM120 = Sheets(Sheet1).Cells(rowtarget + 1, 7).Value
Else
AIM120 = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 2, 7) > 0 Then
AIM9 = Sheets(Sheet1).Cells(rowtarget + 2, 7).Value
Else
AIM9 = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 3, 7) > 0 Then
AIM9X = Sheets(Sheet1).Cells(rowtarget + 3, 7).Value
Else
AIM9X = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 4, 7) > 0 Then
AGM65 = Sheets(Sheet1).Cells(rowtarget + 4, 7).Value
Else
AGM65 = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 5, 7) > 0 Then
B250 = Sheets(Sheet1).Cells(rowtarget + 5, 7).Value
Else
B250 = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 6, 7) > 0 Then
B500 = Sheets(Sheet1).Cells(rowtarget + 6, 7).Value
Else
B500 = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 7, 7) > 0 Then
B500HD = Sheets(Sheet1).Cells(rowtarget + 7, 7).Value
Else
B500HD = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 8, 7) > 0 Then
RKT = Sheets(Sheet1).Cells(rowtarget + 8, 7).Value
Else
RKT = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 9, 7) > 0 Then
FLR = Sheets(Sheet1).Cells(rowtarget + 9, 7).Value
Else
FLR = 0
End If
If Sheets(Sheet1).Cells(rowtarget + 10, 7) > 0 Then
FUEL = Sheets(Sheet1).Cells(rowtarget + 10, 7).Value
Else
FUEL = 0
End If
'Define the line components
Dim WPN1 As String
Dim WPN2 As String
Dim WPN3 As String
Dim WPN4 As String
Dim WPN5 As String
Dim WPN6 As String
Dim WPN7 As String
Dim WPN8 As String
Dim WPN9 As String
Dim WPN10 As String
If AIM120 = 0 Then
WPN1 = ""
Else
WPN1 = "AIM120" & "*" & AIM120 & " "
End If
If AIM9 = 0 Then
WPN2 = ""
Else
WPN2 = "AIM9" & "*" & AIM9 & " "
End If
If AIM9X = 0 Then
WPN3 = ""
Else
WPN3 = "AIM9X" & "*" & AIM9X & " "
End If
If AGM65 = 0 Then
WPN4 = ""
Else
WPN4 = "AGM65" & "*" & AGM65 & " "
End If
If B250 = 0 Then
WPN5 = ""
Else
WPN5 = "B250" & "*" & B250 & " "
End If
If B500 = 0 Then
WPN6 = ""
Else
WPN6 = "B500" & "*" & B500 & " "
End If
If B500HD = 0 Then
WPN7 = " "
Else
WPN7 = "B500HD" & "*" & B500HD & " "
End If
If RKT = 0 Then
WPN8 = ""
Else
WPN8 = "RKT" & "*" & RKT & " "
End If
If FLR = 0 Then
WPN9 = ""
Else
WPN9 = "FLR" & "*" & FLR & " "
End If
If FUEL = 0 Then
WPN10 = ""
Else
WPN10 = "FUEL" & FUEL
End If
Sheets(Sheet2).Cells(row, 1).Value = "HRDPOINT" & " " & Sheets(Sheet1).Cells(rowtarget + 1, 5).Value & "m" & " " & _
Sheets(Sheet1).Cells(rowtarget + 2, 5).Value & "m" & " " & _
Sheets(Sheet1).Cells(rowtarget, 5).Value & "m" & " " & _
Internal & _
WPN1 & _
WPN2 & _
WPN3 & _
WPN4 & _
WPN5 & _
WPN6 & _
WPN7 & _
WPN8 & _
WPN9 & _
WPN10
row = row + 1
rowtarget = rowtarget + 12
Next
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub BombBay()
'This macro writes the Bomb bay lines into the DAT file.
Dim Sheet1 As String
Sheet1 = "Bomb Bay"
If Sheets(Sheet1).Range("D9").Value = "No" Then
Exit Sub
Else
Sheets(Sheet2).Cells(row, 1).Value = "BOMINBAY" & " " & "TRUE"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "BMBAYRCS" & " " & Sheets(Sheet1).Range("D15").Value
row = row + 1
End If
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub WeaponSkins()
'This Macro will write the filepaths to the Custom Weapon Skins specific to this airplane. It makes _
YSFlight ignore the weapon skins defined in the weapons folder for only the weapons specified.
Dim Sheet1 As String
Dim rowtarget As String
Dim i As Integer
Sheet1 = "Weapon Skins"
rowtarget = 17
row = row + 1
For i = 1 To 10
If WorksheetFunction.CountA(Sheets(Sheet1).Cells(rowtarget + 1, 3)) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "WPNSHAPE" & " " & Sheets(Sheet1).Cells(rowtarget, 2).Value & " " & "STATIC" & " " & Sheets(Sheet1).Cells(rowtarget + 1, 3).Value
row = row + 1
End If
If WorksheetFunction.CountA(Sheets(Sheet1).Cells(rowtarget + 2, 3)) = 1 Then
Sheets(Sheet2).Cells(row, 1).Value = "WPNSHAPE" & " " & Sheets(Sheet1).Cells(rowtarget, 2).Value & " " & "FLYING" & " " & Sheets(Sheet1).Cells(rowtarget + 2, 3).Value
row = row + 2
End If
rowtarget = rowtarget + 4
Next
Sheets(Sheet2).Range("B1").Value = row
Sheets(Sheet2).Select
Cells(row, 1).Select
End Sub
Sub JetFuel()
'This Macro writes the fuel consumption for jet engines into the dat file
Dim Sheet1 As String
Dim Sheet2 As String
Sheet1 = "Fuel And Weights"
Sheet2 = "Test"
Sheets(Sheet2).Cells(row, 1).Value = "FUELABRN" & " " & Sheets(Sheet1).Range("G50").Value & Sheets(Sheet1).Range("F50").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "FUELMILI" & " " & Sheets(Sheet1).Range("G51").Value & Sheets(Sheet1).Range("F51").Value
row = row + 2
End Sub
Sub PropFuel()
'This macro writes the fuel consumption for propeller engines into the dat file
Dim Sheet1 As String
Dim Sheet2 As String
Sheet1 = "Fuel And Weights"
Sheet2 = "Test"
Sheets(Sheet2).Cells(row, 1).Value = "FUELABRN" & " " & "0.00kg"
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "FUELMILI" & " " & Sheets(Sheet1).Range("D53").Value & Sheets(Sheet1).Range("E53").Value
row = row + 2
End Sub
Sub JetThrust()
Dim Sheet1 As String
Dim Sheet2 As String
Sheet1 = "Fuel And Weights"
Sheet2 = "Test"
Sheets(Sheet2).Cells(row, 1).Value = "THRAFTBN" & " " & Sheets(Sheet1).Range("C19").Value & Sheets(Sheet1).Range("G19").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "THRMILIT" & " " & Sheets(Sheet1).Range("C20").Value & Sheets(Sheet1).Range("G20").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "THRSTREV" & " " & Sheets(Sheet1).Range("C21").Value & Sheets(Sheet1).Range("G21").Value
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
End Sub
Sub PropThrust()
Dim Sheet1 As String
Dim Sheet2 As String
Sheet1 = "Fuel And Weights"
Sheet2 = "Test"
Sheets(Sheet2).Cells(row, 1).Value = "PROPELLR" & " " & Sheets(Sheet1).Range("C29").Value & Sheets(Sheet1).Range("G29").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "PROPEFCY" & " " & Sheets(Sheet1).Range("C30").Value
row = row + 1
Sheets(Sheet2).Cells(row, 1).Value = "PROPVMIN" & " " & Sheets(Sheet1).Range("C31").Value & Sheets(Sheet1).Range("G31").Value
row = row + 1
Sheets(Sheet2).Range("B1").Value = row
End Sub
-- Tue Dec 24, 2013 12:19 pm --
WOOO!!!
First flight of the 727-200 and subsequent test flights have gone well! I removed the seeder animations propellers and everything worked well, so woo!
I added a color gradient to the center engine intake, fixed the flap movers so the normals looked right and they had black insides so they looked solid when deployed, and added 50% of the color to the landing gear.
Here's some pictures from the first round of test flights.











-- Thu Dec 26, 2013 11:21 pm --
COCKPIT UPDATES!!!!
Worked on and got the cockpit integrated with the rest of the 727. The cockpit base (without the instrument panels) only added 500kb bringing the dnm file size to 2.7 mb...Not too bad.
the cockpit instruments themselves are 1.2 mb. I went in and did a lot of cutting and removal of 3D pieces and putting 2D pieces in their places.
I still have some touchup work to do on the instrument panels, fixing some shading stuff, and then finalizing the bright faces for night flying.



I've also decided to do 3 versions, a -200, -200F, and a -200 with the Quiet Wing Corp 727 winglets. they have 95% or more commonality, so it shouldn't be all that bad getting the different versions from the -200 stock aircraft.
Once I'm done with the cockpit, I'll be working on getting all the pieces in, and adding the final touches to the meshes. Then I'll work on the nav lights.
Visit by Bitbucket page for Python codes: https://bitbucket.org/decaff42/
Server Flight Log
Addon Database Submit Addon To Database
- Turbofan
- Senior Veteran
- Posts: 1979
- Joined: Thu Feb 03, 2011 4:22 pm
- Favorite Aircraft: Boeing 747, all variants
- Location: Southern Plains
- Has thanked: 1077 times
- Been thanked: 784 times
- Contact:
Re: Decaff's Garage
I hope you have left the spoiler animations as default-not synchronized with the reverse thrust. I like fully deploying spoilers after touching down-just saying.
Check out my YSFS videos on my Youtube channel!
-----------------------
Avatar: Pratt and Whitney JT8D-219
-----------------------
Turbofan's Terminal updated! New information on home page and WIP for 2020! Check it out!
Who is online
Users browsing this forum: Bing [Bot] and 1 guest