Board index FlightGear Development New features

AI & MP Dogfighting now working! Bombable ships, aircraft...

Discussion and requests for new features. Please note that FlightGear developers are volunteers and may or may not be able to consider these requests.

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Philosopher » Fri Jul 26, 2013 1:25 pm

Well given that the rest of Nasal works, Bombable should be relatively fine... Could you post the debug log level (within [code] tags, just click on the code button in the forum editing window and paste the text between that)? I mean, there are a number of ways to crash FG from Nasal, but those would crash it on startup.... (since they're related to syntax) Hooray, do you know of any runtime crashers? I'll look at the code later today, see if anything looks interesting...
Philosopher
 
Posts: 1593
Joined: Sun Aug 12, 2012 7:29 pm

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Hooray » Fri Jul 26, 2013 1:43 pm

Bombable is all just Nasal code, so platform-independent - it runs on all platforms supported by FG, so if FG works, Nasal works, too - if Nasal works, Bombable should work, too.
I don't think the bombable code has recently been modified, so if there really is a crash, it is almost certainly related to changes in the underlying C++ code, we need to keep in mind that bombable also uses some custom shaders/effects IIRC - so it is possible that the culprit is outside Nasal space.

An error like "A problem caused the program to stop working correctly." can be easily triggered without even going into Nasal scripting space, just by using the wrong combination of startup settings - FG is extremely dumb here, and allows users to select incompatible settings and then happily crashes afterwards - likewise, XML-tags are rarely, if ever, properly validated - so that it is really easy to crash FG by using a valid XML file that merely happens to exploit weaknesses in the underlying C++ code.

So if there aren't any Nasal parse/runtime errors, it's pretty safe to say that the bombable code itself shouldn't be the culprit here - but there are tons of additional files, like modified aircraft, scenarios that are loaded, too - and some of these are known to have caused issues in the past, mostly due to FG's development focus not really being on backwards compatibility - so if others can confirm this, it just seems that 2.12 has introduced issues that need changes to the bombable addon to restore compatibility again - flug has done this type of maintenance work in the past, so ideally we should just be collecting sufficient info for him to troubleshoot it further and track down the issue.
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby housefatherof6 » Fri Jul 26, 2013 4:43 pm

Philosopher wrote in Fri Jul 26, 2013 1:25 pm:Well given that the rest of Nasal works, Bombable should be relatively fine... Could you post the debug log level (within code tags, just click on the code button in the forum editing window and paste the text between that)? I mean, there are a number of ways to crash FG from Nasal, but those would crash it on startup.... (since they're related to syntax) Hooray, do you know of any runtime crashers? I'll look at the code later today, see if anything looks interesting...


Code: Select all
1 - 'C:\FlightGear\terrasync'
C:\FlightGear\bin\Win32\terrasync.exe -S -d "C:\FlightGear\terrasync" -p 5505
Starting automatic scenery download/synchronization. Using built-in SVN support.
 Directory: 'C:\FlightGear\terrasync'.
Enabling ATI viewport hack
Could not find at least one of the following objects for animation: 'constructio
n'
Could not find at least one of the following objects for animation: 'constructio
n'
Bombable (ver. 4.5) loaded - bombable, weapons, damage, fire, and explosion effe
cts
loading scenario 'nimitz_demo'
loading scenario 'BOMB-MarinCountyCamelInvasion1-Simple'
Valid position data received. Connected successfully.
Loading Fokker DR 1 /ai/models/aircraft
Could not find at least one of the following objects for animation: 'constructio
n'
Could not find at least one of the following objects for animation: 'constructio
n'
Could not find at least one of the following objects for animation: 'chocks'
Texture file not found: 'glass_shader.png'
Loading Sopwith Camel /ai/models/aircraft[1]
Initializing Camel utilities ...
pilot-g
headshake
magneto
smoke
... running Camel utilities
Nasal runtime error: props.setValue() passed a NaN
  at C:/FlightGear/data/Nasal/props.nas, line 29
  called from: C:/FlightGear/data/Aircraft/sopwithCamel-Bombable/Models/fuel.nas
, line 130
Loading S.P.A.D. VII /ai/models/aircraft[2]
Gun vibrations initialized
osgDB ac3d reader: detected line with less than 2 vertices!
osgDB ac3d reader: detected line with less than 2 vertices!
housefatherof6
 
Posts: 48
Joined: Tue Mar 26, 2013 4:12 pm
Location: Kansas USA
Callsign: jayhawk
Version: 3.0.0
OS: Ubuntu 14.4 LTS

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby housefatherof6 » Fri Jul 26, 2013 4:46 pm

Also to let you know before opening the splash screen FG crash with the same error.
housefatherof6
 
Posts: 48
Joined: Tue Mar 26, 2013 4:12 pm
Location: Kansas USA
Callsign: jayhawk
Version: 3.0.0
OS: Ubuntu 14.4 LTS

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Hooray » Fri Jul 26, 2013 4:47 pm

C:/FlightGear/data/Aircraft/sopwithCamel-Bombable/Models/fuel.nas
, line 130


probably needs "or 0.00" defaulting here https://github.com/bhugh/Bombable/blob/ ... l.nas#L130

Replace line 130:
Code: Select all
t.getNode("level-gal_us").setValue(t.getNode("level-lbs").getValue() / ppg);


and use this instead:

Code: Select all
t.getNode("level-gal_us").setValue(t.getNode("level-lbs").getValue() or 0.00 / ppg);


if that gives a parse error, split up the line or introduce a temporary
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Philosopher » Fri Jul 26, 2013 4:55 pm

Rather:
Code: Select all
t.getNode("level-gal_us").setValue((t.getNode("level-lbs").getValue() or 0.00) / ppg);
Philosopher
 
Posts: 1593
Joined: Sun Aug 12, 2012 7:29 pm

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Hooray » Fri Jul 26, 2013 5:06 pm

yeah, in case of doubt, better listen to him, I usually have no clue and just talk out of my ... without actually testing what I post! :D
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby housefatherof6 » Fri Jul 26, 2013 6:41 pm

Philosopher wrote in Fri Jul 26, 2013 4:55 pm:Rather:
Code: Select all
t.getNode("level-gal_us").setValue((t.getNode("level-lbs").getValue() or 0.00) / ppg);


Try to edit with note pad and didn't seem to take the edit. I probably doing something wrong in the editing. Any advice. Looks like I'll have reinstall bombable again since I miss up the edit.
Thanks
housefatherof6
 
Posts: 48
Joined: Tue Mar 26, 2013 4:12 pm
Location: Kansas USA
Callsign: jayhawk
Version: 3.0.0
OS: Ubuntu 14.4 LTS

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Philosopher » Fri Jul 26, 2013 6:59 pm

Sorry, I forgot to say that this is not causing the crash (though it is an error, passing nil does not trigger a crash, especially due to the fact that a warning message is getting printed). But that log doesn't look like --log-level=debug to me.
Philosopher
 
Posts: 1593
Joined: Sun Aug 12, 2012 7:29 pm

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby housefatherof6 » Fri Jul 26, 2013 7:46 pm

That's okay Philosopher, I should have realized that myself.
The interesting thing is that when I delete the bombable.nas file, FG returns back to normal with no errors or crashes.
I even tried some tweaking FG settings before deleting bombable.nas too see if any of my settings were too high and still crashes. It's got me scratching me head.

I saw osjcag you tube review and flug you tube videos and thought it be a nice addition to FG.
housefatherof6
 
Posts: 48
Joined: Tue Mar 26, 2013 4:12 pm
Location: Kansas USA
Callsign: jayhawk
Version: 3.0.0
OS: Ubuntu 14.4 LTS

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Hooray » Fri Jul 26, 2013 8:11 pm

indeed, it IS a nice addition to FlightGear - however, it was never accepted for inclusion into the main project, so that it is still a separate "addon", despite the fact that it clearly is more mature than most scripts and aircraft we have in FG - so, as a platform, FG is a moving target - and the bombable addon not being actively maintained currently means that you may have to wait for a while for flug (its developer) to return (probably some time after the 2.12 release) and restore compatibility again.

It would be helpful if you could file a bug report at: https://github.com/bhugh/Bombable

From a troubleshooting perspective, you could set bombable's debug flag to 1, and post the output again: /bombable/menusettings/debug
You can do this either directly via the property browser, via the Nasal console, via fgrun or just by adding this to your startup arguments:

--prop:/bombable/menusettings/debug=1

This will enable lots of debugging info and tell us where bombable stops working
For fellow Nasal-troubleshooters: https://github.com/bhugh/Bombable/blob/ ... le.nas#L83
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby housefatherof6 » Sat Jul 27, 2013 5:46 am

Not one to give up, I installed 2.8 forcing 32bit on 64 bit. Ran 2.8 as usual with no bombable addon. After finding 2.8 work as 32bit with no errors or crashing, I added bombable to it and it work :D
No errors No crashes work great, with fingers crossed.

Although I have to wait until flug returns and restore the compatibility again, I can it least use 2.8 for bombable and switch to 2.10.3 for just using FG.

I'll use the bombable's debug flag to 1 on 2.10.3, and post the output again for Hooray and Philosopher tomorrow Sat.

Have question on reporting the bug https://github.com/bhugh/Bombable went up there to take look. Do I need to sign up to report the bug? and 2. Do I post the debug you suggested Hooray as issue? and what else do need include in the bug report?

Thanks to both Hooray and Philosopher for your help :)
housefatherof6
 
Posts: 48
Joined: Tue Mar 26, 2013 4:12 pm
Location: Kansas USA
Callsign: jayhawk
Version: 3.0.0
OS: Ubuntu 14.4 LTS

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Hooray » Sat Jul 27, 2013 12:41 pm

ya, just use the issue tracker - I only just remembered that flug gave me commit permissions to the bombable github project, so if you can provide some more info, I can try to reproduce it here, and maybe with some help from Philosopher, come up with a fix - but for anything beyond just Nasal stuff, I'm afraid, flug is the best person to speak to - while I can probably make sense of his Nasal code, I know nothing about all the other components that he's combined there...
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby housefatherof6 » Sun Jul 28, 2013 12:41 am

Horray and Philosopher, Not sure what the heck happen put bombable on 2.10 and it work without errors or crashing. The only thing I can think that may have happen was the I didn't get clean download on the 1st two zip files of bombable. The 3rd download zip one was done the other day just to make sure I had clean download when installed bombable on 2.8. Has me completely surprise and embarrassed. Not sure if you want the log but I'll put up here anyway just in case. Note: that I exited and then went in for second shot with a different scenario and different plane knowing that had crashed before the splash page when I first put bombable on 2.10, it work without crashing this time too :)

