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

Author Topic: Tilemap Editor (working title)  (Read 38195 times)

0 Members and 1 Guest are viewing this topic.

TricksterGuy

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
Tilemap Editor (working title)
« Reply #30 on: June 20, 2010, 07:08:47 am »
Its not really a big deal, its just numbers really nothing no one should get worked up over. Besides this only happens in the xml and txt exporters.

Also I do not understand your post.  The data is not compressed it is laid out in a format readable for other people.

I mean if it really bothers someone that I used -1 for the for the unused tile then they can just manually put as the first tile in their tileset an empty tile that is completely transparent and then when they create a new map fill it with tile 0.


But yeah not enough reason for me to change it

And this is all I am saying on this matter


Here is a screenshot of the current thing I am working on (Animated Tiles)

gsaurus

  • Sr. Member
  • ****
  • Posts: 262
    • View Profile
    • Evolution Engine
Tilemap Editor (working title)
« Reply #31 on: June 20, 2010, 11:10:17 am »
This reminds me of Jazz Jackrabbit 2 Creation Station  :P
Pluma - Plug-in Management Framework

Ashenwraith

  • Sr. Member
  • ****
  • Posts: 270
    • View Profile
Tilemap Editor (working title)
« Reply #32 on: June 21, 2010, 01:04:58 pm »
Hey sorry, not trying to be a pain.

I'm just saying it makes sense to use a unique character instead of a negative number because if you were to compress the data you would have less data.

Plus it makes it more readable and easier for novices to edit with find/replace in text editors--which is always powerful.

Nothingness0x

  • Sr. Member
  • ****
  • Posts: 292
    • View Profile
Tilemap Editor (working title)
« Reply #33 on: June 22, 2010, 07:06:58 am »
hey,

1) I was wondering if i can import my own tiles set in your editor ?

2) If yes do i have to respect some rulez to make it work as good as your exemple with your tiles ?

3) Why I still can't put collisions on the map ?

4) Collisions and layer management are saved and managed by the map walker ? I mean my character will directly be stop by a collision or will be able to walk behind a tree ?

5) After the animated tiles, do you expect to do something else or the editor will be finished ?

Good job for your editor, i cant wait for the last release so i can use it for my RPG

TricksterGuy

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
Tilemap Editor (working title)
« Reply #34 on: June 22, 2010, 10:17:54 am »
Quote from: "Ashenwraith"
Hey sorry, not trying to be a pain.

I'm just saying it makes sense to use a unique character instead of a negative number because if you were to compress the data you would have less data.

Plus it makes it more readable and easier for novices to edit with find/replace in text editors--which is always powerful.


Yes, I keep what you say in mind; However the data is not compressed at the moment as right now I am only implementing the most important (and sometimes easiest) set of features to implement each release.  I have not touched compression yet, however when I do I will consider what you have told me here, but as of now I am not worried about compression yet.

Quote from: "Nothingness0x"
hey,

1) I was wondering if i can import my own tiles set in your editor ?

2) If yes do i have to respect some rulez to make it work as good as your exemple with your tiles ?

3) Why I still can't put collisions on the map ?

4) Collisions and layer management are saved and managed by the map walker ? I mean my character will directly be stop by a collision or will be able to walk behind a tree ?

5) After the animated tiles, do you expect to do something else or the editor will be finished ?

Good job for your editor, i cant wait for the last release so i can use it for my RPG


1) Yes find an image. In the menu Choose Tileset and Choose Change...
2) Image must be loadable from within SFML
3) In the menu choose Map then choose Properties.  Under the collision tab in the Notebook Control Check the HasCollisionLayer checkbox
Choose MapBased and TileBased in the radiobutton groups.  Click Ok.

Change the Current Layer to Collision.  there.

4) It is saved in the .map file for more information read the user manual.
If there is a collision (it is denoted by a glowing red tile) then the player will not be able to walk there.

5) There will be a list of everything I will be doing in the user manual next version, But I am far from finished; However, don't let this stop you from using the program. As of now (minus animated tiles and other collision types) It is usable for creating 2d rectangular maps.

