Search Archive

I would like to add Fuel CaLculator to my mod

By Jfinley0 · May 26, 2010in Hacks/Mods💬 43 posts👁️ 5,933 views
Page 2 of 2
Posted Jun 14, 2010 · 01:26 UTC#26
I got the fuel calc working in Diaftias mod. It was not easy! You are missing a whole bunch of steps. My suggestion to you is to go through the UI files in the 'Common' folder of my mod and make the changes that you see needed in your mod with regards to the fuel calculator. There are too many scripts to post to get this working, you have to do the leg work. You also need a bmp

Ok so all the referenced codes are in your coomon ui folder. I will examdiff each file and see what differs. Thanks for the advice.

Also in the '800_480/UI' folder. It took me several hours going through all the code for the map changer and the fuel calculator, and a LOT of error messages. Error messages are good though, because you know where the problem is in most cases. In Diaftias mod that I redone, I added probably about 60-100 new lines of text, most of it to incorporate the mapchanger and fuel calculator.

 

I did added the map changer about a month ago. I got that working fine. Let me know what steps you took to get the \fuel calculator going. I also spent hours going over the files in the common/ui.

Thanks

Jimbo

Posted Jun 14, 2010 · 02:23 UTC#27

Ok well here i an update to what I have gotten so far. I have finally been able to get to the fuel calc screen when i hit the onmap button. although i am still getting errors but now the error is FFUIERROR: Unknown object identifier Identifier=[d_Umnog] Script"[unnamed]" command 1. then when it does go to the fuel calc screen when i hit consumption it says FFUIERROR : Unknown object identifier Identifier=[d_UmnDelDone] Script"d_StFuelCalc_done" command 0I. guess that is what i have to search for now.

Anyway this is what I added besides what i mentioned earlier.

1. I added this to the top of the start 800_480 file

;Half Patches

import "ui_pioneer/800_480/ui/half_patch_800_480.ui"

2. I also added this to the end of the start.ui file

;Half Patches

import "ui_pioneer/common/ui/half_patch.ui"

Back to the drawing board!

Posted Jun 14, 2010 · 02:45 UTC#28
Ok well here i an update to what I have gotten so far. I have finally been able to get to the fuel calc screen when i hit the onmap button. although i am still getting errors but now the error is FFUIERROR: Unknown object identifier Identifier=[d_Umnog] Script"[unnamed]" command 1. then when it does go to the fuel calc screen when i hit consumption it says FFUIERROR : Unknown object identifier Identifier=[d_UmnDelDone] Script"d_StFuelCalc_done" command 0I. guess that is what i have to search for now.

Anyway this is what I added besides what i mentioned earlier.

1. I added this to the top of the start 800_480 file

;Half Patches

import "ui_pioneer/800_480/ui/half_patch_800_480.ui"

2. I also added this to the end of the start.ui file

;Half Patches

import "ui_pioneer/common/ui/half_patch.ui"

Back to the drawing board!

 

I checked and I had both files in where you mentioned. I guess I forgot to tell you that when I tried to remember everything I did. Let me know if you make any progress. I will also keep trying.

Thanks

Jimbo

Posted Jun 14, 2010 · 02:50 UTC#29

ok found that error, but now i am getting another error FFUIERROR: Unknown object identifier Identifier=[d_UmnDel1] Script"d_Delen" command 1. Anyway as an update add this into the place.ui file at the end to get rid of the last error i was getting. Now on to finding the next error:

;Common Multiplication and Division Function

run d_UmnDelDone

dUmnDel1.set $1

dUmnDel2.set $2

dUmnDel3.set $3

dUmnDel4.set $1

1 run d_UmnogInit

 

decval "dUmnDel2" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 0 'run dUmnDel3'

1 else_run 'incval "dUmnDel1" dUmnDel4, run d_UmnogRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_UmnogInit'

else_run '1 run d_UmnogInit'

 

run d_UmnDelDone

dUmnDel1.set -1

dUmnDel2.set $1

dUmnDel3.set $3

dUmnDel4.set $2

1 run d_DelenInit

 

incval "dUmnDel1" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 <= 0 'run dUmnDel3'

