Home   Help Search Login Register  

Author Topic: Transfering knowsabout to another unit.  (Read 1302 times)

0 Members and 2 Guests are viewing this topic.

Offline icarus_uk

  • Members
  • *
  • LiarLiarPants Inflame True
    • [furryclan]
Transfering knowsabout to another unit.
« on: 12 Sep 2002, 16:07:39 »
This is for a communitcations script that I thought of.  I am making a radar bunker addon, and I want to have a commander inside the building.  A radio man unit can radio into the commander (not in the same group) and get all the enemy positions that the commander knowsabout.

So what I need a way of doing, is for one unit to get the list of units that said commander knowsabout...  (my this is getting confusing).

Said commander will have all the units within an area revealed to him, with the reveal command, and I want this infomation to be available for troops in the field to be able to access.

Offline Chris Death

  • Former Staff
  • ****
  • Finally Death's gonna get ya
    • OFPEC
Re:Transfering knowsabout to another unit.
« Reply #1 on: 12 Sep 2002, 19:44:54 »
hmm - not sure, if you can manually modify reserved
variables.

One thing you could try playing around:

Let one guy of the other group join the group which knowsabout anything, and then let it rejoin back to it's original
group.

I know, this sounds like a far way around, but it could
probably (maybe) work.

~S~ CD
Dont argue with idiots....they will bring you down to their level and beat you there with experience.

How to use Waypoint type Scripted

Offline Chris Death

  • Former Staff
  • ****
  • Finally Death's gonna get ya
    • OFPEC
Re:Transfering knowsabout to another unit.
« Reply #2 on: 12 Sep 2002, 19:47:59 »
hey, ust another idea;

Couldn't that be already in the game:
think about the guard waypoint, and any friendly unit
somewhere else on the map.
The group with that guard wp knows about the strength
of enemy presence, where they got detected (far away).

right, i need to check that for myself now  ;D

~S~ CD
Dont argue with idiots....they will bring you down to their level and beat you there with experience.

How to use Waypoint type Scripted

Offline Dinger

  • Contributing Member
  • **
  • where's the ultra-theoretical mega-scripting forum
Re:Transfering knowsabout to another unit.
« Reply #3 on: 12 Sep 2002, 21:03:25 »
switching groups might work, but it would take time for the information to "settle", you'd get two-way bleed, and you'd have to deal with someone trying to reform.

Reveal has its limitations (knowsabout decays according to range.  Reveal sets knowsabout to 1.  At long ranges, units "forget" about revealed units almost instantly.
still, I have a rune for you:
Code: [Select]
" ""detector"" + _x + "" = []"" Foreach [0]" Foreach ["0", "1", "2", "3", "4"]; instruction1 = " ""format ["" detector%1 = detector%1 + %2"", (""observer knowsabout _x"" count [_x]) - ((""observer knowsabout _x"" count [_x]) mod 1), _x]"" Foreach [_x]"" Foreach list detecttrigger"; instruction2 = " ""commander reveal _x"" ForEach (detector1 + detector2 + detector3 + detector4 + [Observer])"; "_X foreach [0]" Foreach [instruction1, instruction2]Hold on, there are some bugs.  I'll fix it up and post back.
Dinger/Cfit

Offline Dinger

  • Contributing Member
  • **
  • where's the ultra-theoretical mega-scripting forum
Re:Transfering knowsabout to another unit.
« Reply #4 on: 12 Sep 2002, 21:33:55 »


[attachment deleted by admin]
« Last Edit: 12 Sep 2002, 21:35:33 by Dinger »
Dinger/Cfit

Guru

  • Guest
Re:Transfering knowsabout to another unit.
« Reply #5 on: 05 Oct 2002, 03:30:27 »
Woot this sounds promising i d/l'ed it an ill give it a try
this could greatly improve the defencive capabilities of AI dudes in SP missions,have it also set to trigger responsive units to the scene an so-forth.
very good  ;D