Mafia Engine Tool Development

This forum is for discussion related to the game.
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Mafia Engine Tool Development

Post Post #0 (isolation #0) » Sat Dec 19, 2020 9:19 pm

Post by JacksonVirgo »

Howdy Scummers,

I've been working on a tool that game moderators can use to remove any and all tedious aspects of hosting a game. This can include sending out day-start messages, creating role-cards, counting votes and much more.

Current we are in an early beta stage, but the tool is out there to be used regardless at mafiaengine.com. The uptime for the website at this current moment is unpredictable, once the website is in a more stable release I will make sure the servers are up almost 100% of the time.

Browser Extension

In addition to the website, I have been creating a browser extension to make the processes of using some of the tools within the website even easier, without even needing to leave mafiascum. In each thread you can see "Vote Count" and "Replace User" buttons which do exactly what they say, generate votecounts and creates a replacement post that sends you directly to the appropriate replacements thread.

Website Functionality

Currently the only two semi-reliable tools are the vote counter and the replacement form, all of which are super easy to use and can access them immediately from mafiaengine.com, assuming the servers are up. Currently I am working on the moderation panel, and all in one area for majority of the tools I am creating for moderators such as the beforementioned day-start messager.

Old Functionality

I will be recreating the old role-card formatting section of the tool later into the new UI, so don't be upset that it is not accessible at this very moment.


OP History

Spoiler: OP v1
Howdy Scummers,

I've been working on a tool for the past few days to aid in the process of hosting games, more specifically at this time making and distributing role-cards. The full-list of functionality can be found in the following spoiler and more additions are planned.
  • Role Card Formatting via a Lexer+Parser
  • Semi-Automatic Role PM Handler
  • CSV Role Card Formatting
  • Fully Customized Components for Singular Roles.
I'll give a quick overview of each of those.

Role Card Formatting

Using a custom lexer/parser, the tool inputs custom variables into the role-card template, this can be for both individual and mass production of roles for using the singular or the CSV sections.

Semi-Automatic Role PM Handler

You're able to send the produced role-cards through to PMs from a click of a button by utilizing the ucp.php file which PhpBB uses for private messaging (and other stuff). You can designate the content (usually the generated RCs), subject, and recipients of the message for yourself or leave them blank for a default response. I am planning on adding functionality to send each individual role-card separately if using the CSV format.

CSV Role Card Formatting

You're able to utilize the sheer simplicity of using CSV files to generate your roles. If the header of each column is the variables handle, you can make as many roles as your device allows you to. This will go through each role in the file and produce role-cards for each. Functionality for sending each RC separately in a PM is planned but not yet made.

Prototype Showcase V1



Conclusion

I'm doing this for the FM community in general, ease in my future setup designs, and also to put on my portfolio. In my opinion, the worse thing about setup design is making the role-cards by far and I'm trying to make that much faster and easier to do. This isn't for public use at the moment but as soon as the first prototype has been completed I will search for a few testers to make mock (or even real setups) using this tool so if you're interested in helping to test (or trying to break the tool) feel free to let me know here or via PM (or discord if you have mine). If you have any ideas or feedback on my ideas feel free to let me know. Brutal constructive criticism needed.
Last edited by JacksonVirgo on Wed Jun 30, 2021 10:29 am, edited 2 times in total.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #1 (isolation #1) » Sat Dec 19, 2020 9:20 pm

Post by JacksonVirgo »

Duckyboi has been helping me out with ideas and stuff :D
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #4 (isolation #2) » Sun Dec 20, 2020 3:40 am

Post by JacksonVirgo »

In post 3, skitter30 wrote:Oh wow this looks awesome! Happy to help test!
Thanks heaps :D



---


Also if anyone has any brilliant ideas for names please throw them at my eyes
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #5 (isolation #3) » Sun Dec 20, 2020 3:46 am

Post by JacksonVirgo »

