I am trying to make some logic for my OC script. I'm hoping this with improve my thought process by writing it out. And if someone comes along to help me even better.
I currently have a data base in Google sheets for current member CPR and OC role influence.
Current Pseudo Code
1. Code within github
2. Uses render to have discord bot
3. Uses uptimerobot to keep render online
4. Discord bot has several commands
4.1 OC command
4.1.1 bot checks faction available api call for open positions and crimes finishing soon ~4 hrs
4.1.2 bot checks members not in OC
4.1.2.1 check members >1 day activity and filter them from sorting Logic
4.1.3 with list of open positions and available members start sorting Logic
4.1.4 create discord message with link to crime ID for members.
4.1.4.1 include role name and item requirements.
4.1.4.2 sends message as direct message as well?
4.1.5 sends message if crimes are needed within 3 hrs and which levels based on CPR.
OC sorting Logic
1. have a list of OC's
1.1 have position influence rate
1.2 have needed CPR for good success rate
2. Have list of members
2.1 list of crimes/roles with member CPR.
3. Need to direct who goes where.
3.1 how many crimes to number of people?
3.1.1 Sizes vary between 3-6.
3.1.2 Maybe only allow staging 1 crime for every 6 people?
3.2 order depending based on level since higher level crimes matter more.
3.3 members with highest CPR in the highest influence role go first.
3.3.1 if 2+ crime staging need to make sure second+ person is in the next crime and not wasted on second highest influence role of first crime.
3.4 some crimes allow lower CPR members (lvl 7 & lvl 4's)
3.4.1 maybe randomize between the people available? Or cycle somehow?