Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Mr. House

Pages: [1]
1
Graphics / Comparing Images
« on: December 31, 2011, 02:52:25 pm »
Hello,

I'm trying to check if one image matches another for a platforming game (to check if the tile is solid).

I have this snippet of code

Code: [Select]
if(TileMapObj->TileMapVect[i].GetImage() == TileMapObj->TileVect[1])

and it is giving me the error "no match for operator== in ...."

TileMapVect is a vector that contains sf::Sprites while TileVect is a vector that contains objects of type sf::Image.

So yea, I'm probably trying to compare apples and oranges.

2
Graphics / Changing center of rotation
« on: October 12, 2011, 11:44:07 pm »
Nevermind, I figured it out.

3
Graphics / Changing center of rotation
« on: October 12, 2011, 10:16:55 pm »
It doesn't seem to though. I used SetCenter(50,50) but it doesn't place it at point (50,50). I don't get it :/

Would you like me to post my code and see if you can offer me a solution?

4
Graphics / Changing center of rotation
« on: October 12, 2011, 03:16:21 am »
Hello,

I have a sprite that I would like to rotate around a point that is not the origin nor a point of the shape.

Here is a screenshot of my situation:

http://i.minus.com/ibt8ncX55ODhrh.png

I want that yellow sprite to rotate around the centerpoint of that circle like the Moon around the earth, so that the sprite follows the shape of the sectors.

I've tried messing around with the Sprite.SetCenter() methods but I'm not sure if what I'm doing is right.

Anyone have any wisdom on this matter? I'll post my code if needed. I'm using 1.6.

Pages: [1]
anything