In post 0, JacksonVirgo wrote:I am planning on adding functionality to send each individual role-card separately if using the CSV format.
I've finished adding this functionality, a post describing how it works now etc will be incoming. Testing phase 1 will being relatively soon I believe unless setbacks happen.

EDIT: A new addition I was just thinking of is adding is giving the ability to mass-create role-cards using the singular role section (by storing the file into a table so it's editable and convertible to a CSV format) so that you can send individual role-cards without needing to specifically use CSV files. Perhaps allowing to save/load files from CSV into the singular role card section and vice versa. If you like that idea lemme know.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #10 (isolation #4) » Sun Dec 20, 2020 7:39 pm

Post by JacksonVirgo »

In post 8, Gamma Emerald wrote:Can it do more than role PMs? It mostly seems useful for theme games, since newbies/opens/normals have standardized role PMs.
This was
originally
built to handle creating role cards easily but I moved to make it a universal FM helper so I have a few planned additions including an inbuilt game-rander to replace needing to use random.org and you can send the appropriate Role PM to the right player with a click of a button by utilising the Send PM feature I've already created.

If you want to use pre-made role-cards and use this functionality I will have to add that to the tool as I hadn't thought of that just yet but is a great idea.

Although what would you think it should also do?

Perhaps an addition could be an inbuilt screen-scraper for votes, unvotes, heals and hurt tags (utilising a closest-match function for spelling errors and shorthand names such as VOTE: Jackson) and generating a VC using the same lexer/parser functions although that's already a tool that exists I believe.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #11 (isolation #5) » Sun Dec 20, 2020 7:40 pm

Post by JacksonVirgo »

In post 9, Jake The Wolfie wrote:Suggestion:cAdd boilerplate "Cop", "Doctor", "Vig", "VT", and "Goon" abilities
Oh that's a good idea actually, thank you
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #14 (isolation #6) » Sun Dec 20, 2020 7:57 pm

Post by JacksonVirgo »

In post 13, Jake The Wolfie wrote:Suggestion: Create a targeting visualizer, to see who is targeting who with what ability.
Could you explain this further? I don't fully understand
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #17 (isolation #7) » Mon Dec 21, 2020 2:16 pm

Post by JacksonVirgo »

In post 15, Jake The Wolfie wrote:Like a flowchart or something.
I'm not exactly sure how I would implement that but I'll add it to my list for now.
In post 12, Gamma Emerald wrote:Yeah the screen-scraper vote counter seems like a good idea, what it should probably do is give a list of all things that look like votes, and the mod can just prune out things that aren’t, typically the most arduous part of vote counting is skimming the thread for votes. I personally haven’t modded a large without utilizing an auto-votecounter (kinda, I had one where I counted manually but my co-mod used the auto-VC iirc)
I like that it’ll catch heals+hurts, most auto-votecounters don’t do that I believe

Having a game-rander is also good, since random.org limits your uses unless you pay them money
I want all the tools to be modular and adaptable to all forms of Forum Mafia, so I would probably make a list to catch different types of "commands". For mafiascum it will likely catch VOTE: , HURT: ,HEAL: but I'd like the host to be able add custom commands or posts that it catches such as
POTATO:
or
/vote
etc.

Does random.org do that? I've never used it that much to know

EDIT #1: Maybe it will search for the words, not the tags themselves so
VOTE:
and VOTE: will both trigger the screen-scraper.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #20 (isolation #8) » Wed Dec 23, 2020 2:00 am

Post by JacksonVirgo »

The tool is hosted on a temporary heroku server which you can find here. Feel free to mess with it and try and break it etc and tell me what you've done with it. Feel free to spam my PMs with random roles.

I'm hosting it right now to work on an API for a hidden thing myself and ducky are working on so if the server is down for a bit it's probably because I am testing out functionality.
Last edited by JacksonVirgo on Sun Dec 27, 2020 11:12 am, edited 1 time in total.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #22 (isolation #9) » Wed Jan 06, 2021 9:29 pm

Post by JacksonVirgo »

Screen-Scraper

I've created an API to help with reworking the Replacement Form which a special someone, unsure if they want it public, was considering doing. I am planning on adapting the logic for this API for use in vote-counters in time. Right now the screen-scraper finds the following:
  • Author of the Thread
  • Title of the Thread
  • Current Page Index
  • Last Page in the Thread
Role Formatting

I've reworked the logic to be server-side to make the logic more modular as if anybody knows front-end javascript you know how absolutely tedious making large logic is as well as me being able to make a desktop version of this tool if it gets popular enough to do so. I've added "global" variables which you can reference within the spreadsheet to avoid copy+pasting a lot of data (and then changing every. single. one if you need to change a word or two). These global variables can also be referenced within the template itself if EVERY role uses is such as a game thread link and/or asking for confirmation etc. Example can be seen in Figure 1.

Spoiler: Figure 1
Image
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #23 (isolation #10) » Wed Jan 06, 2021 9:32 pm

Post by JacksonVirgo »

I was thinking maybe Mafia Engine, Mafia Mod or something that I definitely didn't get from a name generator.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #25 (isolation #11) » Sat Jan 09, 2021 12:14 am

Post by JacksonVirgo »

I'm going to showcase both the Global Variables which I've already announced and also Role Specific information which is a new addition, but a cool one!

You can now make specific information that only shows under specific conditions, such as if their alignment is Mafia etc (such as for Mafia PTs). This took a bit to actually fix all the bugs that appeared but it's fully workable now. I am planning to add a more in depth boolean functions such as "and/or" operators as well as "not" operator instead of just "equals" so every role BUT Mafia sees someone etc.

"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #26 (isolation #12) » Sat Jan 09, 2021 12:14 am

Post by JacksonVirgo »

In post 24, BBmolla wrote:Hey this kicks ass
Thank you ;)
I agree
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #27 (isolation #13) » Sat Jan 09, 2021 12:17 am

