OpenXcom Forum

Modding => Work In Progress => Topic started by: robin on January 31, 2015, 04:19:14 am

Title: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: robin on January 31, 2015, 04:19:14 am
For reason of uniformity and clarity of my ruleset I wanted to rename all the UFOs strings adding "UFO_" after "STR_" (since I also have non-UFO -aka human- ships); IE:
STR_SUPPLY_SHIP --> STR_UFO_SUPPLY_SHIP

But I wonder if this will break hardcoded missions that involve those special UFOs, such as alien base, terror and supply.

?

Thanks.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: Hobbes on January 31, 2015, 06:00:34 am
To my knowledge, there shouldn't an issue with replacing the vanilla UFO STRs with new ones as long as you assign the new UFOs to the existing missions. I think you could even get rid of the Infiltration, Research, Harvest and Abductions alien missions without any issues. But you'll always need to have the Base, Terror, Supply and Retaliation missions staffed with UFOs.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: Falko on January 31, 2015, 07:03:44 am
and you get incompatible with everymany ufo mods out there
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: robin on January 31, 2015, 11:07:33 am
To my knowledge, there shouldn't an issue with replacing the vanilla UFO STRs with new ones as long as you assign the new UFOs to the existing missions. I think you could even get rid of the Infiltration, Research, Harvest and Abductions alien missions without any issues. But you'll always need to have the Base, Terror, Supply and Retaliation missions staffed with UFOs.
I don't want to get rid of the missions, quite the opposite: I want to change the STRs while being sure everything will still work properly.

and you get incompatible with everymany ufo mods out there
it's a total conversion, ufos will use custom mcd sets, it's going to be incompatible anyway.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: Yankes on January 31, 2015, 02:58:00 pm
Right now its worked on, I even made path that do it. I don't now if it get pass, because SupSuper is working on alien mission and my patch could be incompatible.
This mean that in one way or another it will be soon fix.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: robin on January 31, 2015, 03:23:59 pm
Right now its worked on, I even made path that do it. I don't now if it get pass, because SupSuper is working on alien mission and my patch could be incompatible.
This mean that in one way or another it will be soon fix.
I see. I'm going to keep them unchanged for now.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: SupSuper on January 31, 2015, 06:14:18 pm
There are a lot of hardcoded UFO IDs and mission IDs right now so I wouldn't recommend changing the vanilla stuff (though you can add your own).

We're currently rewriting all the mission stuff for TFTD so this will be fixed, but it'll likely break mission mods as well, so either way you'll have to update your mods afterwards. At least you'll also get some new features to play with. ;)

Right now its worked on, I even made path that do it. I don't now if it get pass, because SupSuper is working on alien mission and my patch could be incompatible.
This mean that in one way or another it will be soon fix.
Yeah currently your patch conflicts with my changes so I'll probably apply your changes myself or ask you to remake the patch afterwards.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: robin on February 01, 2015, 11:23:29 am
So, hum, you guys did the modification already?

I'm looking at this
    specialUfo: STR_TERROR_SHIP
    deployment: STR_TERROR_MISSION
    markerName: STR_TERROR_SITE
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: Yankes on February 01, 2015, 12:56:25 pm
Yes, yesterday SupSuper add his code and merge my patch.

My part do:
Quote
New field specialUfo used my missions to determine how handle different UFO types.
Retaliation: ufo of this type is spawn.
Supply: ufo of this type is transport craft.
Terror: ufo of this type can create terror site.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: robin on February 01, 2015, 01:49:41 pm
New field specialUfo used my missions to determine how handle different UFO types.
Retaliation: ufo of this type is spawn.
Supply: ufo of this type is transport craft.
Terror: ufo of this type can create terror site.
Where is that stuff? I can't find it.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: Yankes on February 01, 2015, 02:02:45 pm
I don't get this question, what are you looking for?
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: robin on February 01, 2015, 02:11:47 pm
I don't get this question, what are you looking for?
If I do this in my ruleset:

alienMissions:
  - type: STR_ALIEN_TERROR
    points: 10
    specialUfo: STR_TERROR_SHIP
    deployment: STR_TERROR_MISSION
    markerName: STR_TERROR_SITE
    raceWeights:
      [...]
    waves:
      [...]
      - ufo: STR_TERROR_SHIP
        count: 1
        trajectory: P7
        timer: 9000
  - type: STR_ALIEN_HORROR
    points: 10
    specialUfo: STR_HORROR_SHIP
    deployment: STR_HORROR_MISSION
    markerName: STR_HORROR_SITE
    raceWeights:
      [...]
    waves:
      [...]
      - ufo: STR_HORROR_SHIP
        count: 1
        trajectory: P7
        timer: 9000

I'll have a second terror-like mission in game.. or is everything still tied and exclusive to the mission type "STR_ALIEN_TERROR"?
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: Yankes on February 01, 2015, 02:25:33 pm
Right now yes, its only work with build in missions. But my next step will be allow any mission to work like terror/retaliation/supply mission.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: robin on February 01, 2015, 02:50:45 pm
Right now yes, its only work with build in missions. But my next step will be allow any mission to work like terror/retaliation/supply mission.
I see.
Title: Re: Renaming UFOs "STR_.." and hardcoded missions involving those UFOs
Post by: robin on February 07, 2015, 02:16:25 pm
I have another question sort-of related. Since I "found out" that messing with trajectories can mess things up (final landing sites not happening or something), I wonder: what about the speed of the UFOs? Significantly higher speed could mean that they cover the trajectory waypoints faster, could this lead to issues too?