1 else_run 'decval "dUmnDel2" dUmnDel4, run d_DelenRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_DelenInit'

else_run '1 run d_DelenInit'

 

term d_UmnogInit

term d_UmnogRepeat

term d_DelenInit

term d_DelenRepeat

dUmnDel5.set 0

Posted Jun 14, 2010 · 03:14 UTC#30

that last error is a tough one. I can't seem to find where that code is being called out in any other ui file. Anyway too tired to continue examdiff. will try again tomorrow.

Posted Jun 14, 2010 · 04:23 UTC#31
that last error is a tough one. I can't seem to find where that code is being called out in any other ui file. Anyway too tired to continue examdiff. will try again tomorrow.

Check these UI files out. I believe that these are the ones that are referenced:

 

ADD:

half_patch_var.ui

half_patch.ui

half_patch_800_480.ui

 

 

Reference (add scripts relating to):

START.UI

place.ui

model_variables.ui

 

There might be a few others as well, but these are DEFINATELY referenced. Make sure that you add the calculations to the 'place.ui' folder

 

 

Through a lot of trial and error, I got it working perfectly in Diaftias mod

Posted Jun 14, 2010 · 11:39 UTC#32
that last error is a tough one. I can't seem to find where that code is being called out in any other ui file. Anyway too tired to continue examdiff. will try again tomorrow.

Check these UI files out. I believe that these are the ones that are referenced:

 

ADD:

half_patch_var.ui

half_patch.ui

half_patch_800_480.ui

 

 

Reference (add scripts relating to):

START.UI

place.ui

model_variables.ui

 

There might be a few others as well, but these are DEFINATELY referenced. Make sure that you add the calculations to the 'place.ui' folder

 

 

Through a lot of trial and error, I got it working perfectly in Diaftias mod

 

What scrips would be add to place.ui?

I have all the patches in the proper ui files.....

Thanks

Jimbo

Posted Jun 14, 2010 · 11:54 UTC#33

 

What scrips would be add to place.ui?

I have all the patches in the proper ui files.....

Thanks

Jimbo

starting out, you will have to replace the header with this









 

then add all this to the bottom. This is your mathematical calculations

;Common Multiplication and Division Function












 

THEN you will have to add this bmp:

z_sliderbar_bg_long.bmp

Posted Jun 14, 2010 · 12:02 UTC#34

If that does not do it, then you are missing code in one of the other ui files. Search for anything with reference to 'half_patch' or 'fuel calculator'

Posted Jun 14, 2010 · 12:39 UTC#35
If that does not do it, then you are missing code in one of the other ui files. Search for anything with reference to 'half_patch' or 'fuel calculator'

 

Thanks ABB1,

I went back to your mod and copied the top lines and copied everything at the bottom of place.ui starting with the divisions scrip and now everything works.

Thanks

Jimbo

Posted Jun 14, 2010 · 12:58 UTC#36
If that does not do it, then you are missing code in one of the other ui files. Search for anything with reference to 'half_patch' or 'fuel calculator'

 

Thanks ABB1,

I went back to your mod and copied the top lines and copied everything at the bottom of place.ui starting with the divisions scrip and now everything works.

Thanks

Jimbo

NP, your welcome :)! Glad that you finally got it working!

Posted Jun 14, 2010 · 13:40 UTC#37
ok found that error, but now i am getting another error FFUIERROR: Unknown object identifier Identifier=[d_UmnDel1] Script"d_Delen" command 1. Anyway as an update add this into the place.ui file at the end to get rid of the last error i was getting. Now on to finding the next error:

;Common Multiplication and Division Function

run d_UmnDelDone

dUmnDel1.set $1

dUmnDel2.set $2

dUmnDel3.set $3

dUmnDel4.set $1

1 run d_UmnogInit

 

decval "dUmnDel2" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 0 'run dUmnDel3'

1 else_run 'incval "dUmnDel1" dUmnDel4, run d_UmnogRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_UmnogInit'

else_run '1 run d_UmnogInit'

 

run d_UmnDelDone

dUmnDel1.set -1

dUmnDel2.set $1

dUmnDel3.set $3

dUmnDel4.set $2

1 run d_DelenInit

 

incval "dUmnDel1" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 <= 0 'run dUmnDel3'