Post by JacksonVirgo »

I'm going to add a way for the user to change all the things the lexer uses to find handles etc. As well as possibly using cookies to store preferences, only if the user allows ofc to prevent paranoia for me stealing all yo passwords.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #29 (isolation #14) » Sat Jan 09, 2021 9:08 pm

Post by JacksonVirgo »

Game Randing and Name Referencing

One issue I had when designing a few mock setups was that you can't make role-cards referring to a players name similar to.
Spoiler:
Welcome JacksonVirgo, you are a...


I've created a way to rand a game, which randoms the order of the player list, searches for new handles which I'm coining {{Player}} which gets the current players name such as in the example above and {{Player_X}} gets another players name, where X is the index of the role you're wanting the players name for, 1 being the first line in the spreadsheet and 4 being the fourth etc. With this you can effectively create Mafia PTs that show players names without having to manually add them to the card before sending it, which is the goal of this project. Example of this in practice can be found in the video below and in the spoiler for the Role Card of one of the Mafia.

Spoiler:
Welcome Trash Can! You are a
Mafia Tracker


Each night you may check a player to see who they visited, if anyone.

You are aligned with the worst


"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #30 (isolation #15) » Sat Jan 09, 2021 9:09 pm

Post by JacksonVirgo »

In post 28, Psyche wrote:I really dig your interface. i'd be happy to make small scale contributions to your project on a weekly basis if it's designed in a way conducive to that
Thank you, for right now the code is a real mess so I've got to refactor a lot of it, may spend a day or two focusing just on that. I don't think I really need it at the moment as it's just a casual tool I'm working on but I might get back to you after I refactor.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #31 (isolation #16) » Sun Jan 10, 2021 5:24 pm

Post by JacksonVirgo »

You can now save the current template and all global variables to a file and then load it back up. Meaning you can save templates to file to re-use.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #32 (isolation #17) » Sun Jan 10, 2021 5:45 pm

