Qhimm.com Forums

Miscellaneous Forums => Troubleshooting => Topic started by: UltimaYoshi on 2007-06-19 22:53:47

Title: Problems with added attacks
Post by: UltimaYoshi on 2007-06-19 22:53:47
Well, I want to add some attacks to certain enemies.

I made a test mod with Guard Scorpion, with Molotov Cocktail as an added attack.
Sadly, he never used it.

Well, he do use it if I replace another attack with Molotov Cocktail, but not if I add it.

I added it at the attack data and names.
And I think it´s the attack ID, I don´t know how to work with attack IDs.
Can someone explain? :cry:
Title: Re: Problems with added attacks
Post by: Aaron on 2007-06-19 23:13:14
I don't have any experience with this myself, but it seems like the Guard Scorpion is scripted (it always does the same attacks in the same order, which may be why it never chose your new attack), while (most) other enemies choose attacks randomly.  Maybe you should try testing with a different enemy.
Title: Re: Problems with added attacks
Post by: UltimaYoshi on 2007-06-20 18:54:31
Okay, I tried on a different enemy: Aps

I gave him Shady Breath, but again no useage of the added attack.

I copied and pasted the attack ID from Samples H0512´s Shady Breath to Aps.
Is that wrong, must the attack ID be different for Aps?
Title: Re: Problems with added attacks
Post by: Skillster/RedSarg99 on 2007-06-21 21:52:36
If you add a move then it might have to go into the AI script for that enemy, also Attack IDs are at the start of the enemy data as well as with the attacks themselves. There may be a number in the scene file that tells the program how many attacks there are in that file?
Title: Re: Problems with added attacks
Post by: halkun on 2007-06-21 23:35:50
You have to re-code the AI to use the added attack. The script doesn't know it exists.
Title: Re: Problems with added attacks
Post by: Skillster/RedSarg99 on 2007-06-21 23:48:38
What if you keep the same Attack ID, just change the name animation effects in the Attack data section?
Then the script will still execute the move, thats another way around it.
Title: Re: Problems with added attacks
Post by: UltimaYoshi on 2007-06-22 12:45:05
You have to re-code the AI to use the added attack. The script doesn't know it exists.
Okay, but witch ID do you mean?
The Enemy ID, the attack ID at 0x0048 or the attack ID at 0x0840?

Sorry, I´m a n00b. ^^"
Title: Re: Problems with added attacks
Post by: Skillster/RedSarg99 on 2007-06-22 22:29:54
If I remember correctly isn't there a list of IDs early in the file and then and ID before each attack name?
They are usually one and the same, kind of like a index with a page number at the start and then the page has the attack data in it.
Scripts are usually at the end of the file though, good luck hacking those
Title: Re: Problems with added attacks
Post by: UltimaYoshi on 2007-06-23 09:44:00
So things are not as easy as it seems.

I still have much to learn. :|
Title: Re: Problems with added attacks
Post by: Skillster/RedSarg99 on 2007-06-23 11:49:34
it can be done,like i said if you simply want to replace an attack data with new attack data,while keeping the IDs the same as the old one.
Title: Re: Problems with added attacks
Post by: UltimaYoshi on 2007-06-23 12:11:39
Yeah, but I want to add attacks and not to replace them. :|

I must experiment with some things. :-(