[BONUS Plug-In] Basic Patrol Commands v1.03 [4-1-05]
Moderators: Moderators for English X Forum, Scripting / Modding Moderators
update 4/1/05:
- New Enemy Detection Logic: fixed problem of friend/foe setting staying set to enemy after attack. Now, as soon as there are no eemies within 20 km of your patrol leader, settings will revert back to friend.
note: this only applies to situations where your patrol engages 'friends' that are attacking you (usually pirates)
- New Enemy Detection Logic: fixed problem of friend/foe setting staying set to enemy after attack. Now, as soon as there are no eemies within 20 km of your patrol leader, settings will revert back to friend.
note: this only applies to situations where your patrol engages 'friends' that are attacking you (usually pirates)
"Nature's first green is gold" . . . stay golden.
keep me posted on how well it works.
It's kind of tricky to strike a balance here, it's hard to know when to switch the friend/foe back to normal.
The standard behavior of the game is that, if a ship from a race you consider to be friendly attacks you, your friend/foe makes it an enemy.
So if a pirate attacks your patrol leader, it will switch pirates to foes forever. This is standard behavior and can't be changed.
My override works, as you know, when pirates (or other races) are attacking one of your other ships/stations besides the patrol. The patrol will override the friend/foe and then attack them.
So here's the issue, when do you switch back to friend? If you switch in the middle of combat (let's say after the first of three pirates is killed) you run the risk of one of the other pirates attacking your ship and switching your friend/foe forever. I thought a 20 km safe zone was enough. Occasionally perhaps the odd pirate freighter will be targetd, but as soon as there are no bad guys within 20 km, the friend/foe settings revert to what they were previously.
I hope this works well.
Make sure to let me know how it goes so I can further tweak it.
Cheers.
It's kind of tricky to strike a balance here, it's hard to know when to switch the friend/foe back to normal.
The standard behavior of the game is that, if a ship from a race you consider to be friendly attacks you, your friend/foe makes it an enemy.
So if a pirate attacks your patrol leader, it will switch pirates to foes forever. This is standard behavior and can't be changed.
My override works, as you know, when pirates (or other races) are attacking one of your other ships/stations besides the patrol. The patrol will override the friend/foe and then attack them.
So here's the issue, when do you switch back to friend? If you switch in the middle of combat (let's say after the first of three pirates is killed) you run the risk of one of the other pirates attacking your ship and switching your friend/foe forever. I thought a 20 km safe zone was enough. Occasionally perhaps the odd pirate freighter will be targetd, but as soon as there are no bad guys within 20 km, the friend/foe settings revert to what they were previously.
I hope this works well.
Make sure to let me know how it goes so I can further tweak it.
Cheers.
"Nature's first green is gold" . . . stay golden.
-
- Posts: 1940
- Joined: Sun, 8. Feb 04, 19:04
If upgrading check the friend foe setting of your patrol leader (s); just to ensure they are back to what you want them to be.
This works like a charm - really - I have substantial factory build in pirate areas and so often have stray pirates come over to play.
M6 flys in B.Triumph... couple of M4s, an M5 and a couple of IS (sorry PS, TS - whatever) attacking my factory. (I was OOS) M6 flys in - scans - engages the pirates - went to the next rally point and flew off. Thing is BT still has its Pirate Base intact and so this had been a problem hot spot for me previously.
From what I've seen I think the range is just fine.
Karl
This works like a charm - really - I have substantial factory build in pirate areas and so often have stray pirates come over to play.
M6 flys in B.Triumph... couple of M4s, an M5 and a couple of IS (sorry PS, TS - whatever) attacking my factory. (I was OOS) M6 flys in - scans - engages the pirates - went to the next rally point and flew off. Thing is BT still has its Pirate Base intact and so this had been a problem hot spot for me previously.
From what I've seen I think the range is just fine.
Karl
I'd suggest setting them back to what they were.
Why keep an entire race as enemies, just cos one rogue decided he didn't like one of your factories.
Checking for enemies within 20k. Hmmmm..... Why do I feel my "attack enemies in radius" script becoming obsolete before it even gets signed
Why keep an entire race as enemies, just cos one rogue decided he didn't like one of your factories.
Checking for enemies within 20k. Hmmmm..... Why do I feel my "attack enemies in radius" script becoming obsolete before it even gets signed
Attack enemies in radius -here
-
- Posts: 1940
- Joined: Sun, 8. Feb 04, 19:04
I'm not sure what you are saying stella.
The Patrol Leader uses the friend foe setting to target enemies.
The player friend/foe setting can be over-ridden at ship level - for example player "Pirates = Foe"; Ship "Pirates = Friend - then show as enemy if enemy to me = no"
With this the player can be "at war" with the Pirates but the Patrol will ignore them.
However - with the update to the Patrol script - if a Pirate is found by the patrol to be attacking one of your ships / factories it will over-ride the friend foe setting and attack the Pirate. This causes the friend / foe setting to be changed at ship level to foe. Not good if there are "friendly" Pirates in sector.
What Burianek has done is to have the Pirate friend/foe setting change back to friend once the Patrol has taken care of the "baddy" pirate and moved away from the area of attack. Obviously this can not occur too soon - but can not be left too long.
This is not an attack in radius but a control over the length of time the Patrol will remain hostile when it is not needed.
The Patrol Leader uses the friend foe setting to target enemies.
The player friend/foe setting can be over-ridden at ship level - for example player "Pirates = Foe"; Ship "Pirates = Friend - then show as enemy if enemy to me = no"
With this the player can be "at war" with the Pirates but the Patrol will ignore them.
However - with the update to the Patrol script - if a Pirate is found by the patrol to be attacking one of your ships / factories it will over-ride the friend foe setting and attack the Pirate. This causes the friend / foe setting to be changed at ship level to foe. Not good if there are "friendly" Pirates in sector.
What Burianek has done is to have the Pirate friend/foe setting change back to friend once the Patrol has taken care of the "baddy" pirate and moved away from the area of attack. Obviously this can not occur too soon - but can not be left too long.
This is not an attack in radius but a control over the length of time the Patrol will remain hostile when it is not needed.
-
- Posts: 1940
- Joined: Sun, 8. Feb 04, 19:04
Thx for the update Karl,
keep me posted.
Stella: yeah, the way the patrols used to work, once they attacked a pirate that was harrassing you, they'd be so angry they'd attack every pirate from that point on. This update lets them switch back to generally friendly terms with them.
(and we keep saying pirates since they're the most common, but it works the same way for every race)
keep me posted.
Stella: yeah, the way the patrols used to work, once they attacked a pirate that was harrassing you, they'd be so angry they'd attack every pirate from that point on. This update lets them switch back to generally friendly terms with them.
(and we keep saying pirates since they're the most common, but it works the same way for every race)
"Nature's first green is gold" . . . stay golden.
-
- Posts: 1940
- Joined: Sun, 8. Feb 04, 19:04
just as an aside, I like the gunnery crew script idea, whereby if there's more than one enemy, they don't all go for the same target.
I mean, if you have 5 M3's on patrol, and they see 2 pirate mandalays, wouldn't it make sense to split your forces?
I mean, if you have 5 M3's on patrol, and they see 2 pirate mandalays, wouldn't it make sense to split your forces?
Attack enemies in radius -here
In sector yes. OOS maybe not. Multiple ships can successfully attack a single target OOS with no penalties since it's purely mathematical and you don't have to worry about your 20 ships performing evasive maneuvers and wasting time to prevent running into eachother . It's much harder for multiple ships to maintain a lock on a single ship In Sector.
Having them all attack the same target kills the target much more quickly OOS. (and most patrol battles will occur OOS)
Gunnery crew battles always occur in sector, hence the optimization. Patrol battles, OOS, hence my optimization.
Just my opinion.
Cheers.
Having them all attack the same target kills the target much more quickly OOS. (and most patrol battles will occur OOS)
Gunnery crew battles always occur in sector, hence the optimization. Patrol battles, OOS, hence my optimization.
Just my opinion.
Cheers.
"Nature's first green is gold" . . . stay golden.
- Pirate Hunter
- Posts: 715
- Joined: Wed, 22. Sep 04, 20:44
Does this script work on all Combat Ships or just Capital ships.
Because I cant find the command in the menu
Because I cant find the command in the menu
[ external image ][/url]
http://www.egosoft.com/x2/forum/viewtopic.php?t=73689 The New and Improved Ultimate Guide to Everything
http://www.egosoft.com/x2/forum/viewtopic.php?t=73689 The New and Improved Ultimate Guide to Everything
To activiate this script you need an M6 or higher, but you can assign lower class ships like M3 to become it's wingmen.Pirate Hunter wrote:Does this script work on all Combat Ships or just Capital ships.
Because I cant find the command in the menu
DZorro,
System spec: Pentium (R) D 2.66 Ghz, Ram : 2048 DDR, HD : 250 GIG 7200 RPM intern 8 MB cash
Videocard : Nvidia Geforce 8800 GTS 320mb : Realtek
Laptop : AMD athlon 64 3200 + 1024 DDR 80 gig HD Conexant AMC Audio, Ati mobility Radeon Express 200
Videocard : Nvidia Geforce 8800 GTS 320mb : Realtek
Laptop : AMD athlon 64 3200 + 1024 DDR 80 gig HD Conexant AMC Audio, Ati mobility Radeon Express 200
*sigh* unfortunately this makes your own OOSD miles better than the standard ones that came with the game. Another example of fans outcoding the developers
What I would like to see is this software used on all AI patrols as well - this would make the new patrol script fit in with the X universe.
As it stands, the normal AI patrols are somewhat lacking.
What I would like to see is this software used on all AI patrols as well - this would make the new patrol script fit in with the X universe.
As it stands, the normal AI patrols are somewhat lacking.
- Pirate Hunter
- Posts: 715
- Joined: Wed, 22. Sep 04, 20:44
Id just be happy if the colossus in Ore belt actualy shot at Khaak ships or even just launched novas.As it stands, the normal AI patrols are somewhat lacking.
[ external image ][/url]
http://www.egosoft.com/x2/forum/viewtopic.php?t=73689 The New and Improved Ultimate Guide to Everything
http://www.egosoft.com/x2/forum/viewtopic.php?t=73689 The New and Improved Ultimate Guide to Everything
They're government employees. Give them a break.Greyhawk1 wrote:*sigh* unfortunately this makes your own OOSD miles better than the standard ones that came with the game. Another example of fans outcoding the developers
What I would like to see is this software used on all AI patrols as well - this would make the new patrol script fit in with the X universe.
As it stands, the normal AI patrols are somewhat lacking.
If it were me designing the game, I actually might be able to justify them not being very attentive to all risks. Can't make the game too easy for you.
Why should a teladi pilot risk his neck to save one of your ships/stations? There's no profit in that.
That being said, we may see patrols reworked in the expansion, anything is possible. Of course, we may see some new threats that the patrols aren't equipped to deal with as well ....
We'll all have to wait and see
"Nature's first green is gold" . . . stay golden.