Jump to content

Sam.

Modders
  • Posts

    493
  • Joined

  • Last visited

Everything posted by Sam.

  1. Alright, this one works for me. Note I changed the function name as the functionality was expanded: Does this work for you?
  2. As to what PS BAM can do, yes and no. You can SET all frame offsets to a specific value using "--SetXOffset" and "--SetYOffset y". You can also modify frame offsets by a +/- amount using "--ModXOffset" and "--ModYOffset". There is currently no mechanism for scaling X and Y offsets (by a percentage or factor), but I could add this without much effort if there was a need [I would add "--ScaleXOffset" and "--ScaleYOffset" that would let you specify a factor like 0.6667 or 1.5.]. However, there are other mechanisms for calculating the appropriate frame offsets for specific types of BAMs. You can set a specific BAM profile (type) using "--BAMProfile", and PS BAM will calculate the appropriate offsets for you. Currently recognized values are: GroundIcon, DescriptionIconEE, and ItemIconPST all set all frame offsets to half the width and half the height (centering the frame). If your BAM has rows/columns of transparent pixels around the border, you can use the "--TrimFrameData" to remove these before (or after) setting/calculating the appropriate offsets, depending on what you want to do. As to frame dimensions being off by a pixel in either direction after resizing them, the problem is with rounding errors. The solution is to "--Unify" frames (add rows/columns of transparent pixels) so that all frames are the same dimensions BEFORE resizing them. This ensure all rounding errors are in the same direction. You can then "--TrimFrameData" afterwards to remove any remaining extra rows/columns of transparent pixels. Both PS BAM and BAM Resizer can do this, but I haven't studied just how well PS BAM handles transparency after resizing in detail.
  3. When I don't leave it blank, I have only given ChildDirRegex a raw name of a specific folder, like ChildDirRegex = ~test~ Later I'll try and see why WeiDU isn't happy with actual RegEx.
  4. @Luke If you just want a textual list, you could do: If instead you want the function to return an array of files, see RET_ARRAY in the WeiDU docs.
  5. You'll need to send me the files (either upload them to a post or send me a PM), let me know what type of BAM it should be (e.g. spell animation), and then tell me how you want the frames centered.
  6. Recursion. You could adapt my ps_recursive_search function (modified by Gwendolyne) to return arrays of files instead of the count of files. Ninjas... argent77's answer was better.
  7. You have listed the obvious choices. If you use the updated version of BAMWorkshop, you can set the frame offsets, but you have to enter them (as a positive or negative number) for each frame individually. Other than the programs you listed, your other choice is PS BAM. It can automatically calculate the proper frame offsets for a variety of BAM types by setting a --BAMProfile. Alternatively, if you need to set particular offsets, you can increment, decrement, or set X and Y offsets for all frames by/to particular values. See --ModXOffset, --ModYOffset, --SetXOffset, --SetYOffset. The down side is there is no graphical interface, so you have to know what offsets you want before you start. The up side is that PS BAM can build BAMs (even very complex BAMs like creature animations) automatically for you from frames, set the frame offsets, and compress the BAM. All automatically and in batch. If you're interested in trying it, describe what you want to do and I'll provide example code for doing it.
  8. FWIW, everything I have ever seen or heard or been taught from high school mathematics to Boy Scouts to classes in orientation and land nav says it is e.g. ESE and not SEE (I'm in the USA). Looking on Wikipedia, the vast majority of languages and cases behave thus: I'm a bit confused on how the Chinese, Gaelic, etc. method extrapolates to the 16-wind compass rose (EES in this case?), but we're talking about internal systems of a game written in English here. English (and French for any French Canadians working for Beamdog?) seem to unanimously use ESE, so no idea why the others were introduced.
  9. You have left off how to set the proper X and Y offsets. You can do it in BAMWorkshop II, but but its implementation is a bit clunky and imprecise. It's the "Selects the center point of the frame" button on the left hand toolbar, and you have to try and click on the proper pixel. Mathematically, the proper offsets for the large frame are CenterX=Width//2 CenterY=Height//2 and for the small frame they are CenterX=(Width-32)//2 CenterY=(Height-32)//2 Where "//" is a floor divide (truncate the remainder). These are easier to set in BAMWorkshop where you can type in the numbers. The original version of BAMWorkshop didn't let you input negative offsets, but you can find an edited version here that lets you do it.
  10. @Alexander12 I'm going to try again to show you how PS BAM is supposed to work. Download this and run it. It is a self-extracting archive of everything you need. Select a location that is an empty folder, and let it extract the contents of the archive. DO NOT DELETE ANYTHING! DO NOT MOVE ANYTHING! Everything you need will be extracted into a folder called "AllTogether" at whatever location you specified. Inside "AllTogether" you will find "!AllTogether.bat". Run it. Your new BAMs should be created and saved into a folder called "YourNewBAMsAreHere" At this point, take a look at "!AllTogether.bat" to see how it works, and how the relative paths are set up. The only special thing to note is "%~dp0". This inserts the current path to your BAT file (including the trailing \). See if that clears things up.
  11. PS BAM is written in the AutoHotkey programming language, which is Windows only. I'd say you start with finding or making an image of the item you want. Preferably with a clean background, and preferably one that is already about the right size (the large frame is no larger than 64x64 pixels.
  12. I don't follow these statements. I could list all the ways I'm confused by them and the seeming inconsistencies, but maybe it would be easier if you could elaborate/explain?
  13. Yes, that is most likely the reason for your issue. BG:EE Classic Movies should be installed after GUI mods like LEUI-BG1EE.
  14. Your BAM has an appropriate transparent color, and the palette doesn't have any transparency. The shadow color isn't black, but that should be OK considering what type of animation it is. When playing it in-game via the CLUAConsole via it looks like this: If that's what you're seeing, then it eliminates options 1 and 2.
  15. One of four things must be happening: Your BAM was malformed when it was created (e.g. the transparent or shadow colors got messed up). Your BAM is good but the palette contains semi-transparent colors, thus your BAM renders differently in-game than it does in legacy editors which do not support the alpha channel. Your PRO has been incorrectly configured to display the BAM the way you intend. The flags mentioned above are the most likely culprits. You aren't actually testing the files you think you are (e.g. you're testing on SoD but haven't installed a version of Modmerge, you aren't closing and restarting the game between testing changes to the files, you aren't running the same game you're saving the edited files to, etc.) If you upload your BAM and PRO, we can help you narrow down the list of possible issues.
  16. Im using the Dragon Disciples ddbreat.PRO I'm thinking you need to adjust the flags in your PRO file. For starters, turn off "Translucent (7)". It has this effect. You may need to play around with the other flags as well. My second guess is if you created the BAM yourself with DLTCEP, I think it might interpret pure black as the transparent color (which is a bit odd IMO). That could be throwing you off too. Sadly, no progress has been made in many years.
  17. Some general comments: @Gwendolyne had done this several times before. He'll be a good person to talk to. If you're adding this animation to the EE games, they can handle BAM frames of any size. Just make it a normal (unsplit) animation instead of splitting it into the 4-part or 9-part split types. In fact, Beamdog is looking into re-combining all split spell and creature animations to eliminate the dark lines between sections caused by zooming. Have you seen this topic: http://www.shsforums.net/topic/57025-dragons-problems-to-create-an-animation-using-the-dragon-format-xdr/ ? There is also this old topic: https://www.gibberlings3.net/forums/topic/24006-how-to-export-dragon/. I have better tools now. If you get to the point where you have all of your frames done and are ready to convert them into BAMs, I can batch process them for you, or you can do it yourself with PS BAM.
  18. EET does provide a version of the old movies, but IMO my version is a higher quality. Also, if you install Classic Movies after EET and use the "Restore BG1 Chapter and Dream Screens" component, the appropriate GUI theme will be used to match your EET game.
  19. Assuming you have the latest version, Classic Movies should now be installed after EET. Edit: And after EET's GUI changing component.
  20. I'm looking for a function to clone all of an extended header's effects into global effects (for an item). I thought I had seen such a function posted somewhere, but I don't remember where and didn't see it here. Any suggestions? I could probably write my own, but would prefer not to reinvent the wheel if an existing solution exists.
  21. Notepad++ supports RegEx in it's find/replace, but I'm unsure of the particular flavor of RegEx it uses. You'd need to check the docs. However, doing this would be incompatible with languages other than English. Instead, add 200000 to each StrRef to get the EET equivalent.
  22. Not that my opinion counts for anything, but in general I prefer NI's jargon over the language used in the IESDP, especially the names of Effects. I'm sure both are technically correct, but NI uses language I find more natural. I acknowledge this is purely a personal preference.
×
×
  • Create New...