Git Product home page Git Product logo

junethack's Introduction

Junethack is a server for holding tournaments for the roguelike game NetHack and its forks.

This server collects data from several external public servers and show achievements and trophies for the participating players.

Requirements

Needed pre-installed software

  • ruby 3.1.4
  • curl
  • sqlite3

Installation

Clone the repository:

git clone https://github.com/junethack/Junethack.git junethack

Install the Ruby interpreter. Example using RVM:

\curl -#L https://get.rvm.io | bash -s stable
source ~/.rvm/scripts/rvm
rvm install `cat junethack/.ruby-version`

Install all required rubygems:

cd junethack
bundle install

Start the server

rake

Setting up the server for a new year

Update the year in the following files

  • lib/junethack/tournament_times.rb
  • public/graph/graph_ascensions.js
  • public/graph/graph_finished_games_per_day.js
  • public/graph/graph_new_users_per_day.js
  • views/footer.haml
  • views/layout.haml
  • views/splash.haml
  • views/user.haml

Go through the list of servers and variants and add new ones and remove old ones.

Archival of a finished tournament

Start the webserver with ARCHIVE_MODE=1 and use the script scripts/archive.sh to make a static copy of the website.

Edit the archive links to the previous Junethack tournaments in public/archive/2023/index.html. Also add a link to the the new Junethack archive in views/splash.haml.

Add and commit the repository.

TODO: more documentation, distinction prod/dev env, maintenance mode, manually fetching games, dummy users

junethack's People

Contributors

actual-nh avatar bhaak avatar borekl avatar cheryl avatar demogorgon22 avatar espadolini avatar junethack avatar mathematicalcoffee avatar minoru avatar noeda avatar rojjacebolla avatar zuzak avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

junethack's Issues

Clan disbanding is nonfunctional

It appears there is no working way to remove a clan. Trying to leave the clan as the admin always results in an Internal Server Error, followed by the message "The clan admin can not leave the clan." after refresh. Using the "Disband" option always results in the message "Could not destroy clan".

This happens even when the admin is the only member remaining in the clan.

New trophies for EvilHack 0.8.2

Trophy for defeating a new unique boss - Saint Michael (appears in purgatory, bright magenta boss Angel). In the xlogfile, will show up under 'killed_uniques' as 'Saint Michael'. Can use https://junethack.net/icons/m-astral.png as the icon, color could probably be bright magenta.

Trophy for entering Purgatory, shows up under achieveX as 'entered_purgatory'. Can use https://junethack.net/icons/c-highest-score.png as the icon, whatever color change makes sense.

Trophy for defeating another unique, Gollum. Shows under 'killed_uniques' as 'Gollum'. Can use https://junethack.net/icons/entered_the_gnomish_mines.png as the icon, maybe shade it light gray.

EDIT - this graphic https://junethack.net/icons/entered_moria.png recolored to bright magenta would be a great replacement for the goblin king glyph.

Thanks!

dNethack trophy names and new trophies

Link to CSV: https://github.com/Chris-plus-alphanumericgibberish/dNAO/blob/compat-3.21.0/junethack_trophies/trophy_descriptions.csv

