Skip to content

Commit

Permalink
fixed setActSprite offset not working correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
SylviBlossom committed Apr 21, 2022
1 parent f4cf9c1 commit 2c6362d
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.4.0
0.5.0-dev
12 changes: 6 additions & 6 deletions mods/_testmod/libraries/virovirokun/lib.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"Sylvi",
"Nyako"
],
"version": "v1.0.0",
"engineVer": "v0.3.0-dev",
"version": "v1.1.0",
"engineVer": "v0.4.0",

"config": {
"enable_cook": false,
Expand All @@ -18,10 +18,10 @@
"noelle": "enemies/virovirokun/take_care/noelle"
},
"take_care_offsets": {
"kris": [4, 2],
"susie": [6, 0],
"ralsei": [-6, 1],
"noelle": [7, 0]
"kris": [-4, -2],
"susie": [-6, 0],
"ralsei": [6, -1],
"noelle": [-7, 0]
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ function actor:init()
}

self.offsets = {
["idle"] = {6, 3},
["spared"] = {1, 0},
["hurt"] = {2, 2},
["idle"] = {-6, -3},
["spared"] = {-1, 0},
["hurt"] = {-2, -2},
}
end

Expand Down
2 changes: 1 addition & 1 deletion mods/_testmod/mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"subtitle": "A testing mod full of various stuff and things",

"version": "v?.?.?",
"engineVer": "v0.4.0",
"engineVer": "v0.5.0-dev",

"chapter": 2,

Expand Down
2 changes: 1 addition & 1 deletion mods/example/mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"subtitle": "",

"version": "v1.0.0",
"engineVer": "v0.4.0",
"engineVer": "v0.5.0-dev",

"chapter": 2,

Expand Down
4 changes: 2 additions & 2 deletions src/engine/game/battle/partybattler.lua
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,8 @@ function PartyBattler:setActSprite(sprite, ox, oy, speed, loop, after)

self:setCustomSprite(sprite, ox, oy, speed, loop, after)

local x = self.x - (self.actor:getWidth()/2 + ox) * 2
local y = self.y - (self.actor:getHeight() + oy) * 2
local x = self.x - (self.actor:getWidth()/2 - ox) * 2
local y = self.y - (self.actor:getHeight() - oy) * 2
local flash = FlashFade(sprite, x, y)
flash:setOrigin(0, 0)
flash:setScale(self:getScale())
Expand Down

0 comments on commit 2c6362d

Please sign in to comment.