#A 2D vector in my lib :P - Just the header file
1 messages · Page 1 of 1 (latest)
since you define your vector as a pair of floats, just the float overloads are enough imo
that, and also appropriate Vector2D ones
Yeah there are way too many overloads
float gets automatically promoted to double for one
Though I can see doing something different for integer multiplication and division at least
I just wanted to be sure 'cause sometimes it would just not work without a overload :P.
Oh ok
Use templates
And std::is_arithmetic_t from the STL
And then, if you want to specialise, you can just use template specialisations instead
I've done that with a template and it sure worked well! And now there's some more stuff that I need to look out for but.. for now.. Thanks y'all for helping me with this.. if you want to see the source-files and some propably semi-good implementation I'll make sure to post it on github.
whoever would need the link i would dm or if that isn't aginst server rules I'll leave the link here
And for those people who don't trust some random links on discord I'll include some screen-shots.
I'll try giving it a try.. but I dunno if I'm gonna be able to figure it out but.. youtube will maybe help of I don't figure it out myself. I'm still a semi-new programmer
You have a server here just to ask
Cppreference also includes code examples
It's fine, everyone else leaves the link on the project by default
One problem now.. The GitHub repo does not want to show up in the browser or my account even tho I've made it public.. I'll try doing something to make it work