Skip to content

Commit

Permalink
make opponent do note splash
Browse files Browse the repository at this point in the history
  • Loading branch information
GuglioIsStupid committed May 15, 2024
1 parent 7d02368 commit 0103fdc
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/love/modules/Splash.lua
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ function splash:new(settings, id)
local s = {}
s.anim = settings.anim
s.posX = settings.posX
s.posY = settings.posY
s.sprite = self.spr()
s.sprite.x = s.posX
s.sprite.y = -400
s.sprite.y = s.posY
s.sprite.id = id
s.sprite:animate(s.anim)

Expand All @@ -32,9 +33,6 @@ function splash:update(dt)
if not v then break end
v.sprite:update(dt)

v.sprite.y = boyfriendArrows[v.sprite.id].y
v.sprite.x = boyfriendArrows[v.sprite.id].x

if not v.sprite:isAnimated() then
table.remove(self.cache, i)
end
Expand Down
9 changes: 9 additions & 0 deletions src/love/states/weeks.lua
Original file line number Diff line number Diff line change
Expand Up @@ -808,6 +808,14 @@ return {
if whohit and whohit.holdTimer > whohit.maxHoldTimer then whohit:animate(curAnim, (_psychmod and true or false)) end
end
else
NoteSplash:new(
{
anim = CONSTANTS.WEEKS.NOTE_LIST[i] .. tostring(love.math.random(1, 2)),
posX = enemyArrow.x,
posY = enemyArrow.y,
},
i
)
if useAltAnims then
if whohit then whohit:animate(curAnim .. " alt", false) end
else
Expand Down Expand Up @@ -942,6 +950,7 @@ return {
{
anim = CONSTANTS.WEEKS.NOTE_LIST[i] .. tostring(love.math.random(1, 2)),
posX = boyfriendArrow.x,
posY = boyfriendArrow.y,
},
i
)
Expand Down

0 comments on commit 0103fdc

Please sign in to comment.