View unanswered posts | View active topics


Post a new topicPost a reply
Previous topic | Next topic 

  Beginner BeginnerMember since: 03.04.2011, 13:11Posts: 58Location: The Netherlands Likes: 2
 

 Post Topic: Re: Flyable aircraft
PostPosted 28.07.2011, 23:56 
It looks like aircraft's are getting popular!
viewtopic.php?f=280&t=70349

And I Love the new terrain. :D

  Uber Modder Uber ModderMember since: 11.08.2004, 12:38Posts: 2241 Likes: 61
 

 Post Topic: Re: Flyable aircraft
PostPosted 30.07.2011, 12:14 
Hi Jon,
Yes, the F-35 seems to be quite popular! I'll try to remember to give it the VTOL option for the next release.
I've got the terrain system down to a fine art. I can create a new area in around 30 minutes, including downloading the Google Earth textures. There are still some issues to fix (e.g. there are registration errors between the textures and terrain) but overall the results are excellent. I've just worked out a method for inserting higher resolution areas e.g. for airports.
I'm going to try to contact Google to see if I can get permission to release scenery that uses the textures. It may be possible for non-commercial applications such as this, but I'm not very optimistic. However, I could release the tools and documentation so interested people could make their own scenery.
I'll see if I can make a short video that shows some of the latest stuff in action.
All the best,
Chris
User avatar   Has no life Has no lifeMember since: 27.12.2007, 01:50Posts: 6478Location: Nottingham Likes: 4
 

 Post Topic: Re: Flyable aircraft
PostPosted 24.08.2011, 13:48 
Hi Chris, just following up on our discussion is there any plans or possibility of a release of the aircraft factory with the helicopter flight model included? Really interested to explore this further.
  Uber Modder Uber ModderMember since: 11.08.2004, 12:38Posts: 2241 Likes: 61
 

 Post Topic: Re: Flyable aircraft
PostPosted 26.08.2011, 12:21 
Hi Mark,
I'll reply to your PM here. If you prefer to continue via PM, then no problem.
I'll get a new release together in the next few days. I'm not sure if a CE3 version is possible at this stage.
The problem with the CE3 keyboard FG node is this: the key pressed output works just fine, but the key released output doesn't work. This means that direct keyboard commands will work (e.g. F for flaps, G for gear). But keyboard 'analog' applications (flight control and view panning) don't work, because the code has to know when the key has been released. I have made a workaround for this, but it's far from satisfactory.
For a relatively slow helicopter some of the large map problems (fog flickering, cockpit vibration, non-solid objects beyond the terrain area) may not be so severe. By the way, in CE3 standard terrain can be up to 64 km across (compared to 8 km in CE2).
The main problem is that the code uses several addon flowgraph nodes. Right now I'm not even sure whether addon nodes can be used in CE3 - does anyone know?
So, overall I'm not sure if a CE3 release is practical at this time. But I will see if those problems can be fixed.
.
Yes, the code allows a separate model for a detailed cockpit. I use the term 'virtual cockpit' as used by Microsoft Flight Simulator. You can define two separate VC models e.g. the cockpit and passenger cabin, as in the Constellation. There are three classes of objects supported:
1. External model, visible only when in an external view mode such as flypast.
2. Objects which are always visible, e.g. the wings and engines which are visible from the interior (passenger cabin) and also visible in external view modes.
3. The virtual cockpit itself, visible only when player is in the cockpit.
Earlier this year I added a new class of objects to support the ships code. By writing a simple script you can define objects which are visible depending on whether the player is inside or outside a defined rectangular volume. This could replace the virtual cockpit system. It also allows you to define low poly models which are visible at a large distance (in other words, a LOD system).
.
Yes, the code supports clickable panel controls. In the Connie, hit F4 and you will see a cursor. Move the cursor onto a panel switch or lever and click to activate. In the Connie the clickable controls control the gear, flaps and lights. Currently AF supports 12 clickable controls (and indicators) but this could easily be increased by adding a script option. Currently the startup procedure is very simple (basically, switch on the engines and go) but it would be easy to create more complex aircraft systems with Lua that would require more complex startup procedures.
I was very impressed by your ARMA 2 youtube video:
http://www.youtube.com/watch?v=flgB2APES2c
Am I right in thinking that ARMA has quite a lot of native support for aircraft e.g. gauges and MFD's? Currently I'm not sure how to produce MFD's in CryEngine, though it's something I would need for, say, a modern airliner such as a 747. I'd be very interested in knowing how you implemented those displays.
My gauges are based on objects which are moved and rotated (in this case the gauge needle). Lua can move and rotate objects very easily, by means of 'slots'. Slots are identified by a number starting at one and going up to tens of thousands. To move an object you use e.g.
local pos={x=self.x, y=self.y, z=self.z}; -- self.x etc are x,y,z position, n is the slot number
self:SetSlotPos(n, pos);
To set the angles:
local angles = {x=self.AngleX, y=self.AngleY, z=self.AngleZ};
self:SetSlotAngles(n, angles);
Slot positions and angles are local with respect to the entity (in this case the aircraft) so it's ideal for gauges etc.
.
The main problem right now is to decide whether to go with CE2 or CE3. I'll look into that in the next few days.
All the best,
Chris

