What I want to do is make a level in paint.net by drawing certain colored pixels and having the Level class decode this into an array of tiles, and if I want an entity to spawn on a certain tile, put the info necessary into the right pixel on the .png for the level.

Is this possible at all? How do I put the data into the image? How do I read the data from the image?

To load: Get the pixel data from the image (Depending on what library you're using the method to get the data this will differ, though not too considerably), then you iterate through each pixel and get the color data from it. From there, you should be able to take information out of that value (Either by using a set of if statements, a switch, maybe even using several arrays filled with the corresponding data you need, etc.)

To edit/paint: This is more complicated. If you're using Paint.net (Which I've used for a simplified version of this) then you just have to be very specific about how you fill in the values of the color (Use the 'More >>' to be able to pick a specific color value). Then you just fill in the specific pixel with that data. The main issue is that if you're using each color channel (including Alpha) to mean something different you have to get that color (Using the eye drop) edit it using the color panel, then refill it in.

For anything complicated, attempting to draw it all using Paint.net is probably going to be more difficult to keep straight than writing your own tile editor system (Even if it outputs data in the form of an image).

java-gaming.org is not responsible for the content posted by its members, including references to external websites,
and other references that may or may not have a relation with our primarily
gaming and game production oriented community.
inquiries and complaints can be sent via email to the info‑account of the
company managing the website of java‑gaming.org