-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
161 changed files
with
7,909 additions
and
7,894 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
module SpringCollab2020BlackholeCustomColors | ||
|
||
using ..Ahorn, Maple | ||
|
||
@mapdef Effect "SpringCollab2020/BlackholeCustomColors" BlackholeCustomColors(only::String="*", exclude::String="", colorsMild::String="6e3199,851f91,3026b0", colorsWild::String="ca4ca7,b14cca,ca4ca7", | ||
bgColorInner::String="000000", bgColorOuterMild::String="512a8b", bgColorOuterWild::String="bd2192", alpha::Number=1.0) | ||
|
||
placements = BlackholeCustomColors | ||
|
||
function Ahorn.canFgBg(effect::BlackholeCustomColors) | ||
return true, true | ||
end | ||
|
||
end | ||
module SpringCollab2020BlackholeCustomColors | ||
|
||
using ..Ahorn, Maple | ||
|
||
@mapdef Effect "SpringCollab2020/BlackholeCustomColors" BlackholeCustomColors(only::String="*", exclude::String="", colorsMild::String="6e3199,851f91,3026b0", colorsWild::String="ca4ca7,b14cca,ca4ca7", | ||
bgColorInner::String="000000", bgColorOuterMild::String="512a8b", bgColorOuterWild::String="bd2192", alpha::Number=1.0) | ||
|
||
placements = BlackholeCustomColors | ||
|
||
function Ahorn.canFgBg(effect::BlackholeCustomColors) | ||
return true, true | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
module SpringCollab2020CustomSnow | ||
|
||
using ..Ahorn, Maple | ||
|
||
@mapdef Effect "SpringCollab2020/CustomSnow" CustomSnow(only::String="*", exclude::String="", colors::String="FFFFFF,FFFFFF") | ||
|
||
placements = CustomSnow | ||
|
||
function Ahorn.canFgBg(effect::CustomSnow) | ||
return true, true | ||
end | ||
|
||
end | ||
module SpringCollab2020CustomSnow | ||
|
||
using ..Ahorn, Maple | ||
|
||
@mapdef Effect "SpringCollab2020/CustomSnow" CustomSnow(only::String="*", exclude::String="", colors::String="FFFFFF,FFFFFF") | ||
|
||
placements = CustomSnow | ||
|
||
function Ahorn.canFgBg(effect::CustomSnow) | ||
return true, true | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
module SpringCollab2020HeatWaveNoColorGrade | ||
|
||
using ..Ahorn, Maple | ||
|
||
@mapdef Effect "SpringCollab2020/HeatWaveNoColorGrade" HeatWaveNoColorGrade(only::String="*", exclude::String="") | ||
|
||
placements = HeatWaveNoColorGrade | ||
|
||
function Ahorn.canFgBg(effect::HeatWaveNoColorGrade) | ||
return true, true | ||
end | ||
|
||
end | ||
module SpringCollab2020HeatWaveNoColorGrade | ||
|
||
using ..Ahorn, Maple | ||
|
||
@mapdef Effect "SpringCollab2020/HeatWaveNoColorGrade" HeatWaveNoColorGrade(only::String="*", exclude::String="") | ||
|
||
placements = HeatWaveNoColorGrade | ||
|
||
function Ahorn.canFgBg(effect::HeatWaveNoColorGrade) | ||
return true, true | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,77 +1,77 @@ | ||
module SpringCollab2020AttachedIceWall | ||
|
||
using ..Ahorn, Maple | ||
|
||
@mapdef Entity "SpringCollab2020/AttachedIceWall" AttachedIceWall(x::Integer, y::Integer, height::Integer=8, left::Bool=false) | ||
|
||
const placements = Ahorn.PlacementDict( | ||
"Attached Ice Wall (Right) (Spring Collab 2020)" => Ahorn.EntityPlacement( | ||
AttachedIceWall, | ||
"rectangle", | ||
Dict{String, Any}( | ||
"left" => true | ||
) | ||
), | ||
"Attached Ice Wall (Left) (Spring Collab 2020)" => Ahorn.EntityPlacement( | ||
AttachedIceWall, | ||
"rectangle", | ||
Dict{String, Any}( | ||
"left" => false | ||
) | ||
) | ||
) | ||
|
||
Ahorn.minimumSize(entity::AttachedIceWall) = 0, 8 | ||
Ahorn.resizable(entity::AttachedIceWall) = false, true | ||
|
||
function Ahorn.selection(entity::AttachedIceWall) | ||
x, y = Ahorn.position(entity) | ||
height = Int(get(entity.data, "height", 8)) | ||
|
||
return Ahorn.Rectangle(x, y, 8, height) | ||
end | ||
|
||
function Ahorn.render(ctx::Ahorn.Cairo.CairoContext, entity::AttachedIceWall, room::Maple.Room) | ||
left = get(entity.data, "left", false) | ||
|
||
# Values need to be system specific integer | ||
x = Int(get(entity.data, "x", 0)) | ||
y = Int(get(entity.data, "y", 0)) | ||
|
||
height = Int(get(entity.data, "height", 8)) | ||
tileHeight = div(height, 8) | ||
|
||
if left | ||
for i in 2:tileHeight - 1 | ||
Ahorn.drawImage(ctx, "objects/wallBooster/iceMid00", 0, (i - 1) * 8) | ||
end | ||
|
||
Ahorn.drawImage(ctx, "objects/wallBooster/iceTop00", 0, 0) | ||
Ahorn.drawImage(ctx, "objects/wallBooster/iceBottom00", 0, (tileHeight - 1) * 8) | ||
|
||
else | ||
Ahorn.Cairo.save(ctx) | ||
Ahorn.scale(ctx, -1, 1) | ||
|
||
for i in 2:tileHeight - 1 | ||
Ahorn.drawImage(ctx, "objects/wallBooster/iceMid00", -8, (i - 1) * 8) | ||
end | ||
|
||
Ahorn.drawImage(ctx, "objects/wallBooster/iceTop00", -8, 0) | ||
Ahorn.drawImage(ctx, "objects/wallBooster/iceBottom00", -8, (tileHeight - 1) * 8) | ||
|
||
Ahorn.restore(ctx) | ||
end | ||
end | ||
|
||
# Offset X position so it flips in place | ||
function Ahorn.flipped(entity::AttachedIceWall, horizontal::Bool) | ||
if horizontal | ||
entity.left = !entity.left | ||
entity.x += entity.left ? 8 : -8 | ||
|
||
return entity | ||
end | ||
end | ||
|
||
end | ||
module SpringCollab2020AttachedIceWall | ||
|
||
using ..Ahorn, Maple | ||
|
||
@mapdef Entity "SpringCollab2020/AttachedIceWall" AttachedIceWall(x::Integer, y::Integer, height::Integer=8, left::Bool=false) | ||
|
||
const placements = Ahorn.PlacementDict( | ||
"Attached Ice Wall (Right) (Spring Collab 2020)" => Ahorn.EntityPlacement( | ||
AttachedIceWall, | ||
"rectangle", | ||
Dict{String, Any}( | ||
"left" => true | ||
) | ||
), | ||
"Attached Ice Wall (Left) (Spring Collab 2020)" => Ahorn.EntityPlacement( | ||
AttachedIceWall, | ||
"rectangle", | ||
Dict{String, Any}( | ||
"left" => false | ||
) | ||
) | ||
) | ||
|
||
Ahorn.minimumSize(entity::AttachedIceWall) = 0, 8 | ||
Ahorn.resizable(entity::AttachedIceWall) = false, true | ||
|
||
function Ahorn.selection(entity::AttachedIceWall) | ||
x, y = Ahorn.position(entity) | ||
height = Int(get(entity.data, "height", 8)) | ||
|
||
return Ahorn.Rectangle(x, y, 8, height) | ||
end | ||
|
||
function Ahorn.render(ctx::Ahorn.Cairo.CairoContext, entity::AttachedIceWall, room::Maple.Room) | ||
left = get(entity.data, "left", false) | ||
|
||
# Values need to be system specific integer | ||
x = Int(get(entity.data, "x", 0)) | ||
y = Int(get(entity.data, "y", 0)) | ||
|
||
height = Int(get(entity.data, "height", 8)) | ||
tileHeight = div(height, 8) | ||
|
||
if left | ||
for i in 2:tileHeight - 1 | ||
Ahorn.drawImage(ctx, "objects/wallBooster/iceMid00", 0, (i - 1) * 8) | ||
end | ||
|
||
Ahorn.drawImage(ctx, "objects/wallBooster/iceTop00", 0, 0) | ||
Ahorn.drawImage(ctx, "objects/wallBooster/iceBottom00", 0, (tileHeight - 1) * 8) | ||
|
||
else | ||
Ahorn.Cairo.save(ctx) | ||
Ahorn.scale(ctx, -1, 1) | ||
|
||
for i in 2:tileHeight - 1 | ||
Ahorn.drawImage(ctx, "objects/wallBooster/iceMid00", -8, (i - 1) * 8) | ||
end | ||
|
||
Ahorn.drawImage(ctx, "objects/wallBooster/iceTop00", -8, 0) | ||
Ahorn.drawImage(ctx, "objects/wallBooster/iceBottom00", -8, (tileHeight - 1) * 8) | ||
|
||
Ahorn.restore(ctx) | ||
end | ||
end | ||
|
||
# Offset X position so it flips in place | ||
function Ahorn.flipped(entity::AttachedIceWall, horizontal::Bool) | ||
if horizontal | ||
entity.left = !entity.left | ||
entity.x += entity.left ? 8 : -8 | ||
|
||
return entity | ||
end | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.