-------------------------------------------------- NOTICE --------------------------------------------------
PEP is not dead, it's just not being worked on. What's that? That
is dead? No no no, you're mistaken. Anyway I
will get around to re-writing a great deal of this with the necessary new features soon. As soon as I've finished my current project. I'm insanely busy right now
------------------------------------------------------------------------------------------------------------
Hello and welcome to the
Placement Editor Professional v1.2.1 thread. Curious? Read on.
To put it simply, Placement Editor Professional (or PEP for short) is the AppGameKit Placement Editor rewritten, completely from scratch, done much better and with many new features. I didn't like the original so I wrote my own. For a more detailed background, read the Introduction in the Documentation.
IMPORTANT: It seems some of you reading this thread came to the conclusion that Placement Editor Professional can only be used with the AGK. This is not true. It can be used with any programming language that can draw 2D sprites and load external files.
This includes DBPro.
I was originally going to name the program "Placement Editor Extreme", but the first time I typed the acronym I decided that name wasn't so good
There are several features that have been requested (eg. Magnetic Snap and Sprite Sheet support) that have been postponed at least until the next release. There were just so many things that needed adding and fixing that they were pushed forward. Sorry
It's worth noting here that the full source code is now included (What's that? No, don't thank me! Really? A 911 Turbo? Well, if you insist!
). If you make something with it (either using it or modding the source), I'd love to know
I don't have time to scan through the TGC forums all the time for threads asking for help on PEP. If you want me to reply to
anything regarding PEP, post in this thread.
TGC, you are welcome (and, in fact, I encourage you) to include Placement Editor Professional in the official release of the AGK.
DOWNLOAD HERE: https://forumfiles.thegamecreators.com/download/2303559
Also in the bottom-right corner of this post, the little red button.
Here's a summary of the most important changes since the last version (most of this stuff is explained in the Docs so don't worry if you don't understand anything here):
- Lots of little fixes and bug-squashings.
- It now asks you whether or not to delete the temp.temp temporary level file created when changing settings from inside PEP.
- You can now properly use floats in the Properties Window.
- All dialogs (including the Properties Window) now make use of the AGK's Editbox commands.
- Arrow-key sprite movement delay is now time-based.
- You can now right-click and drag to move the viewport around. This can be done anywhere on screen, even over buttons.
- There are now keyboard shortcuts for most actions: New=Ctrl+N, Load=Ctrl+L, Save=Ctrl+S, Paint=P, Properties=Tab, Grid=G, Snap=S, Borders=B, NewSpriteLock=N, UVLock=U, LockX=X, LockY=Y, AutoCopy=A, GridWidth=W, GridHeight=H, CentreScreen=C.
- You can now select unlocked sprites when they are underneath locked sprites.
- You can now create a text file with the same name as an image in the Sprites folder to set the default properties of all sprites created with that image.
- You can now press escape to deselect sprites.
- New, better HTML documentation and an HTML documentation generator that took me a whole day to write (source included).
- The Status Bar now informs you when there are no images in the Sprites folder.
- Lots more bug-squashing.
If you're really interested, I wrote a complete list of changes as I completed them. I actually love reading changelogs, because it often gives some insight into the developer's life and programming techniques. Anyway, here it is, hidden away in a code box so that those of you who are scared of changelogs need not be worried:
1.2.1
- Fixed Width and Height in the Properties Window being the wrong way around (Height changed Width and vice versa).
1.2
- Corrected the in-program description for the AutoCopy button. It no longer just says "AutoCopy does stuff".
- Corrected a credit in the Media\Textures\Credits.txt file.
- Fixed a huge problem where AGK Build 107 caused ScreenToWorldX/Y() to be necessary in many areas where it was previously unnecessary.
- "temp.temp" temporary level files (generated after changing PEP settings) are no longer deleted after loading.
- Fixed Properties window data boxes to make use of the new Val()/ValFloat() commands and the new Decimals parameter in Str().
- Rewrote Properties window code again to make use of the new (as of Build 107) EditBox commands. Much better property editing!
- Fixed float values in the Properties window defaulting to 0 if they were clicked on but not changed.
- Properties window EditBoxes now display correct help text when clicked on.
- Changed Properties window help texts to better suit the new EditBoxes.
- After much consideration, removed text support and triggers from my TODO list. Far too much work involved.
- Also removed automatic sprite flipping when resizing into negative sizes from my TODO list. It's actually better the way it is currently.
- Fixed selection box in Properties window. It now highlights the EditBoxes, and stays lit whilst editing.
- Discovered extremely annoying bug with AGK; if you create an EditBox, fix it to the screen, then offset the screen, the visual box stays in the correct place but the internal selection code doesn't account for the offset correctly (ie. it doesn't use ScreenToWorldX/Y()).
- Fixed (hopefully) painted sprites not saving their filenames correctly after the first sprite was placed.
- TGC fixed the above bug with the AGK not long after I reported it; now I'm using BETA3 as it contains the fix.
- Added a "Canceled Features" section to the Notable Improvements file, so people can see easily what's been canceled.
- Corrected gazillions of tiny little errors in the documentation (like "it's" instead of "its").
- Added data type definitions to the settings file documentation.
- Fixed delay when using the arrow keys, now time-based.
- Rewrote requesttext() to create a dialog making use of an editbox and ok/cancel.
- Changed requestok() and requestokcancel() so all text buttons now have a height of 30 and all text buttons and editboxes are seperated by 10, as with the Properties window.
- Discovered some weird bug with a VERY specific combination of loops, globals, datatypes and more globals that causes AGK to crash.
- Yelled "YES!!" when I managed to crash AGK by creating a seperate project and isolating the code that causes the crash. Now to narrow it down to the exact lines and report the bug...
- Added right-click dragging. You can now right-click anywhere on the screen on anything and drag and the viewport will scroll around. You can do this at any time, even when moving or resizing sprites.
- Disabled auto-scrolling when sprites are dragged near the edge of the screen when right-click is held down.
- Added keyboard shortcuts to most buttons: New=Ctrl+N, Load=Ctrl+L, Save=Ctrl+S, Paint=P, Properties=Tab, Grid=G, Snap=S, Borders=B, NewSpriteLock=N, UVLock=U, LockX=X, LockY=Y, AutoCopy=A, GridWidth=W, GridHeight=H, CentreScreen=C.
- Added keyboard shortcuts to all dialogs except the Properties window, so you can press Enter instead of clicking Ok and Escape instead of Cancel.
- Added see-through locking, so it's now possible to select a sprite that's visibly underneath a locked sprite.
- Changed all GetPointerState(), GetPointerX() and GetPointerY() to GetRawMouseLeftState(), GetRawMouseX() and GetRawMouseY() to be consistent.
- Fixed above weird bug (via workaround, it's not actually fixed, though TGC is working on it).
- Fixed Physics Mass in the Properties window being incorrectly read and saved as an integer when it should have been a float.
- Added sprite properties text files. Now you can create a file with the same name as the image and put properties in it so any sprites created with that image will automatically use the properties in the text file.
- Changed Size X and Size Y in the Properties window to Width and Height.
- Changed all occurences of "mirrorh/v" in the code to "mirrorx/y", renamed the images to follow suit and adjusted the credits file to match.
- Updated the documentation to say "mirrorx/y" instead of "mirrorh/v".
- Added pressing Escape to deselect sprites.
- Spent almost literally all day writing an HTML documentation generator to replace the PDF documentation, which is hard to maintain. It's school holidays so I just got up early (ok, 9am isn't early) and started typing, and I didn't realise how long I'd been sitting there till it was 3pm. I even missed lunch. Anyway it's 11:39pm and I just finished it. So far I think it has no bugs and it allows the generation of fairly complex HTML docs so I'm happy. Time for bed, I think.
- Squashed an extra section ("2.4 Removing Sprites") into the docs between 2.3 and 2.4, which shoved sections 2.4-2.6 up one. I hate doing this, because if there's a reference to section 2.5, say, I have to go searching through the rest of the docs checking for it and changing it to 2.6.
- Made several corrections to the documentation.
- Added two new sections to the documentation, "2.8 Moving The Viewport" and "3.3 Sprite Property Text Files".
- Fixed saving levels containing sprites with unedited Name and Properties fields (it used to crash with an error: "String value has not been initialised").
- Fixed temp.temp levels (created when changing PEP settings from inside PEP) being deleted automatically; now it asks what you want to do.
- It just occured to me that I should actually test the sprite property text files. Lo and behold it doesn't work. Great.
- Changed all "setcurrentdir()" to "setfolder()".
- Fixed sprite property text files, turns out it was a stupid-idiot error...I just wasn't thinking (like, at all) when I coded that bit.
- Fixed sprite prop txt files incorrectly loading uv scales and offsets.
- Fixed (via a workaround) the can't-exit-with-the-quit-button bug that was due to "end" not working inside subroutines...come on, TGC! Fix it already!
- Fixed Sprite Property Text Files not requiring the extensions of the image files (I mean they didn't require them and should have, so now they do).
- Fixed rare bug in requesttext() dialogs (such as the Grid Width dialog): sometimes the function would return 0 even when the editbox's value was non-0.
- Made the status bar inform you when you need to add images to Media\Sprites (when there are no images).
- Added a new section to the documentation, "3.4 Keyboard Shortcuts", and updated relevant areas with relevant keyboard shortcuts information.
1.1
- Corrected many, many small errors in the documentation.
- Added the version number to the About dialog.
- Fixed toolbar-screen-move direction (now the screen moves down rather then up when you lower the toolbar).
- Fixed painting with moved viewport.
- Fixed starting painting when dragging the mouse (no longer ignores the Set Paint value).
- Fixed scrollbar precedence over sprites (sprites were selected if under a scrollbar when selecting the scrollbar).
- Fixed holding delete and clicking on sprites (no longer crashes the program).
- Fixed updating of U and V properties when scaling with UV Lock on.
- Added visual grid (finally!). It was friggin hard.
- Added arrow-key-movement, which allows you to move sprites one pixel or "snap" at a time via the arrow keys.
- Added time-based scrollbar movement, so if the program slows down, you can still move the screen at the same speed.
- Updated documentation with information on the new visual grid and also added two new sections, "4.6 Time-Based Movement" and "4.7 The PEP Settings File (And How To Reset It)".
- Fixed Sprite Bar when only using a few sprites (sprites no longer stick to the bottom of the screen).
- Fixed "escape to cancel" in properties window.
- Fixed initial setting of UV values when painting (painted sprites no longer start with UVs of 0,0).
- Fixed UV scaling with UV Lock off and then on (no longer resets UVs to 1,1 randomly).
- Updated level save format to allow for fixed UV scaling. Old files won't be converted and won't load correctly, sorry. However, this new format allows for backwards compatibility for future versions of the save format.
- Updated documentation with information on the new level save format.
- Changed a whole lot of code to better support UV Offsets when they are implemented in future.
- Rewrote properties window code. Now it's much more dynamic and considerably easier to modify the code.
- Rewrote ok/cancel message box code so the width is set to the size of the text.
- Changed current file version to 1.1 to match the current program version.
- Updated documention to reflect changes to file version number format.
- Fixed some major problems with the new properties window (the wrong number of properties were appearing per page).
- Made the properties window much wider.
- Added settings window (click Properties with no sprite selected).
- Added the ability to edit UV offsets via stretching a sprite with UV Lock on or directly via properties.
- Added Auto Copy. When turned on, any new sprites created (including via painting) will be exact copies of the last selected sprite.
- Now when the mouse is over the dropdown arrow on the toolbar, the button turns green.
- Updated Settings.txt with autocopyon setting.
- Updated Settings window with autocopyon setting.
- Added image placeholder system. Now if you try to load a level that contains an image that doesn't exist, it will be replaced with a placeholder image. However, even after you save the level, if you supply the required image, it will be found and used when the level is loaded next.
- Updated documentation with information on the new Properties window and the Settings window with a new section, "2.4 Using The Sprite Properties Window".
- Updated documentation with more information on the UV Lock feature.
- Updated documentation with information on Auto Copy with a new section, "2.5 Using Auto Copy".
- Updated documentation with information on the Ctrl+ClickAndDrag method of cloning sprites with a new section, "2.6 Quick Sprite Cloning".
- Added a Creative Commons license to the source code, so the source code will now be included for you to fiddle with!
- Added Physics Mode and Physics Mass to sprite properties.
- Updated file format with Physics Mode and Physics Mass.
- Added Physics Shape to sprite properties.
- Updated file format with Physics Shape.
- Updated documentation to reflect changes to file format in regards to the new Physics properties.
- Updated example project and loader code.
- Just at the last minute before uploading this version, corrected the Grid button information text (it still said it was disabled!).
- Added full source code to the release zip. Have fun breaking it! xD
1.0
- Initial public release.
The improvements over TGC's Placement Editor are amazing, even if I do say so myself. I know you're interested, so here is a great long list of the current improvements over the original AppGameKit Placement Editor, the planned features, and the canceled features:
Noteable Improvements:
- Visually prettier interface (for example, selection boxes appear when the mouse is over buttons).
- Better sprite scroll bar. Now there's actually a draggable bar!
- Sprites no longer disappear at the top of the Sprite Panel (they slide smoothly out the top AND bottom of the screen).
- Keyboard shortcuts. Now pressing Delete with a sprite selected will delete it.
- Ctrl-Click on a sprite to instantly create an exact copy.
- Full-screen editing; editing area is no longer limited to a preset size.
- "New Sprite" movement locking option. When dragging a new sprite from the sprite area, this toggles whether or not the currently active locks affect the dragging.
- Better, more helpful documentation. Don't understand something? Look it up in the hyperlinked table of contents!
- Support for more then one level; now you can name your levels anything you want.
- Screen resolution-independent text and scroll bars; scroll bars move things at the same speed no matter what the screen resolution is.
- Scroll bars to move the view around, removing the need for the obstructive AppGameKit Virtual Joystick.
- More reliable; everything in Placement Editor Professional has been tested extensively during and after development.
- Status/help text automatically gets smaller if it's too big to fit in the screen.
- More flexible properties in the properties window. Now you can set the position, depth, size (but not scale) and adjust UV coords as well.
- Lockable movement/scaling. Only want to move a sprite sideways? Just lock the Y axis!
- Status/help text provides tips and help for most buttons and windows.
- Settings file. Just open a text file and set scroll speeds, default grid sizes and much more.
- Adjustable paint tool; you can set how many pixels the tool must be dragged before it paints another sprite, and, with SNAP on, how many "snaps".
- Unlockable sprite UVs. This makes background sprites much easier to create, as you just unlock the UVs then drag or scale the sprite.
- Option to make status/help text scroll back and forth rather then get smaller (on by default, as making it smaller can make it too blurry to read).
- New "Properties" field in the sprite properties window, so you can use the Name field purely for naming the sprite.
- Working Cancel buttons. Unlike TGC's original AppGameKit Placement Editor, Placement Editor Professional's cancel buttons actually cancel!
- Multimedia Fusion 2-style locking and unlocking: if a sprite is locked, it cannot be selected. To unlock it, hold Ctrl+Shift and click on it.
- Perfect sprite rotation. Sprites always point straight towards the mouse from where you clicked, and rotate around the centre of the sprite.
- Automatic paint-over prevention: the paint tool never paints over an identical sprite in an identical position (great for backgrounds).
- Secondary toolbar with more buttons - just click the down-arrow at the top of the screen.
- Easy multi-sprite sprite deletion. Just hold Delete and click on the sprites you want to remove.
- Automatic screen scrolling when painting (the same as dragging a sprite to the edge of the screen).
- Better visual grid - this new grid doesn't flicker and disappear when scrolling!
- Settings are written back to settings file on exit, so Placement Editor Professional remembers your grid sizes etc.
- Open-source and free even for commercial use (but not to sell it). Need an editor for your game? Just don't go saying you wrote the original
- Editor settings window - just click Properties with no sprite selected.
- Very good support for UV editing, both directly and interactively.
- Resettable settings file. Stuffed up a setting or want something back to the default? Just delete the settings file, or a specific line in it.
- Mouse dragging to allow the playfield to be dragged around using right mouse button, anywhere on the screen (even over buttons), at any time.
- "See-through" locking (so you can select sprites underneath a locked sprite - the locked sprite is completely ignored).
- Pre-defined sprite properties in text files; load and create sprites with preset properties, for much easier level creation.
- Keyboard shortcuts for most actions, such as S to toggle Snap and Ctrl+H to set the Grid Height.
- 3100+ lines of code, written just for you!
Planned Features (in no particular order):
- Textured Sprite Panel (so blue to light-blue sprites are easier to see).
- Rotation snapping (by degrees).
- Visual page-by-page level selection on saving and loading with preview images.
- Multiselect (selecting more then one sprite at a time for moving, deleting, etc.).
- View zooming (so you can zoom out to see lots at once).
- Visual "rotation snapping circle" (a circle surrounding the sprite with snapping points marked so you can see where the sprite will snap to when rotating).
- Save/Save As, so you don't have to type the level name every time you save.
- Autosaving at adjustable intervals - never lose a level ever again!
- Detailed tutorials, so you don't have guess at how to make full use of Placement Editor Professional.
- Magnetic Snap - sprites can optionally snap to each other based on how close they are together.
- Support for sprite sheets, whether that be a sheet of frames for an animated sprite or a sheet of multiple sprites.
- Sprites in the Sprite Panel that have Sprite Property Text Files are modified according to the text file so you can see what you're about to place.
Canceled Features:
- Automatic sprite flipping when resizing into negative sizes.
- Triggers (solid-colour sprites of various shapes that are exported but only loaded as checkable regions).
- Text creation and editing.
This time I have some screenshots for you. They were taken from version 1.1, but nothing has changed visually since then. Here they are:
If you find any bugs, please tell me and give an example of how to reproduce the bug(s).
I really enjoyed making this program and hope you enjoy using it
Have fun breaking the source code
(Why do I always say this? My code is so complicated and lacking in useful comments that I doubt anyone else could successfully make big changes without breaking it, that's why.)
Enjoy,
Clonkex