 |
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
Could I get some help with makespr.exe please.
I have completed 165 .tif files with 165 matching shadow files for a new sprite.
After some initial difficulties I am getting makespr.exe to run but get the following error message.
"Processing "GU20.txt"
[Move..
Error in Bitmap data. Pixel with no Associated Alpha"
I checked GU..MA1.2.tif and resaved it and ran it again and it started then came back with the same error but "[Move....." was different, there were 5 ". " now instead of 2.
Could someone explain the error messages you get with makespr.exe please? Do the "." relate to frame no's?
I am using Paintshop pro to make the tif files. Could someone indicate the best settings for-
a) magic wand, and
b) color replacer.
I think that may be where I made the mistakes. I noticed I had some near black pixels in my picture, ie 1,1,0 rather than 0,0,0. thats in the background.
c) do pixels that close in colour in the picture cause any problems, ie shhould I aim for a bigger gap and whats the best way to do it?
Thanks for any help.
|
|
|  |
 |
|
Pedrunn
|
 |
of Natal, Brazil
Jul 2001 time: 02:27
|
|
You didnt created an alpha channel.
Quoting Harlan Thompson's unit creation document:
quote: Harlan Thompson
7. Now comes the tricky part of getting the alpha channel to work. Find the Layers window in Photoshop. Along the top of this window you should see three tabs, Layers, Channels and Paths. Click the Channels tab. You should see four channels for your graphic already: RGB, Red, Green and Blue. If you have any other channels, delete them.
8. Select the pure black background behind your unit. To make sure you select every last pure black pixel, use the Select -> Color Range command. With the eyedropper, click on the black background, then click OK. Now use the Select -> Inverse command. You should now see every last pixel that is NOT pure black selected. If you see pixels that should be pure black but aren’t, fix that now, then repeat step 8 until you have it right.
9. Now make the Alpha channel. With all the non-pure black pixels selected and the Channels tab open on the Layers window, click the “save selection as channel” button at the bottom of the Channels tab window. The icon on this button is a black box with a dashed circle inside it. When you click on this, a channel called Alpha 1 should appear in your Channels window.
|
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
I used PaintshopPro and followed IW instructions.
a) saving both the main picture outline to alpha channel before saving the whole to .tif and
b) the shadow to alpha channel separately before saving the whole picture as a tif file.
I used magic wand/invert selection to ensure I got the whole of the image (without background) and used color change to change the background or shadow where approp. When I rechecked, I saved to alpha and it came up with an outline and separate background called channel 1. When I resaved it I saved it over Channel 1. So as far as I know I have the alpha channels required for each frame, ie I have 165 .tif files for the main image and each has a matching alpha chanel, and 165 .tif files for the shadow and each has a matching alpha chanel.
I thought I read somewhere that if you read the dots in the makespr report you can work out which frame has a problem, that is what I was alluding to in my request.
However, now I know a bit about paintshop, I will re-read Harlans instructions and see if I missed a process. I have checked some frames and it SEEMS everything should be ok in that i cant find any non 0.0.0 pixels in the background or any 0.0.0 in the image, only an occassional 1.1.0 in the picture around the edges.
Thanks for your help.
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
However, just a thought, I did not give each alpha chanel a name, just let the computer name it channel 1 which i thought I read in some instructions.
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
I have attached two files, MA1.1 and MS1.1 in case anyone can find the problem.
Attachment: gu20.zip
This has been downloaded 1 time(s).
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
Thanks for the help Martin.
Just checking, what you are suggesting is that I need less near black pixels around the edge of the main picture.
How do you achieve this please?
a) If I select the image, color change from 0.0.0 to 32.32.32 with a tolerance of say 25, will that do the trick?, or
b) is there another way to do it when saving to alpha?
This was my procedure.
I am redoing CIV 3 flic files and this is what I did.
Picked 10 -13 frames from the Flic animation, cropped to get the unit in the right place, then loaded the frames into PSP. Then frame by frame-
1)I used colour replacer to change the pink to pure black in the CIV3 frames,
2) then selected the red shadow, pasted as new frame, re-sized to 96X72, selected the background and painted it pure white,
3) inverted to the shadow and painted in pure black, saved it to alpha while the shadow was still selected,
4)then de selected, saved to file with the GU.. S .etc. tif prefix.
5)Then went back to the main image where the shadow was still selected, painted it pure black, de selected, resized to 96X72,
6) selected the black background with magic wand then saved to alpha,
7) de selected then saved to file with GU..A .tif etc.
Just confirming the objectives,
a) background selected and saved to alpha with only 0,0,0, black colour in it
b) picture frame saved as GU A with no pure black in any part, (should I make sure there are no near black as well?)
c) shadow, selected saved to alpha with only 0,0,0, black colour in it
d) shadow background, with only pure white, saved to GU S..tif.
e) there must be no pure black in the picture and only pure black in the picture background. (should I remove near black pixels in the picture here?)
f) there must be only pure black in the shadow and only pure white in the shadow background.
Thanks for your help.
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
Hi Martin,
When I saved the PSP files I saved as .tif, uncompressed, RGB. I checked back, cant see where you get the 24 bit option in the save dialog box. Is it somewhere else?
Thanks for your help.
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
I have made some progress. 
I found the main problem seems to be that my starting frame for each animation was 1 rather than 0, ie GU20MA1.1.tif instead of GU20MA1.0.tif. I asked in an email whether this could be the problem but got no response, so I assumed it was not the cause.
I took a punt and started a sample sprite with only 1 frame for each event and direction, all numbered 0 and ran makespr.exe and it started to create a sprite, occassionally hanging up on a frame where I had missed so all black pixels in the unit image or had forgot to invert properly for the background, but completed eventually.
I then tried it again, but this time adding a few frames at a time. The dots do relate to frames as it came back with messages when it could not find the next frame and the dots equalled the number of frames processed, less 1 for each "0" frame.
Eventually, I made the sprite and now I can see how to improve it. Mainly centering the units and my spearman is a little large.
However, there was one issue, when executing the makespr (remembering I had insterted 1 frame, numbered 0 for each event, move, attack, death with matching shadow file) requested all the movement frames, then requested 16 more victory frames for direction 4 then finished executing and produced the sprite.
I gather from this that the GU01.txt file provided in the download is not complete in the number of frames for each event. I had a quick look but was a bot overwhelmed.
I am not good at altering .txt files so can someone post a GU.txt file for a complete move, attack, victory sequence with 10 frames for movement/victory and 13 for attack.
As far as the sprite for the spearman goes, I should be able to clean it up fairly quickly and once I have a text file, make it available. I need to put a border around some frames as he is a bit big and a bit low down on the square, but otherwise seeks OK.
Thanks for help received and in advance for the .txt file.
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
I have downloaded the file but it appears to not have the full number of animation frames for it. eg, movement frames are 1 and attack frames are 4.
For some reason which I have no idea about, after I constructed my first sprite yesterday using 0 as the first frame number, which is the way both gu.txt files are deliverd, makespr started crashing when I executed.
I experimented and found out if I changed the first frame number in movement to 1 it would run. So I constructed a new sprite with more frames in it but when I run it in the game , the game crashes when I attack with it.
I wondered if it had to do with the line UNIT_SPRITE_ATTACK_IS_DIRECTIONAL 0.
I tried changing it to 1 and makespr wont finish executing , coming up with the error gu20.txt line 35:Expected Keyword UNIT_SPRITE_ATTACK not found. I go to line 35 and its there, UNIT_SPRITE_ATTACK 1 is there?
I cant work it out. After making my first sprite I added some new frames to my folder and started makespr and it just started crashing with the illegal operation message. If I removed the first movement frame it came up cant find GUMA201.0.tif, if I added any file named that including once which I know ran through makespr before, it crashed. If I change first movement frame to 1, I can run it but it isnt using the full number of frames and crashes when I attack with the unit in the game?
I thought I had it all sorted out yesterday now i havnt got an idea 
|
|
|  |
 |
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
Sorry, zip file attached.
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
Dont know what happened, I have uploaded it twice and its not there.
Can the moderator attack please, file spear.zip or spear1.zip?
|
|
|  |
 |
