Home   Help Search Login Register  

Author Topic: map clicking unit  (Read 1133 times)

0 Members and 1 Guest are viewing this topic.

mikkelfh

  • Guest
map clicking unit
« on: 14 Mar 2004, 13:39:27 »
is it possible to get the side or unit of the player clicking in the map?

I use it for controlling AI troops via map, like CoC, but I don't want the east players to control west troops! So I need to find out which unit/side is clicking the map.

I use the onMapSingleClick command, which works perfectly, except east can control west units and so on.

Offline Spinor

  • Members
  • *
  • I'm a llama!
    • The chain of command
Re:map clicking unit
« Reply #1 on: 14 Mar 2004, 13:57:08 »
The onMapSingleClick command is local and can differ between machines. To disable the map click for all non-west sides you can use:
Code: [Select]
if(side player == west) then {onMapSingleClick{blablabla}}