Post by JacksonVirgo »

When trying to remake my old Mini Normal setup + rand to test. I ran into an issue where referencing a second player's name fails to work. I will be focusing on fixing that and if all goes well I'll get this version hosted to get it tested.

EDIT: The logic I was using to find them gets conflicted with previous {{Player_X}} tags, I'm going to rework the way I reference them. Right now I'm thinking making {{Player}}[4] like tags. Where that accesses player 4's name. {{Player}}[0] may get the current players name.


EDIT 2: I've found the problem so I am going to revert back to my old code and fix it, it was dumb.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #33 (isolation #18) » Sun Jan 10, 2021 7:45 pm

Post by JacksonVirgo »

An example of how it works in practice, I've created a google spreadsheet of all the information within the spreadsheet which you can find here

And using the following JSON file as the saved template/globals. It looks confusing but it's simply just storing the template string and an array of all of the global variables. Which is the winconditions, mafia PT link, game thread, confirmation message and describing the mafia factional kill.
Spoiler:

Code: Select all

{"template":"[area={{Player}}]\n[b][color={{rcolour}}][size=150]{{align}} {{rname}}[/size][/color][/b]\n\n{{abilities}}```align=Mafia:\n\nYour partners are {{aligned}}.\n\n{{fac_kill}}\n\nYou can find the Mafia PT [url={{pt_mafia}}]here[/url]```\n\nYou can find the game thread [url={{game_thread}}]here[/url]\n\n{{confirm}}\n[/area]","globals":[{"id":1,"handle":"wincon_mafia","content":"You win when at least one Mafia is alive and all threats to the Mafia are eliminated or when nothing can stop that from happening"},{"id":2,"handle":"wincon_town","content":"You win when all threats to the Town are eliminated and at least one member of the Town is alive."},{"id":3,"handle":"confirm","content":"Confirm your role via replying with your role name, alignment and any abilities you have."},{"id":4,"handle":"fac_kill","content":"If you are not performing another action, and if no other is doing so, you may perform the factional kill each night."},{"id":5,"handle":"game_thread","content":"https://forum.mafiascum.net/viewtopic.php?p=12263829#p12263829"},{"id":6,"handle":"pt_mafia","content":"https://forum.mafiascum.net/viewtopic.php?f=90&t=84752&p=12263952#p12263952"}]}


