Coder Social home page Coder Social logo

michal2sab / stick-arena-private-server Goto Github PK

View Code? Open in Web Editor NEW
3.0 5.0 1.0 6.47 MB

Improved version of BallistickEMU.

Java 96.01% Batchfile 0.03% PHP 3.96%
flash-games private-servers stick-arena stick-arena-ballistick xgenstudios ballistickemu

stick-arena-private-server's Introduction

Stick-Arena-Private-Server

Improved version of BallistickEMU. The original is probably entirely written by Simon but I'm not sure.

What changed?

  • Added CredTicketHandler. You can now collect cred ticket when it's available.
  • Added DoubleLoginHandler. You can't have two of the same accounts in the same server at the same time anymore, you will be notified that somebody just logged in to your account.
  • Better ban handling. Ban packet actually being sent to the client (user getting banned) with a time and message, instead of getting disconnected.
  • Fixed lobby appearance bug. Sometimes users were invisible after joining lobby and.. it was a mess.
  • Fixed game bug - reset player's kills and deaths if they rejoin the room.
  • Wrote win/loss logic, same as on original SA server. Not the best code, change it if you can cus I don't care.
  • Partially fixed the inventory glitch. You can now select the spinner you purchased/added without logging out first, but when you log out you will have your first spinner selected.
  • Added !bluehead command. Gives you the original bluehead color and the spinner as on original stick arena. Requires 588 version of SA SWF client.
  • !fuzzyspinner, !builderspinner, !candycane, !heartsspinner are not simply just !fuzzy, !builder, !cane and !hearts.
  • Easier to read syntax help for color and spinner commands (no annoying black glitch with the <> characters)
  • Fixed stick_arena.php to work with PHP 7 and up.

Hints for those who want to continue improving the project

Fix the inventory

Buying or adding a new item to database will not properly add it to the stick inventory data you've already read. You can't properly set it as selected, and if you buy another item, it will overwrite the previous one (on client only, it will exist on database)

Possible solutions
  1. Make the player's client automatically re-read and re-set inventory data from the inventory table after purchasing or adding an item.
  2. Make the player automatically re-login (bad idea, noob idea).
  3. Change the way inventories are being handled entirely. Rewrite the code.

Fix the in-game kick

Kicking a player is not working for regular players. It works for moderators but it just disconnects a player, and that's stupid.

Solutions
  1. In KickHandler, make everybody's kick vote for a new user add to a list.
  2. Have a listener or something like that for that list, to keep checking if that list finally contains x amount of votes.
  3. Also keep checking for how many players in total there are in the game.
  4. Have a var x to keep updating. If the game has 3 players, 2 kicks are required. If 4, then 3 are required and so on. Like on sa.
  5. Once the list reached x amount of votes, send the "K" packet to the voted user.
  6. Add the kicked out user's id to a blacklist so he can't join this game again.

Properly deregister rooms if nobody is in them

Although games disappear from the 01 room request packet for everybody's client, they are still active or remembered in the server so creating another room with the same name will make you litteraly disappear until you come back to lobby.

Possible solutions
  1. Check if there is any StickRoom type list or whatever where all new rooms are additionally kept and make sure the room is removed from there aswel. It may be located both in StickRoom and StickClient tbh.
  2. Follow anything related to StickRoom or StickRoomRegistry line by line and find the issue. I honestly didn't even get to this so idk myself, just assuming.

!setkills is buggy

I think I recall setkills either not working or just being buggy.. look into it.

Solutions
  • There's probably a small error, find it and get rid of it in PlayersCommandsHandler.
  • Probably will have to re-read and re-set the player's stats from database again just like with the inventory glitch or re-login.

Remove ::disconnect command

Do I need to say more? Remove that cancerous command, unless you want to moderate only by yourself. We know how mods on the original SA were, you don't want that all over again. Or just separate mod powers with user level 1 and user level 2.

Improve ::ban further

Ok. So I made the player receive ban message but what about giving the user actual ban reason and time? It's not neccessary but we get closer to real SA if you add it. Would require for you to add a ban table on database to keep the reasons and create ban schedule/event.

Create event on database for cred ticket.

You can make it available per every login but that can be easily abused for no reason. Create an event on database instead to keep setting tickets to 1 for users every 24 hours.

Have a table for custom maps

Ok, the xgen api is still up.. but what if it's not? And what if you're using an account name that you don't actually have the password to on original SA? You're stuck.

Solutions
  1. Create new table on database for custom maps of users.
  2. Write custom api for saving and loading maps from your own database.
  3. Replace the api links in SA SWF client.

Why won't you finish the improvement?

I'm moving on. I realized that if I host this server for the european players, I'll just be stuck with stick arena and the community for years again. It'stime to move on.

Good luck =)

stick-arena-private-server's People

Contributors

michal2sab avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

andre-jar

stick-arena-private-server's Issues

help needed + questions

Hi! I'm not too sure how to go about this too well,

  1. should i use this repository on it's own or should i follow the steps by Kevin (https://github.com/6Kevin/StickEMU) and append files? the "dist" directory is missing.

  2. should i edit the index.php to say sab.swf or rename sab to game.swf

  3. should i paste just the contents of the \stickarena directory in htdocs or just the whole folder fine or doesn't matter?

ingame credtickethandler not working

As stated above I inserted your credtickethandler into my src\ballistickemu\Lobby\handlers and it doesn't work when I login and go to shop it doesnt do the whole random cred like it should

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.