Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[MiniTUT] New Acc

Skilled Illusionist
Joined
Nov 27, 2018
Messages
337
Reaction score
66
Hello Ragezone! This tut not Flash src and not complete SQL.

WarZ.sln

Search:
ProfileData.isDevAccount = xmlAccount.attribute("IsDeveloper").as_uint();

add below:
ProfileData.IsModerator = xmlAccount.attribute("IsModerator").as_int();

Search:
int PremiumAcc;

add below:
int IsModerator;

Search:
if(gUserProfile.ProfileData.PremiumAcc>0)
{
gfxMovie.SetVariable("_root.api.Main.SurvivorsAnim.Survivors.PremiumAcc.visible", true);
}
gfxMovie.Invoke("_root.api.Main.CreateSurv.EnableHardcore", "");

add below: if(gUserProfile.ProfileData.IsModerator==1)
{
gfxMovie.SetVariable("_root.api.Main.SurvivorsAnim.Survivors.MODER.visible", true); gfxMovie.SetVariable("_root.api.Main.SurvivorsAnim.Survivors.PremiumAcc.visible", false); gfxMovie.SetVariable("_root.api.Main.SurvivorsAnim.Survivors.ADMIN.visible", false);
}

Search:
if(gUserProfile.ProfileData.isDevAccount==0)
{
...
}

Replace All:
if(gUserProfile.ProfileData.isDevAccount==0 || gUserProfile.ProfileData.IsModerator==0)
{
if(gdata->info.gameTimeLimit > int(gUserProfile.ProfileData.TimePlayed/60/60))
{
Scaleform::GFx::Value var[3]; char tmpStr[512]; sprintf(tmpStr, gLangMngr.getString("CannotJoinGameTimeLimit"), gdata->info.gameTimeLimit); var[0].SetString(tmpStr); var[1].SetBoolean(true); var[2].SetString(""); gfxMovie.Invoke("_root.api.showInfoMsg", var, 3); return;
}
}

Search:
if(gUserProfile.ProfileData.AccountType==0)

add below:
if(gUserProfile.ProfileData.IsModerator==1) flags|=4;

Search:
bool isUserDev = (flags&2)?true:false;

add below:
bool isModerator = (flags&4)?true:false;

Search:
if(isUserDev)
{
userColor = "#d6ac04"; textColor = "#d6ac04"; namePrefix = "<GM>";
}

add below:
if(isModerator)
{
userColor = "#032aa0"; textColor = "#d0d0d0"; namePrefix = "<MOD>";
}

Search:
bool isAdmin = gUserProfile.ProfileData.isDevAccount > 0;

Add below:
bool IsModerator = gUserProfile.ProfileData.IsModerator > 0; if(IsModerator)
{
if(gUserProfile.ProfileData.IsModerator && !selectedSelf) cntxCmds[curCntxCmd++] = ContextCommand(HUDDisplay_ContextMenu_AdminKickPlayerID, "KICK 30MINUTES"); if(gUserProfile.ProfileData.IsModerator && !selectedSelf) cntxCmds[curCntxCmd++] = ContextCommand(HUDDisplay_ContextMenu_AdminBanPlayerID, "$HUD_PlayerAction_Ban");
}

ASP.NET:

Search:
xml.Append(xml_attr("AccountType", reader["AccountType"]));

add below:
xml.Append(xml_attr("IsModerator", reader["IsModerator"]));

WarZ_Server.sln

Search:
if(plr->profile_.ProfileData.isDevAccount & wiUserProfile::DAA_DEV_ICON)
n.flags |= 2;

Add below:
if(plr->profile_.ProfileData.IsModerator == 1)
n.flags |= 4;

Search:
if(peers_.player->profile_.ProfileData.isDevAccount & wiUserProfile::DAA_DEV_ICON)
n.flags |= 2;

Add below:
if(peers_.player->profile_.ProfileData.IsModerator == 1)
n.flags |= 4;




Search:
g_GameBlocks_Client->AddKeyValueInt("IsDeveloper", peer.temp_profile.ProfileData.isDevAccount);

Add below:
g_GameBlocks_Client->AddKeyValueInt("IsModerator", peer.temp_profile.ProfileData.IsModerator);

Search:
if(strncmp(cmd, "/kick", 5) == 0 && ((plr->profile_.ProfileData.isDevAccount & wiUserProfile::DAA_KICK)

Replace func:
if(strncmp(cmd, "/kick", 5) == 0 && ((plr->profile_.ProfileData.isDevAccount & wiUserProfile::DAA_KICK) || plr->profile_.CustomerID == creatorID_ || plr->profile_.ProfileData.IsModerator))
return Cmd_Kick(plr, cmd);

and Search:
if(strncmp(cmd, "/ban", 4) == 0 && ((plr->profile_.ProfileData.isDevAccount & wiUserProfile::DAA_BAN)

Replace Func:
if(strncmp(cmd, "/ban", 4) == 0 && ((plr->profile_.ProfileData.isDevAccount & wiUserProfile::DAA_BAN) || plr->profile_.ProfileData.IsModerator))
return Cmd_Ban(plr, cmd);

Search:
if(fromPlr->profile_.ProfileData.isDevAccount & wiUserProfile::DAA_DEV_ICON)
{
n_non_const->userFlag |= 2;
}

Add Below:
if(fromPlr->profile_.ProfileData.IsModerator == 1)
{
n_non_const->userFlag |= 4;
}
 
Last edited:
Experienced Elementalist
Joined
May 28, 2017
Messages
225
Reaction score
127
This is just client/server/api, to make a new account flag you will have to add a new parameter to the databse and then you have to get the new variable which you already declared in your database via the api and the api sends it as a xml format to the client/server!
 
Skilled Illusionist
Joined
Nov 27, 2018
Messages
337
Reaction score
66
This is just client/server/api, to make a new account flag you will have to add a new parameter to the databse and then you have to get the new variable which you already declared in your database via the api and the api sends it as a xml format to the client/server!

This tut not Flash src and not complete SQL.
 
Experienced Elementalist
Joined
May 28, 2017
Messages
225
Reaction score
127
Steal or not, tbh this poop is not even a tut worth, its simple programming stuff and people will never learn from copy pasta....

Its already more than 5 years ago when the first src got leaked and tbh this type of copy pasta from isdeveloper to a new variable is such a joke... this is more than nothing new to anyone!
 
Back
Top