diff --git a/js/bullets.js b/js/bullets.js
index d8e61a4..70a1052 100644
--- a/js/bullets.js
+++ b/js/bullets.js
@@ -746,7 +746,7 @@ const b = {
}
},
{
- name: "+1 cardinality",
+ name: "cardinality",
description: "one extra choice when selecting power ups",
maxCount: 1,
count: 0,
@@ -937,33 +937,33 @@ const b = {
}
},
{
- name: "fléchettes cartridges",
- description: "fléchettes release three needles in each shot
ammo cost are increases by 3x",
+ name: "flechettes cartridges",
+ description: "flechettes release three needles in each shot
ammo cost are increases by 3x",
maxCount: 1,
count: 0,
allowed() {
- return b.haveGunCheck("fléchettes")
+ return b.haveGunCheck("flechettes")
},
- requires: "fléchettes",
+ requires: "flechettes",
effect() {
b.isModFlechetteMultiShot = true;
//cut current ammo by 1/3
for (i = 0, len = b.guns.length; i < len; i++) { //find which gun
- if (b.guns[i].name === "fléchettes") b.guns[i].ammo = Math.ceil(b.guns[i].ammo / 3);
+ if (b.guns[i].name === "flechettes") b.guns[i].ammo = Math.ceil(b.guns[i].ammo / 3);
}
//cut ammo packs by 1/3
for (i = 0, len = b.guns.length; i < len; i++) { //find which gun
- if (b.guns[i].name === "fléchettes") b.guns[i].ammoPack = Math.ceil(b.guns[i].defaultAmmoPack / 3);
+ if (b.guns[i].name === "flechettes") b.guns[i].ammoPack = Math.ceil(b.guns[i].defaultAmmoPack / 3);
}
game.updateGunHUD();
},
remove() {
b.isModFlechetteMultiShot = false;
for (i = 0, len = b.guns.length; i < len; i++) { //find which gun
- if (b.guns[i].name === "fléchettes") b.guns[i].ammo = Math.ceil(b.guns[i].ammo * 3);
+ if (b.guns[i].name === "flechettes") b.guns[i].ammo = Math.ceil(b.guns[i].ammo * 3);
}
for (i = 0, len = b.guns.length; i < len; i++) { //find which gun
- if (b.guns[i].name === "fléchettes") b.guns[i].ammoPack = b.guns[i].defaultAmmoPack;
+ if (b.guns[i].name === "flechettes") b.guns[i].ammoPack = b.guns[i].defaultAmmoPack;
}
game.updateGunHUD();
}
@@ -974,9 +974,9 @@ const b = {
maxCount: 1,
count: 0,
allowed() {
- return b.haveGunCheck("fléchettes")
+ return b.haveGunCheck("flechettes")
},
- requires: "fléchettes",
+ requires: "flechettes",
effect() {
b.isModDotFlechette = true;
},
@@ -2470,7 +2470,7 @@ const b = {
}
},
{
- name: "fléchettes", //3
+ name: "flechettes", //3
description: "fire a precise volley of high velocity needles
that apply chemical damage over 3 seconds",
ammo: 0,
ammoPack: 23,
diff --git a/js/game.js b/js/game.js
index 0c50b94..4741906 100644
--- a/js/game.js
+++ b/js/game.js
@@ -527,6 +527,7 @@ const game = {
splashReturn() {
game.onTitlePage = true;
// document.getElementById('splash').onclick = 'run(this)';
+ // build.isURLBuild = false;
document.getElementById("splash").onclick = function () {
game.startGame();
};
diff --git a/js/index.js b/js/index.js
index d0ddb82..cbd72e9 100644
--- a/js/index.js
+++ b/js/index.js
@@ -22,30 +22,63 @@ const cat = {
// &difficulty=2
//use %20 for spaces
//difficulty is 0 easy, 1 normal, 2 hard, 4 why
-function onLoadPowerUps() {
- function getUrlVars() {
- let vars = {};
- window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function (m, k, v) {
- vars[k] = v;
- });
- return vars;
- }
- const set = getUrlVars()
- for (const property in set) {
- // console.log(`${property}: ${give[property]}`);
- set[property] = set[property].replace(/%20/g, " ")
- if (property.substring(0, 3) === "gun") b.giveGuns(set[property])
- if (property.substring(0, 3) === "mod") b.giveMod(set[property])
- if (property === "field") mech.setField(set[property])
- if (property === "difficulty") {
- game.difficultyMode = Number(set[property])
- document.getElementById("difficulty-select").value = Number(set[property])
- }
- }
+function getUrlVars() {
+ let vars = {};
+ window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function (m, k, v) {
+ vars[k] = v;
+ });
+ return vars;
}
+// ?
+// &gun0 = minigun & gun1 = shotgun & gun2 = super % 20 balls & gun3 = flechettes & gun4 = wave % 20 beam & gun5 = missiles & gun6 = flak & gun7 = grenades & gun8 = vacuum % 20 bomb &
+// gun9 = mine & gun10 = spores & gun11 = drones & gun12 = ice % 20 IX & gun13 = foam & gun14 = rail % 20 gun & gun15 = laser & gun16 = pulse
+// &
+// mod0 = depleted % 20 uranium % 20 rounds & mod1 = kinetic % 20 bombardment & mod2 = fracture % 20 analysis & mod3 = fluoroantimonic % 20 acid &
+// mod4 = negative % 20 feedback & mod5 = radiative % 20 equilibrium & mod6 = high % 20 explosives & mod7 = high % 20 explosives &
+// mod8 = high % 20 explosives & mod9 = electric % 20 reactive % 20 armor & mod10 = thermal % 20 runaway & mod11 = auto - loading % 20 heuristics &
+// mod12 = desublimated % 20 ammunition & mod13 = mass % 20 driver & mod14 = laser - bot & mod15 = nail - bot & mod16 = ablative % 20 drones &
+// mod17 = ablative % 20 mines & mod18 = Lorentzian % 20 topology & mod19 = Lorentzian % 20 topology & mod20 = Lorentzian % 20 topology &
+// mod21 = zoospore % 20 vector & mod22 = reaction % 20 inhibitor & mod23 = waste % 20 energy % 20 recovery & mod24 = scrap % 20 recycling &
+// mod25 = acute % 20 stress % 20 response & mod26 = squirrel - cage % 20 rotor & mod27 = basidio - stomp & mod28 = Pauli % 20 exclusion &
+// mod29 = annihilation & mod30 = quantum % 20 immortality & mod31 = weak % 20 anthropic % 20 principle & mod32 = entanglement & mod33 = piezoelectricity &
+// mod34 = ground % 20 state & mod35 = energy % 20 conservation & mod36 = entropy % 20 exchange & mod37 = overcharge & mod38 = supersaturation &
+// mod39 = recursive % 20 healing & mod40 = mass - energy % 20 equivalence & mod41 = Bayesian % 20 inference & mod42 = % 2 B1 % 20 cardinality &
+// mod43 = catabolism & mod44 = leveraged % 20 investment & mod45 = ice % 20 crystal % 20n ucleation & mod46 = shotgun % 20 spin - statistics &
+// mod47 = super % 20 duper & mod48 = super % 20 duper & mod49 = flechettes % 20 cartridges & mod50 = irradiated % 20n eedles & mod51 = wave % 20 phase % 20 velocity &
+// mod52 = pocket % 20 universe & mod53 = self - replication & mod54 = optimized % 20 shell % 20 packing & mod55 = electromagnetic % 20 pulse &
+// mod56 = mine % 20 reclamation & mod57 = tinsellated % 20 flagella & mod58 = redundant % 20 systems & mod59 = heavy % 20 water & mod60 = foam % 20 stabilization &
+// mod61 = fragmenting % 20 projectiles & mod62 = specular % 20 reflection & mod63 = specular % 20 reflection & mod64 = specular % 20 reflection &
+// mod65 = quantum % 20 dissipation & field = phase % 20 decoherence % 20 field & difficulty = 2
+
+
+
+window.addEventListener('load', (event) => {
+ const set = getUrlVars()
+ if (Object.keys(set).length !== 0) {
+ build.isURLBuild = true;
+ game.startGame()
+ }
+});
//build build grid display
const build = {
+ isURLBuild: false,
+ onLoadPowerUps() {
+ const set = getUrlVars()
+ if (Object.keys(set).length !== 0) {
+ for (const property in set) {
+ // console.log(`${property}: ${give[property]}`);
+ set[property] = set[property].replace(/%20/g, " ")
+ if (property.substring(0, 3) === "gun") b.giveGuns(set[property])
+ if (property.substring(0, 3) === "mod") b.giveMod(set[property])
+ if (property === "field") mech.setField(set[property])
+ if (property === "difficulty") {
+ game.difficultyMode = Number(set[property])
+ document.getElementById("difficulty-select").value = Number(set[property])
+ }
+ }
+ }
+ },
pauseGrid() {
// let text = `