>
>
> Subject: Re: tiles and Sprite Surface
> From: "Joseph J. Strout" <joe at realsoftware dot com>
> Date: Sat, 26 Jul 2003 16:31:44 -0700
>
> At 5:45 PM -0500 7/26/03, Eric wrote:
>
> >Ok in the PaintTile I have this
> > g.drawPicture
> >Tiles(game_Map_Layers(1).Get_Tile_ID(ypos+1,xpos+1)).Get_TileImage,ypos,xpos
>
> ...
>
> You shouldn't be drawing them at YPos, XYos, or at least I can't
> think of any reason why you should be doing so. You should be
> drawing them at 0,0 if your tiles match SpriteSurface tiles in size.
>
> Yours don't -- you'd need to draw four of your tiles for each one of
> the SpriteSurface's tiles. But that's going to be a little more
> complex, and since you're new at this, you should be looking for ways
> to make your life easier. Using 64x64 tiles will do that. I highly
> recommend you switch to that for this project, and go back to smaller
> tile sizes later when you have more experience under your belt.
>
> Also, you really should study the existing examples. They virtually
> all show how to do this properly, thus avoiding the need to
> . If you really don't do well from examples, then perhaps
> you'd do better with a book -- for example, REALbasic: The Definitive
> Guide has a chapter on the SpriteSurface and explains this stuff
> pretty well.
>
> OTOH, learning by doing is good too, and don't be shy about asking
> here when you get stuck!
>
> Cheers,
> - Joe
>
> --
So would I use xpos and ypos for look at data in a map?
Ok I'm lost.... so draw at 0,0?
Tiles(game_Map_Layers(1).Get_Tile_ID(ypos+1,xpos+1)).Get_TileImage,?,?
What would do in the ?'s place? Do I use a loop or increment it
some how?
The map data is an array. So what ever is in say Map(0,1) the tile
that matches it needs to be drawn at the spot in Sprite Surface right?
So where do I get the x,y from? - Assuming the tiles are 64 x 64.
Since I don't know much about SpriteSurface in's and out's would it not
be better for Spritesurface to draw at what ever the tiles size's are rather
than a set 64x64?
Well going with 64x64 tiles wouldn't be to hard. I would have to
scale the tiles up though I don't know if they will look still look good.
Well I haven't made a bunch of tiles yet for this project...but my other...
Mapping it out wouldn't be hard at all to change. Just have to set my
Map Maker to a 64 x64 tile/grid size.
So if I use 32x32 I would need to draw 4 for ever I tile of Sprite Surface...ewe
That sounds very hard....
Well I check my cd no platform demo or any good examples or demos....
A book? Well If I wasn't laid off perhaps..... :-(
Going from Canvas to Sprite Surface is bit of a pain. Drawing
the tiles in Canvas is easy.
Thanks
Eric
---
A searchable archive of this list is available at:
<http://support.realsoftware.com/listarchives/search.php>
Unsubscribe or switch delivery mode:
<http://support.realsoftware.com/listmanager/>
.
|