Getting an objects mirrored (x;y)

CAPSLOCKFTW

Member
Reaction score
5
How can i place a gold mine symetrically into my map...

I have 1 gold mine at lower right part of the map - what triggering is required to make another gold mine at the top left corner with mirrored placing... so that when 2 guys start from the middle and travel with the same speed get to the 2 different gold mine at the same time.

I thought about using a sin function... i noticed in dota that the units may be spawning using some distance formula...

Im in a hurry now so i cant explain with more detail.
 

Accname

2D-Graphics enthusiast
Reaction score
1,465
usually people place these by hand. i wouldnt know any benefits for placing them by hand.
besides, 2 units move towards these goldmines havent gotten to reach them in equal time even if the goldmines are the same distance off of them. thats becaus the intern wc3 pathfinding system is not flawless and some units take awkward edgy paths on their way.
 

CAPSLOCKFTW

Member
Reaction score
5
Ty diod, didnt expect it 2 be so easy...

Trigger:
  • Untitled Trigger 005
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set G_mine_1 = Gold Mine 0104 <gen>
      • Set G_point_x = (X of (Position of G_mine_1))
      • Set G_point_y = (Y of (Position of G_mine_1))
      • Set G_mirror = (Point((G_point_x x -1.00), (G_point_y x -1.00)))
      • Unit - Create 1 Gold Mine for Neutral Passive at G_mirror facing Default building facing degrees


I didnt know that the scales x;y equaled 0 in the centre of the map :DDD
 

Accname

2D-Graphics enthusiast
Reaction score
1,465
they do by default but they dont if you change the map size unequally afterwards. its not 100% failsafe. but still, where is the problem to place them by hand?
 

TomTTT

New Member
Reaction score
44
@Accname
I agree. Where's the problem of placing by hand? Just count the cells or even just place it by what you see, It's won't matter a lot if a units comes to the same spot 2 seconds earlier or later.
 

CAPSLOCKFTW

Member
Reaction score
5
accuratley placed distances + inaccurate terains equals random awesomeness... this is what makes good maps good

Now with my trigger i can get the mirrored point in under a minute instead of counting xd
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top