***************************************************
Here's a video that shows some Battle of Britain action and the new photorealistic terrain (70 Mb, 4 minutes).
http://dl.dropbox.com/u/4380128/Aircraft11_short.avi
User avatar   Has no life Has no lifeMember since: 27.12.2007, 01:50Posts: 6478Location: Nottingham Likes: 4
 

 Post Topic: Re: Flyable aircraft
PostPosted 26.08.2011, 12:53 
Hi Chris many thanks for replying again. The new release sounds fantastic, I actually found a tutorial for helicopter flight modeling in Unity engine and taking a look through the code explained quite a lot even thought it was in Javascript, however having your lua system in-place to get a good understanding of how this would work would be fantastic. Is sad to hear about the input node being bugged in this way, I am quite supprised it released like this, hopefully it may be fixable or somebody in the community could rectify it. I am not sure if the flownodes C++ was released with the free SDK but if it is it could be quite easily fixed, I think for now I will attempt to get this going in CE2 then port when things are ready, luckily CE3 SDK supports things like a mouse input node natively without the need for the FGPS.

Thats very promising news on the virtual cockpit model as the normal vehicle system does not allow for this, also in all honesty the helicopter handling is very basic in the C++ version so approaching this with lua instead of trying to use the vehicle system should be very flexible. I have been testing your original aircraft release in more detail since opening up this discussion and have been finding out quite how deep you have managed to take this, is very impressive. I am also impressed with the weapon system, more specificially things such as your tracer code which literally is viewable for MILES which is very promising for what i had in mind, not to mention gravitational drop etc.

