Search found 3709 matches

by albinopapa
May 20th, 2019, 9:20 am
Forum: Everything
Topic: operator overload : how to take care of the "rest" ?
Replies: 3
Views: 17

Re: operator overload : how to take care of the "rest" ?

Ok, well then no not really. Say you have this: struct Thing1 { int a, b, c; std::string name; }; struct Thing2 { Vec3f position, velocity; Rectf bb; }; How are you going to have one function take care of both of these types? The best you can do is to define overloads for them. struct Thing1 { int a...
by albinopapa
May 20th, 2019, 5:38 am
Forum: Everything
Topic: I guess I'll start
Replies: 19
Views: 134

Re: I guess I'll start

Oh, to add to the topic of a sprite sheet, I have thought about how I might do it using the 3D application. I'd just have to have multiple copies of the characters arranged in the manner I'd like them presented then just pull back the camera until all models are in view and disable perspective. Not ...
by albinopapa
May 20th, 2019, 5:32 am
Forum: Everything
Topic: I guess I'll start
Replies: 19
Views: 134

Re: I guess I'll start

I'm rendering out the sprites using a 3D application and haven't wanted to take the time to compose them into a sheet yet, but I'm not sure it's worth the effort to do so. I have done the stage tilemap using text before, it's super easy to create and manipulate, but for this game I'm doing as much a...
by albinopapa
May 20th, 2019, 3:37 am
Forum: Everything
Topic: Homework 5 - Beginner C++
Replies: 7
Views: 48

Re: Homework 5 - Beginner C++

Yeah, after going back and watching and reading the wiki, it says nothing aside from "Draw two targeting boxes, one controlled with the arrow keys and one stationary, and have the color of the mobile targeting box change whenever the targeting boxes overlap." The targeting boxes should already be pa...
by albinopapa
May 20th, 2019, 3:10 am
Forum: Everything
Topic: operator overload : how to take care of the "rest" ?
Replies: 3
Views: 17

Re: operator overload : how to take care of the "rest" ?

Custom types or User Defined Types will need to have overloads for them as well.

What other types are you looking for?

wchar_t* and std::wstring should already be overloaded for std::wcstream.
by albinopapa
May 19th, 2019, 9:12 pm
Forum: Everything
Topic: I guess I'll start
Replies: 19
Views: 134

Re: I guess I'll start

Y'all like games that troll it's players? The reason I ask is as a way of simplifying my job as a programmer, I am sorting a container in descending order. This container is used to pick which rooms to place keys in which unlock doors. I did this so I can just loop through the container and remove t...
by albinopapa
May 18th, 2019, 11:16 pm
Forum: Everything
Topic: I guess I'll start
Replies: 19
Views: 134

Re: I guess I'll start

Oh, another thing I have been thinking of is surrounding connected tiles with lines. This way I'd check collision with a single line instead of a vector of tiles, both for lighting and entity collision. I'm thinking of changing the setup a bit for the map. The change would involve creating a tile ma...
by albinopapa
May 18th, 2019, 11:03 pm
Forum: Everything
Topic: I guess I'll start
Replies: 19
Views: 134

Re: I guess I'll start

NOOOOO! I'm shocked at how dumb I can be sometimes. I get so focused on coding sometimes I forget to commit changes before implementing something that could break what is working. Then when it does break, I get so frustrated I just undo everything and now I can't get the parts I was working on back....
by albinopapa
May 18th, 2019, 6:21 pm
Forum: Everything
Topic: I guess I'll start
Replies: 19
Views: 134

Re: I guess I'll start

I was able to use a triangle rasterization method to calculate the triangle of "light" which was a mixture of chili's scanline rasterization method and barycentric coordinates. I didn't want to look up and go through the videos and I was having troubles with blank pixels between triangles, so I just...
by albinopapa
May 18th, 2019, 5:31 am
Forum: Everything
Topic: I guess I'll start
Replies: 19
Views: 134

Re: I guess I'll start

This might be useful, thanks. I have been messing around with Ray/Line collision, and came up with something that will fill in an area where the rays are pointing ( like a light source or line of sight ). https://i.imgur.com/9BpWOfA.png?1 Right now, it scans each pixel in the entire screen, so not v...