Source Code for Mini Golf?

Hi there. Anybody know where I could find some mini-golf source code? Or tutorials?

Or if there isn’t any, does anyone have source code or thoery on how to make a diagonal wall for an object to bounce off of? I have ideas, but I’m not sure if they are as efficient as some other ideas may be. Thanks!