The ARMA/2 gauge system is very simple to be honest, this is why the majority of ARMA/2 vehicles have very simple cockpit designs. The engine has a selection of values which you can access, things like speed, ASL, banking angle, attack angle, attitude etc. These values are then used to simply animate geometry, exactly as you have been doing with your aircraft. I am very happy to see your gauges working in this manner. The MFD system I developed is a mixture of a couple of things. The bootup screen system is a single geometry with different textures being applied to it to appear animated, something which can be done in CE2 with flowgraph so I am sure LUA is again able to do that. The second thing is animated geometry again. For example on the left side is the attitude indicator, which is animated by 2 values from the engine, the right side is a compass (again animated by the engine) but it also features two waypoint systems, the firt is an airport waypoint marker, this picks up the location of the airport on the map you are playing and rotates around the outside of the compass to point towards it at all times, the second is a manual waypoint system which allows the player to place a waypoint on the map and this again rotates to point towards the waypoint at all times. I created a seperate script for this system which I am %100 sure would be doable in LUA also. Its just all rotation/translations based on basic engine values (or calculated via newly created scripts (the F117A has about 21 ingame accurate displays/gauges and about %40 of them are driven by data from scripts I created as opposed to standard engine values) which as you stated LUA is quite capable of, even if all these values need to be calculated by hand (I see your AGL system basically raycasts downwards to determin AboveGroundLevel altitude). I mean even parts of the HUD on the F117A are created in the same manner, the ladder etc is just a VERY long tall plane with an alpha texture which is translated and rotated from engine values, I was hoping to possibly be able to use the same system if scaleform was not possible for a custom LUA vehicle but ARMA2 uses a special Z-depth texture setting which allows you to make an invisible mask for HUD elements stacked behind each other, so im not sure if i will be able to use this method in CE2.

To have a truly functioning MFD as in "actual" multiple display screens inside a single box you can simply stack these system inside the MFD geometry and hide them via a single plane geometry inbetween each system, switching the plane/top MFD screen to an alpha texture. This allows you to stack displays ontop of each other and basically just make them seethrough to be able to see the one below it, with some thought and planning you could easily have as many screens as you could physically fit geometry into your MFD geometry box. Basically if you can change textures using LUA then you can do this, if not you would have to resort to just a single display on each MFD box. Just as a side not about switching textures I believe i remember seeing your gear up/down light turn on/off on one of your aircraft which would seem to indicated texture switching in LUA is possible ?

Anyway many thanks for replying again, I will be finishing up this model in the meantime so am very much looking forward to testing it out with the AF with the helo code when you get time to release. The battle of britain video looks fantastic! Your terrain system is outstanding.
  Beginner BeginnerMember since: 03.04.2011, 13:11Posts: 58Location: The Netherlands Likes: 2
 

 Post Topic: Re: Flyable aircraft
PostPosted 26.08.2011, 17:04 
Sounds very nice!
So there are some problems on CE#. I dodn't expect that with the improved editor. But I have to say that CE2 also works like an charm. Chris did a good job on fixing most of the problems with the CE2 limits.
Look on this vid: http://www.youtube.com/watch?v=hjYct6uvG1A
It's probably trackview, but it still looks amazing compared to CE3. At least that's what I think. :P

I'm looking forward for the new update Chris. Good luck with making an decision between the two CE versions.
  Uber Modder Uber ModderMember since: 11.08.2004, 12:38Posts: 2241 Likes: 61
 

 Post Topic: Re: Flyable aircraft
PostPosted 27.08.2011, 13:49 
@Fortran
Hi Mark,
Thanks very much for the explanation re MFD's in ARMA. I think it should be possible to create an equivalent in CE3. In fact I think Crysis 2 did have some quite good animated screen displays.
But, for text displays, I would like to be able to put up any text depending on the situation, rather than a set of pre-made text strings. I think there are some functions that allow you to place text in 3 dimensions, I'll take another look at that. As for the other MFD functions, I think similar methods could be made to work in CE. I would like to do a modern jet liner at some stage, so working MFD's will be essential.
The panel indicator lamps are actually objects with luminous textures placed in slots. I use self:DrawSlot(n,1); or self:DrawSlot(n,0); to show or hide the object.
You can place other kinds of objects in slots, including effects and clouds. My recent Weather entity places clouds in slots, and I place effects in slots for e.g. ship wakes and jet exhaust effects.
By the way, Crytek just released some CE3 assets including the BlackHawk. It looks very nice in Sandbox3. They provide the max file, but I use Softimage, so I'll be looking for a way to import it into Softimage. It would make a *very* nice flyable helicopter!
.
I'll get a CE2 AF release ready in, hopefully, a couple of days. Then, in maybe a couple of weeks I'll be able to release a CE3 version. Probably the main CE3 problems relate to flow graph nodes. The code would include a (rather crude, but usable) fix for the keyboard node bug.
You could use AF to update the aircraft code in the 2010 release (AF includes all the aircraft project files). For compatability you would need to make a small change in the map and also load the new aircraft flow graph.
You probably noticed some annoying problems associated with mouse control, for exampl when using the mouse to pan the view it would stop moving and you could only pan back the other way. That's because the Mouse plugin (made by James-Ryan) actually returns the mouse cursor x,y positions. When the cursor reaches the edge of the screen it stops updating.
Fortunately murcocr has kindly made two new FG nodes that solve this problem (in a thread not a million miles from here). With the new code and flow graph, you can now pan the view without restriction and it also brings a major improvement to mouse flight control and some other functions.
.
The tracer code has quite an unusual method. I was a huge fan of IL-2, but the tracer had a *big* problem. The tracer model was good. But, when viewing your own tracer from the cockpit, it quickly vanished. A fraction of a second after firing, the tracer is so small so that it's smaller than a single pixel. It flickers and then vanishes, so you simply couldn't follow its path all the way to the target.
With this in mind, I wanted a solution that gives tracer visibility over a long distance, as in the real world. Each tracer is a separate entity e.g. cannon_shell.lua
It calculates the distance from the player and actually makes the tracer object larger as the distance increases. This explains the large visibility distance. When you fire tracer at another aircraft, you really can follow each tracer as it flies through space (it falls under gravity but doesn't currently calculate atmospheric friction). There are probably very few commercial games, if any, including Crysis, that allow this.
.
Thanks for the comments about the video. I actually have some video card problems and, together with FRAPS, video frame rates/smoothness aren't brilliant. I plan on getting a new PC any time now, so, assuming videos are smoother etc I'll probably make a set of youtube videos.
.
Anyway, I should have the new AF CE2 release ready early next week.
All the best,
Chris

@Blinkin
Hi Jon,
It is a bit disappointing that CE3 still has the fundamental CE2 problems (e.g. cockpit vibration and fog flickering) and that the programmers have thoughtfully added some new problems for no valid reason whatsoever. But I am in contact with Crytek and there is a chance the problems will be fixed eventually.
Nice video! My code currently has no damage modelling but it wouldn't be too difficult to add....
Unfortunately the next release will be delayed a bit, probably October or November. I hope it will be worth the wait!
All the best,
Chris
  Beginner BeginnerMember since: 03.04.2011, 13:11Posts: 58Location: The Netherlands Likes: 2
 

 Post Topic: Re: Flyable aircraft
PostPosted 27.08.2011, 19:37 
Quote by cwright:
and that the programmers have thoughtfully added some new problems for no valid reason whatsoever.
Lol funniest comment I've seen in months. x'D

So you're in contact with Crytek? Interesting, I hope they can fix it (not only for your project).
I understand it's delayed, and it no problem. It's your project, I love the work you've put into it.
I'll keep an eye on this topic. If you ever need some photographs... :P

All the best,
Jon
User avatar   Has no life Has no lifeMember since: 27.12.2007, 01:50Posts: 6478Location: Nottingham Likes: 4
 

 Post Topic: Re: Flyable aircraft
PostPosted 28.08.2011, 01:18 
Ah fantastic news Chris, will be very much looking forward to that, I have decided to stay based in CE2 for the time being until I have a working prototype which I then might port to CE3 SDK. The method for the tracers is very interesting and as I mentioned before producers vastly superior results so great job with that!

The blackhawk is actually included in the asset pack which came out today (see front page) so making a lua version of that would be great too :) I have actually nearly finished modeling the apache I have been working on. You can see a couple of shots of it here > viewtopic.php?p=836927#p836927 this is what I will be basing the project around.

I also found the thread you were talking about with the nodes released by murcor which is great, I can also see some use for them while invisioning further developments in regards to the weapon systems I wish to implement etc. so great news that they have also been of such great help with the functionality of your turrets/flight models.

Anyway thanks again Chris, really looking forward to getting this model up in the air, will get a test version exported to code/develop with while I get the dreaded task of Uv'ing and texturing this thing done.
  Uber Modder Uber ModderMember since: 11.08.2004, 12:38Posts: 2241 Likes: 61
 

 Post Topic: Re: Flyable aircraft
PostPosted 29.08.2011, 11:07 
@Blinkin
Hi Jon,
Thanks for the offer! I would love to do a DC-3 and I see there is one at Aviodrome, also in KLM colours. A top priority would be really clear close-ups of the pilot's panel that shows the gauge artwork etc. Maybe in a few months....
Chris

@Fortran
Hi Mark,
I think it should be possible to make the Lua aircraft code identical for CE2 and CE3, the only difference would be the flow graph. The code could read the flow graph so it knows which CE version it's running on.
I also use the same method for the aircraft navigation lights as for the tracer, so the lights are also visible at large distance. And also for the Lights entity, which you can use to lay down large numbers of lights on the ground e.g. city and runway lights.
Your Apache model looks absolutely fantastic! Don't worry about too many polygons, the code allows you to set up lower polygon models for distance viewing. I can't wait to see it textured!
I'll try to get AF ready for release on Wednesday.
All the best,
Chris
User avatar   Has no life Has no lifeMember since: 27.12.2007, 01:50Posts: 6478Location: Nottingham Likes: 4
 

 Post Topic: Re: Flyable aircraft
PostPosted 29.08.2011, 13:05 
Fantastic news Chris, will be looking forward to it! There are some extra bits and pieces that might keep me on CE2 for the timebeing namely Blue's render to texture system which I will be implementing in the apache MFD's and hopefully on the HMD. Been spending the weekend trying to work out how to implement a selection of the apaches well known sensor and targeting systems even down to doing LOAL and LOBL for the hellfires and dynamic loading of the wing struts etc. I believe most of them are quite achievable in a combination of LUA and some extended functionality from the FGPS. Anyway many thanks again for the AF release, cant wait to see her fly :)
User avatar   Superstar Dolphin Superstar DolphinMember since: 16.08.2004, 10:46Posts: 9869Location: Finland Likes: 176
 

 Post Topic: Re: Flyable aircraft