Code: Select all
1 - 'C:\FlightGear\terrasync'
C:\FlightGear\bin\Win32\terrasync.exe -S -d "C:\FlightGear\terrasync" -p 5505
Enabling ATI viewport hack
Starting automatic scenery download/synchronization. Using built-in SVN support.
 Directory: 'C:\FlightGear\terrasync'.
Could not find at least one of the following objects for animation: 'constructio
n'
Could not find at least one of the following objects for animation: 'constructio
n'
 Bombable: Initializing variables. (Line #8292 8472 )
 Updating main weapon power combo . . .  (Line #1825 100 )
 Updating ai weapon power combo . . .  (Line #1849 100 )
 Updating ai aircraft skill combo . . .  (Line #1882 100 )
 Updating main weapon power combo . . .  (Line #1825 100 )
 Updating ai weapon power combo . . .  (Line #1849 100 )
 Updating ai aircraft skill combo . . .  (Line #1882 100 )
 Bombable: ioreading . . .  (Line #1988 8316 8472 )
 Updating main weapon power combo . . .  (Line #1825 100 )
 Updating ai weapon power combo . . .  (Line #1849 100 )
 Updating ai aircraft skill combo . . .  (Line #1882 100 )
Bombable (ver. 4.5) loaded - bombable, weapons, damage, fire, and explosion effe
cts
loading scenario 'nimitz_demo'
loading scenario 'BOMB-MarinCountyCamelInvasion1-Simple'
Valid position data received. Connected successfully.
Loading Fokker DR 1 /ai/models/aircraft
Could not find at least one of the following objects for animation: 'constructio
n'
Could not find at least one of the following objects for animation: 'constructio
n'
Could not find at least one of the following objects for animation: 'chocks'
Texture file not found: 'glass_shader.png'
Loading Sopwith Camel /ai/models/aircraft[1]
Initializing Camel utilities ...
pilot-g
headshake
magneto
smoke
... running Camel utilities
Nasal runtime error: props.setValue() passed a NaN
  at C:/FlightGear/data/Nasal/props.nas, line 29
  called from: C:/FlightGear/data/Aircraft/sopwithCamel-Bombable/Models/fuel.nas
, line 130
Loading S.P.A.D. VII /ai/models/aircraft[2]
Gun vibrations initialized
Error in ground network. Failed to find first waypoint: 0 at KSMF
osgDB ac3d reader: detected line with less than 2 vertices!
Enabling ATI viewport hack
osgDB ac3d reader: detected line with less than 2 vertices!
 Bombable: Initializing variables. (Line #8292 8472 )
 Updating main weapon power combo . . .  (Line #1825 100 )
 Updating ai weapon power combo . . .  (Line #1849 100 )
 Updating ai aircraft skill combo . . .  (Line #1882 100 )
 Updating main weapon power combo . . .  (Line #1825 100 )
 Updating ai weapon power combo . . .  (Line #1849 100 )
 Updating ai aircraft skill combo . . .  (Line #1882 100 )
 Bombable: ioreading . . .  (Line #1988 8316 8472 )
 Updating main weapon power combo . . .  (Line #1825 100 )
 Updating ai weapon power combo . . .  (Line #1849 100 )
 Updating ai aircraft skill combo . . .  (Line #1882 100 )
Bombable (ver. 4.5) loaded - bombable, weapons, damage, fire, and explosion effe
cts
Cannot find Nasal script 'Aircraft/F4U/Nasal/weapons.nas' for module 'weapons'.
loading scenario 'nimitz_demo'
loading scenario 'BOMB-SanFranBayFerryInvasion'
Could not find at least one of the following objects for animation: 'terminal_2'

Could not find at least one of the following objects for animation: 'terminal_2'

Electrical  ---Check
Loading ferry /ai/models/ship
Loading ferry /ai/models/ship[1]
Loading ferry /ai/models/ship[2]
Loading ferry /ai/models/ship[3]
Loading ferry /ai/models/ship[4]
Error in ground network. Failed to find first waypoint: 0 at KSMF
Error in ground network. Failed to find first waypoint: 0 at KSMF
housefatherof6
 
Posts: 48
Joined: Tue Mar 26, 2013 4:12 pm
Location: Kansas USA
Callsign: jayhawk
Version: 3.0.0
OS: Ubuntu 14.4 LTS

Re: AI & MP Dogfighting now working! Bombable ships, aircraf

Postby Hooray » Sun Jul 28, 2013 1:10 am

great news, but would it possibly happen to work only in debug mode, i.e. after your set the --prop: parameter (which you apparently succeeded doing, according to the log you provided now) ?
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

PreviousNext

Return to New features

Who is online

Users browsing this forum: No registered users and 5 guests