View unanswered posts | View active topics It is currently Fri Jan 10, 2025 6:06 am



Reply to topic  [ 10 posts ] 
 x y Overlay 
Author Message
User avatar

Joined: Mon Jun 29, 2009 10:34 pm
Posts: 51
Reply with quote
Post x y Overlay
Is there any way to put a CC x y grid overlay on a sprite or scene so that you can find cordinates without using trial and error in the game?


Wed Jul 01, 2009 7:01 pm
Profile
User avatar

Joined: Sun May 11, 2008 12:50 pm
Posts: 899
Reply with quote
Post Re: x y Overlay
Image


Wed Jul 01, 2009 7:07 pm
Profile WWW
User avatar

Joined: Thu Mar 06, 2008 10:54 pm
Posts: 1360
Location: USA
Reply with quote
Post Re: x y Overlay
I think this is what you are asking, so if you want to find what point the thing is at, you could attach a lua script and put

Code:
Function Create(self)
end
Function Update(self)
print("Vector(self.Pos.X, self.Pos.Y)")
end


Then press the "~" key when you select the item you attached the script to in the editor and it should print the coordinate that the item is at.

Hope this helps.



Oh. I read this wrong. Look at roon's


Wed Jul 01, 2009 7:08 pm
Profile
User avatar

Joined: Wed Nov 22, 2006 3:19 pm
Posts: 2073
Reply with quote
Post Re: x y Overlay
TechnoGeek wrote:
Is there any way to put a CC x y grid overlay on a sprite or scene so that you can find cordinates without using trial and error in the game?


Stop being a pussy!
Calculate offsets with your brain!
Its not hard, but tricky, because in CC (+) is (-) and (-) is (+)


Wed Jul 01, 2009 7:15 pm
Profile
REAL AMERICAN HERO
User avatar

Joined: Sat Jan 27, 2007 10:25 pm
Posts: 5655
Reply with quote
Post Re: x y Overlay
CC's scene offsets are all calculated from the top left of the scene, as if the entire scene were in the fourth quadrant of a graph. Thus, an offset of 0 in X means it'll be exactly on the edge of the scene. Similarly, an X offset exactly as long as the scene puts it at the same edge, but the other side of it.

If you just look at the scene bitmap and draw lines from the top and left to where you want things, that'll get you what you need. Mind's method also works, and then there's always trial and error. Or use the scene editor to place things, then change them in the scene code.

Really there's plenty of ways to do it.


Wed Jul 01, 2009 7:23 pm
Profile
User avatar

Joined: Mon Jun 29, 2009 10:34 pm
Posts: 51
Reply with quote
Post Re: x y Overlay
So is each pixel one unit of movement along the axis?


Wed Jul 01, 2009 9:04 pm
Profile
User avatar

Joined: Wed Nov 22, 2006 3:19 pm
Posts: 2073
Reply with quote
Post Re: x y Overlay
TechnoGeek wrote:
So is each pixel one unit of movement along the axis?


Yes.


Wed Jul 01, 2009 9:07 pm
Profile
User avatar

Joined: Mon Jun 29, 2009 10:34 pm
Posts: 51
Reply with quote
Post Re: x y Overlay
Thanks for all the help guys. I know i sound like a noob but this is my first scene! :grin:


Wed Jul 01, 2009 9:09 pm
Profile
Banned
User avatar

Joined: Tue Feb 27, 2007 4:05 pm
Posts: 2527
Reply with quote
Post Re: x y Overlay
I'm sure it's going to be awe-inspiring.


Thu Jul 02, 2009 4:31 am
Profile YIM
User avatar

Joined: Sun Jul 13, 2008 9:57 am
Posts: 4886
Location: some compy
Reply with quote
Post Re: x y Overlay
oh you cad.
when you draw a line in paint, it even "offsets" it correctly for you.


Thu Jul 02, 2009 8:01 am
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 10 posts ] 

Who is online

Users browsing this forum: Google [Bot]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.192s | 14 Queries | GZIP : Off ]