+ laser alert component
|
@ -6,6 +6,7 @@ local CritLine = require('gameplay.crit_line')
|
||||||
local Console = require('gameplay.console')
|
local Console = require('gameplay.console')
|
||||||
local Gauge = require('gameplay.gauge')
|
local Gauge = require('gameplay.gauge')
|
||||||
local Chain = require('gameplay.chain')
|
local Chain = require('gameplay.chain')
|
||||||
|
local LaserAlert = require('gameplay.laser_alert')
|
||||||
|
|
||||||
local resx, resy = game.GetResolution()
|
local resx, resy = game.GetResolution()
|
||||||
local desw, desh;
|
local desw, desh;
|
||||||
|
@ -32,6 +33,8 @@ function render(deltaTime)
|
||||||
(game.GetSkinSetting('_gaugeARS') == 1)
|
(game.GetSkinSetting('_gaugeARS') == 1)
|
||||||
);
|
);
|
||||||
Chain.render(deltaTime, gameplay.comboState, chain, gameplay.critLine.x, gameplay.critLine.y);
|
Chain.render(deltaTime, gameplay.comboState, chain, gameplay.critLine.x, gameplay.critLine.y);
|
||||||
|
|
||||||
|
LaserAlert.render(deltaTime);
|
||||||
end
|
end
|
||||||
|
|
||||||
function render_crit_base(deltaTime)
|
function render_crit_base(deltaTime)
|
||||||
|
|
|
@ -0,0 +1,100 @@
|
||||||
|
|
||||||
|
local leftAlertBaseImage = gfx.CreateSkinImage("gameplay/laser_alert/left/base.png", 0)
|
||||||
|
local leftAlertTopImage = gfx.CreateSkinImage("gameplay/laser_alert/left/top.png", 0)
|
||||||
|
local leftAlertTextImage = gfx.CreateSkinImage("gameplay/laser_alert/left/text.png", 0)
|
||||||
|
|
||||||
|
local rightAlertBaseImage = gfx.CreateSkinImage("gameplay/laser_alert/right/base.png", 0)
|
||||||
|
local rightAlertTopImage = gfx.CreateSkinImage("gameplay/laser_alert/right/top.png", 0)
|
||||||
|
local rightAlertTextImage = gfx.CreateSkinImage("gameplay/laser_alert/right/text.png", 0)
|
||||||
|
|
||||||
|
local LEFT_ALERT_X_POS = 0
|
||||||
|
local RIGHT_ALERT_X_POS = 1080 - 450*0.5
|
||||||
|
|
||||||
|
local ALERT_Y_POS = 1115
|
||||||
|
|
||||||
|
local test = -2*3.14;
|
||||||
|
|
||||||
|
local renderLeftAlert = function ()
|
||||||
|
-- gfx.Translate(LEFT_ALERT_X_POS, ALERT_Y_POS);
|
||||||
|
-- -- gfx.SkewX(-1*3.14)
|
||||||
|
-- gfx.Scale(test, 1)
|
||||||
|
|
||||||
|
gfx.BeginPath();
|
||||||
|
gfx.ImageRect(
|
||||||
|
LEFT_ALERT_X_POS+450*0.5,
|
||||||
|
ALERT_Y_POS+450*0.5,
|
||||||
|
450*0.5,
|
||||||
|
450*0.5,
|
||||||
|
leftAlertBaseImage,
|
||||||
|
1,
|
||||||
|
-3.14
|
||||||
|
);
|
||||||
|
|
||||||
|
gfx.BeginPath();
|
||||||
|
gfx.ImageRect(
|
||||||
|
LEFT_ALERT_X_POS+450*0.5,
|
||||||
|
ALERT_Y_POS+450*0.5,
|
||||||
|
450*0.5,
|
||||||
|
450*0.5,
|
||||||
|
leftAlertTopImage,
|
||||||
|
1,
|
||||||
|
-3.14
|
||||||
|
);
|
||||||
|
|
||||||
|
gfx.BeginPath();
|
||||||
|
gfx.ImageRect(
|
||||||
|
LEFT_ALERT_X_POS,
|
||||||
|
ALERT_Y_POS,
|
||||||
|
450*0.5,
|
||||||
|
450*0.5,
|
||||||
|
leftAlertTextImage,
|
||||||
|
1,
|
||||||
|
0
|
||||||
|
);
|
||||||
|
|
||||||
|
-- gfx.ResetTransform();
|
||||||
|
end
|
||||||
|
local renderRightAlert = function ()
|
||||||
|
gfx.BeginPath();
|
||||||
|
gfx.ImageRect(
|
||||||
|
RIGHT_ALERT_X_POS,
|
||||||
|
ALERT_Y_POS,
|
||||||
|
450*0.5,
|
||||||
|
450*0.5,
|
||||||
|
rightAlertBaseImage,
|
||||||
|
1,
|
||||||
|
0
|
||||||
|
);
|
||||||
|
|
||||||
|
gfx.BeginPath();
|
||||||
|
gfx.ImageRect(
|
||||||
|
RIGHT_ALERT_X_POS,
|
||||||
|
ALERT_Y_POS,
|
||||||
|
450*0.5,
|
||||||
|
450*0.5,
|
||||||
|
rightAlertTopImage,
|
||||||
|
1,
|
||||||
|
0
|
||||||
|
);
|
||||||
|
|
||||||
|
gfx.BeginPath();
|
||||||
|
gfx.ImageRect(
|
||||||
|
RIGHT_ALERT_X_POS,
|
||||||
|
ALERT_Y_POS,
|
||||||
|
450*0.5,
|
||||||
|
450*0.5,
|
||||||
|
rightAlertTextImage,
|
||||||
|
1,
|
||||||
|
0
|
||||||
|
);
|
||||||
|
end
|
||||||
|
|
||||||
|
local render = function (deltaTime)
|
||||||
|
renderLeftAlert();
|
||||||
|
renderRightAlert();
|
||||||
|
test = test + deltaTime;
|
||||||
|
end
|
||||||
|
|
||||||
|
return {
|
||||||
|
render=render
|
||||||
|
}
|
After Width: | Height: | Size: 196 KiB |
Before Width: | Height: | Size: 4.0 KiB After Width: | Height: | Size: 4.0 KiB |
After Width: | Height: | Size: 114 KiB |
After Width: | Height: | Size: 207 KiB |
Before Width: | Height: | Size: 5.3 KiB After Width: | Height: | Size: 5.3 KiB |
After Width: | Height: | Size: 94 KiB |