I randed the game using the same player-list and roles as my Mini Normal setup (which has finished don't sweat your butt cheeks)
Spoiler: Example Role-Cards
PlusJoyed
Town Macho Doctor-Enabler


When you die, any Doctors will lose that ability. You cannot be protected from kills.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
bob3141
Town Doctor


Each night, if your action succeeds, you will protect a player from one attack.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
MisaTange
Town Doctor


Each night, if your action succeeds, you will protect a player from one attack.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
beeboy
Town Even-Night Role Cop


Every even-night, if your action succeeds, you will learn their role. Mafia Goons, Town Vanillas and Serial Killers will appears as Vanilla.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
nopointinactingup
Town Odd-Night Gunsmith


Every odd-night, if your action succeeds, you will learn if they have a gun or not. You will get a positive result on all Mafia (except Traitors and Doctors), Cops, Vigilantes, Gunsmiths, Role Cops, Vanilla Cops, PT Cops, Vengefuls, Detectives, Neapolitans, Backups of roles with guns and JoATs that have any of these listed powers. You will get a negative result otherwise.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
Staarling
Town Vanilla


You have no abilities.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
Flubbernugget
Town Vanilla


You have no abilities.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
derp
Town Vanilla


You have no abilities.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
Keita
Town Vanilla


You have no abilities.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
Hiraki
Town Vanilla


You have no abilities.

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
Noraa
Mafia Enabler-Finder


Each night, if your action succeeds, you will learn if your target is an Enabler or not.

Your partners are Glitch and Trendall.

If you are not performing another action, and if no other is doing so, you may perform the factional kill each night.

You can find the Mafia PT here

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
Glitch
Mafia Goon


You have no abilities.

Your partners are Noraa and Trendall.

If you are not performing another action, and if no other is doing so, you may perform the factional kill each night.

You can find the Mafia PT here

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.
Trendall
Mafia Informed


You are informed that there are two Doctors.

Your partners are Glitch and Noraa.

If you are not performing another action, and if no other is doing so, you may perform the factional kill each night.

You can find the Mafia PT here

You can find the game thread here

Confirm your role via replying with your role name, alignment and any abilities you have.


I'm currently planning on making a way to reference the attributes of the roles such as the role name for confirmation etc. Also I've found sending the ENTIRE setup through PM is too large to send through a link. Just click the copy button and paste it into the PM.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #34 (isolation #19) » Sun Jan 10, 2021 7:56 pm

Post by JacksonVirgo »

Current version is now hosted if anyone can test it in a mock-setup please do so and help me out. Send me a message on Discord or via PM here if you do so and/or need help. Any issues, no matter how big or small, let me know it so I can change it as the only tester I've had so far is myself and a few others in the very early stages.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #35 (isolation #20) » Mon Jan 18, 2021 2:38 am

Post by JacksonVirgo »

I've created a mock main menu. Two of the three sections are functional the other two does nothing. Thoughts? I've also semi-made a decision on the name change.

Image
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #37 (isolation #21) » Mon Jan 18, 2021 2:45 am

Post by JacksonVirgo »

In post 36, Jake The Wolfie wrote:Idea:

I CAT

I Created A Tool
Purrfection
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #39 (isolation #22) » Wed Jan 20, 2021 5:43 pm

Post by JacksonVirgo »

Screen-scraping is fully functional for the replacement form as I've replaced the original logic and dependencies which broke heavily. You can see the showcase in the video below. All that's needed is the link to the game and the player that's getting replaced. That's it. The screen-scraper will find the Moderator name, which is the user who created the thread, it grabs the thread title (which should include the game type/number/name/phase anyway) and also the page count.

I am going to eventually add ways to manually add information that they don't want the screen scraper to grab. This includes the moderator, as if the game has been taken over by another moderator you don't want the old hosts name on it (and I want to avoid users having to still manually change the result as much as possible).

Now that the screen-scraping for that is functional, I am now slowly moving towards vote count territory. I know plenty already exist but I want this to be a main hub for a lot of different forum mafia related tools.

"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #41 (isolation #23) » Wed Jan 20, 2021 10:46 pm

Post by JacksonVirgo »

In post 40, Psyche wrote:so are you aiming for extensibility? i'd love for there to be an easy way to plug tools i've been developing into your UI
The general goal for this project is to have any tools regarding FM all in one place and easily accessible to avoid needing twenty billion links for all sorts of tools.

That being said, that does include aiming for extensibility and thus if I could think of an effective way to do so that would be great, although I am not sure exactly on how I could do so, at least for right now.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #42 (isolation #24) » Mon Jan 25, 2021 4:45 am

Post by JacksonVirgo »

I'm currently in the process of moving from using Web Sockets into using a REST API as much as I can, the role formatting currently isn't functioning due to the changes but I'm planning to have that working again by the end of the weel.

You can effectively use my API to make your own tools if you wish and/or make it possible for me to make a desktop version of my site without redoing all the logic that I've made up to this point if that's something people are wanting once it's all completed.

How to use the API

The tool is currently being hosted by Heroku, meaning you can access the API via http://mafia-engine.herokuapp.com/api. This link doesn't go anywhere but it's the root access to all the http request URLs you will need.

http://mafia-engine.herokuapp.com/api/replacements which you can be seen utilised here by encoding the games URL into a value that can be safely passed through the URL and then decoded on the other side (using encodeURIComponent and decodeURIComponent respectively).

A Vote Counting version of it has been made as well, utilising a similar VC Settings as MathBlades Vote Counter to make things cross-compatible. I'm planning on making this compatible with other Vote Counting settings as well as not needing one at all if you want to simply check the last vote of all users that posted on the thread (if they voted at all).
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #43 (isolation #25) » Tue Apr 20, 2021 4:30 am

Post by JacksonVirgo »

If you thought I abandoned this project... you thought wrong!
I have added a lot more features and am very close to releasing this to the public!

If you have been excited for this project so far... I have a new addition I think will have you explode with even more!

If you want to be notified via PM once a public release for this project airs feel free to reply with a
/notify
or PM me directly.

Be patient...
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #46 (isolation #26) » Tue May 04, 2021 4:44 am

Post by JacksonVirgo »

It has come to my attention that someone has spoken about myself and this tool in a pub near where I am staying at the moment. Small world
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #48 (isolation #27) » Mon May 10, 2021 4:23 pm

Post by JacksonVirgo »

Chrome Browser Extension

I am now announcing that I have been working on a Chrome Browser Extension to make votecounting and replacement forms as seamless as possible. Why is it seamless? It creates buttons directly onto the MafiaScum web page and thus you have no need to ever leave the website to do what you need to do.

Currently it has two buttons.
- Vote Counter
- Replace User


Vote Counter

Assuming you have the correct settings in the OP of the game, this button will make a votecount for your game and place the formatted VC in the edit box.

Replace User

This button is below a users "details" and by pressing it you will be pushed towards the Replacement Thread where the replacement post will be placed in that edit box making the whole process seamless.


---

Why am I posting this now? Well I need some testers!
If anybody has a Chrome desktop browser or any Chromium based browsers such as Brave please hit me up so we can test this and make this project the best it can be!
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #49 (isolation #28) » Fri May 14, 2021 1:29 am

Post by JacksonVirgo »

I will use this post to explain how the vote count settings work.

Firstly, you have to have format things correctly to have the tool correctly grab the settings in the first place. In the following spoiler I will explain how to do exactly that.

Spoiler: Formatting
  1. Create a spoiler tag, in the first post, have the name be exactly

    Code: Select all

    VoteCount Settings

  2. For each setting, create an italics tag

    Code: Select all

    [i][/i]
    in which to put the one setting and it's information within. This is so the tool can easily recognize each setting.
  3. Profit


Now for the settings themselves. I will also update this post as I add more

First Column -> The recommended setting name.
Second Column -> All possible setting names, all works the same.
Third Column -> Description on what the setting does.

If you find any confusing, let me know so I can have it reworded.

SettingAlternate Handles (N/A means it has none)Description
playersplayerListList each player separated by commas (,). You can shorthand replacements as well by splitting replacements by a colon (:) with the most recent slot being on the left.
slotsslotList, replacementList, replacementsList each slot separated by commas (,). Split replacements by a colon (:) where the most recent slot being on the left. It is recommended you use the shorthand part of the players setting, this is only here for cross-compatibility with MathBlades VoteScrubber.
aliasnicknames, nicknameList, aliasListIf a player goes by a name that isn't what the votecounter recognizes (e.g. JV for myself) then list the nicknames like this (JacksonVirgo: JV) and seperate each individual nickname by a comma, even if it is for the same user. e.g. (JacksonVirgo: JV, JacksonVirgo: Jackson)
moderatorsmoderatorList, moderatorNamesList each moderator or anyone that is not a player that needs to access the votecounter here (such as possible overseers, backups, co-mods etc), seperated by a comma (,)
deaddeadList, eliminatedList each player that has been eliminated/died here seperated by a comma (,)
deadlinetimerPlace here the EXACT time that you would put in the countdown tags for the End of Day. If this is shown, it will add a "Day ends in X" section at the bottom of the votecount.
edashedashweightEnter a number of which what amount of votes before hammer you would like to show the [E-X] suffix to each wagon. Default is 2 and that means that only those at E-2, E-1 and eliminated will be shown.
edashOnTopN/AEnter a number (I will refer as X), the top X players will have their edash suffix attached. Default is 1 (meaning just the top wagon/s)
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #51 (isolation #29) » Fri May 14, 2021 6:42 pm

Post by JacksonVirgo »

In post 50, fferyllt wrote:Would it be possible to include text in the form "With X alive, it takes Y to eliminate" in the vote count? Not a huge problem if it's not feasible/easy. My vote count format is idiosyncratic, and I'll need to add a fair bit of additional text anyway.
Yeah I can add that easily :D
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #55 (isolation #30) » Tue May 18, 2021 5:31 pm

Post by JacksonVirgo »

In post 53, Psyche wrote:firefox can't install chrome extensions?
You can make it cross-browser, as it is currently at its core, but at the moment the websocket connection isn't working on Firefox browsers for some reason.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #56 (isolation #31) » Tue May 18, 2021 6:06 pm

Post by JacksonVirgo »

In post 52, lendunistus wrote:
In post 48, JacksonVirgo wrote:
Chrome Browser Extension

I am now announcing that I have been working on a
Chrome
Browser Extension
why spyware :(

jokes aside, this is a really cool project and i have to give you a huge thanks for dedicating your time to this. if you’re thinking of making it open source, maybe I could get off my ass and learn programming so I can port it to firefox

(yes I know that other chromium-based browsers exist, I just like firefox)
It already is open-source to be fair
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #58 (isolation #32) » Thu May 20, 2021 11:05 pm

Post by JacksonVirgo »

I have now added that each votecount will show how many votes is hammer.

I have also removed the Replacement buttons from newbie games since the replacement process is different in a way that cannot be automated easily (the SE/Newbie differentiation). I may possibly add a prompt to ask if they are an SE or not so it's not fully automated but it is as much as possible.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #59 (isolation #33) » Fri May 21, 2021 11:43 pm

Post by JacksonVirgo »

The tool used to fail if you clicked on a post number instead of the normal thread URL, this has been solved for the Browser extension only, the website still has this issue.

--

Side note, when this is all done I will be porting the role-card formatter from my old frontend to the new one so look forward to that as well.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #62 (isolation #34) » Tue May 25, 2021 8:23 pm

Post by JacksonVirgo »

In post 60, Cook wrote:anything at all that could steal pagetops so that i can edit votecounts in?
I would need to make an automated bot to do that, if you want it to be in your name it would need you to put your username+password in (which is bad and I am not going to do) or a new account for my bot to take it and you either edit it with your mod perms or it does VCs automatically.

I am not entirely sure what specifically is allowed or not on this site, so if it comes to it I'll let you all know
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #64 (isolation #35) » Tue May 25, 2021 8:47 pm

Post by JacksonVirgo »

In post 63, Ythan wrote:
In post 62, JacksonVirgo wrote:or a new account for my bot to take it and you either edit it with your mod perms or it does VCs automatically
This seems like it would be fine. It's not very different than if you were comodding.
I already have the account Trash Can for the role card formatting (which is coming back I swear), I'll make a new one called something else if needed
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #66 (isolation #36) » Sat Jun 26, 2021 2:27 am

Post by JacksonVirgo »

The server will be down for about 5 days, nothing I can do about it so apologies for anyone actively using it or testing it.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #67 (isolation #37) » Sun Mar 27, 2022 12:22 pm

Post by JacksonVirgo »

Good morning/afternoon,

I have had a decent amount of time off of this project, or at least the forum aspect of it, and I've recently returned to it. I have added a few features I think would entice the developers amongst us and that is a public API to convert a thread to JSON data. This isn't live but it will be once I've polished it enough to be used in production.

I'm going to be live-streaming the development every Monday 8am AEST for a few hours as I have today, I don't particularly want to keep posting here on every post I do unless it has updates alongside it so I'll probably post update posts right before I start streaming again so I have a reason to bump without flooding with useless information.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #68 (isolation #38) » Sun Apr 03, 2022 12:26 pm

Post by JacksonVirgo »

Greetings,

Last week I sorted out how the website client fetches the data from my new API. Today I'll be formatting that in a way that is more like how I used to, a proper vote count.

You can catch the stream, just check in the following spoiler. No need to pop it at all :)

Spoiler:
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #70 (isolation #39) » Fri Apr 08, 2022 12:59 pm

Post by JacksonVirgo »

This week will work slightly differently, I am busy on the Monday morning where I would usually stream. So it'd be pushed back a few hours, 1pm AEST is when I'd be streaming.
In post 69, the worst wrote:I know I'm constantly in your DMs but this is so, so exciting. Thank you :)
:D
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #71 (isolation #40) » Sun Apr 10, 2022 2:01 pm

Post by JacksonVirgo »

I'm starting my stream now, feel free to pop by if you so wish.

Today I'll be working on authentication, and making sure that a user is an actual MafiaScum user. I am also using face-cam owo, just ignore messy hair :p

Spoiler: Stream Link on YT


After-Stream Notes

I've fully worked out the logic to check through MafiaScum's discord to see if they are verified through that, as MS staff has to verify those users. A way to log in without using Discord is planned but will not be prioritised at this moment.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #74 (isolation #41) » Sun Apr 10, 2022 8:44 pm

Post by JacksonVirgo »

In post 73, Kcdaspot wrote:i cant access the site.
It's down at the moment, has been while I've been doing quite intensive changes. Apologies
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #75 (isolation #42) » Sat Apr 16, 2022 8:34 am

Post by JacksonVirgo »

Livestream for this week will be done at around 7am instead of the regular 9am AEST. This is due to planning a day out with my friends and family
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #76 (isolation #43) » Sat May 14, 2022 1:30 pm

Post by JacksonVirgo »

I haven't livestreamed for a month, this is due to my shifts at work being all messed up. I am now getting back to a steady schedule, but instead of Monday mornings it will be Tuesday mornings around 9am AEST that I will be livestreaming.

However, this does not mean I haven't been working on this tool in the meantime. I have changed the overall infastructure as I believe it to be much better for the enduser. I'm hosting the frontend and backend seperately, this is due to the fact that I want the frontend to notify the end user if a server is down where otherwise that wouldn't happen (as the frontend is fetched through the server). This also means that I won't have to pay as much to keep the backend alive 24/7 as I would have to otherwise.

New Functionality

Due to the fact that I am changing codebase, and that I didn't have the full functionality up and running anyway I am going to start small and make sure that it's as fleshed out as possible before adding extra functionality.

Going forward, you will be required to log in through Discord as well as be in the MafiaScum discord server. This is how I am going to verify that you are an actual user to avoid people abusing the API. I will also be rate-limitting to avoid extenuious stress on my servers, and spammed automation through my automated bot.

The following list is the order of functionality that will be added. If you wish to be notified of any of these individually once completed, feel free to reply here or send me a DM.
  1. You can register a game. This will allow you to enter all needed data such as players for my tool to use instead of the usual way of putting it in the first post of a thread.
  2. After registering a game, you can request a replacement through my site and it'll automatically post the request in the replacements thread (I have gotten permission to do this), it will contain a link to a direct DM with all hosts and the appropriate subject/message so they'll just need to hit send.
  3. With a registered game, you can request a vote count through my site and this will count up the votes with the data my tool already has. This can either give you the formatted post to copy+paste into the thread, or I can post it automatically through my Mafia Engine account.
I do apologies for how long I have been working on this without a production version ready. I will be working hard to make sure that one thing works before I continue to the next, I keep falling into shiny object syndrome.

Thanks for your continued support :)
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
Post Reply

Return to “Mafia Discussion”