View previous topic :: View next topic |
Author |
Message |
Bellman
Joined: 14 Feb 2004 Posts: 1724
|
Posted: Sat Apr 29, 2006 9:24 pm Post subject: Random timed events. |
|
|
I wish to start an event at a random time but within a window like start plus 20 - 40 minutes.
That event is itself a random selection from say three options egs. Alliance change (N + R), Alliance change (N+B)
or pirate attack.
Given dynamic groups with randomised starting points I can see a very cumbersome way of achieving this
by means of area circle triggers, but I'm sure I'm overlooking a simpler solution. Can anyone help please
where possible quoting example scenario/s ? |
|
Back to top |
|
|
OKO
Joined: 10 Jan 2002 Posts: 468 Location: Solar system, mainly on earth
|
Posted: Sun Apr 30, 2006 4:31 am Post subject: |
|
|
1)
create 3 triggers=>
- trgtime1 starting at 12:20
- trgtime2 starting at 12:30
- trgtime3 starting at 12:40
now create dynamic group and put =>
- trgtime1 in group named "time1" prob 33%
- trgtime2 in group named "time2" prob 33%
- trgtime3 in group named"time3" prob 33%
create a dynamic group named rdmtime
min/max @ 1, prob 100%
include : time1 + time2 + time3
you have now a random choice of time trigger at mission start
2) create an aggregate trigger named timetrg
min : 1
dependant triggers : trgtime1, tgrtime2, trgtime3
3)
create 3 triggers=>
- trgevent1 with N+R if completedtrigger timetrg
- trgevent2 with N+B if completedtrigger timetrg
- trgevent3 with pirate attack if completedtrigger timetrg
now create dynamic group and put =>
- trgevent1 in group named grpevent1 prob 33%
- trgevent2 in group named grpevent2 prob 33%
- trgevent3 in group named grpevent3 prob 33%
create a dynamic group named rdmevent
min/max @ 1, prob 100%
[EDIT]
include in the rdmevent group => trgevent1, trgevent2, trgevent3
sorry I forgot that ...
[/EDIT]
So, now you have 1 out of 3 timers selected, and when it will be triggered, you will have 1 out of 3 event selected
you MUST encapsulate EACH trigger on his own dynamic group (example "time1" for the trgtime1) if you want to choose 1 of many triggers.
In other case, if you just put all triggers in the same group, they will all exist, even if you choose min/max 1 in the dynamic group where you put them together.
So you just have to put each triggers into a specific dynamic group, with a specific group probability, to avoid this problem.
With this example, you don't need area circle, this is only calculation.
Last edited by OKO on Sun Apr 30, 2006 1:28 pm; edited 1 time in total |
|
Back to top |
|
|
Bellman
Joined: 14 Feb 2004 Posts: 1724
|
Posted: Sun Apr 30, 2006 6:30 am Post subject: |
|
|
Thank you very much OKO, I will try to set that up |
|
Back to top |
|
|
MaHuJa
Joined: 10 Jan 2002 Posts: 447 Location: 59.96156N 11.02255E
|
Posted: Mon May 01, 2006 11:03 pm Post subject: |
|
|
Alternate solution, for a random time, not just a randomly selected time:
In the upper right corner of the map (when applicable; this will usually hide it beneath the 3d window even with show truth) create a ship of some kind. Or even a sub. Give it a transit tactic, in either of directions 0, 90, 180, 270. Give it an attached goal, destination type, and set it so that the ship enters it along its course. Use the random starting box to have its random placement somewhere along that course.
Set the distances between the beginning/end of randomStartBox and goal depending on the speed of the ship and the times you want. |
|
Back to top |
|
|
Bellman
Joined: 14 Feb 2004 Posts: 1724
|
Posted: Tue May 02, 2006 1:16 am Post subject: |
|
|
Ah that's a very neat solution to the problem MHJ providing true randomness. \
Pre OKOs solution I had played with several neutrals each with attached approach triggers and tactics which
allowed time randomness per triggering group.
After a foggy weekend I think I can now see a new horizon. |
|
Back to top |
|
|
Bill Nichols
Joined: 14 Mar 2001 Posts: 2657
|
Posted: Tue May 02, 2006 3:45 am Post subject: |
|
|
MaHuJa wrote: | Alternate solution, for a random time, not just a randomly selected time:
In the upper right corner of the map (when applicable; this will usually hide it beneath the 3d window even with show truth) create a ship of some kind. Or even a sub. Give it a transit tactic, in either of directions 0, 90, 180, 270. Give it an attached goal, destination type, and set it so that the ship enters it along its course. Use the random starting box to have its random placement somewhere along that course.
Set the distances between the beginning/end of randomStartBox and goal depending on the speed of the ship and the times you want. |
I've done this before (in Sub Command), using whales as the trigger. |
|
Back to top |
|
|
Bellman
Joined: 14 Feb 2004 Posts: 1724
|
Posted: Tue May 02, 2006 4:23 am Post subject: |
|
|
Techniques work well |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|