improvement: make sure that the hit gfx appear *when* the attack connect

This commit is contained in:
Kazhnuz 2019-08-19 16:39:23 +02:00
parent d84001c150
commit 851a3d9804
2 changed files with 33 additions and 9 deletions

View file

@ -35,22 +35,43 @@ return {
speed = 10,
pauseAtEnd = true,
},
["hit1"] = {
["hit1start"] = {
startAt = 22,
endAt = 24,
loop = 24,
speed = 15,
pauseAtEnd = true,
},
["hit1end"] = {
startAt = 24,
endAt = 26,
loop = 26,
speed = 15,
pauseAtEnd = true,
},
["hit2"] = {
["hit2start"] = {
startAt = 28,
endAt = 31,
loop = 31,
endAt = 30,
loop = 30,
speed = 15,
pauseAtEnd = true,
},
["hit3"] = {
startAt = 32,
["hit2end"] = {
startAt = 30,
endAt = 32,
loop = 32,
speed = 15,
pauseAtEnd = true,
},
["hit3start"] = {
startAt = 33,
endAt = 35,
loop = 35,
speed = 15,
pauseAtEnd = true,
},
["hit3end"] = {
startAt = 36,
endAt = 36,
loop = 36,
speed = 15,

View file

@ -17,15 +17,18 @@ return {
-- if not nil : {ox, oy, shape, size, affectedByDirection}
choregraphy = { -- the main attack choregraphy
{'setAnimation', "none", 'hit1', true},
{'setAnimation', "none", 'hit1start', true},
{'sendDamage', "none", 33, 100, false, false},
{'addGFX',"sentDamage", 'hitGFX', 0.75, 0, true, false},
{'setAnimation', "none", 'hit2', true},
{'setAnimation', "none", 'hit1end', true},
{'setAnimation', "none", 'hit2start', true},
{'sendDamage', "none", 33, 100, false, false},
{'addGFX',"sentDamage", 'hitGFX', 0.75, 0, true, false},
{'setAnimation', "none", 'hit3', true},
{'setAnimation', "none", 'hit2end', true},
{'setAnimation', "none", 'hit3start', true},
{'sendDamage', "none", 33, 100, false, false},
{'addGFX',"sentDamage", 'hitGFX', 0.75, 0, true, false},
{'setAnimation', "none", 'hit3end', true},
{'setAnimation', "none", 'idle', false},
{'wait', "none", 0.5}
},