Author Topic: layout question  (Read 34849 times)

1024

  • Guest
layout question
« on: July 27, 2009, 01:18:28 PM »
Hi, I'm new to the game, played several levels and thought I'd have to try editing levels. I tried to decrease the standard 4x4 grid to 3x3 - it seems to work - but the board around it is the same size. How do I change that? Also, will there be any detailed info on how to create layouts for the boards? Thanks in advance.

admin

  • Rob
  • Administrator
  • Widgeteer
  • *****
  • Posts: 218
    • View Profile
Re: layout question
« Reply #1 on: July 27, 2009, 11:47:07 PM »
Hey, 1024 -

The Cogs engine doesn't support scaling of geometry, so if you want to make a 3x3 frame for a new board, you'll need to build it (i.e., it won't let you just scale the 4x4 frame by 75%).  The existing 4x4 boards are saved in a custom .strip format that's designed to make it fast to load -- but there are no good tools out there for editing it.  Thankfully, Cogs also supports triangulated .obj files with position, normal, and texture coordinate data, which you can export from just about any modeling software.  So in short, here are three options:

  - Using 3D modeling tools like Maya, 3D Studio Max, or a free alternative like Blender, build your own 3x3 board.
  - Or send an email to rob@lazy8studios.com and I'll send you the .obj file for the existing 4x4 board so that you can make some simple edits using one of the tools mentioned above.
  - Or send an email to rob@lazy8studios.com and I'll scale the model for you and send you an .obj or .strip file that you can use.

Glad to hear that you're trying to make some puzzles of your own!  Let me know if you find any of the documentation confusing or if you need any other assistance.

  - Rob
    Founder, Lazy 8 Studios

Brendan

  • Lead Artist
  • Administrator
  • Widgeteer
  • *****
  • Posts: 101
    • View Profile
Re: layout question
« Reply #2 on: July 28, 2009, 12:18:32 AM »
You could also use one of the existing boards like a 3x4 (MESH  data/models/board3x4-01.obj or board3x4-02.obj under the MODELCOUNT) and block off a row with unmoveable tiles. Set the slideOK to 0000 for their positions and use LIBMESH meshBlock for gadget geometry.  Something like twogears.puzzle is a good example.

1024

  • Guest
Re: layout question
« Reply #3 on: July 28, 2009, 01:33:39 AM »
Many thanks for your replies. I like level editing, in fact, usually first thing I'm looking for in a game is a method to create (and maybe share) own levels, and this game has it while being fun at the same time - a rare combination.

I used to be experimenting around with modeling but I found it difficult and time consuming. I might give it a go again later but not this time. Nice that you offer your own models for editing though. Blocking off a line of the 3x4 seems the best solution so far.

I think the documentation is fairly clear, however I didn't work out at first that the layouts are somewhat fixed - as I see now. I could make layouts but the borders seem fixed - specific models; first I thought they're generated somehow. For example, I don't think I could make a 7x7 puzzle now (not that I want to, but as an example). Judging by your replies you seem to be the game developer(s) or close to them, and I heared  you're planning expansion packs.  I know this is no request feature forum, but I'd love a way to be able to contsruct my own border using tile-sized pieces that fit together. I know I could model these myself - maybe I will one day - but it's easier to ask here.

Also, thanks for your support and with ongoing support I can guarantee at least a few puzzles in a couple of weeks/months or so. My ultimate plan is to make a cube level where the camera is in it and you have to work on the inside of the cube... but that's just a long-term plan so far.

edit: also, just for the lol


managed to rotate it, but seems a bit shifted away


I know I could just copypaste from a default level, but I'm trying to learn here.
Now that I think of it, some reference on sizes would be nice (how big is a tile, the boarders etc.)
« Last Edit: July 28, 2009, 02:32:16 AM by 1024 »

Brendan

  • Lead Artist
  • Administrator
  • Widgeteer
  • *****
  • Posts: 101
    • View Profile
Re: layout question
« Reply #4 on: July 28, 2009, 12:42:42 PM »
Ah, that's an easy one - every tile is 1x1 game units.  It's mentioned in the beginning of the tiles section in the wiki, maybe we can make that more apparent.

It looks like your layout is still set up in positions for a 4x4 puzzle, all you need to do is (correct me if I'm wrong Rob) add another .5 to each of the posX values in your board layout, which should shift them all half a unit to the right.

Dude, the modular board is a great idea and would not be hard to do using our existing models.  Let me get back to you on that one. :)  And yes, Rob (admin) and I are the developers.

1024

  • Guest
Re: layout question
« Reply #5 on: July 28, 2009, 01:10:55 PM »
Thanks that 0.5 really worked. This is getting easier.

I need to know though and it wasn't clear from the docs (maybe just my fault). According to the txt file, I place a tile to all positions 0-8. But there's an empty place at position 8. How does it work?

notgreat

  • Apprentice
  • *
  • Posts: 26
    • View Profile
Re: layout question
« Reply #6 on: July 28, 2009, 03:43:46 PM »
Just don't place any gadgets on the position 8 tile to make it a blank space.

admin

  • Rob
  • Administrator
  • Widgeteer
  • *****
  • Posts: 218
    • View Profile
Re: layout question
« Reply #7 on: July 28, 2009, 11:46:40 PM »
Hi, 1024 -

As you experiment with level construction, make sure you're not confusing board spaces with tiles.  For instance, a 3x3 puzzle has 9 board spaces (defined at the top of your puzzle file) but only 8 tiles (defined at the bottom of your puzzle file).

When you add or remove tiles, make sure you update your TILECOUNT.  If it seems like tiles are missing, this is probably the cause.  For a 3x3 puzzle with a border, your TILECOUNT will probably be 9 -- 8 sliding tiles, plus the border geometry.

I'm not sure if it will work to have the camera inside of a cube, but you might as well give it a try.  You'll have to play around with the CAMERA and LOOKAT parameters to get that working.

  - Rob
    (Level designer and programmer for Cogs)

1024

  • Guest
Re: layout question
« Reply #8 on: July 29, 2009, 01:05:42 AM »
Thanks, it worked. I also added the line of blocks. This was a bit of a pain cause the game is very very sensitive on the txt file, I got it to work after about 5 tries. I'll move on gadgets now as I think I understand 2D layouts now.



I think I'll ask for a 3x3 one though.

edit: Also, I saw at finishconditions that animations can be made, I'm not sure if it involves just specific models or tiles. It'd be nice to move around tiles when the level ends, to move around the tiles in a synchronized way, is it possible?

2nd edit: Thanks for the 3x3 border!

« Last Edit: July 29, 2009, 01:07:30 PM by 1024 »

admin

  • Rob
  • Administrator
  • Widgeteer
  • *****
  • Posts: 218
    • View Profile
Re: layout question
« Reply #9 on: July 29, 2009, 01:19:06 PM »
Yes, you could create an animation that makes the tiles move when a puzzle is completed.  It may be a little tricky to wrap your head around: what would happen is that the tile origins would actually stay where they are, but the tile geometry could be animated to make it look like the tiles are sliding.

Congrats on mastering board layouts -- they're tricky.  IMHO, gadgets are a little more intuitive to work with and way more fun.

  - Rob
    Founder, Lazy 8 Studios

Brendan

  • Lead Artist
  • Administrator
  • Widgeteer
  • *****
  • Posts: 101
    • View Profile
Re: layout question
« Reply #10 on: July 30, 2009, 01:13:50 PM »
Ack, you just scaled down a 4x4 to make a 3x3?  My eyes!!! x.x

I'll make you a proper 3x3 today.  And those modular pieces, I like that idea.

Edit: Here ya go:  http://www.lazy8studios.com/downloads/board3x3-01.obj
« Last Edit: July 30, 2009, 06:38:35 PM by Brendan »

1024

  • Guest
Re: layout question
« Reply #11 on: July 30, 2009, 10:24:48 PM »
Thanks, I already put it in my first level, and the second will include it too as soon as I get started with it, maybe more later.

Brendan

  • Lead Artist
  • Administrator
  • Widgeteer
  • *****
  • Posts: 101
    • View Profile
Re: layout question
« Reply #12 on: July 31, 2009, 06:33:11 PM »
I put up a thread for extra asset downloads:
http://forum.lazy8studios.com/index.php?topic=103.0