1 else_run 'decval "dUmnDel2" dUmnDel4, run d_DelenRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_DelenInit'

else_run '1 run d_DelenInit'

 

term d_UmnogInit

term d_UmnogRepeat

term d_DelenInit

term d_DelenRepeat

dUmnDel5.set 0

Hey i was close. i was only missing the top header part of the place.ui file.

Oh well you beat me to it jimbo, good team work. Mine works now as well thanks for your help abb. do i still need that Restart.exe file in the extension folder if i am not using the map changer?

Posted Jun 14, 2010 · 15:41 UTC#38
ok found that error, but now i am getting another error FFUIERROR: Unknown object identifier Identifier=[d_UmnDel1] Script"d_Delen" command 1. Anyway as an update add this into the place.ui file at the end to get rid of the last error i was getting. Now on to finding the next error:

;Common Multiplication and Division Function

run d_UmnDelDone

dUmnDel1.set $1

dUmnDel2.set $2

dUmnDel3.set $3

dUmnDel4.set $1

1 run d_UmnogInit

 

decval "dUmnDel2" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 0 'run dUmnDel3'

1 else_run 'incval "dUmnDel1" dUmnDel4, run d_UmnogRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_UmnogInit'

else_run '1 run d_UmnogInit'

 

run d_UmnDelDone

dUmnDel1.set -1

dUmnDel2.set $1

dUmnDel3.set $3

dUmnDel4.set $2

1 run d_DelenInit

 

incval "dUmnDel1" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 <= 0 'run dUmnDel3'

1 else_run 'decval "dUmnDel2" dUmnDel4, run d_DelenRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_DelenInit'

else_run '1 run d_DelenInit'

 

term d_UmnogInit

term d_UmnogRepeat

term d_DelenInit

term d_DelenRepeat

dUmnDel5.set 0

Hey i was close. i was only missing the top header part of the place.ui file.

Oh well you beat me to it jimbo, good team work. Mine works now as well thanks for your help abb. do i still need that Restart.exe file in the extension folder if i am not using the map changer?

 

I don't believe so. I think the restart.exe is for the map changer.

Jimbo

Posted Jun 15, 2010 · 05:08 UTC#39

Would you mind posting the steps/code needed to do this mod? It would be nice to have it all on one page.

 

Thanks! :D

Posted Jun 15, 2010 · 13:00 UTC#40
Would you mind posting the steps/code needed to do this mod? It would be nice to have it all on one page.

 

Thanks! :D

As Abb1 mentioned earlier, it took lots of work and time to make this work. What I did was I opened another data file that had the fuel calculation and map changer and did a search on all the scrips and bmp files and copied them over. This is how to make changes etc.

Read the comment from ABB1 about which ui files to search for. I will try to put steps together but I may miss a step or so.

Let me know if you need help.

Jimbo

Posted Jun 15, 2010 · 13:37 UTC#41
Would you mind posting the steps/code needed to do this mod? It would be nice to have it all on one page.

Thanks! :D

Here you go, I know how hard it is to read through the entire thread to piece together the mod, so hope this makes it easy for everyone:

1. You have to add the extension folder inside IGO folder in APL2 in the AVIC. There will be a FuelCalc Folder inside of the folder and you can download it from Abb1's mod.

There are three files inside

1. FuelCalc.ui; FuelCalc_800_480.ui and FuelCalc_var.ui.(I got this off the forum)

 

2. Then copy the half_patch_800_480.ui to 800_480/ui folder from Abb1 Mod

 

3. Then copy the half_patch.ui and half_patch_var.ui to common/ui folder.

 

4. Then copy over the Bmp File (bmp="z_sliderbar_bg_long.bmp" and "IDT_onmap_fuelcalc.bmp") also from ABB1 mod.

 

5. Then copy the script line (FuelCalc) to 800_480/ui/navigationmap.ui:

;FUEL CALC

.

 

6. Then Add these lines to the model_variables.ui:

;Half Patches

import "ui_pioneer/common/ui/half_patch_var.ui" and .

 

7. Then Add these lines to the top of the start 800_480 file:

;Half Patches

import "ui_pioneer/800_480/ui/half_patch_800_480.ui"

 