And I don't plan on changing the .map format for awhile so your .map files should remain compatible between updates for awhile. (And if I do change it I will include an option to load from the previous format as I have done for .map files created with the first few versions of the program).

And thanks!

Nothingness0x

  • Sr. Member
  • ****
  • Posts: 292
    • View Profile
Tilemap Editor (working title)
« Reply #35 on: June 22, 2010, 11:05:40 am »
i forgot to ask , is it a "pixel perfect" method of collision ? because its important in a rpg, a rectangle collision method is not realist ...

and how do i put collision on the limit of the map, so the player cant get out of the window ?

the .map is an image that i load in my game ? Or just a file with information about the tiles and collision ? Because if the map is bigger than the screen, does it work ? (i have a scrolling management)

 thx

Nothingness0x

  • Sr. Member
  • ****
  • Posts: 292
    • View Profile
Tilemap Editor (working title)
« Reply #36 on: June 22, 2010, 01:50:30 pm »
I also would like to report a bug :

When you try to switch the current layer and The select tool is activated, the program crashes.

Do not forget to answer my questions above though  :D

TricksterGuy

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
Tilemap Editor (working title)
« Reply #37 on: June 22, 2010, 05:21:48 pm »
Quote from: "Nothingness0x"
i forgot to ask , is it a "pixel perfect" method of collision ? because its important in a rpg, a rectangle collision method is not realist ...


No. The collision as of now is defined per tile not per pixel.
So you can tell which tiles on the map as of now are not passable.
If you want per pixel you will have to wait.

Quote from: "Nothingness0x"

and how do i put collision on the limit of the map, so the player cant get out of the window ?


The way I coded my map playback thing for SFML is that the player can not go outside the bounds of the map.

Quote from: "Nothingness0x"

the .map is an image that i load in my game ? Or just a file with information about the tiles and collision ? Because if the map is bigger than the screen, does it work ? (i have a scrolling management)
 thx


No it is not an image, again information on what this file contains is explained in the manual like the very last few pages I talk about how the information is laid out in that file, but basically each layer, each background, and the collision layer are stored.  You must also have the tileset you used for the map in your project as the tileset graphics is not stored in the map file. (As I find it better this way storing the tileset with the map makes things bloated if you use the same tileset for each map).


But yeah this was in the first post, but it is the source code I have written to make a small program that

1) Loads a map
2) Displays a player
3) You can move the player around with the arrow keys
4) It does check if the player can move to that tile. (Collision Layer)
5) The player can not go outside of the map.
6) Scrolls the map if the map is bigger than the screen and the player moves (The player is always in the center except for when he reaches the edge of the screen).




Quote from: "Nothingness0x"
I also would like to report a bug :

When you try to switch the current layer and The select tool is activated, the program crashes.

Do not forget to answer my questions above though  :D


Ok, I will have this fixed.

Nothingness0x

  • Sr. Member
  • ****
  • Posts: 292
    • View Profile
Tilemap Editor (working title)
« Reply #38 on: June 23, 2010, 02:19:04 am »
I tried to test your map walker but the compilation doesnt work, why ?

Here are the error I get :

||=== MapWalker, Debug ===|
C:\Users\user\Desktop\New Folder\map walker\Background.hpp|46|error: `sf::Renderer' has not been declared|

C:\Users\user\Desktop\New Folder\map walker\Background.hpp|46|error: ISO C++ forbids declaration of `queue' with no type|

C:\Users\user\Desktop\New Folder\map walker\Player.hpp|28|error: `sf::Renderer' has not been declared|

C:\Users\user\Desktop\New Folder\map walker\Player.hpp|28|error: ISO C++ forbids declaration of `queue' with no type|

C:\Users\user\Desktop\New Folder\map walker\Player.hpp|51|error: cannot declare variable `player' to be of type `Player'|

C:\Users\user\Desktop\New Folder\map walker\Player.hpp|51|error:   because the following virtual functions are abstract:|

C:\Program Files (x86)\CodeBlocks\SFML-1.5\include\SFML\Graphics\Drawable.hpp|341|error:  virtual void sf::Drawable::Render(sf::RenderTarget&) const|

