Giter Club home page Giter Club logo

slenderaac's Introduction

Slender AAC

This project is a website for the Canary project. The main goal is to use modern technology to have something that is easy to maintain and extend. It is also meant to be efficient, secure and easy to deploy.

Features / Roadmap

Getting started

Requirements

Installation

Clone this repository and install the dependencies:

git clone https://github.com/luan/slenderaac.git
cd slenderaac
pnpm install
cp .env.dist .env

Edit .env with your server and desired settings. Then migrate the database using the command below. Note that this assumes your current database already has the canary schema imported.

pnpm migrate:resolve
pnpm migrate
pnpm generate

Running

At this point you should be ready to run the server:

pnpm dev

Deployment

Deployment depends highly on your server setup. Assuming you are on a Linux dedicated server or VPS. You need the following:

As well as a database compatible with canary. You can use either MySQL or MariaDB.

Installation

sudo apt update
curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash - && sudo apt install -y nodejs
sudo npm install -g pnpm
sudo apt install -y nginx

Clone this repository and install the dependencies:

git clone https://github.com/luan/slenderaac.git
cd slenderaac
pnpm install
cp .env.dist .env

Nginx

We're just using Nginx as a reverse proxy. You can use any other web server that supports reverse proxying if you'd like. The Nginx configuration is as follows (adjust port and domain as needed if you're not using the defaults):

server {
        listen 80 default_server;
        listen [::]:80 default_server;
        server_name _;

        location / {
                   proxy_pass http://127.0.0.1:3000;
                   proxy_http_version 1.1;
                   proxy_set_header Upgrade $http_upgrade;
                   proxy_set_header Connection 'upgrade';
                   proxy_set_header Host $host;
                   proxy_cache_bypass $http_upgrade;
       }
}

Building

Because we're now in a production environment, we need to build the project. This will generate the static files that will be served by the nodejs server. This is a one time step, you only need to do this again if you change /update the code.

pnpm generate
pnpm build

Migrating the database

At this point you should be ready to migrate the database. This will create the necessary tables and columns. Note that this assumes your current database already has the canary schema imported.

pnpm migrate:resolve
pnpm migrate

Running

Finally, we need to run the server, this will run on port 3000 by defaul, which is what we configured Nginx to proxy to.

NODE_ENV=production node -r dotenv/config build

Client config

Using your favorite method to edit the client (see this tutorial for help). Set the login webservice url to http://localhost:5173/api/login (or your appropraite server URL). This will make the client use the AAC to login.

Animated outfits

You'll need to download the spritesheet from here and place it in outfits_anim. These assets are not included in the repository because they can cause the repo to bloat, and are also not release under the same license as the code.

Game store assets

Anything you put into the static folder in this repo will be served by the server. This is useful for storing assets for the game store. For example, you can put a static/images/store folder and then reference the images in the store using /images/store/my-image.png. For instance, you can use the store assets made available in the canary docs

Screenshots

Homepage (as admin)

image

Login page after registration

image

Account page (unverified)

image

Verification email

image

Static page

image

Shop 1

Slender

Shop 2

Slender (1)

Shop (video)

Kapture.2023-06-12.at.16.09.37.mp4

Highscores

Slender | Highscores

Character search

Kapture.2023-06-12.at.16.11.52.mp4

Guilds

Slender | Guilds (1) Slender Slender (2) Capture-2023-06-16-195438 Capture-2023-06-16-195453 Capture-2023-06-16-195510 Slender (3) Capture-2023-06-16-195556

Tech stack

Contributing

Contributions are welcome! Please open an issue or pull request. Be sure to post screenshots and logs of any issues you're having.

License

MIT

slenderaac's People

Contributors

luan avatar jarrodpjohnston avatar

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.