Function to find out if a point is inside a parallelogram. This is a GameMaker project however the code would be easy to adapt to any language.
On GitHub is the full GameMaker project, for just the function and a full breakdown visit: https://www.davetech.co.uk/gamemakerpointinparallelogram