C:\Users\user\Desktop\New Folder\map walker\Map.hpp|60|error: `sf::Renderer' has not been declared|

C:\Users\user\Desktop\New Folder\map walker\Map.hpp|60|error: ISO C++ forbids declaration of `queue' with no type|

C:\Users\user\Desktop\New Folder\map walker\Map.hpp|80|error: cannot declare variable `map' to be of type `Map'|

C:\Users\user\Desktop\New Folder\map walker\Map.hpp|80|error:   because the following virtual functions are abstract:|

C:\Program Files (x86)\CodeBlocks\SFML-1.5\include\SFML\Graphics\Drawable.hpp|341|error:  virtual void sf::Drawable::Render(sf::RenderTarget&) const|

C:\Users\user\Desktop\New Folder\map walker\BinaryMapReader.cpp||In member function `int BinaryMapReader::ReadBGDS(std::ifstream&, Map&)':|

C:\Users\user\Desktop\New Folder\map walker\BinaryMapReader.cpp|304|error: cannot allocate an object of type `Background'|

C:\Users\user\Desktop\New Folder\map walker\BinaryMapReader.cpp|304|error:   because the following virtual functions are abstract:|

C:\Program Files (x86)\CodeBlocks\SFML-1.5\include\SFML\Graphics\Drawable.hpp|341|error:  virtual void sf::Drawable::Render(sf::RenderTarget&) const|

TricksterGuy

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
Tilemap Editor (working title)
« Reply #39 on: June 23, 2010, 03:24:20 am »
It requires using SFML 2.x

Nothingness0x

  • Sr. Member
  • ****
  • Posts: 292
    • View Profile
Tilemap Editor (working title)
« Reply #40 on: June 23, 2010, 03:40:21 am »
ohh okay :) anyway I will wait the last version of your program to finally use it, so maybe in that time sfml 2 will be realesed :)

Anyway you're a genius and I hope you'll finish your editor in an ultimate version very soon :)

ps : can you post a .exe version of what the map walker is supposed to be ? So i can just see without getting sfml 2 and without compiling, if you dont have time its no big deal :)

TricksterGuy

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
Tilemap Editor (working title)
« Reply #41 on: June 23, 2010, 04:07:57 am »
It is included with the program.

I.e. When you select PlayTest within the View menu it automatically runs that program passing the current map as a parameter.

Nothingness0x

  • Sr. Member
  • ****
  • Posts: 292
    • View Profile
Tilemap Editor (working title)
« Reply #42 on: June 23, 2010, 04:36:53 am »
I saw that but it doesnt work, i see a windows opening and close directly ...
do i have to put a start for a suppose character or i dunno ?

But i was talkiing about a .exe in the map walker folder, i mean you compile it and you post it with the exe inside cause i cannot compile without sfml 2.

strange anyway for the play test ..

Nothingness0x

  • Sr. Member
  • ****
  • Posts: 292
    • View Profile
Tilemap Editor (working title)
« Reply #43 on: June 23, 2010, 05:19:43 am »
i noticed problems with backgrounds, i can't make it run left to right for example, its always up to down, i cant control the speed of its scrolling, in the exemple Hey.map i cant remove the background below the grass part ...

TricksterGuy

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
Tilemap Editor (working title)
« Reply #44 on: June 23, 2010, 05:41:31 am »
Quote from: "Nothingness0x"
i noticed problems with backgrounds, i can't make it run left to right for example, its always up to down, i cant control the speed of its scrolling, in the exemple Hey.map i cant remove the background below the grass part ...


It is a background. Not a layer.  To change how the background scrolls

Under the Map window, Choose properties.

In the Notebook choose the Background Tab.

From there there should be a Background called The Sky.  Select it from the Listbox.  You can then modify the properties of this background such as the speed it scrolls and its direction.


Also Like I said a few posts back, If you wait until I am completely done with the program you will be waiting forever.  I get (or think of) feature requests on stuff to add all of the time. You could be waiting infinitely for it!

This may help a bit to see where I am, but I will update the features list (It will be in the user manual in a nicer format than presented here) in the next version http://trickster.wg2140.com/Temp/requirements.txt

 

anything