Jump to content

Search the Community

Showing results for tags 'sql'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • News & Rules
    • News/Announcements
    • Forum Rules
  • General
    • General Chat
    • Introduce Yourself
    • Forum Suggestion/Bug Reporting
  • World of Warcraft Emulation
    • Emulation Releases
    • Support
    • Tutorials
    • Model Editing
    • Emulation Chat
    • Requests
  • World of Warcraft Private Servers
    • Advertise Your Server
    • Recruitment
  • World of Warcraft Emulation Marketplace
    • For Sale
    • Wanted
    • Hosting
  • World of Warcraft General
    • Retail Discussions
    • Class Discussions
    • PVP
    • PVE

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests

Found 5 results

  1. Vitalis - a custom 80 private WotLK 3.3.5a server https://vitalis-wow.com WE ARE HIRING! SQL Developer C++ Developer Web Developer If you are able to fill any these roles, please join our Discord to discuss your potential position. Other positions can be discussed further. These positions are NOT PAID! Please connect to our Discord to learn more about the project and ask us questions. A little bit about our server and our idea... Vitalis is a 3.3.5 Custom Level 80 realm which enables our players to begin exploring fast paced custom content Travel through custom tiers, world bosses, raids, dungeons and custom events while feeling the benefits of WotLK and more! Start with 36 slot bags and 5000g 2500 Custom Items Respeccing is free Instant 80 Cosmetic items drop from bosses/elites/rares Transmog and custom transmog items Custom dungeons/raids All classes available for each race Custom World Bosses Custom Item Sets Custom Leveling Items Custom Currency Custom Season 9 Items Mall area to teleport to Donation NPCs Cross-faction grouping/guilds world PVP enabled AND MUCH, MUCH MORE! Please connect to our Discord to learn more about the project and ask us questions.
  2. Hi there I am here to share one part of PHP SCRIPT made by ME and the biggest part made by Tim Levinsson Biggest part of credit - Tim Levinsson Smaller part - Cyberpro98 This script is working on the latest OregonCore revision. You just need to go to your XAMPP folder and open up htdocs folder and drop inside of it : index.php ; npcinsert.php ; images (u can add whichever image but u must to edit the php file ) So, open up your Program NOTEPAD or Notepad++ and just place this code inside of it <?php $host = "127.0.0.1"; $dbuser = "yourdbuser"; //mine is root $dbpass = "yourdbpassword"; //mine password is roooooooot $dbname = "yourdatabaseworldname"; //mine database name is world $conn = mysqli_connect($host, $dbuser, $dbpass, $dbname); $inputs = array( "entry", "modelid1", "name", "subname", "IconName", "gossip_menu_id", "minlevel", "maxlevel", "minhealth", "maxhealth", "minmana", "maxmana", "armor", "faction", "npcflag", "scale", "rank", "mindmg", "maxdmg", "rangeattacktime", "unit_class", "minrangedmg", "maxrangedmg", "lootid", "mingold", "maxgold", "ManaModifier", "HealthModifier", "mechanic_immune_mask"); //added if(empty($_POST['baseattacktime'])) { $baseattacktime = 2000; }else{ $baseattacktime = $_POST ['baseattacktime']; } //added if(empty($_POST['attackpower'])) { $attackpower = 100; }else{ $attackpower = $_POST ['attackpower']; } //added if(empty($_POST['rangedattackpower'])) { $rangedattackpower = 100; }else{ $rangedattackpower = $_POST ['rangedattackpower']; } //added if(empty($_POST['speed_walk'])) { $speed_walk = 1; }else{ $speed_walk = $_POST ['speed_walk']; } //added if(empty($_POST['speed_run'])) { $speed_run = 1.14286; }else{ $speed_run = $_POST ['speed_run']; } foreach($inputs as $input) { ${$input} = (!empty($_POST[$input])) ? $_POST[$input] : ""; } $stmt = $conn->prepare("INSERT INTO `creature_template` ( entry, `modelid1`, name, subname, IconName, gossip_menu_id, minlevel, maxlevel, minhealth, maxhealth, minmana, maxmana, armor, faction, npcflag, speed_walk, speed_run, scale, rank, mindmg, maxdmg, attackpower, baseattacktime, rangeattacktime, unit_class, minrangedmg, maxrangedmg, rangedattackpower, lootid, mingold, maxgold, ManaModifier, HealthModifier, mechanic_immune_mask) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)"); $stmt->bind_param("iisssiiiiiiiiiiiiiiiiiiiiiiiiiiiii", $entry, $modelid1, $name, $subname, $IconName, $gossip_menu_id, $minlevel, $maxlevel, $minhealth, $maxhealth, $minmana, $maxmana, $armor, $faction, $npcflag, $speed_walk, $speed_run, $scale, $rank, $mindmg, $maxdmg, $attackpower, $baseattacktime, $rangeattacktime, $unit_class, $minrangedmg, $maxrangedmg, $rangedattackpower, $lootid, $mingold, $maxgold, $ManaModifier, $HealthModifier, $mechanic_immune_mask); if($stmt->execute()) { echo "Success"; header('location: index.php'); }else{ echo "Failed" . $stmt->error; } $stmt->close(); ?> close it and save it with name : npcinsert.php And now that file put it into folder nammed htdocs ( its located in C:\xampp\htdocs ) Open again NOTEPAD++ or Notepad and put this code inside <!DOCTYPE html> <html> <head> <title>SQL Generator</title> <style> * { margin:0; padding:0; } body { background-image:url(images/background-3.jpg); } #wrapper { width:868px; margin:100px auto; } [type=text] { width:200px; height:25px; padding:0 5px; } select { width:214px; height:29px; } [type=submit] { width:100px; height:30px; } </style> <meta charset="UTF-8"> </head> <body> <div id="wrapper"> <form action="npcinsert.php" method="POST"> <input type="text" name="entry" placeholder="Creature Entry"> <input type="text" name="modelid1" placeholder="model id 1"> <input type="text" name="name" placeholder="Creature Name"> <input type="text" name="subname" placeholder="Subname"> <select name="IconName"> <option value="" selected hidden disabled>Icon Name</option> <option value="">None</option> <option value="Directions">Directions</option> <option value="Gunner">Gunner</option> <option value="vehichleCursor">vehichleCursor</option> <option value="Driver">Driver</option> <option value="Attack">Attack</option> <option value="Buy">Buy</option> <option value="Speak">Speak</option> <option value="Pickup">Pickup</option> <option value="Interact">Interact</option> <option value="Trainer">Trainer</option> <option value="Taxi">Taxi</option> <option value="Repair">Repair</option> <option value="LootAll">LootAll</option> <option value="Quest">Quest</option> </select> <input type="text" name="gossip_menu_id" placeholder="gossip_menu_id"> <input type="text" name="minlevel" placeholder="min level"> <input type="text" name="maxlevel" placeholder="max level"> <input type="text" name="minhealth" placeholder="minhealth"> <input type="text" name="maxhealth" placeholder="maxhealth"> <input type="text" name="minmana" placeholder="minmana"> <input type="text" name="maxmana" placeholder="maxmana"> <input type="text" name="armor" placeholder="armor"> <input type="text" name="faction" placeholder="faction"> <select name="npcflag"> <option value="" selected hidden disabled>NPC Flag</option> <option value="">None</option> <option value="1">Gossip</option> <option value="2">Quest Giver</option> <option value="16">Trainer</option> <option value="32">Class Trainer</option> <option value="64">Profession Trainer</option> <option value="128">Vendor</option> <option value="256">Vendor Ammo</option> <option value="512">Vendor Food</option> <option value="1024">Vendor Poison</option> <option value="2048">Vendor Reagent</option> <option value="4096">Repairer</option> <option value="8192">Flight Master</option> <option value="16384">Spirit Healer</option> <option value="32768">Spirit Guide</option> <option value="65536">Innkeeper</option> <option value="131072">Banker</option> <option value="262144">Petitioner</option> <option value="524288">Tabard Designer</option> <option value="1048576">Battlemaster</option> <option value="2097152">Auctioneer</option> <option value="4194304">Stable Master</option> <option value="8388608">Guild Banker</option> <option value="16777216">Spellclick</option> <option value="67108864">Mailbox</option> </select> <input type="text" name="scale" placeholder="scale"> <select name="rank"> <option value="" hidden selected disabled>Rank</option> <option value="">None</option> <option value="">Normal</option> <option value="">Elite</option> <option value="">Rare Elite</option> <option value="">Boss</option> <option value="">Rare</option> </select> <input type="text" name="mindmg" placeholder="mindmg"> <input type="text" name="maxdmg" placeholder="maxdmg"> <input type="text" name="attackpower" placeholder="attackpower"> <input type="text" name="baseattacktime" placeholder="baseattacktime"> <input type="text" name="rangeattacktime" placeholder="rangeattacktime"> <select name="unit_class"> <option value="" hidden selected disabled>Unit Class</option> <option value="">None</option> <option value="1">Warrior</option> <option value="2">Paladin</option> <option value="4">Rogue</option> <option value="8">Mage</option> </select> <input type="text" name="minrangedmg" placeholder="maxrangedmg"> <input type="text" name="maxrangedmg" placeholder="maxrangedmg"> <input type="text" name="rangedattackpower" placeholder="rangedattackpower"> <input type="text" name="lootid" placeholder="lootid"> <input type="text" name="mingold" placeholder="mingold"> <input type="text" name="maxgold" placeholder="maxgold"> <input type="text" name="ManaModifier" placeholder="ManaModifier"> <input type="text" name="HealthModifier" placeholder="HealthModifier"> <input type="text" name="mechanic_immune_mask" placeholder="mechanic_immune_mask"> <select name="mechanic_immune_mask"> <option value="" selected hidden disabled>Mechanic Immune Mask</option> <option value="">None</option> <option value="1">MECHANIC_CHARM</option> <option value="2">MECHANIC_DISORIENTED</option> <option value="4">MECHANIC_DISARM</option> <option value="8">MECHANIC_DISTRACT</option> <option value="16">MECHANIC_FEAR</option> <option value="32">MECHANIC_GRIP</option> <option value="64">MECHANIC_ROOT</option> <option value="128">MECHANIC_PACIFY</option> <option value="256">MECHANIC_SILENCE</option> <option value="512">MECHANIC_SLEEP</option> <option value="1024">MECHANIC_SNARE</option> <option value="2048">MECHANIC_STUN</option> <option value="4096">MECHANIC_FREEZE</option> <option value="8192">MECHANIC_KNOCKOUT</option> <option value="16384">MECHANIC_BLEED</option> <option value="32768">MECHANIC_BANDAGE</option> <option value="65536">MECHANIC_POLYMORPH</option> <option value="131072">MECHANIC_BANISH</option> <option value="262144">MECHANIC_SHIELD</option> <option value="524288">MECHANIC_SHACKLE</option> <option value="1048576">MECHANIC_MOUNT</option> <option value="2097152">MECHANIC_INFECTED</option> <option value="4194304">MECHANIC_TURN</option> <option value="8388608">MECHANIC_HORROR</option> <option value="16777216">MECHANIC_INVULNERABILITY</option> <option value="33554432">MECHANIC_INTERRUPT</option> <option value="67108864">MECHANIC_DAZE</option> <option value="134217728">MECHANIC_DISCOVERY</option> <option value="268435456">MECHANIC_IMMUNE_SHIELD</option> <option value="536870912">MECHANIC_SAPPED</option> <option value="1073741824">MECHANIC_ENRAGED</option> </select><br> <center><input type="submit" value="Insert"></center> </form> </div> </body> </html> Close it and save it with name index.php and this file add TOO to htdocs folder. And the latest part IN htdocs folder create 1 new folder nammed images and inside of it put any image named " background-3.jpg " And that's IT !
  3. mysql_close();
  4. Madness

    How to RBAC!

    This tutorial was created by QQRofl. Hello guys! It comes to my attention that people are having difficulties trying to communicate with this RBAC system that shouldn't have been implemented because it generates more support! Anyway, let's begin, shall we? Contents: 1. Understanding the commands and tables -1.1. List of the Permissions / Roles / Groups (Default) ~ SQL Structure of all the RBAC tables (DEFAULT) -1.2. Knowing your configuration 2 Giving GM Permissions 2.1 Giving Full Administrator permissions ~ List of the Permissions / Roles / Groups (Default) ~ SQL Structure of all the RBAC tables (DEFAULT) ~ Here is the default SQL structure of the RBAC tables (EXECUTE in your auth DATABASE): http://paste2.org/p/3047713 Here is the default Permissions / Roles / Groups ID/NAME: http://paste2.org/p/3047694 TrinityCore's RBAC (wiki) documentation: http://collab.kpsn.org/display/tc/RB...Access+Control ~ Knowing your configuration ~ Inside of your worldserver.conf, you will have a configuration setting, like so: ## RBAC.DefaultGroups# Description: Comma separated list of groups to be added to any account# Check auth.rbac_groups for correct ids# Default: "" (No group)RBAC.DefaultGroups = "1" As it says, once someone I believe registers, logins.. whatever, will be granted with the specified DefaultGroups. The DefaultGroups value can be: 1 = Player2 = Moderator3 = GameMaster4 = Administrator Or, you can separate the values as it says by commas: 1,2,3,4 1,2 1,2,3 Right now, mine is at 1. Players will only get player permissions. ~ Understanding the commands and tables ~ This is rather simple, so let's start off with the tables before heading into the commands right away. You should have the following tables: rbac_account_groups -- Holds data of accounts that have groups rbac_account_permissions -- Holds data of accounts that have permissions rbac_account_roles -- Holds data of accounts that has roles set rbac_group_roles -- Holds data of group roles rbac_groups -- Holds data of staff groups (Player, GM, etc) rbac_permissions -- Holds data of permission Id/Names rbac_role_permissions Holds data of role permissions rbac_roles -- Holds data of roles Id/Name rbac_security_level_groups -- Holds data of group security levels (secId) Now, the main tables that you will be inserting data into are: rbac_account_groups rbac_account_permissions rbac_account_roles The other tables are basically holding the data that make RBAC what it is. You have commands to look at what permissions/roles/groups you have. You can look at what roles/permissions/groups accounts have by typing: Roles: .rbac account role ACCOUNTNAME Example of (ROLES): .rbac account role Easelm This will show what roles account 'Easelm' has from the `rbac_roles` table. Permissions: .rbac account permission ACCOUNTNAME Example of (PERMISSIONS): .rbac account permission Easelm This will show what permissions account 'Easelm' from the `rbac_permissions` table. Groups: .rbac account group ACCOUNTNAME Example of (GROUPS): .rbac account group Easelm This will show what permissions account 'Easelm' from the `rbac_account_groups` table. (NOTE): You can select a player ingame and type in these commands to view their groups/permissions/roles without specifying their account name. .: KNOWING YOUR GROUPS :. If your `rbac_groups` hasn't been altered, groups should be as followed: 1 = Player2 = Moderator3 = GameMaster4 = Administrator .: KNOWING YOUR COMMANDS :. You have 15 commands all together, but don't worry, I'll only explain the ones you'll potentially use. The main commands you'll most likely use are: ALSO NOTE: You can set the REALMID to -1 for all realms .rbac account group add ACCOUNTNAME GROUPID REALMID Example of command '.rbac account group add': .rbac account group add Easelm 4 -1 The above will grant account 'Easelm' (or the selected player) group 4 which is administrator to all realms (-1). ---- .rbac account group remove ACCOUNTNAME GROUPID Example of command '.rbac account group remove': .rbac account group remove Easelm 4 The above will remove account 'Easelm' from group 4. ---- .rbac account role grant ACCOUNTNAME ROLEID REALMID Example of command '.rbac account role grant': .rbac account role grant Easelm 4 -1 The above will grant account 'Easelm' role 4 (Administrator Commands) to all realms (-1) ---- .rbac account role deny ACCOUNTNAME ROLEID REALMID Example of command '.rbac account role deny': .rbac account role deny Easelm 4 -1 The above will deny account 'Easelm' from using role 4 (Administrator Commands), from all realms (-1) ---- .rbac account role revoke ACCOUNTNAME ROLEID Example of command '.rbac account role revoke': .rbac account role revoke Easelm 4 The above will revoke account 'Easelm' from having role 4 (Administrator Commands) ---- .rbac account permission grant ACCOUNTNAME PERMISSIONID REALMID Example of command '.rbac account permission grant': .rbac account permission grant Easelm 10 -1 The above will grant account 'Easelm' permission 10 (Administrator permissions) for all realms (-1) ---- .rbac account permission deny ACCOUNTNAME PERMISSIONID REALMID Example of command '.rbac account permission deny': .rbac account permission deny Easelm 10 -1 The above will deny account 'Easelm' from using permission 10 (Administrator permissions) from all realms (-1) ---- .rbac account permission revoke ACCOUNTNAME PERMISSIONID Example of command '.rbac account permission revoke': .rbac account permission revoke Easelm 10 The above will revoke account 'Easelm' of its permission 10 (Administrator permissions) (NOTE): You can select a player ingame and type in these commands to assign their groups/permissions/roles without specifying their account name. ~ Giving GM Permissions ~ Now, I tested with this and came up with the results. To give a GameMaster Player, Moderator and GM Permissions, you will need to set their groups, permission and role. Don't get me wrong, it works perfectly. To do this, we'll use a basic SQL query or the commands. .: By SQL Query :. To grant your GameMaster Player, Moderator and GameMaster permissions do (Will be more commands): Code: INSERT INTO `rbac_account_groups` (`accountId`, `groupId`, `realmId`) VALUES('2', '1', '-1'),('2', '2', '-1'),('2', '3', '-1');INSERT INTO `rbac_account_permissions` (`accountId`, `permissionId`, `granted`, `realmId`) VALUES('2', '9', '1', '-1');INSERT INTO `rbac_account_roles` (`accountId`, `roleId`, `granted`, `realmId`) VALUES('2', '3', '1', '-1'); To grant your GameMaster GameMaster only permissions do (Will be less commands): Code: INSERT INTO `rbac_account_groups` (`accountId`, `groupId`, `realmId`) VALUES('2', '3', '-1');INSERT INTO `rbac_account_permissions` (`accountId`, `permissionId`, `granted`, `realmId`) VALUES('2', '9', '1', '-1');INSERT INTO `rbac_account_roles` (`accountId`, `roleId`, `granted`, `realmId`) VALUES('2', '3', '1', '-1'); YOU CAN REPLACE THE VALUES WITH YOUR OWN. THEY ARE SPECIFIC AND CAN EASILY BE CHANGED. .: By Commands :. Assigning the group(s): To grant your GameMaster Player, Moderator and GameMaster permissions do (Will be more commands): .rbac account group add Easelm 1 -1.rbac account group add Easelm 2 -1.rbac account group add Easelm 3 -1 To grant your GameMaster GameMaster only permissions do (Will be less commands): .rbac account group add Easelm 3 -1 Assigning the role: .rbac account role grant Easelm 3 -1 Assigning the permission(s): .rbac account permission grant Easelm 9 -1 ~ Giving Full Administrator Permissions (All commands) ~ To do this, we'll use a basic SQL query or the commands. .: By SQL Query :. Code: INSERT INTO `rbac_account_groups` (`accountId`, `groupId`, `realmId`) VALUES('2', '1', '-1'),('2', '2', '-1'),('2', '3', '-1');('2', '4', '-1'); INSERT INTO `rbac_account_permissions` (`accountId`, `permissionId`, `granted`, `realmId`) VALUES('2', '10', '1', '-1');INSERT INTO `rbac_account_roles` (`accountId`, `roleId`, `granted`, `realmId`) VALUES('2', '4', '1', '-1'); YOU CAN REPLACE THE VALUES WITH YOUR OWN. THEY ARE SPECIFIC AND CAN EASILY BE CHANGED. .: By Commands :. Assigning the group(s): .rbac account group add Easelm 1 -1.rbac account group add Easelm 2 -1.rbac account group add Easelm 3 -1.rbac account group add Easelm 4 -1 Assigning the role: .rbac account role grant Easelm 4 -1 Assigning the permission(s): .rbac account permission grant Easelm 10 -1 ALWAYS REMEMBER: -1 is ALL REALMS. You can set permissions to a specific realm, for example 1, 2, 3, etc.. (RealmID goes by the amount of realms you have.) I hope you enjoyed this guide on how to fully comprehend the RBAC system.
×
×
  • Create New...