Mind if ask what language you've built the system on?
Spoiler : FM Experience :
We are opposed to the line of compromise with imperialism. At the same time, we cannot tolerate the practice of only shouting against imperialism, but, in actual fact, being afraid to fight it. Kim Il Sung
[CENTER]S-FM: Bus Drivers, S-FM: Trust, S-FM: Double Killers, S-FM: Double Killers Too, S-FM: Heart of the Swarm [COLOR="#FF0000"]HOST[SIZE=1]
Apo has to agree that javascript is working nicely, barely even have to edit the previous functions.
Currently only able to call commands with the ers reference like ers.text(String) or ers.textTo(playerNum,String), but it's an 'ok' downside for now but will be looking for a way to make it possible to use the commands without an object reference.
With this scripting style, object oriented programming is possible, referencing directly(well..Apo will make it pesdo-directly) to Roles/Match/Player to access things, OR the current style of 'general' functions, OR a mix of both?
Opinions of the general populace is best to work out what is easiest and most functional to use. Like going with the OOP style would changes things like <TARGET1> to ers.self.getTarget1(). <TEXT_TO>5,I see you pee.</TEXT_TO> to ers.playerObj.text("I see you pee.") or ers.textTo(5, "I see you pee.") to keep ease of possibilities.
Apo is sorry for long delay, have been without a computer since ... The Friday before last??
JavaScript support is fully functional, so when he gets Internet at his new location he will update everything. Controlling the match through the scripts is object based.
To make things simpler, the basic objects are already labeled for quick access. For example: if a role is running the script, 'self' is referenced.
If a team is running the script 'team' would be used. And 'match' will always be available.
Example commands would be self.getRoleName(); team.getName(); match.getNumAlivePlayers; match.getAlivePlayers(); ect
Will go into more details later...
Have also enabled Teams to go along with team win conditions. Only those within the same affiliation may be in the same team or the match won't start(there will be default teams so this can normally be ignored altogether, but teams will be changed from within the role selection setup)
Still perfecting the Teams and working on the Flags needed to allow normal and special statuses such as Doused, Electrified/Charged, Poisoned, ect.
Finally have the interwebs back, YAY! Apo happy.
Updated the first two posts with the new features of Teams, onEvents, Javascript, ect.
So is this scripting style more preferable to the previous custom markup language? Have to say it's more to grasp for players new at it, but provides alot more functionality.
Working on Flags now, once running, will feel more comfortable to open access to the game.
Added onDeath event, holding off on misc Match commands for the moment but on my todo list, can prehaps be done through the ChatController commands that already exist(the anonymous feature is disabled atm)How great will our ability to implement roles be? For example, would implementing a lightkeeper type role (for a day after their death, all players are anonymous) be possible with the functions we'll have access to?
Edit: if you set all the players through the use of match.chatAddPlayer, you should have been already able to achieve your goal(once Apo re-enables the option)
Suggestion design worked out, inprocess1. Have hosts set the OoO when designing the setup
2. Have each role assigned to a list of pre-defined "types" which are in a specific OoO position each, some types would run all actions in their group at the same type while others (like roleblockers) would do several loops to clear out paradoxes.
The Action Type(ooo thats what I'll call it now) will be named when creating the role.
Then within the Match Settings, the host can order the Action Types(The Types will be providied based on what roles are enabled for the match)
It won't have a default order for new types, custom Action Types would be placed at the bottom of the list of an already made Default list of the normal roles
self.getVar("StringName") and self.setVar("StringName","Whee") were converted to the javascript version, may not work the same right now due to different way of handling data types, but it's a startApocist, is there any chance you'd add an option to name the variable produced by [FOREACH] to allow for nested loops? Right now I can't think of a situation where you'd need them but you never know!
Edit: Totally read that wrong... was trying to get everything fixed too fast...
Because it's java script now, it's named to whatever you choose
Ok, here is the flag system that was required to make special roles work(good thing I add onVisit)...
Let me know how this could be improved upon.
Example of the Electromaniac script:
onNightTargetChoice:
var target = self.getTarget1():
if(target != null){
self.text("You will charge "+target.getName()+" tonight.");}
else{
self.text("You will not charge anyone tonight.");}
onNightEnd:
var target = self.getTarget1();
if(target != null){
self.visit(target);}
target.addFlag("CHARGED");
target.getFlag("CHARGED").setScriptPre("onVisit","
if(visitor.hasFlag(\"CHARGED\")){");
match.attack(visitor, \"Electocuted\", \"been shocked to death\");}
match.attack(self, \"Electocuted\", \"been shocked to death\");
------------------------------------------
Here is what is going on:
Like normal, it detects the user is choosing a target at night during onNightTargetChoice.
When the night ends:
Visits the targetted player
Gives the target a flag/status by the name of CHARGED.
Gives a script to the flag to run during a certain time. (which is onVisit).
The end result being that onVisit runs whenever the player is visited by someone else.
Therefore; whoever visits a player with the charged flag, that visitor is checked for having the flag as well....if so...death for both.
Flags seem a bit more complex because we are running different objects(each with different functions) as well as in different onEvents
Apo's allowed Flags themselves to hold the same scripts as the Roles. A script on a flag merely appends its own script BEFORE or AFTER the script of the Role it is apart of. So lets say making a Flag post script for the event... 'onNightEnd' would make its Role holder perform that Flag script after it's done doing its own Role script
Many more commands updated/moved/deleted. Change behavior of core roles. onAttacked event added. Doctor, Escort, Mafiaso, and Godfather scripts updated.
Added Constant functionality of a player merely possessing a certain named flag, these include:
NIGHTIMMUNE
for the moment
Edit: Then quickly realized that only Doc scripts aren't posted.
I might try to help a bit once my final is finished.
When we talked about pubs, we are talking about us.
When they talked about pubs, they exclude themselves.
They say only bad players want to modify citizens, and they do not satisfy bad players.
Are we bad players? We include bad players, but that is just a part of us.
---They put veteran, mayor, allowed jester to visit for nothing, and they regretted and say those things are brainless.
Action Categories replaced the flawed Action Order by number system.
All Roles are to given a named category instead of a number. The actions can be order arranged by the host of the match, but starts with the standard default ordering in place.
Next order of business is going to be throwing the engine onto my dev laptop and let that act as the 24/7 server until expenses are settled. With that in place, access to the game will be made available with the much flawed client. In addition the client will be able to view the innards of every role in the next update.
Attempting 1:
Name: Survivor
Affiliation: every factions
Category: core neutral
Action Category: selfvest
onTeam: OFF
Team Name: (blank)
Teammates visible OFF
Share Night chat OFF
Share Win ON
Number of Day Targets: 1
Number of Night Targets: 0
Who you may target during Day: Everyone except self
(During the example of these scripts the object references 'match', 'self', and sometimes 'team' are already provided)
onNightTargetChoice:
var target = self.getTarget?();
if(target != null){
self.text("You will put on your bullet-proof vest");
}
When we talked about pubs, we are talking about us.
When they talked about pubs, they exclude themselves.
They say only bad players want to modify citizens, and they do not satisfy bad players.
Are we bad players? We include bad players, but that is just a part of us.
---They put veteran, mayor, allowed jester to visit for nothing, and they regretted and say those things are brainless.
I apologize for my ignorance here, but wouldn't it be better to code this in HTML5? That way you could design it so that people on tablets could also play and not just comps.
Oh that's reminds me, been busy with 60 hour work weeks Apo's been slack'n. I'll put the ability to upload/add your own role into the next release so you can test scripts.
As for HTML5, I personally don't know it's potentials. I have the a ability to put this on an iPhone add in the future, but development on a completely different platform(for a third time) is a bit much. But it should be possible to allow different clients to connect to the server, but Apo has no intention of creating one.
Released a very unrefined and unpolished version. Download this file, and put it into a folder and it will keep the program up to date.
You can script your own roles with the built-in editor and even test them out if you can get a match running. (For now you can access it by creating a match and viewing a role from the Possible Role list)
Apo still needs to still make a decent guide and reference sheet.
Quite sure there are plenty of bugs and ugliness, but any suggestions
error.JPG
also is it possible to make it 3 characters?
Hrm, for some reason it logged eMafia out of the sc2maf forum.
As for 3 characters, do you mean like 3 playable accounts? It is possible, each eMafia account is linked to a Sc2Maf forum account, so you would need 3 forum accounts. There will be safe guards in the future to inform everyone in that match if two or more accounts share the same IP to prevent cheating.
Also Apo noticed he forgot to add the New Role button so you can only edit existing roles. Will add that, add a menu in the main lobby for roles, and fix the forum login issue as soon as Apo gets home.
no, what i mean is my fourm account is 3 chracters long and it doenst allow 3 chracters
Almost forgot to. Client updated with Create New Role Option, location in the Lobby -> Menu -> Role
Might need to change how updates are handled, 3.5 mbs(atm) per update for the main program is a bit much if it happens alot. Apo's a seeing about the program loading the class files instead to make the updates smaller.
(edit: well found a quick fix to that, poorly structured directories don't help)
verifying.JPG
i tried to verify but got this again...
it worked on making my account and got the pm to verify but when i wnet o verify i got that
creating the account had no problems dealing with 3 character though
@#!#, Didn't remember setting a limit on the verify section too. fixed
Your account still exists, just on waiting verification still
Capturewut.JPG
was sitting in the game alone. you can do one player apparenylt withc is kinda funny
Can anyone tell me whats with this code? (Besides the use of \n\)
https://pastebin.com/ZjEKHJZw Godfather Startup Script
Shouldn't line 17 be.
- for(var player in team.getAliveTeammates()){\n\
Spoiler : FM Experience :
Yes, you are correct!
But that didn't solve the problem either. The For-in variant would not work due to it not keeping the object references. had to change it to
Edit: also changed the scripting to show the javascript syntax errors as well as line number nowCode:var teammates = team.getAliveTeammates();\n\ for (var i = 0; i < teammates.length; i++) {\n\
Thx for the help, with this it works... now off to make the Forum Signups, feel free help out by 'signing' up on the forum if you ever see the eMafia GM post
Bitches clappin and they aint usin hands
Say no to ratchet pussy