|
Immortal Wombat
|
 |
in perpetuity
Dec 2000 time: 05:27
|
|
ok, I got your email with the attached frames, double-checked the script file, am now running a bug-free script. I commented out the victory shadow files that you included in the zip, and tried to make a shadow-free sprite (perfectly possible) rather than a semi-shadowed sprite (questionable) and yes, something in either the death or attack animations crashes the game.
Which is odd, because usually a game-crashing type error will mean the sprite should fail to compile in the first place.
I also substituted a copy of GU02VA5.9 in for 5.8 which was looking a bit weird. That doesn't appear to be the problem, the game crashes regardless.
What I did notice was odd is that the sprite compiler has only 10 dots following the Victory[] line, when the script dictates it should have 10*5 = 50 dots (=50 frames)
Oh hold on. Real-time posting here. Martin, didn't you find that sprites didn't like having the alpha channel touching the edge of the image?
If so, your problem is with GU02VA4.10.tif
edit: no, that doesn't solve it either.
Have you tried it with shadows?
Last edited by Immortal Wombat on 16-04-2003 at 01:23
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
I noticed that the compiler did not make all the death animations, only 1 sequence.
I am using a sprite in my game made with the cow.txt which as movement and death animations but no attack animation. I tried to cut and paste an attack sequence but it wont work. The compiler works but the unit crashes the game.
The shadow files are in the folder but I dont know how the compiler uses them but the finished sprite has a shadow under it.
I know the first 4 frames of the attack animation are ok because I used IW's gu0002.txt posted above and made a sprite that does not crash the game. It used 1 movement and 4 attack/death frames.
How about trying to copy and paste an attack sequence into the cow sprite?
I was beginning to think that my computer was corrupted or the notepad was not working properly. But I used it last night to cut and paste .txt files to add advances and buildings to the game and they work fine.
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
Like IW, I assumed that if a .tiff frame went through the makespr utility it must be OK. However, I was thinking that there are only two common things that related to the problem of the game crashing with the completed spr file, one was the altered text file and the second was the attack animation frames. Seeing that the attack frames went through the utility, it followed that the problem was in the text file.
I was thinking and decided to try something. I knew the movement animations worked so I moved all the attack animations, copied the movement animations, renamed them as attack animations and put them back in the folder and ran the utility. Hey presto, the sprite was made , I put it in the game and it worked, although the spearman just charges the enemy, not thrust his spear. Nevermind, now I know I need to check all the animation frames. Obviously, there is an error after frame 4 of the attack sequence 4 that manages to go through the utility but then crashes the game.
Thank god I eventually found it. I was beginning to go bonkers. Should have 3 new sprites available within the next week. Heavy Spearman, Phalanx and war chariot.
Thanks for everyones help. 
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
The problem turned out to be GU02AA2.5.tif, after all that.
The following lessons have been learned about making sprites.
1) Most importantly, dont assume a frame is OK if it goes through the makespr utility. i have now had at least 3 instances where a frame crashed the game after makepsr had created a sprite.
2) I think the best thing to do is to have a set of frames from one sprite known to be working, then as you make each new frame, save it as the appropriate one in the existing folder of working frames. This also saves time in typing out the numbers. Every 10 frames or so, run the utility and make a sprite and run it in a game to make sure. That way you can quickly narrow down the problem if the game crashes. Dont assume that when checking a frame, that it is ok, I did that many times and it appears that some .flic frames just dont seem to convert properly. I cannot think of any other explanation.
3) the picture should be about 85-90% of the height of the frame, ie, 85-95 % of 72 pixels, mainly to the top of the frame, ie have a gap at the bottom of at least 6-7 pixels. this will sit much better on the game screen, not appear to be down a bit in the next square.
4) The picture should be as close to centre as possible, except for movement animation no 5. For some unknown reason this always set to the left for me and with experience, I now have this frame with the picture sitting to the right as far as practicable, if not for the movement frames, for frame no 0 which is the one used as the idle frame.
I have attackhed (I hope) zip file, Hvy Spearman which includes the necessary TGA files.
Special thanks to Immortal Wombat for making it possible.
Last edited by stankarp on 27-04-2003 at 09:43
|
|
|  |
 |
|
stankarp
|
|
australia
Feb 2002 time: 05:27
|
|
PLEASE NOTE.
FURTHER TESTING INDICATED A PORBLEM WITH THE SPEARMAN SPRITE SO I HAVE REMOVED IT FROM POST.
It will be posted again when full testing is complete.
There was a problem with a frame that led to an opaque flash when executing an on screen special attack in direction number 5. Have fixed now but will post theis sprite and 2 more shortly, both undergoing final testing.
|
|
|  |
All times are GMT. The time now is 05:27. Apolyton Time is 00:27. |
top of page
|
| archivepost |
|
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
|
|
|
|
|
|