Assign attacks

Talk about Severance Blade of Darkness modifications and maps here. No tips or tech support questions please, use the forum above. Note that the game is rated 18 so some content may be unsuitable for younger readers.

Moderators: prospero, Ade

User avatar
IrateGiant
Dragon
Posts: 328
Joined: Fri Jan 08, 2010 12:35 pm
Location: Spain
Contact:

Assign attacks

Postby IrateGiant » Thu Oct 20, 2011 7:58 pm

Hi guys! I'm trying to add a attack sequence to a character. I edit the file "...Combos.py" in [Scripts\Combos] folder.

#########################
# GRUPOS DE GOLPES SELECTIVOS #
#########################

#GM1 group
chk.AddAttack("G01","chk_g_01")
chk.AttackTypeFlag("GM1",ATK_UNIQUE)
chk.AddLevels("chk_g_01",0,0)

#################
# GOLPES SELECTIVOS #
#################

#GM1
chk.AllowAttack("G01","A+F","","GM,GM","","1H")
chk.AllowAttack("G01","&A+F","","GM,GM","","1H")

But I dont see any change [xx(]

What files I need to modify to see this changes in game?

Greetings!

User avatar
Tomash
Dragon
Posts: 246
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Postby Tomash » Thu Oct 20, 2011 8:42 pm

For what character do you want to add this attack?

User avatar
IrateGiant
Dragon
Posts: 328
Joined: Fri Jan 08, 2010 12:35 pm
Location: Spain
Contact:

Postby IrateGiant » Thu Oct 20, 2011 9:12 pm

I´m trying to make usable the original attacks from ChaosKnight.

User avatar
Tomash
Dragon
Posts: 246
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Postby Tomash » Thu Oct 20, 2011 9:40 pm

Do you want to use the CHKnight as PlayerChar or as NPC?

If you want to add more attack to NPC then you don't need to use the method AllowAttack, but you need to modify the list of attack of this kind of person.

User avatar
IrateGiant
Dragon
Posts: 328
Joined: Fri Jan 08, 2010 12:35 pm
Location: Spain
Contact:

Postby IrateGiant » Thu Oct 20, 2011 10:13 pm

I want to test ChaosKnight as Playable character. [:)]

User avatar
Tomash
Dragon
Posts: 246
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Postby Tomash » Thu Oct 20, 2011 10:39 pm

I just tried too, and it works. The only trouble was the loss of energy on 1lvl. I made the character 19lvl to fix it.

User avatar
IrateGiant
Dragon
Posts: 328
Joined: Fri Jan 08, 2010 12:35 pm
Location: Spain
Contact:

Postby IrateGiant » Thu Oct 20, 2011 11:15 pm

Thanks Tomash! What files you edit and how to make Chk playable? [:)]

User avatar
prospero
Ancient Dragon
Posts: 1725
Joined: Wed Nov 21, 2001 1:42 am
Location: United Kingdom

Postby prospero » Fri Oct 21, 2011 3:04 am

Hi IG [:D]

Perfectly possible to make the CK playable, but you need to do a lot of work. NPCs generally lack the animations that the Player chars have. Jump/Take/Use stuff mainly. If you simply create "Player1" as a Chaos Knight, he will work and you can walk around. But try to 'use' something or lock a door, etc and the game will crash.

You can add the missing animations with code but it's a messy job. And there are quite few that have to be added. If I were doing it I would clone the CK model and create a completely new race. Then all the data is seperate from the original and you can customise the code without risk of screwing up the original NPC version.

User avatar
mingyue1371
Dragon
Posts: 208
Joined: Fri Aug 05, 2011 4:46 pm
Location: China
Contact:

Postby mingyue1371 » Fri Oct 21, 2011 5:37 am

Hi IG,[:D]
I thought you should also need to modify[or add some stuff] these files:
..\Scripts\ChkBAct.py
..\Lib\AnmSets\ChkAnimationSet.py

User avatar
Tomash
Dragon
Posts: 246
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Postby Tomash » Fri Oct 21, 2011 9:37 am

http://www.youtube.com/watch?v=Xn3h8QMbwdI

Files:
http://www.mediafire.com/?o94elynnvb7is3s

I changed just 3 files:
Scripts/Combos/ChkCombos.py to make the attacks usable

Maps/Barb_M1/pj.py to replace Tukaram with ChaosKnight in Kashgar
Maps/Barb_M1/barb.lvl to load the textures

User avatar
Tomash
Dragon
Posts: 246
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Postby Tomash » Fri Oct 21, 2011 9:42 am

But as Pro said, this character lacks some animations wich are neccesary for PC. And also this model may be too large to pass through some narrow passages in main game.

User avatar
prospero
Ancient Dragon
Posts: 1725
Joined: Wed Nov 21, 2001 1:42 am
Location: United Kingdom

Postby prospero » Fri Oct 21, 2011 1:49 pm

You can assign the "Rlx_no" or "Rlx_1H" animations to the use/take actions in the biped action file. This will stop the crashes and the actions should still work - albeit by telekninesis. [:D]

Not sure if the CK has any strafe or combat facing anims..... [8)]

User avatar
IrateGiant
Dragon
Posts: 328
Joined: Fri Jan 08, 2010 12:35 pm
Location: Spain
Contact:

Postby IrateGiant » Fri Oct 21, 2011 2:31 pm

Many thanks pro, mingyue and Tomash! [:D]

Now, I can continue testing this with the correct files!

Tomash: I don´t want play ChK in maingame, I don´t have problem with passages in main game. I test this for a mod. [;)]

pro: I think that your cloned method is more easy but before I need to know what files I need to modify. [:D]

Thanks again! Greetings!

User avatar
Tomash
Dragon
Posts: 246
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Postby Tomash » Fri Oct 21, 2011 2:57 pm

See the scripts of the Pro's "Wizards Domain". It is good example of how to make the new character

User avatar
prospero
Ancient Dragon
Posts: 1725
Joined: Wed Nov 21, 2001 1:42 am
Location: United Kingdom

Postby prospero » Fri Oct 21, 2011 7:57 pm

look in any of my mods that have new characters for folders with *******Stuff. [:D] All the files within relate to an individual new character. The basic set is:

***Data.py - master file to initiate the new race.
***AnimationSet.py - loads the animations.
***BAct.py - sets the Biped actions
***Anm_def.py - Assigns the animation events
***AnmFact***.py - sets the animation timing
***Combos.py - attacks
***Stats.py - tables for life points/resistances and combo damages

Any file specific to the character, put in this folder. I usually start by copying an animation set as near to the new char as possible and then copy/paste/edit animations from others. It's quite complicated so you need to do this gradually or you can get totally cnfused. But having all the files in one folder helps and there is no way it can effect the main game.

I had an idea for a CK map once. You had to guard a doorway a constant stream of dwarfs tried to get past you. Some would attack while others just ran around you. You would have to stop as many as possible. [:D]


Return to “Severance BoD: Modding Community”

Who is online

Users browsing this forum: No registered users and 2 guests

cron