dNethack has one new role this year: the Madman (file code "Mad"), which will need to be added to the dNethack Tour trophy (I'm going to create a second suggesting the removal of the dNethack prince and king trophies, the tour one I kind of like the idea of).

All trophies now have names listed (which is clearly the important part, not the artwork <_<). I've separated out the new trophies from the old ones.

The first three trophies are straightforward achieveX tags, the first for finishing the Madman quest, the other two for defeating Lamashtu and Baalphegor (it seemed odd that Demogorgon and Asmodeus had trophies but those two didn't).

The last pair of trophies is a bit more complex, but I think still straightforward to add. There is a set of three _vault achieveX tags, and I'm proposing giving out the first trophy when a player earns any one of those tags, and the second trophy once a player has earned all three of those tags (across however many games that takes). If that's not actually straightforward to handle, there could just as easily be one trophy per _vault flag.

Multiple occurrences of a single game

Currently 2011-07-18 07:30:00Z a game of zid http://junethack.rawrnix.com/user/zid is recorded 10 times.

That was to be expected as there is no real transaction handling and when something goes wrong while fetching games, it just stops with possibly some games already imported but the timestamp of the xlogfile not being updated (to not lose any games).

blister's clan name

ie the string "~|:{" (and possibly other non-standard clan names) is preventing creation of clearspan on /home, ie div#clanmanager div.account-clan span.clear. Result is that the last section with the form that creates a new clan is not cleared. This causes it to be cut off outside the central content box.

Idea: display (more) clan scores relative to each other?

This could be on /scoreboard or /clans, or both. At the moment, the only way for a viewer to find out relative clan standing for any clans other than the top 3 is to visit two clans separately and remember the score or placing between them.

Possibilities:

  • scoreboard: display all (or 10 for example) instead of 3 - since we have quite a few more than 3 clans.
  • scoreboard: clickable option to "view more" clans and display more than 3
  • clans: have additional column(s) with clan score and/or placing

Unless there's a good reason to keep it at 3, of course :)

No clientside validation

Status

  • /login and /register are not being validated clientside yet
  • a very basic script has been written (see webmocks login.html, scripts.js), may not be symlinked to /public
  • script gives feedback but does not prevent form submission.
  • script currently performs whitespace trimming and checks for empty fields.

Idea: Be able to deregister an account from a user

Maybe this could be achieved by taking the # junethack2011 username out of their rcfile - I have not tested this - but it would be nice to be able to deregister an account for the tournament within the tournament site too.

Clan admin can leave the clan?

Leaving no one as admin. Not sure how this works, just watching demilichens. Shouldn't this either disband the clan or leave someone else in charge?

Improve navigation item display

  • Better delineation between navigation items
  • make the home logo more in line with the rest of the navigation, right now it seems to jut out
  • left aligning the navigation means the centered logo and dividers now look odd come up with a less centred solution that stays true to the original spirit of the design. Maybe a more grid-like layout?
  • add drop down menus to enable access to hierarchy of a lot of otherwise diverse pages

Some unique deaths should not be unique

This was raised in irc, I don't remember by whom. The example was that "killed by a couatl" should be indistinct from "killed by a couatl of $DEITY". There are probably other examples.

Clan invite error message

If inviting somebody (e.g. Alice) fails, the error message says
"Could not find Alice on 1"
where 1 should really be the server display_name

1/2 cross-variants achievements

With at least 6 different variants, it's reasonable to add cross-variant achievements when having done the cross-variant achievements in at least half the variants.

Webmocks appears to be spaghetti?

Webmocks I assume was originally some kind of drafts communication folder. It seems to have grown into far more than that, having images linked directly into there as well as much (presumed) clutter from previous years.

  • How do we go about tidying it up? (Does anyone know?)
  • Is it possible to move important graphics stuff into its own folder, reassigning links in the logic as we go?
  • If not, what bits can we get rid of?

Front end design is inconsistent

  • At least 4 different designs of the logo are being used throughout the site (eg favicon)
  • Some parts of the design are relatively polished, while others are barely styled at all.
  • Some parts have one design aesthetic (eg, gradients with drop shadows and slightly round corners) while others use conflicting aesthetics (eg, flat shadowless sharp edges; very large round corners).

These may date from 2011 when the deadline was more urgent and branding/design was rather of a lesser importance. Eventually it would be nice to see a more coherent overall design.

Get rid of SlashTHEM

It's got some server-only bug meaning you can't really play a game for any length of time before it crashes repeatedly and unrecoverably.

<Soviet5lo> As for the crashes Bluescreen and a few others all collectively agree it's due to random corruption in mons[]

In one game I had, whenever I tried to wish the game would crash. I was told (by Bluescreen) that as I continued playing the game would get progressively more corrupted and eventually would not even load. The next time I logged on to continue the game (I was going to die creatively), it had disappeared off the server completely and was not logged as part of Junethack. The game was not able to be recovered.

In the second game, I played as a doppelganger monk, but whenever I #youpoly, the game would crash. Hard to be a doppelganger who can't poly! Same bug, apparently. At least this time I was able to die before the game disappeared off the server, so as to have my achievements recorded for Junethack.

Anyhow, a game that is broken (not in terms of being too hard, but in terms of instability and crashes) should not be part of Junethack.

I would argue that it even be removed this month (how can I ascend in every variant when you cannot ascend in SlashTHEM because of corruption bugs? though let's be honest, I'm not going to ascend in every variant anyway). However, I do understand that many players have devoted time to it already(e.g. it's great for unique deaths simply due to the large number of monsters), and to remove SlashTHEM half way through the month would waste that time, so probably best to leave it in this year.

Remove dNethack Prince and King trophies

dNethack is the only variant with its own Prince and King trophies. While they served at least a theoretical purpose originally, they're now largely redundant with the per-role quest trophies and per-race ascension trophies, have been getting more difficult to earn with each passing year, and require special handling to award. They were also not earned last year, and have either never or almost never been earned.

Although basically all of those points apply to the dNethack Tour trophy, I still like it in theory because it doesn't require making it to the mid-to-late game. However, I would understand if you also dropped support for dNethack Tour. The bit where it's rarely-to-never actually earned certainly suggests that it serves no purpose.

FAQ

a faq would have been nice

entries:

  • tournament duration
  • what happens to games if I register late?
  • etc

Add multiple accounts on the same server

Original behavior was to allow a user to add multiple accounts on the same server to a user. What happened to this? Tjr would very much like it to be implemented.

/home account-clan section styling

Could be displayed better. These are non-essential changes.

  • non-table format
  • table format with more spacing and styling (eg no "accept" / "decline" table heading cell - not necessary)
  • more consistent margins
  • "accept"/"decline" links styled more elegantly
  • "leave" link (for a current clan) styled so the user knows they are a separate clickable entity, not part of the clan name

Accounts of same user in different clans

Xaiph on nfi is in a different clan to xaiph on NAO, the two accounts belong to the same user. However, currently both clans receive all the points from both accounts.

Behaviour should either be restricted to:

  • one clan per user across all their accounts, OR
  • clan score consists only of scores of accounts that are in that clan, regardless what the account's user's other accounts' scores are. (whew)

404 error when adding a server account.

After registration, a user may experience a 404 error while adding a server account. I am told this is caused by the case sensitivity of the server account name parser and can be easily solved by the user giving the correct case of their server account. The error message should communicate this. A 404 error does not intuitively explain the problem or what the user can do to solve it.

Alternatively the name parser could be made case insensitive.

Different users can link the same account

From IRC:

[21:55:50] Squolly\unfoog | dunno if it is fixed, but different users can link the same account
[21:56:08] Squolly\unfoog | and some strange inconsistency seems to happen in that case

Probably won't happen unless people co-operate to do this.

SLEX trophies, version 2.70

slextrophies2021.zip

This adds new trophies for SLASH'EM Extended 2.70, which are encoded in the achieveX xlogfile string. The new trophies are:
devnull_complete = s-devnull.png "visited all DevNull challenges"
killed_minotaur = s-minotaur.png "killed the Minotaur of the Maze"
killed_kalwina = s-kalwina.png "killed Kalwina"
killed_stahngnir = s-stahngnir.png "killed Lord Stahngnir"
killed_ariane = s-ariane.png "killed Lady Ariane"
completed_rivalquest = s-rivalquest.png "completed the Rival Quest"
completed_minusworld = s-minusworld.png "completed the Minus World"
killed_vera = s-vera.png "killed Vera the Ice Queen"
killed_elaine = s-elaine.png "killed Elaine the Enchantress"

On the Junethack trophies page for SLEX, please sort them such that the ones that aren't for killing specific monsters are sorted with the other misc trophies (imbued bell of opening, imbued amulet of yendor etc.) :-)

New clan trophies/replacement for "most points"

New clan trophies are best added before the tournament starts for transparency reasons.

"Most points" must be replaced as scoring is heavily broken in vanilla. We knew that already last year but there was no time to replace it then and we would have missed Berry's completely pwning of hist score ascensions.

Alt tags empty for trophies

In these files

views/_trophy_scores.haml
views/games_played.haml
views/user.haml
views/home.haml

there should be added a :alt => $trophy_names[...] at the appropiate places for having alt tags on the trophy images.

I'm not at home right now, so cannot really test it before comitting, so I'll log it here.

Proper image styling for /home trophies

Still using inline style width/height - this needs to be removed and the structure of .trophycabinet > ul > li > a.imagelink > img.trophyright implemented, exactly as per /user/name.

EvilHack new achievement - defeated the Goblin king

defeated_goblin_king
Attached a pic for the trophy. I don't have the tools to make a lightened version.

In lib/junethack/models/trophy.rb around line 301, add:
achievements << [:defeated_goblin_king, 'defeated the Goblin King', "defeated_goblin_king.png", 10]

Length of names

"claaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaan" has been made as a clan name, breaking the prettytable. usernames and clan names should be restricted to a certain char length.

TODO before tournament 2019 starts

  • add notdnethack/evilhack
  • add generic cross-variant achievements
  • fix up text for cross-variant achievements on /trophies
  • new pictures for cross-variant achievements
  • update FAQ for 2019
  • SpliceHack death messages
  • remove lowest sum

A way for users to give feedback and suggestions

For example, trophy ideas, or ways to improve the website, or report bugs.

  • Github: It is not intuitive to require a user to sign up to and navigate through github to report issues. The repo is primarily for people interested in development.
  • junethack: This is somewhat intuitive, however it is a fleeting medium and issues reported here are either dealt with in passing or forgotten unless also reported at github. NB: If at the time of reporting the reporting user happens to meet with a developer who is present, capable and willing to solve the issue at that moment, it may be solved at that point, however:

    • this does not happen often (present, capable and willing)
    • this does not take advantage of the whole team's knowledge to provide an answer
    • this is not visible to future developers looking back at previous years' projects unless it was also noted in the log or issues page.

Suggestions

  • Add a feedback/contact form on the website itself that would post issues to github
  • Allow a bot in #junethack to post issues to github (would require moderation)
  • Allow a bot in #junethack to collect suggestions and feedback from users for later perusal by developers willing to register or deal with the issues themselves.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.