Compare commits
22
Commits
229f97e3d2
...
6e304a9536
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6e304a9536 | ||
|
|
edccfbc42b | ||
|
|
9ed191d9ae | ||
|
|
36b5b5088b | ||
|
|
077b79e49f | ||
|
|
bf6d0c2202 | ||
|
|
c39cfba970 | ||
|
|
1d9ab02ff3 | ||
|
|
4b3d5d5586 | ||
|
|
4abcfdef0c | ||
|
|
7539b40f08 | ||
|
|
0e97eb462d | ||
|
|
c3a8463ea9 | ||
|
|
0a0db9e57f | ||
|
|
262eaa357b | ||
|
|
87af1fded7 | ||
|
|
1f2dcbe83f | ||
|
|
2e7a8c3530 | ||
|
|
db1516bef6 | ||
|
|
40f3bb5be6 | ||
|
|
594fe49eb2 | ||
|
|
d5ba372264 |
No files matched your search
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "mnml-client",
|
||||
"version": "1.13.0",
|
||||
"version": "1.14.1",
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
|
||||
@@ -27,7 +27,7 @@ aside {
|
||||
flex-flow: column;;
|
||||
}
|
||||
|
||||
grid-template-rows: min-content 3fr 3fr 1fr;
|
||||
grid-template-rows: min-content 1fr 1fr min-content;
|
||||
grid-gap: 0.5em 0;
|
||||
}
|
||||
|
||||
@@ -132,7 +132,7 @@ aside {
|
||||
|
||||
.ready {
|
||||
flex: 1;
|
||||
font-size: 200%;
|
||||
font-size: 2.5em;
|
||||
}
|
||||
|
||||
.quit {
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "mnml-client",
|
||||
"version": "1.13.0",
|
||||
"version": "1.14.1",
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
|
||||
@@ -59,8 +59,13 @@ class AccountAvatar extends Component {
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.idle = idleAnimation(this.props.account.id);
|
||||
return this.animations.push(this.idle);
|
||||
const startIdle = () => {
|
||||
this.idle = idleAnimation(this.props.account.id);
|
||||
this.animations.push(this.idle);
|
||||
this.idle.finished.then(startIdle);
|
||||
};
|
||||
|
||||
startIdle();
|
||||
}
|
||||
|
||||
resetAnimations() {
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
const anime = require('animejs').default;
|
||||
|
||||
function idle(id) {
|
||||
const duration = anime.random(2000, 18000);
|
||||
const duration = anime.random(2000, 8000);
|
||||
const target = document.getElementById(id);
|
||||
|
||||
return anime({
|
||||
targets: target,
|
||||
translateX: () => anime.random(-20, 20),
|
||||
@@ -10,8 +11,7 @@ function idle(id) {
|
||||
rotate: () => anime.random(-15, 15),
|
||||
duration,
|
||||
direction: 'alternate',
|
||||
easing: 'linear',
|
||||
loop: true,
|
||||
easing: 'easeInOutSine',
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -48,8 +48,13 @@ class ConstructAvatar extends Component {
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.idle = idleAnimation(this.props.construct.id);
|
||||
return this.animations.push(this.idle);
|
||||
const startIdle = () => {
|
||||
this.idle = idleAnimation(this.props.construct.id);
|
||||
this.animations.push(this.idle);
|
||||
this.idle.finished.then(startIdle);
|
||||
};
|
||||
|
||||
startIdle();
|
||||
}
|
||||
|
||||
resetAnimations() {
|
||||
|
||||
@@ -22,7 +22,7 @@ const addState = connect(
|
||||
}
|
||||
|
||||
return {
|
||||
promptRegister: tutorial === 99, // see events
|
||||
promptRegister: !tutorial, // see events
|
||||
account,
|
||||
sendInstancePractice,
|
||||
};
|
||||
|
||||
@@ -98,7 +98,7 @@ function GameCtrlBtns(args) {
|
||||
return (
|
||||
<div class="game-ctrl-btns">
|
||||
<button disabled={!account.subscribed} onClick={() => setChatShow(!chatShow)}>Chat</button>
|
||||
<button disabled={animating} onClick={sendGameSkillClear}>Clear</button>
|
||||
<button disabled={finished || animating} onClick={sendGameSkillClear}>Clear</button>
|
||||
{finished ? quitBtn : readyBtn}
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -34,8 +34,13 @@ class MnniAvatatr extends Component {
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.idle = idleAnimation('mnni');
|
||||
return this.animations.push(this.idle);
|
||||
const startIdle = () => {
|
||||
this.idle = idleAnimation('mnni');
|
||||
this.animations.push(this.idle);
|
||||
this.idle.finished.then(startIdle);
|
||||
};
|
||||
|
||||
startIdle();
|
||||
}
|
||||
|
||||
resetAnimations() {
|
||||
|
||||
@@ -37,8 +37,13 @@ class Img extends Component {
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.idle = idleAnimation(this.props.id);
|
||||
return this.animations.push(this.idle);
|
||||
const startIdle = () => {
|
||||
this.idle = idleAnimation(this.props.id);
|
||||
this.animations.push(this.idle);
|
||||
this.idle.finished.then(startIdle);
|
||||
};
|
||||
|
||||
startIdle();
|
||||
}
|
||||
|
||||
resetAnimations() {
|
||||
|
||||
@@ -166,9 +166,12 @@ function registerEvents(store) {
|
||||
function setInvite(code) {
|
||||
if (!code) return store.dispatch(actions.setInvite(null));
|
||||
const link = `${document.location.origin}#join=${code}`;
|
||||
navigator.clipboard.writeText(link).then(() => {
|
||||
notify('Your invite code was copied to the clipboard.');
|
||||
}, () => {});
|
||||
|
||||
if (navigator.clipboard) {
|
||||
navigator.clipboard.writeText(link).then(() => {
|
||||
notify('Invite link copied to clipboard.');
|
||||
}, () => {});
|
||||
}
|
||||
|
||||
return store.dispatch(actions.setInvite(code));
|
||||
}
|
||||
|
||||
@@ -349,6 +349,7 @@ function createSocket(events) {
|
||||
sendItemInfo();
|
||||
|
||||
events.urlHashChange();
|
||||
events.setPvp(false);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -97,6 +97,7 @@ function tutorialVbox(player, store, tutorial) {
|
||||
if (stage === 7) {
|
||||
if (vbox.bits < 25) {
|
||||
stage += 1;
|
||||
setTimeout(() => store.dispatch(actions.setTutorial(null)), 4000);
|
||||
} else {
|
||||
vbox.store.Colours = {};
|
||||
vbox.store.Skills = {};
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "mnml_core"
|
||||
version = "1.13.0"
|
||||
version = "1.14.1"
|
||||
authors = ["ntr <ntr@smokestack.io>", "mashy <mashy@mnml.gg>"]
|
||||
|
||||
[dependencies]
|
||||
|
||||
+1
-7
@@ -121,13 +121,7 @@ impl Effect {
|
||||
}
|
||||
|
||||
pub fn disables_skill(&self, skill: Skill) -> bool {
|
||||
if skill.is_tick() {
|
||||
return false;
|
||||
}
|
||||
|
||||
// electrocute always goes off baybee
|
||||
// even if you are stunned particularly
|
||||
if [Skill::Electrocute, Skill::ElectrocutePlus, Skill::ElectrocutePlusPlus].contains(&skill) {
|
||||
if !skill.can_be_disabled() {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
+17
-7
@@ -804,7 +804,7 @@ impl Game {
|
||||
}
|
||||
}
|
||||
|
||||
fn finish(mut self) -> Game {
|
||||
pub fn finish(mut self) -> Game {
|
||||
self.phase = Phase::Finished;
|
||||
// self.log.push(format!("Game finished."));
|
||||
|
||||
@@ -835,7 +835,7 @@ impl Game {
|
||||
return self;
|
||||
}
|
||||
|
||||
info!("upkeep game: {:} vs {:}", self.players[0].name, self.players[1].name);
|
||||
info!("upkeep {:?} {:} vs {:}", self.id, self.players[0].name, self.players[1].name);
|
||||
|
||||
for player in self.players.iter_mut() {
|
||||
if !player.ready {
|
||||
@@ -2335,13 +2335,23 @@ mod tests {
|
||||
},
|
||||
_ => false,
|
||||
}));
|
||||
}
|
||||
|
||||
/* assert!(match game.players[1].constructs[0].effects[0].meta {
|
||||
Some(EffectMeta::AddedDamage(d)) => d,
|
||||
_ => 0
|
||||
// 320 base blue power and 125 base blue life
|
||||
} == 320.pct(Skill::Blast.multiplier()) - 125);*/
|
||||
#[test]
|
||||
fn absorb_silence_test() {
|
||||
let mut game = create_2v2_test_game();
|
||||
let player_id = game.players[0].id;
|
||||
let target_player_id = game.players[1].id;
|
||||
|
||||
let source = game.players[0].constructs[0].id;
|
||||
let target = game.players[1].constructs[0].id;
|
||||
|
||||
game.new_resolve(Cast::new(target, player_id, target, Skill::Absorb));
|
||||
assert!(game.construct_by_id(target).unwrap().affected(Effect::Absorb));
|
||||
|
||||
game.new_resolve(Cast::new(source, target_player_id, target, Skill::Silence));
|
||||
assert!(game.construct_by_id(target).unwrap().affected(Effect::Silence));
|
||||
assert!(game.construct_by_id(target).unwrap().affected(Effect::Absorption));
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
||||
@@ -834,6 +834,22 @@ impl Skill {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn can_be_disabled(self) -> bool {
|
||||
match self {
|
||||
Skill::ElectrocuteTick |
|
||||
Skill::DecayTick |
|
||||
Skill::SiphonTick |
|
||||
Skill::TriageTick |
|
||||
Skill::Electrocute |
|
||||
Skill::ElectrocutePlus |
|
||||
Skill::ElectrocutePlusPlus |
|
||||
Skill::Absorption |
|
||||
Skill::AbsorptionPlus |
|
||||
Skill::AbsorptionPlusPlus => false,
|
||||
_ => true,
|
||||
}
|
||||
}
|
||||
|
||||
pub fn additional_skill(&self, effect: Effect) -> Option<Skill> {
|
||||
match effect {
|
||||
Effect::Haste => match self {
|
||||
|
||||
Regular → Executable
+3
-3
@@ -13,7 +13,7 @@ map $http_upgrade $connection_upgrade {
|
||||
}
|
||||
|
||||
server {
|
||||
server_name sixtysix.pro;
|
||||
server_name calamarirace.team;
|
||||
|
||||
gzip on;
|
||||
gzip_vary on;
|
||||
@@ -50,8 +50,8 @@ server {
|
||||
|
||||
listen [::]:443 ssl ipv6only=on; # managed by Certbot
|
||||
listen 443 ssl; # managed by Certbot
|
||||
ssl_certificate /etc/letsencrypt/live/sixtysix.pro/fullchain.pem; # managed by Certbot
|
||||
ssl_certificate_key /etc/letsencrypt/live/sixtysix.pro/privkey.pem; # managed by Certbot
|
||||
ssl_certificate /etc/letsencrypt/live/calamarirace.team/fullchain.pem; # managed by Certbot
|
||||
ssl_certificate_key /etc/letsencrypt/live/calamarirace.team/privkey.pem; # managed by Certbot
|
||||
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
|
||||
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
|
||||
}
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "mnml-ops",
|
||||
"version": "1.13.0",
|
||||
"version": "1.14.1",
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "mnml"
|
||||
version = "1.13.0"
|
||||
version = "1.14.1"
|
||||
authors = ["ntr <ntr@smokestack.io>"]
|
||||
|
||||
[dependencies]
|
||||
|
||||
@@ -13,6 +13,7 @@ use pg::{
|
||||
PgPool,
|
||||
|
||||
games_need_upkeep,
|
||||
game_get,
|
||||
game_update,
|
||||
game_write,
|
||||
game_delete,
|
||||
@@ -157,6 +158,12 @@ fn fetch_instances(mut tx: Transaction) -> Result<Transaction, Error> {
|
||||
}
|
||||
|
||||
for mut instance in instances_idle(&mut tx)? {
|
||||
if let Some(game_id) = instance.current_game_id() {
|
||||
let mut game = game_get(&mut tx, game_id)?;
|
||||
game = game.finish();
|
||||
game_update(&mut tx, &game)?;
|
||||
}
|
||||
|
||||
instance.finish();
|
||||
instance_update(&mut tx, instance)?;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "mnml-studios",
|
||||
"version": "1.13.0",
|
||||
"version": "1.14.1",
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
|
||||
Reference in new issue
Block a user