# x,y of centre region ?

#### dannyboydude

##### New Member
I know
JASS:
``````local real x=GetUnitX(myUnit)
local real y=GetUnitY(myUnit)``````

Is units x + y

How do i get the x + y of the centre of a region?

#### Trollvottel

##### never aging title
easy.

you have the MaxX and the MinX of a region. and how to calculate the average(center) of 2 values? right, add value1 to value2 and divide them by 2:

centerx = (MinX + MaxX) / 2

the same with the y-value

centery = (MinY + MaxY) / 2

#### dannyboydude

##### New Member
im not a gd jasser so how do i get

max x + y
&
min x + y

of a region?

So still how do i get the min and max of x + y for a region ?

JASS:
``````GetRectCentreX(bank1)
GetRectCentreY(bank1)``````

Is that right ?

#### Trollvottel

##### never aging title
hm my TESH says: no

its GetRectCenterX/Y()

#### dannyboydude

##### New Member
hm my TESH says: no

its GetRectCenterX/Y()
Thats what i put
JASS:
``GetRectCentreY(bank1)``

#### Trollvottel

##### never aging title
no you put Centre while I said Center.

do you see the difference?

#### dannyboydude

##### New Member

Thanks for the help

+rep

General chit-chat
Help Users
• No one is chatting at the moment.
• jonas:
Wow
• jonas:
Is the school system in your country similar to Chinese school system? I could never imagine being a teacher in a Chinese school, what's expected of students and teachers is just so different from what I'd be looking for as a teacher
• vypur85:
A Levels is based on the UK syllabus offered internationally. So the syllabus is similar throughout different countries, taught in english.
• vypur85:
I can't speak or write or read much chinese... Too difficult....... Which also makes my life here in china a lil difficult.
• jonas:
Oh, I see. I thought Chinese version of A-levels
• jonas:
I've been using the translate app a lot on my phone. take a photo, translate. take another photo, translate again
• jonas:
it also has voice translation, my colleagues sometimes use that
• jonas:
You came during the 0 covid policy right? How'd you get through quarantine? Did you have some help with the apps and green codes?
• tom_mai78101:
If you have any Chinese you need help with, let me know.
+1
• vypur85:
@jonas Those were the things I did too. Translate app and VPN are always the most important things to have to survive. Lol.
• vypur85:
Yea I came last year. I was quarantined for about 30 days. Fml. The first day of my quarantine was the eve of Chinese new year last year. Fml again... Lol.
• vypur85:
@tom_mai78101 IIRC you're from Taiwan right.
• The Helper:
I thought China had cracked down on having any foreign teachers?
• vypur85:
Yeah I've heard of the news before. My school is still actively hiring foreign teachers. Not sure how things work now.
• The Helper:
yeah it is hard to get reliable information about that kind of stuff
• The Helper:
but you are doing it so it is still doable
• vypur85:
I think it doesn't affect existing foreign teachers. Then again, its still weird that my school is hiring.
• The Helper:
Happy Monday people hope everyone has a fantastic week!
• Ghan:
• jonas:
• jonas:
please put this in the news section, it's crazy
• tom_mai78101:
Technically, you can post in the Headline News. Just posted your news there.
• tom_mai78101:
I'm not aware of you not being able to post news.
• jonas:
I think technically I can I just forget how

### Members online

No members online now.