PostPosted 29.08.2011, 13:22 
Chris: The CE3 documentation details the process of rendering Flash UI elements on surfaces: http://freesdk.crydev.net/display/SDKDO ... c+Textures

If Scaleform support is added in the future this would be an elegant way of adding displays in the cockpit. ;) Seems promising since the documentation is intact.

Additionally, there's documentation on rendering TrueType text on screen: http://freesdk.crydev.net/display/SDKDO ... +Rendering

I'm not sure if this can be applied on 3D surfaces though. It appears to be merely for displaying 2D text on the screen.

Keep on working, this must be the most impressive mod project to date and I'd love to see it on Cryengine 3. :)
  Uber Modder Uber ModderMember since: 11.08.2004, 12:38Posts: 2241 Likes: 61
 

 Post Topic: Re: Flyable aircraft
PostPosted 31.08.2011, 11:35 
@Fortran
Hi Mark,
I'll be very interested to see what you come up with re MFD's!
.
Sadly murdocr has confirmed that currently it's not possible to make addon FG nodes for CE3. Hopefully someone will step in to create a CE3 equivalent of the addon system. I'm really surprised Crytek didn't build in an addon system as standard.
.
There is one positive note. The latest CE3 versions (including 3.3.5 used by the free SDK) has two useful new FG nodes provided as standard. One appears to be identical to James-Ryan's Mouse node, which is essential for the aircraft code. In addition there is a new Camera node that actually works! It has inputs to enable/disable the specified camera view and the FOV control also works. This makes the creation of new camera views very easy and is ideal for my aircraft code.
.
I've updated the AF manual. I need to do a few more things so it'll probably be tomorrow (Thursday). I'll include my Blackhawk test aircraft that uses a simple model. You could get that flying easily and then use the AF Black hawk project as a template for your own design. I'll also include a new mod already set up with murdocr's new FG nodes.
.
The code has a brand new feature: full aircraft operations on moving carriers. Actually, after working on the ships code earlier this year, I did make some aircraft code for carrier operations but it didn't work very well and didn't work at all for AI aircraft. The new method works very well, though there are still some minor issues. It allows you to taxi, take off and land naturally on moving carriers (both forward speed and ship pitching/rolling). In addition the waypoint system now works in this mode - when the aircraft is taxiing you specify local carrier coordinates rather than world coordinates.
In one of the old demo maps there were a bunch of B-25's that taxied on the carrier and then took off. Of course, the carrier was static. In the new demo, there'll be something similar - but the carrier will be going at 30 knots and also pitching and rolling.
Today I'll test the helicopter with HMS Westminster. It should be possible to take of/land on the rear deck with the ship under way.
All the best,
Chris

