Jump to content


Photo

Questions for making a custom "Comet" projectile


  • Please log in to reply
9 replies to this topic

#1 Aeviannce

Aeviannce
  • Member
  • 74 posts

Posted 31 May 2014 - 03:20 AM

Hello everyone.

 

I want to make a "white" version of the spell projectile, "comet". At the moment, I looked as some files related to it. So far, all I've seen were its VVC and BAM. This is the first time I'm doing something like this so I know next to nothing about it.

 

So, for my questions:

 

I've seen a lot of spell projectiles in the listed in "pro". How come comet is not in there? Are VVC and BAM the only files needed for this to work? If so, what other files do I need and what procedure must I do to get it in the game?

 

How do I append a custom spell projectile to a custom spell through weidu commands? I've looked at the file, can't really understand. :(

 

A step-by-step procedure would be very appreciated. Thanks!



#2 Aeviannce

Aeviannce
  • Member
  • 74 posts

Posted 01 June 2014 - 01:26 AM

So comet seems to be hard coded.

 

I was thinking that maybe if I make a projectile and set the comet BAMS as animations, kinda similar to Storm of Vengeance, or various dragon breaths... Would that work? I can't try it out yet since I still don't understand how to patch projectiles via weidu. :(



#3 Wisp

Wisp
  • Modder
  • 1353 posts

Posted 01 June 2014 - 04:29 AM

ADD_PROJECTILE ~yourmod/yourprefix#some.pro~
 
COPY ~yourmod/some.spl~
  LPF ALTER_SPELL_HEADER INT_VAR projectile = ~yourprefix#some~ END

 

 

ADD_PROJECTILE adds your PRO to the game and sets a variable named after the resource reference (the file name sans the file extension) of your PRO to the number the game uses to keep track of your projectile. You then write that number to the PRO field in your SPL. This can easily be done with the function ALTER_SPELL_HEADER, which, as invoked here, will write the specified projectile to all headers in your SPL. If you want ALTER_SPELL_HEADER to write other things and/or be more discrimitating, there are options for that too. Refer to the WeiDU readme for additional information.


Edited by Wisp, 01 June 2014 - 04:39 AM.


#4 Aeviannce

Aeviannce
  • Member
  • 74 posts

Posted 01 June 2014 - 05:52 AM

Yeah, just saw that one a while ago. Thanks!

 

So I've been trying to combine spcomex1 and x2 using photoshop cs5. I was thinking of porting it afterwards in BAM workshop so I could make it into a BAM. However, I can't seem to get it right. It either looses its color or is completely messed up when ported. Is there a proper way of saving a jpg,bmp,png from photoshop that would work with bam workshop?



#5 Daulmakan

Daulmakan

    Comfortably numb

  • Member
  • 1069 posts

Posted 01 June 2014 - 09:26 AM

Try this:

 

http://www.shsforums...nventory-icons/


item_pack.jpg   Drows.jpg

 


#6 Aeviannce

Aeviannce
  • Member
  • 74 posts

Posted 01 June 2014 - 09:54 AM

Thanks for the link but I figured it out earlier.

 

What I did was export the frames via BWS and saved them as png. Then I opened them using Photoshop, converted them first to RGB to allow for editing, merge X1 and X2 together and then convert them back to indexed color (256 colors, preserved colors was my settings). Then saved them as png again. I ported all png back to BWS as frames and miraculously, was ported perfectly. I just deleted the white background using a BWS tool and I'm done!

 

Now my question is... How do I make the game recognize my newly made bams? I thought I only need to place them in the override folder but apparently I was mistaken. So do I really have to attach the bams to pro.ids or a missile.ids or make them to VVC to make it work? Or am I missing a step here? :o


Edited by Aeviannce, 01 June 2014 - 09:55 AM.


#7 Kwiat_W

Kwiat_W
  • Modder
  • 290 posts

Posted 01 June 2014 - 10:40 AM

Try this:
 
http://www.shsforums...nventory-icons/
This doesn't work well with animated bams.

Aeviannce, if all that you want is just colourizing differently the bam file, you can try to use the colour manipulation tools that dltcep and bamworkshop have.
One of the bamorkshop tools has an option to decolourize the bam (make it use shades of grey) and dltcep has options to change contrast or brightness. Combination of those tools might produce the effect you desire.

For generating proper colour pallets for new animations you can use dltcep. It's quite good at it, but unfortunately it generates it using only the first imported frame, so you have to be sure that that frame is representative for entire animation. You can do it by combining few frames into one large. This "collage" can be bigger than 256x256 pixels, since you are going to delete it after the palette has been generated, but going to far will corrupt the bam and you won't know it until you have reloaded the file. I don't know the limits for the dimensions, but 500x500 works fine for sure.

icon11.gif W_GUI - a GUI replacement for Baldur's Gate 2/TUTU/BGT/CA
icon11.gif W_PackMule - Your own pack mule for Baldur's Gate 2/Tutu/BGT/CA, BGEE and BG2:EE

icon11.gif Psionics Unleashed - play as a Psion, mod for Baldur's Gate 2/Tutu/BGT/CA

 


#8 Aeviannce

Aeviannce
  • Member
  • 74 posts

Posted 01 June 2014 - 09:33 PM

Thanks Kwiat! You were right, DLTCEP does a better job in making animated bams. It got rid of "loaded with errors"  prompt from the bam I created and preserved its colors perfectly.

 

I encountered another problem though... After I ported it in the game, the animation goes of smoothly however, on the last 3 frames (presumably), it gets a weird glitch where it offsets from the point of casting and has this glitchy screen animation- looks like the GUI being dragged along or something... I'm sure the largest bam frame was no bigger than 500x500 px. So... any ideas whats causing this?

 

Attached are the files I'm working on. Feel free to take a look.

Attached Files


Edited by Aeviannce, 01 June 2014 - 09:41 PM.


#9 Aeviannce

Aeviannce
  • Member
  • 74 posts

Posted 01 June 2014 - 10:39 PM

So it seems the reason why the last few frames were glitching is due to the 200x200 px bam limitation of the game. I guess that's the reason why the original comet animation was split in half. I don't know how to make those work however so I'm stuck here atm...

 

Is there a tutorial somewhere that teaches how to make split images to bams and make the game recognize to play it at the same time? I tried doing this once, only one-half of the split bam is playing in-game. Comet VVC or bams don't give any hints at all... :(



#10 Aeviannce

Aeviannce
  • Member
  • 74 posts

Posted 06 June 2014 - 08:13 AM

Hi guys. Thanks to everyone who tried to help. I decided to drop this effort for the time being, at least, till I'm able to figure out how to code one. In the meantime, I tweaked the custom comet bam and is now featured in my recently updated Kit mod.

 

Again, thank you everyone. Happy modding :)