mod - many worlds: 100% chance on choosing a power up to spawn a reroll if you have no rerolls mod - microstates: +7% damage for every 10 active bullets (requires mod: Lorentzian topology) mod - laser diode: laser, pulse, and laser-bots use 37% less energy 25% increase in difficulty scaling (level 10 should now have the difficulty of level 12) effects: player damage, mod damage, mob acceleration, mob reaction time, mob cooldown time
43 lines
1002 B
JavaScript
43 lines
1002 B
JavaScript
// redblobgames.com/articles/visibility
|
|
// https://github.com/Silverwolf90/2d-visibility/tree/master/src
|
|
// could apply to explosions, neutron bomb, player LOS
|
|
|
|
|
|
const v = {
|
|
points: [],
|
|
populate() {
|
|
v.points = [{
|
|
x: -150,
|
|
y: -950
|
|
}, {
|
|
x: 710,
|
|
y: -950
|
|
}, {
|
|
x: 710,
|
|
y: -940
|
|
}, {
|
|
x: 710,
|
|
y: -710
|
|
}, {
|
|
x: 710,
|
|
y: -700
|
|
}, {
|
|
x: -150,
|
|
y: -700
|
|
}]
|
|
},
|
|
draw() {
|
|
ctx.beginPath();
|
|
ctx.moveTo(v.points[0].x, v.points[0].y)
|
|
for (let i = 0, len = v.points.length; i < len; i++) {
|
|
ctx.lineTo(v.points[i].x, v.points[i].y)
|
|
}
|
|
// ctx.fillStyle = "#333"
|
|
ctx.globalCompositeOperation = "destination-in";
|
|
ctx.fill();
|
|
ctx.globalCompositeOperation = "source-over";
|
|
ctx.clip();
|
|
}
|
|
}
|
|
v.populate();
|
|
// console.log(v.points)
|