8. Then Add these lines to the end of the start.ui file:

;Half Patches

import "ui_pioneer/common/ui/half_patch.ui"

 

9. Then replace the header of the place.ui file with this:

 

10. Then add this to the bottom of the place.ui file:

;Common Multiplication and Division Function

run d_UmnDelDone

dUmnDel1.set $1

dUmnDel2.set $2

dUmnDel3.set $3

dUmnDel4.set $1

1 run d_UmnogInit

 

decval "dUmnDel2" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 0 'run dUmnDel3'

1 else_run 'incval "dUmnDel1" dUmnDel4, run d_UmnogRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_UmnogInit'

else_run '1 run d_UmnogInit'

 

run d_UmnDelDone

dUmnDel1.set -1

dUmnDel2.set $1

dUmnDel3.set $3

dUmnDel4.set $2

1 run d_DelenInit

 

incval "dUmnDel1" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 <= 0 'run dUmnDel3'

1 else_run 'decval "dUmnDel2" dUmnDel4, run d_DelenRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_DelenInit'

else_run '1 run d_DelenInit'

 

term d_UmnogInit

term d_UmnogRepeat

term d_DelenInit

term d_DelenRepeat

dUmnDel5.set 0

Posted Jun 15, 2010 · 21:12 UTC#42
Would you mind posting the steps/code needed to do this mod? It would be nice to have it all on one page.

Thanks! :D

Here you go, I know how hard it is to read through the entire thread to piece together the mod, so hope this makes it easy for everyone:

1. You have to add the extension folder inside IGO folder in APL2 in the AVIC. There will be a FuelCalc Folder inside of the folder and you can download it from Abb1's mod.

There are three files inside

1. FuelCalc.ui; FuelCalc_800_480.ui and FuelCalc_var.ui.(I got this off the forum)

 

2. Then copy the half_patch_800_480.ui to 800_480/ui folder from Abb1 Mod

 

3. Then copy the half_patch.ui and half_patch_var.ui to common/ui folder.

 

4. Then copy over the Bmp File (bmp="z_sliderbar_bg_long.bmp" and "IDT_onmap_fuelcalc.bmp") also from ABB1 mod.

 

5. Then copy the script line (FuelCalc) to 800_480/ui/navigationmap.ui:

;FUEL CALC

.

 

6. Then Add these lines to the model_variables.ui:

;Half Patches

import "ui_pioneer/common/ui/half_patch_var.ui" and .

 

7. Then Add these lines to the top of the start 800_480 file:

;Half Patches

import "ui_pioneer/800_480/ui/half_patch_800_480.ui"

 

8. Then Add these lines to the end of the start.ui file:

;Half Patches

import "ui_pioneer/common/ui/half_patch.ui"

 

9. Then replace the header of the place.ui file with this:

 

10. Then add this to the bottom of the place.ui file:

;Common Multiplication and Division Function

run d_UmnDelDone

dUmnDel1.set $1

dUmnDel2.set $2

dUmnDel3.set $3

dUmnDel4.set $1

1 run d_UmnogInit

 

decval "dUmnDel2" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 0 'run dUmnDel3'

1 else_run 'incval "dUmnDel1" dUmnDel4, run d_UmnogRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_UmnogInit'

else_run '1 run d_UmnogInit'

 

run d_UmnDelDone

dUmnDel1.set -1

dUmnDel2.set $1

dUmnDel3.set $3

dUmnDel4.set $2

1 run d_DelenInit

 

incval "dUmnDel1" 1

incval "dUmnDel5" 1

1 runif dUmnDel2 <= 0 'run dUmnDel3'

1 else_run 'decval "dUmnDel2" dUmnDel4, run d_DelenRepeat'

 

runif dUmnDel5 1000 'dUmnDel5.set 0, 30 run d_DelenInit'

else_run '1 run d_DelenInit'

 

term d_UmnogInit

term d_UmnogRepeat

term d_DelenInit

term d_DelenRepeat

dUmnDel5.set 0

 

Great Job!

I don't think I would have done this well!

Jimbo

Posted Jun 27, 2010 · 12:30 UTC#43

Nice team work guys.

Page 2 of 2