Compare commits
5 Commits
71a7351d77
...
gun_upgrad
Author | SHA1 | Date | |
---|---|---|---|
b7c3e6ee92
|
|||
c91e5f4bd1
|
|||
ea2ddadb15
|
|||
9333c03bf3
|
|||
1b45bd3dc3
|
@ -736,8 +736,8 @@ function gun_base:ammo_upgrade_opt()
|
||||
before you
|
||||
run out.
|
||||
|
||||
is: ]]..tostr(a)..[[
|
||||
add: ]]..tostr(x)..[[
|
||||
is: ]]..tostr(a)..[[
|
||||
add: ]]..tostr(x)..[[
|
||||
----------
|
||||
total: ]]..tostr(a+x),
|
||||
action=function()
|
||||
@ -761,15 +761,13 @@ between each
|
||||
shot when
|
||||
firing.
|
||||
|
||||
fractions
|
||||
not shown,
|
||||
but they
|
||||
add up.
|
||||
|
||||
is: ]]..tostr(c)..[[f
|
||||
minus: ]]..tostr(c-newc)..[[f
|
||||
----------
|
||||
total: ]]..tostr(newc).."f",
|
||||
total: ]]..tostr(newc)..[[f
|
||||
|
||||
remainder:
|
||||
]]..sub(tostr(newc-rawnewc),0,5),
|
||||
action=function()
|
||||
self.cooldown=newc>>16
|
||||
self.cd_remainder=newc-rawnewc
|
||||
@ -1200,7 +1198,9 @@ from further
|
||||
action=function ()
|
||||
self.magnet += 2
|
||||
end,
|
||||
}}
|
||||
},
|
||||
self.main_gun:rate_upgrade_opt(),
|
||||
}
|
||||
|
||||
if cdr > 0 then
|
||||
add(ret, {
|
||||
@ -1906,7 +1906,7 @@ end
|
||||
rearm_mode = mknew{
|
||||
sel=1,
|
||||
bfm=1,
|
||||
crt_frm = 1,
|
||||
crt_frm = 0,
|
||||
pos=-1,
|
||||
init=function(this)
|
||||
poke(0x5f5c, 255) --no btnp repeat
|
||||
@ -1921,7 +1921,7 @@ function rearm_mode:glow_box(x0, y0, x1, y1, c, cf)
|
||||
i -= 1
|
||||
rect(x0+i,y0+i,x1-i,y1-i,v)
|
||||
end
|
||||
fillp(crt[self.crt_frm&0xff])
|
||||
fillp(crt[1+(self.crt_frm&7)])
|
||||
rectfill(x0+4, y0+4, x1-4, y1-4, cf)
|
||||
fillp()
|
||||
end
|
||||
@ -1953,7 +1953,7 @@ end
|
||||
|
||||
function rearm_mode:draw_option(id)
|
||||
local rec = self.options[id]
|
||||
self:glow_box(0,0,55,100,self:frame_col(self.sel == id),1)
|
||||
self:glow_box(0,0,55,101,self:frame_col(self.sel == id),1)
|
||||
spr(rec.icon,5, 5)
|
||||
print(rec.hdr, 13, 8, 7)
|
||||
print(rec.body, 5, 15, 6)
|
||||
@ -1989,9 +1989,9 @@ function rearm_mode:draw()
|
||||
camera(frac * -128 + (1-frac) * -56, 0)
|
||||
self:draw_option(2)
|
||||
camera(0, -28 * frac)
|
||||
self:glow_box(0,101,111,127,self:frame_col(self.sel < 0),1)
|
||||
self:glow_box(0,102,111,127,self:frame_col(self.sel < 0),1)
|
||||
spr(96,15,107,4,2)
|
||||
print("full ammo\nfull shield\n+50% health",54, 106, 6)
|
||||
print("full ammo\nfull shield\n+50% health",54, 107, 6)
|
||||
end
|
||||
|
||||
function rearm_mode:update_pos()
|
||||
@ -2011,6 +2011,7 @@ function rearm_mode:update_pos()
|
||||
end
|
||||
|
||||
function rearm_mode:update()
|
||||
self.crt_frm+=0.25
|
||||
self:update_pos()
|
||||
if self.pos > 1 then
|
||||
mode = game_mode
|
||||
|
Reference in New Issue
Block a user