Boucing off of walls

BlackPlague

New Member
Reaction score
1
What I'm doing is making a ping-poing like game, what I need is to figure out how to get the angle of refraction correct for the ball when it hits a wall in WCIII editor.
Scenario:
-The ball is hit
-Then ball is missed, and hits a wall
and there's where I'm stuck, I need to ball to bounce off the wall and and go in the right direction, basically I need to change it's angle correctly.
Now I'm completelly lost with things in the high end math area here, so I'll need it in baby steps if you post :D.
 

Curo

Why am I still playing this game...?
Reaction score
109
There are soooo many complicated things that you can do in wc3. Why do people try and recreated the most basic games (pacman, pong, tetris, etc)? It takes so much work to do so, and is hardly worth it.

Anyway, it's your time to waste. I remember seeing this question before, so try and do a search. Keyword try, since this search function is garbage :p
 

BornANoob[MR]

Member
Reaction score
21
I imagine i can give you a formula that might work, have a go at this.

Theta = Arcsine (1.00/1.00)

or (Asin((1.00/1.00))) as seen in the editor, once a unit enters a region, it should be reflected at the this angle
 

Darkenneko

TH.net Regular
Reaction score
3
There are soooo many complicated things that you can do in wc3. Why do people try and recreated the most basic games (pacman, pong, tetris, etc)? It takes so much work to do so, and is hardly worth it.

Anyway, it's your time to waste. I remember seeing this question before, so try and do a search. Keyword try, since this search function is garbage :p

I'm pretty sure the helper is here for people to help others,
not to flame there ideas down to the ground. If he wants to make it, he can make it, don't post if your not going to be helpful,
As for the function, I don't have too much of a idea, maybe someone else can help you with that, but if you have any questions, just ask the "friendly" people here at thehelper.net, anyways,
Off with me.
-Calvin
 

BlackPlague

New Member
Reaction score
1
There are soooo many complicated things that you can do in wc3. Why do people try and recreated the most basic games (pacman, pong, tetris, etc)?
Because it's better than you

I remember seeing this question before, so try and do a search. Keyword try, since this search function is garbage :p

I already tried and failed :(
 

BlackPlague

New Member
Reaction score
1
Nah, you didn't offend me any thank you for find this, I look for a while then gave up after about 15 mintues of shifting...I fail
 

BornANoob[MR]

Member
Reaction score
21
What i suggested is not set in stone, play with it, see if it works, i wont be 100% unless i fully tested it, which would take too long without the map already made, so go ahead, and see what its like
 

PrisonLove

Hard Realist
Reaction score
78
wouldnt the angle of reflection just be the angle it strikes at + or - 90 degrees? so you can derive a formula based on that maybe?
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top