made a better function for finding triangle centr

by better i mean "one that actually works"