View previous topic :: View next topic |
Author |
Message |
Skyburn Space Emperor

Joined: Mar 12, 2008
|
Posted: Sun Oct 30, 2011 4:27 pm Post subject: Periodic and One-Way Warp Points |
|
|
I think I've figured out a way to implement these two, using the impassible storms idea from the Warp 10 mod in an event script.
For a one-way WP the script would spawn an impassible storm on one side of the WP. I think that you could warp through the clear side and wind up in the sector with the impassible storm in it, yet ships couldn't warp the other way because they can't move into the sector with the WP (and the storm) in it. You could also couple this script with the script from GG mod that pushes everything out of the WP sector, so if you go through a one way WP you can't just turn around.
For a periodic WP the script would generate impassible storms on both ends of the WP. It should be easy to do it on a repeating schedule, like 5 turns open and 5 turns closed.
I haven't tested these ideas yet, but I can't see anything that would prevent them from working.
Back to top |
|
 |
marhawkman Space Emperor

Joined: Mar 24, 2008
|
Posted: Sun Oct 30, 2011 8:42 pm Post subject: |
|
|
I like the idea, but...
1: how does the game know which storm object to spawn? I know you can tell it manually when adding storms to system types, but can you do that in a script? You might be able to work around this by using the storm "size" function, but I'm not sure.
2: how does the game know which warppoints should have one of these? IIRC the only way to tag "special" warp points is with Unstable. but that would affect BOTH ends.
One possible idea is to have a script spawn them at random on warp points then delete them at random.
Back to top |
|
 |
Skyburn Space Emperor

Joined: Mar 12, 2008
|
Posted: Mon Oct 31, 2011 4:33 pm Post subject: |
|
|
1: The Sys_Create_Storm function lets you select a specific storm type from StellarObjTypes.txt according to the script pdf.
2: Each warp point apparently has a space object id. Hopefully you can get system and sector of both ends of the WP somehow. If each side of the WP has a separate ID then there might be a problem.
Back to top |
|
 |
marhawkman Space Emperor

Joined: Mar 24, 2008
|
Posted: Tue Nov 01, 2011 5:19 am Post subject: |
|
|
1: great!
2: hmmm... can you make the script just work with unstable warp points?
Back to top |
|
 |
rnl Space Emperor

Joined: Jun 02, 2008
|
Posted: Tue Nov 01, 2011 1:35 pm Post subject: |
|
|
Hi, guys got some bad news for you.
1. the Sys_Create_Storm does not allow you to select which storm u get, I believe. I had to planet create planets instead for the Debris for the CCMOD event. It's also the only way to give a ability to an object as well.
2.Both side do have separate ID and there is no one function that will give you the connecting WP. But you can setup a function to find the WP with a script function that tells you where that WP is connected to.
As to keeping track of the unstable WP the event script does allow data to be carried over from each turn. I used it in my cloak WP event, you could possible use the code to help. Or if you go the planet way, then just have a function looking for that planet type and give it a random chance of closing based on the planet type it has. I did this with the debris field.
Good Luck and ask if you need any help.
Back to top |
|
 |
marhawkman Space Emperor

Joined: Mar 24, 2008
|
Posted: Tue Nov 01, 2011 5:12 pm Post subject: |
|
|
1: it's not an ability. It's a Storm type with a blocked hex radius. 
Back to top |
|
 |
Skyburn Space Emperor

Joined: Mar 12, 2008
|
Posted: Fri Apr 18, 2014 10:39 pm Post subject: |
|
|
I finally got around to testing one way warp points. They work ok. Ships can warp into the blocked hex, but can't cross into it from the same system.
Back to top |
|
 |
marhawkman Space Emperor

Joined: Mar 24, 2008
|
Posted: Sat Apr 19, 2014 1:56 am Post subject: |
|
|
Skyburn wrote: | I finally got around to testing one way warp points. They work ok. Ships can warp into the blocked hex, but can't cross into it from the same system. | IIRC this drives the AI insane. One of the older versions of the game had situations where a warp point could spawn in the corona of a star. Needless to say that made it one way, but the AI was too dumb to figure that out.
Back to top |
|
 |
Skyburn Space Emperor

Joined: Mar 12, 2008
|
Posted: Sat Apr 19, 2014 2:13 pm Post subject: |
|
|
Good to know. Maybe they should not spawn on the AI friendly maps for now.
Back to top |
|
 |
Crissa Space Emperor

Joined: Jan 07, 2006
|
Posted: Mon Apr 21, 2014 12:04 am Post subject: |
|
|
It can play havok with player unit pathing as well.
-Crissa
Back to top |
|
 |
|