|
1 |
| -# Cortex Command Community Project Bender |
| 1 | +# Cortex Command Bender |
2 | 2 |
|
3 | 3 | ## About
|
4 | 4 |
|
5 |
| -The purpose of this tool is to make the life of modders easier by automagically generating bent limb sprites from limb parts. |
6 |
| - |
7 |
| -The CC Bender was originally created by Arne Jansson ([**AndroidArts**](https://twitter.com/AndroidArts)), the man behind all the Cortex Command artwork. |
8 |
| - |
9 |
| -The CCCommunityProject Bender, however, is a brand new tool that allows more control and convenience for the modder (hopefully). |
10 |
| - |
11 |
| -Arne's original bend code was used as base and has been modified and improved to enable new features. |
| 5 | +The purpose of this tool is to make the life of modders easier by automagically generating bent limb sprites from limb parts. |
| 6 | +The CC Bender was originally created by Arne Jansson ([**AndroidArts**](https://twitter.com/AndroidArts)), the man behind all the Cortex Command artwork. |
| 7 | +This version however is a brand new tool that allows more control and convenience for the modder (hopefully). |
| 8 | +Arne's original bend code was used as base and has been modified and improved to enable new features. |
12 | 9 |
|
13 | 10 | **Do note that the generated output from this tool is not ideal and will most likely require some manual touching up for best results.**
|
14 | 11 |
|
15 |
| -### Features |
16 |
| - |
17 |
| -- GUI |
18 |
| -- Loading/saving files. |
19 |
| -- Adjusting joint position. |
20 |
| -- Zoom setting on input image for easy joint adjustment. |
21 |
| -- Frames number output setting. |
22 |
| -- Background color setting. |
23 |
| -- Automatic setting of background color to magenta on save. |
24 |
| -- Saving as PNG or Indexed BMP (CC Palette). |
25 |
| -- Saving as individual named frames. |
| 12 | +## Feature Info |
| 13 | + |
| 14 | +1. **Input Files:** |
| 15 | + - This tool is not a miracle maker and can only do it's job when fed a properly set up input file: |
| 16 | + - Input files **must** be **exactly** 192x24px for everything to work as intended. Wrong dimensions will be rejected. |
| 17 | + - Input files **must** use Magenta (255,0,255) for anything that needs to be transparent/masked. |
| 18 | + - The order of limb parts in the input file **is important!** Order should be as specified, going left to right: |
| 19 | + *Upper Arm FG*, *Lower Arm FG*, *Upper Arm BG*, *Lower Arm BG*, *Upper Leg FG*, *Lower Leg FG*, *Upper Leg BG*, *Lower Leg BG*. |
| 20 | + - Arm parts should be facing **right** for correct bending! |
| 21 | + - Leg parts should be facing **left** for correct bending! |
| 22 | + - See included *"TestImage.png"* to understand how your input file should look like. |
| 23 | + - Supports loading BMP and PNG input files. |
| 24 | + |
| 25 | +2. **Background Color:** |
| 26 | + - Set values in the **RGB** textboxes to change the color of the background for easier inspection/personal preference. |
| 27 | + - Background color will be set to Magenta (255,0,255) automatically when save is clicked so setting it manually beforehand is not required. |
| 28 | + |
| 29 | +3. **Input Zoom:** |
| 30 | + - Set value in the **Input Zoom** textbox to magnify the input image for easier joint adjustment. |
| 31 | + - The maximum zoom value is calculated from the desktop width. 5 for 1366px, 11 for 2560px, etc. |
| 32 | + - When zooming, the joint markers will reset to original positions. First zoom, then adjust. |
| 33 | + |
| 34 | +4. **Output Zoom:** |
| 35 | + - Set value in the **Output Zoom** textbox to magnify the output for easier inspection. Maximum zoom value is 5. |
| 36 | + - When the output is zoomed, the workspace can be panned by clicking and dragging so everything that doesn't fit into the visible area can also be inspected. |
| 37 | + - The output zoom setting does not affect saved files. Those will be saved with no magnification. |
| 38 | + |
| 39 | +5. **Frame Count:** |
| 40 | + - Set value in the **Frame Count** textbox to change the number of bent limb frames. Maximum frame count is 20. |
| 41 | + - Bend angle will adjust automatically to the number of frames. First/Last frames will always be fully bent/unbent. |
| 42 | + |
| 43 | +6. **Indexed Color:** |
| 44 | + - Supports saving as RGB332 (8bpp) BMP and PNG formats. The desired format can be selected from a combo box when the **Save as Indexed** checkbox is ticked. |
| 45 | + - Saved files will be indexed to the *Cortex Command* palette. |
| 46 | + |
| 47 | +7. **Output Files:** |
| 48 | + - Output can be saved as either one file containing all the frames or individual frames. |
| 49 | + - Saved files are RGB888 (24bpp) PNG unless specified otherwise by **Save as Indexed**. |
| 50 | + - File extension will be added automatically so there is no need to add it manually. Avoid doing so. |
| 51 | + - When **Save as Frames** is ticked: |
| 52 | + - A visual aid will be shown around each frame to help the user stay within bounds. |
| 53 | + - Exported frames will be flipped (legs only), rotated and cropped automatically so no extra manual labor is required. |
| 54 | + - Limb names and frame numbers will be added automatically. **Doing so manually will result in horrible exported file names!** |
| 55 | + |
| 56 | +8. **Joint Adjustment:** |
| 57 | + - Joints can be adjusted individually on both axis. |
| 58 | + - Clicking or clicking and dragging in the limb tile area will set the joint marker. |
| 59 | + - The top joint marker adjusts the length and offset (and in turn rotation) of the limb part, while the bottom marker only adjusts length. |
| 60 | + |
| 61 | +9. **Layering Controls:** |
| 62 | + - Draw order of limb parts in each limb can be adjusted by ticking the limb checkbox in the layering controls panel. |
| 63 | + |
| 64 | +10. **Defaults and User Settings:** |
| 65 | + - A file with the current editor settings can be exported using the **Save Settings** button in the title bar. |
| 66 | + - If a settings file exists, it will be loaded and applied automatically on startup. Invalid property values will be overridden. |
| 67 | + - Settings file properties are self explanatory. |
| 68 | + - Properties that cannot be set through the GUI: |
| 69 | + - `StartMaximizedWindow = 0/1` - If set true will start the editor maximized. |
| 70 | + - `OutputRefreshRate = #` - Used to limit the graphics refresh rate to reduce GPU load (fairly high for whatever reason). |
| 71 | + Only really relevant for high resolution (above 1080p) and high refresh rate (above 60hz) displays. |
26 | 72 |
|
27 | 73 | ## How To
|
28 | 74 |
|
29 |
| -1. Create an input file using the provided template. |
30 |
| - - **Warning:** The order of limb parts in the input file **is important!** |
31 |
| - - Order should be as specified, going left to right: |
32 |
| - Upper Arm FG, Lower Arm FG, Upper Arm BG, Lower Arm BG, Upper Leg FG, Lower Leg FG, Upper Leg BG, Lower Leg BG. |
33 |
| - - **Double Warning:** |
34 |
| - - Arm parts should be facing **right** for correct bending! |
35 |
| - - Leg parts should be facing **left** for correct bending! |
36 |
| - |
37 |
| - - See included "test-image.bmp" to understand how your input file should look like. |
38 |
| - |
39 |
| -2. Load your input file using the "**Load**" button. |
40 |
| - |
41 |
| -3. Bent limbs will auto generate with default settings. |
42 |
| - |
43 |
| -4. Adjust joint positions by clicking on the upper joint marker and dragging it around. |
44 |
| - - ~~Use **Zoom** setting to enlarge the input image for easier joint adjustment~~ |
45 |
| - - Input image will be automatically zoomed to x4 on first load. |
46 |
| - - **Warning:** When zooming the joint markers will reset to original positions. First zoom, then adjust. |
47 |
| - |
48 |
| -5. Use **Frames** setting to set number of bend frames. |
49 |
| - - Bend angle will adjust automatically. First/Last frames will always be fully bent/unbent. |
50 |
| - |
51 |
| -6. Decide whether you want to save as Indexed BMP or not - if yes, tick the "**Save as Indexed Bitmap**" checkbox. |
52 |
| - |
53 |
| -7. Decide whether you want to save as individual named frames or not - if yes, tick the "**Save as Frames**" checkbox. |
54 |
| - - Exported frame size is fixed to 24x24px. |
55 |
| - - If enabled, a visual aid will be shown around each frame to help the user stay within bounds. |
56 |
| - - Pixels outside bounds will be cropped. |
57 |
| - - Exported leg frames will be automatically flipped horizontally to face right. |
58 |
| - |
59 |
| -**Note:** "Save as Indexed Bitmap" and "Save as Frames" do not conflict and can be used together to export indexed individual frames. |
60 |
| - |
61 |
| -8. Hit save |
62 |
| - - Background color will automatically be set to magenta (255,0,255) when save is clicked and will revert back to previous color when finished. |
63 |
| - |
64 |
| - - **Warning:** |
65 |
| - - File extension will be added automatically depending on selected "**Save as Indexed Bitmap**" setting so there is no need to add it manually. |
66 |
| - Doing so will resolve in a double extension (for example: "MyFile.png.png"). |
67 |
| - |
68 |
| - - **Quadruple Warning:** |
69 |
| - |
70 |
| - - When saving with "**Save as Frames**" enabled, only input the name of the actor these limbs belong to (for example: "Robot"). |
71 |
| - Limb names and frame numbers will be added automatically. |
72 |
| - **Adding the limb name and frame number manually will result in horrible exported file names.** |
73 |
| - |
74 |
| - |
| 75 | +1. Create an input file using the provided template. |
| 76 | +2. Load your input file using the **Load** button or by dragging and dropping it into the main window. |
| 77 | +3. Bent limbs will auto generate with default settings. |
| 78 | +4. Adjust joint positions by clicking a joint marker and dragging it around. |
| 79 | +5. Use **Frame Count** setting to set number of bent frames. |
| 80 | +6. Decide whether you want to save as individual named frames or not - if yes, tick the **Save as Frames** checkbox. |
| 81 | + 6.1. Make sure each frame is within the displayed bounds. |
| 82 | +7. Decide whether you want to save the file with indexed color - if yes, tick the **Save as Indexed** checkbox. |
| 83 | + 7.1. Select the desired indexed file type from the combobox. |
| 84 | +8. Save the output with the **Save** button. |
| 85 | +9. Manually touchup saved files if necessary. |
| 86 | +10. Make great mods. |
| 87 | + |
75 | 88 | ## Current Issues
|
76 | 89 |
|
77 |
| -- Joint adjustment is only on Y axis and adjusts upper/lower marker equally. |
78 |
| -- Works only with input files that are 24x24px tiled (for each limb part. Max input image size is 192x24px for 8 limb parts (4 limbs)). |
| 90 | +- Works only with input files that are 24x24px tiled (for each limb part. Input image size is locked to 192x24px for 8 limb parts (4 limbs)). |
| 91 | +- Builds but doesn't run on Linux due to some issue with MaxGUI not being able to instantiate the main window. |
79 | 92 |
|
80 | 93 | ## Changelog
|
81 | 94 |
|
82 | 95 | https://github.com/cortex-command-community/Cortex-Command-Community-Project-Bender/wiki/Changelog
|
83 | 96 |
|
84 |
| -## Credits |
85 |
| - |
86 |
| -Created by MaximDude using BlitzMax 0.105.3.35 and MaxIDE 1.52 |
87 |
| - |
88 |
| -Bender logo image by Arne Jansson - Edited by MaximDude |
89 |
| - |
90 | 97 | ## Building
|
91 | 98 |
|
92 |
| -Buildable with BlitzMax 0.105.3.35 using MaxIDE 1.52 |
93 |
| - |
| 99 | +Buildable with BlitzMax NG 0.129 (and possibly earlier versions) using MaxIDE. |
| 100 | +Uses only modules that are provided with the release. |
94 | 101 | [BlitzMax.org](https://blitzmax.org)
|
95 | 102 |
|
| 103 | +## Credits |
| 104 | + |
| 105 | +Bender logo image by Arne Jansson. |
| 106 | + |
0 commit comments