Hard Light Productions Forums
Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: Molybdenum on February 07, 2009, 09:42:32 am
-
So in my mod. I try to set a group of ships that are friendly by default to hostile in the ship editor. When testing the mission they are marked as green and act as if friendly. This is my iff_def.tbl folder and all seems fine.
#IFFs
;; Every iff_defs.tbl must contain a Traitor entry. Traitors attack
;; one another (required by the dogfighting code) but it is up to you
;; to decide who attacks the traitor or whom else the traitor attacks.
$Traitor IFF: Traitor
;------------------------
; Friendly
;------------------------
$IFF Name: Friendly
$Color: ( 0, 255, 0 )
$Attacks: ( "Hostile" "Neutral" "Traitor" )
$Flags: ( "support allowed" )
$Default Ship Flags: ( "cargo-known" )
;------------------------
; Hostile
;------------------------
$IFF Name: Hostile
$Color: ( 255, 0, 0 )
$Attacks: ( "Friendly" "Neutral" "Traitor" )
+Sees Friendly As: ( 255, 0, 0 )
+Sees Hostile As: ( 0, 255, 0 )
;------------------------
; Neutral
;------------------------
$IFF Name: Neutral
$Color: ( 155, 155, 155 )
$Attacks: ( "Friendly" "Hostile" "Traitor" )
+Sees Friendly As: ( 0, 255, 0 )
+Sees Hostile As: ( 255, 255, 0 )
+Sees Neutral As: ( 255, 0, 0 )
;------------------------
; Unknown
;------------------------
$IFF Name: Unknown
$Color: ( 255, 0, 255 )
$Attacks: ( "Hostile" )
+Sees Neutral As: ( 0, 255, 0 )
+Sees Traitor As: ( 255, 0, 0 )
$Flags: ( "exempt from all teams at war" )
;------------------------
; Traitor
;------------------------
$IFF Name: Traitor
$Color: ( 255, 0, 0 )
$Attacks: ( "Friendly" "Hostile" "Neutral" "Traitor" )
+Sees Friendly As: ( 255, 0, 0 )
#End
Is it possible that this is a FRED related bug?
-
What happens if you remove the IFF_Defs table?
Unless you've altered it in some way you don't need that table at all.
-
Removing it didn't change anything. I'm using fred2_open_3_6_10r-20081217_r5008-Wanderer
-
Can you post the mission then?
-
Sorry to keep you waiting. I don't think the mission file has anything to do with it. The same thing occurs with even the simplest of missions. I think the problem is in my modpack somewhere. I'm also afraid that having to find it will hider my progress.
-
So you want to add iff that is friendly towards the ships which have 'hostile' iff?
On a quick look at your table all other iffs had 'hostile' in their 'attacks' entry so they all should attack the ships with 'hostile' iff on sight.
-
The problem was, with or without the table ,the ship that where set to hostile show up green and could be targeted as friendly and attacking them would be treason. It's no longer a problem though. I'm just using the Traitor IFF with setting as if hostile so no I'm moving on somehow.
-
Were they part of a wing, or something?
Or maybe you accidentally put the player as hostile?
-
Or maybe you accidentally put the player as hostile?
<Checks mission>
<*Slaps Forehead*>
"D'oh!"
Thanks, I can't belive I've been failing so hard. :ick:
Shivan ships where set to hostile as standard.
-
$Flags: ( "support allowed" )
So...that's what enables each faction to call in support ships? And what happens if a docking bay arrival/departure is set? Both hostile and friendly support ships will take off from/land to the same ship?
-
Never tried it but as far as I know there isn't any reason you can't launch a hostile ship or supply ship from a friendly destroyer.
-
Uhm...
Two separate "Hostile" entries, let's say "Hostile" and "Hostile#2", could be used when necessary to represent both effects. The first, default one would be used for missions in which friendly support ships take off from a destroyer/station/whatever while the second could be used in any normal situation(support ships jumping in) so that there will be no significant difference between the arrival anchor of friendly and hostile support ships.
I might give this a try. :nod:
EDIT: What's the correct name of the IFF Def.s table? I don't see the new entry in FRED.
-
iff_defs.tbl
And do note that '_' is not the same as ' '.
-
Yeah, that was a typo in my post.
I found the error: I added the ".tbl" part in the name, thus having "iff_defs.tbl" as name when the correct name is "iff_defs". The new entry works, now. :)