Hard Light Productions Forums

General FreeSpace => FreeSpace Discussion => Topic started by: JustinOhio on August 19, 2016, 02:23:13 pm

Title: Tie Fighter?
Post by: JustinOhio on August 19, 2016, 02:23:13 pm
One of my favorite games besides the FS series was Tie Fighter.  This may have been discussed before but, is there a way to possibly port that whole thing over to this engine? Have there been any efforts to re-create that great game as well?  Maybe there's a project already that's been done that I'm unaware of? 
Title: Re: Tie Fighter?
Post by: z64555 on August 19, 2016, 03:10:47 pm
There is a total conversion mod by the name of Fate of the Galaxy (http://www.hard-light.net/forums/index.php?board=143.0) that is set in the Star Wars universe.
Title: Re: Tie Fighter?
Post by: AdmiralRalwood on August 19, 2016, 05:24:49 pm
Additionally, someone was working on a project to parse TIE Fighter missions and at least partially convert them (automatically) into .fs2 missions to be used with FSO; I don't recall if anything was ever released from that, though.
Title: Re: Tie Fighter?
Post by: niffiwan on August 19, 2016, 06:12:08 pm
That was me, and I haven't released anything yet.  I can convert the 1st battle 1st mission to FSO format and it's playable, but not all the ships have the correct orders yet. I'll get back to this one day :)  (I need to find a good balance between automatically converting everything & requiring a FREDer to tweak/update the missions)
Title: Re: Tie Fighter?
Post by: JustinOhio on August 20, 2016, 08:50:58 am
Would be sweet to play the original game on this new engine!  I wish I knew enough to help.
Title: Re: Tie Fighter?
Post by: Goober5000 on August 22, 2016, 12:14:27 am
(I need to find a good balance between automatically converting everything & requiring a FREDer to tweak/update the missions)

Eh?  Tweaking/updating is probably going to be required regardless, but I don't think you'd gain anything by requiring any sort of manual conversion.  Convert everything automatically and then the FREDder can adjust it as needed.
Title: Re: Tie Fighter?
Post by: niffiwan on August 22, 2016, 12:33:56 am
I wasn't thinking of requiring manual conversion, it was more about how to translate all the TIE fighter orders into FSO orders, where there's a lot of TIE fighter orders with no direct equivalent in FSO (e.g. attack ship class X, and there's more than 5 wings of that ship class in the mission, and anyway FSO processes ai-chase goals in order, which could result in ships attacking targets WAAAAAY over there rather than the ships closest to them).  I mean, it's possible to script the TIE fighter order behaviours so should I make the conversion call scripts, or should I instead expect a FREDer to use other events & orders to recreate the overall effect of the TIE fighter orders? (or I could try to implement all the TIE orders in the FSO AI...)
Title: Re: Tie Fighter?
Post by: Goober5000 on August 22, 2016, 12:48:12 am
Hmm.  My first impression is that it shouldn't be hard to implement "Attack Ship Class X" in FSO; it would probably be similar to ai-chase or ai-chase-any except with a filter.  The ai-chase-any already filters by IFF anyway.

How many TIE orders would need to be implemented?
Title: Re: Tie Fighter?
Post by: niffiwan on August 22, 2016, 01:53:57 am
/me fires up TFW

There's around 40 orders, with some duplicates, and others which are implemented in FSO.  On the other hand, the "attack target" order has several parameters without a direct equivalent in FSO, like ship type, ship category & ship orders. I'd need to run some more analysis on all the missions to figure out exactly which orders are used across the entire 13 battles.
Title: Re: Tie Fighter?
Post by: -Norbert- on August 25, 2016, 01:01:02 pm
That sounds like something that'd be incredibly useful (or at least more intuitive and easier to use) outside of a TIE fighter conversion too.

For example it oculd be used to tell interceptors to target a specific bomber class over another, by giving attack orders against all present bomber types, but with different priorities.

And should the comm menu ever be overworked, such an option as "attack my target's class" would make a fine addition too.
Title: Re: Tie Fighter?
Post by: Goober5000 on August 25, 2016, 02:10:29 pm
I took a look at the code.  Adding an "attack ship class" order would be a little annoying, since there are several layers of code that the goal passes through and it would be necessary to modify all of them.  But it is really not a terribly complex problem.  I'll code it up (in a few days) and submit a PR.
Title: Re: Tie Fighter?
Post by: Phantom Hoover on August 25, 2016, 02:15:12 pm
Could you not just script that?
Title: Re: Tie Fighter?
Post by: z64555 on August 25, 2016, 05:32:06 pm
Could you not just script that?

They're working on a tool that'll translate the mission from TIE's format into FSO's format. Somewhat moot if somebody has to go in and hand roll every instance of "attack ship class."
Title: Re: Tie Fighter?
Post by: niffiwan on August 25, 2016, 09:44:58 pm
Could you not just script that?

They're working on a tool that'll translate the mission from TIE's format into FSO's format. Somewhat moot if somebody has to go in and hand roll every instance of "attack ship class."

Except that you wouldn't have to hand roll everything with a script. It's a bit touch & go as to whether it's easier to do in a script or in FSO itself, off hand I'd say that the scripting is easier upfront, but harder to maintain. And as Norbert pointed out, this is a feature that could be more generally useful to FREDers for any campaign.
Title: Re: Tie Fighter?
Post by: Goober5000 on September 05, 2016, 01:07:11 am
Ok, ai-chase-ship-class has been implemented in PR #939 (https://github.com/scp-fs2open/fs2open.github.com/pull/939).  The vast majority of the work went into the infrastructure as opposed to the goal behavior proper.

I've tested the goal in a sample mission with a bunch of cargo containers; it works splendidly.  I still need to test it in FRED (due to encountering the OpenGL bug) and I'll need someone to take a look at the Lua hook.
Title: Re: Tie Fighter?
Post by: Goober5000 on September 05, 2016, 04:30:05 pm
After rebasing on latest master and fixing a few bugs, I've been able to test it on FRED.  The only remaining untested aspect is getting and setting orders via Lua.  Here are some builds:
http://staff.hard-light.net/goober5000/temp/ai_chase_ship_class.7z