@the_grim,
Many thanks, that's very interesting. I don't know much about this stuff so I have some learning to do - until yesterday I didn't even know what scaleform was!
.
I'll see if I can get that projection method in your first link working. If I could then get it working in an aircraft that would be pretty neat!
Many thanks for the encouragement.
All the best,
Chris
User avatar   Has no life Has no lifeMember since: 27.12.2007, 01:50Posts: 6478Location: Nottingham Likes: 4
 

 Post Topic: Re: Flyable aircraft
PostPosted 31.08.2011, 12:00 
That sounds fantastic Chris, the moving carrier code sounds amazing, will be great to be able to utilize it as a proper base of operation! As for the blackhawk that will be very handy also as I have stopped modelling for a short while and moved over to HUD/MFD prototyping which is going very well indeed. With a mixture of HUD:Flash / Entity:FlashInvoke flowgraph nodes, some flash Actionscript, some bone setups in 3D and finally some LUA values to drive the whole thing I am getting very close to realizing a quite competent MFD system. I have even discovered I could sub out the Flashinvoke FG section of the system and do it purely in LUA with the MaterialFlashInvoke function

Code:
self.display:MaterialFlashInvoke(0, 0, 0, "displayInfo", i, date);


The only minor problem at present is that texture based flash (as opposed to screen based such as the HUD/Menu systems) will not allow FS commands to be sent, which means I can (presently) send data to the texture on the MFD, I can click buttons on the MFD (eg Change screens) and have them do things, however I cannot get any data back out of the MFD into LUA/Flowgraph.

In itself its not "such" a big deal unless you were going for a fully clickable pit but it would be nice to utilize changes in the MFD to operate other systems outside of the MFD. So far I have managed to put a compass and pitchladder/Bank indicator MFD screen together which visually displays all 3 pieces of data in realtime. Also I have already worked out a HUD system (will post a screen in a minute). This is simply driven by a new LUA entity with FG support outputting data into a HUD:Flash node from the FGPS and works great, there is really no limit to which data that can be ouputted to the screen via this setup. Once I have worked out the best method for each and created a full prototype of the combined system I will do a writeup on the method for it so you can implement them in any more modern aircraft you might be bringing into the engine.

Anyway many thanks again, really looking forward to the release!
  Uber Modder Uber ModderMember since: 11.08.2004, 12:38Posts: 2241 Likes: 61
 

 Post Topic: Re: Flyable aircraft
PostPosted 31.08.2011, 12:07 
Hi Mark,
Just one quick comment: WOW!
Chris