OpenTibiaBR
GithubDiscordSponsor
  • Home
    • 📖Welcome!
    • 💵Donate
  • OpenTibiaBR
    • 🖥️Projects
      • 🐦Canary
        • About
        • Getting Started
          • Compiling
            • Linux
              • [Linux] Compiling Canary Sources
            • Windows
              • Visual Studio
                • [Windows][VC2022][CMake] Compiling Canary Sources
                • [Windows][VC2022][Solution] Compiling Canary Sources
              • WSL
                • [WSL] Compiling Canary Sources
          • Installing
            • aaPanel
              • [Linux] Canary + aaPanel + MyAAC
            • Docker
              • [Docker] Canary + MariaDB + MyAAC
            • Linux
              • Nginx + MariaDB + MyAAC
            • Windows
              • Uniform Server
                • [Windows][Basic] Canary + Uniform Server + MyAAC
              • XAMPP
                • [Windows][Advanced] Canary + XAMPP + MyAAC
        • Tutorials
          • Basic
            • Auto Backup Server Database
            • Auto Restart and Linux Logs
            • Custom Bestiary / Prey with Canary Monster Editor
            • Event Schedule Canary / OTServBR-Global
            • How to make a custom server with Canary
            • How to reset players in your database
            • How to secure a Linux server
            • SSL Certificates
            • Webhook Discord
            • [Outdated] Custom Bestiary / Prey
            • [Linux] Backup + Upload - Google Drive
            • [Linux] How to install Linux headers
            • VPS Linux
            • [Windows] SSL/HTTPS Certificate with XAMPP
          • Mapping
            • [Windows] Remere's Map Editor - Opening Canary / OTServBR-Global Map
            • [Windows] Remere's Map Editor - Converting map server id to client id
          • Programming & Scripting
            • How to add a new vocation
            • Revscriptsys
            • Guide Lua Objects
            • How to get raceId for monsters
          • Websites
            • [Canary][OTServBR-Global][GesiorAAC][MyAAC] Set up Initial Character
          • Miscellaneous
            • Useful Tutorials
            • Video Tutorials
      • 🗺️Remere's Map Editor
        • About
        • Getting Started
          • Linux
            • [Linux] Compiling Remere's Map Editor Sources
          • Windows
            • WSL
              • [WSL] Compiling Remere's Map Editor Sources
            • Visual Studio
              • [Windows][VC2022][CMake] Compiling Remere's Map Editor Sources
              • [Windows][VC2022][Solution] Compiling Remere's Map Editor Sources
      • 🎮OTClient Redemption
        • About
        • Getting Started
          • Android
            • [Android] Compiling OTClient Redemption Sources
          • Linux
            • [Linux] Compiling OTClient Redemption Sources
          • Windows
            • WSL
              • [WSL] Compiling OTClient Redemption Sources
            • Visual Studio
              • [Windows][VC2022][CMake] Compiling OTClient Redemption Sources
              • [Windows][VC2022][Solution] Compiling OTClient Redemption Sources
          • Web
            • [Web] OTClient Redemption
        • Tutorials
          • Basic
            • Client Updater
    • 🔗Downloads
      • 🎮Clients
        • Client 11
        • Client 14
          • Tutorials
            • Client with HexEditorXVI32
            • Client with Notepad++
            • Client with config.ini
            • [Windows] How to change client background
        • OTClientV8
          • About
          • Getting Started
            • Android
              • [Android] Compiling OTClientV8 Sources
            • Linux
              • [Linux] Compiling OTClientV8 Sources
            • Windows
              • WSL
                • [WSL] Compiling OTClientV8 Sources
              • Visual Studio
                • [Windows][VC2022][CMake] Compiling OTClientV8 Sources
                • [Windows][VC2022][Solution] Compiling OTClientV8 Sources
          • Features
            • Health and Mana bar backgrounds
            • HTTP support
            • OTML Improvement
            • Simple cam recorder and player
            • Updater, encryption and compression
            • WebSockets
        • Minimap
      • 📑Codes
        • C++
        • Events
        • Functions
        • Libs
        • Modules
        • Others
      • 🖼️Images
        • PSDs
        • Others
      • 🗺️Maps
        • Custom
        • Global
      • 📑Revscripts
        • Actions
        • CreatureEvents
        • GlobalEvents
        • MoveEvents
        • NPCs
        • Spells
        • Systems
        • TalkActions
      • ⚔️Sprites
      • ⚙️Tools
        • Editors
        • Launchers
          • Canary Launcher
            • About
            • Getting Started
              • Windows
                • [Windows][VC2022][Solution] Compiling Canary Launcher Sources
          • Slender Launcher
            • About
            • Getting Started
              • Windows
                • [Windows][Go] Compiling Slender Launcher Sources
        • Login Server
          • About
          • Getting Started
        • Map Generators
      • 🌐Web Packages
        • Linux
        • Windows
      • 🌐Website Applications
        • Websites
          • CanaryAAC
            • About
            • Informations
              • Features
              • Functions
              • API
              • Routes
              • Middleware
            • CanaryAAC Bot
          • Gesior2012
            • About
          • GesiorAAC Global
            • About
          • MyAAC
            • About
          • MyAAC Global
            • About
          • SlenderAAC
            • About
          • ZnoteAAC
            • About
        • Applications
        • Layouts
        • APIs and SDKs
Powered by GitBook
On this page
  • Tutorial explaining how to reset your server without losing the players.
  • 1 - Running commands via SQL:
  • 2 - Understanding each function and customizing the codes:
  1. OpenTibiaBR
  2. Projects
  3. Canary
  4. Tutorials
  5. Basic

How to reset players in your database

Last updated 9 months ago

Tutorial explaining how to reset your server without losing the players.

1 - Running commands via SQL:

  • To get started, you must access your database through your https://your-ip/phpmyadmin, log into your administrative account. In the table to your left you will see the following infos:

  • Access your database, I will use otservbrglobal as an example.

  • Access the SQL button to be able to run the codes:

2 - Understanding each function and customizing the codes:

Here are the UPDATES, ie the commands to update player information:

UPDATE players SET level=2;            - Sets the level of all your players.
UPDATE players SET vocation=0;         - Defines the vocation of all your players.
UPDATE players SET health=155;         - The life of all your players.
UPDATE players SET healthmax=155;      - The maximum life of all your players.
UPDATE players SET experience=100;     - Sets the initial exp of all your players.
UPDATE players SET lookbody=94;        - Sets the outfit color.
UPDATE players SET lookfeet=78;        - Sets the outfit color.
UPDATE players SET lookhead=78;        - Sets the outfit color.
UPDATE players SET looklegs=0;         - Sets the outfit color.
UPDATE players SET looktype=129;       - Defines the outfit.
UPDATE players SET lookaddons=0;       - Resets addons.
UPDATE players SET maglevel=0;         - Sets the magic level of all players.
UPDATE players SET mana=60;            - The mana of all players.
UPDATE players SET manamax=60;         - The maximum mana of all players.
UPDATE players SET manaspent=0;        - Defines how much mana your players have already spent.
UPDATE players SET soul=100;           - Sets the Soul of all players.
UPDATE players SET town_id=1;          - The city your player will be born in, IDs range from 1 to 23.
UPDATE players SET posx=32069;         - Defines the position on the X axis from where your players will log in for the first time.
UPDATE players SET posy=31901;         - Defines the position on the Y axis from where your players will log in for the first time.
UPDATE players SET posz=6;             - Defines the position on the Z axis from where your players will log in for the first time.
UPDATE players SET cap=410;            - Sets the total amount of cap without items.
UPDATE players SET sex=0;              - Sets the gender of your players.
UPDATE players SET skull=0;            - Sets the frags of your players.
UPDATE players SET skulltime=0;        - Set the time to expire the frags.
UPDATE players SET blessings=0;        - Defines if your players will start with bless.
UPDATE players SET blessings1=1;       - Bless 1.
UPDATE players SET blessings2=1;       - Bless 2.
UPDATE players SET blessings3=1;       - Bless 3.
UPDATE players SET blessings4=1;       - Bless 4.
UPDATE players SET blessings5=1;       - Bless 5.
UPDATE players SET blessings6=1;       - Bless 6.
UPDATE players SET blessings7=0;       - Bless 7.
UPDATE players SET blessings8=0;       - Bless 8.
UPDATE players SET balance=0;          - Defines the amount of money your players will have in the bank.
UPDATE players SET quickloot_fallback=0; - Resets your players' loot settings.
UPDATE players SET offlinetraining_time=43200; - Defines the time the player will have to train Offline.
UPDATE players SET stamina=2520;          - Sets player's stamina in minutes.
UPDATE players SET skill_fist=10;         - Sets the player's first skill.
UPDATE players SET skill_fist_tries=0;    - Sets the player's first skill.
UPDATE players SET skill_club=10;         - Defines the player's skill club.
UPDATE players SET skill_club_tries=0;    - Defines the player's skill club.
UPDATE players SET skill_sword=10;        - Sets the player's sword skill.
UPDATE players SET skill_sword_tries=0;   - Sets the player's sword skill.
UPDATE players SET skill_axe=10;          - Sets the player's ax skill.
UPDATE players SET skill_axe_tries=0;     - Sets the player's ax skill.
UPDATE players SET skill_dist=10;         - Sets the player's skill distance.
UPDATE players SET skill_dist_tries=0;    - Sets the player's skill distance.
UPDATE players SET skill_shielding=0;     - Sets the player's shield skill.
UPDATE players SET skill_shielding_tries=0; - Sets the player's shield skill.
UPDATE players SET skill_fishing=10;      - Sets the player's fishing skill.
UPDATE players SET skill_fishing_tries=0; - Sets the player's fishing skill.
UPDATE players SET xpboost_stamina=0;     - Sets the player's expboost reset.
UPDATE players SET xpboost_value=0;       - Sets the player's expboost reset.
UPDATE players SET marriage_status=0;     - Defines if the player is married.
UPDATE players SET marriage_spouse=-1;    - Defines if the player has already married.
UPDATE players SET bonus_rerolls=0;       - Defines if the player has already run the prey.

Here are the DELETES, that is, the commands to delete the information of the players:

DELETE FROM player_storage;            - Removes all storage
DELETE FROM player_items;              - Removes all items from players.
DELETE FROM player_depotitems;         - Removes all items from players' depot(DP).
DELETE FROM player_stash;              - Removes all items from Supply Stash
DELETE FROM player_rewards;            - Removes all rewards.
DELETE FROM player_inboxitems;         - Removes all inbox items.
DELETE FROM player_hirelings;          - Removes hirelings from houses
DELETE FROM player_deaths;             - Removes player deaths.
DELETE FROM coins_transactions;        - Removes the history of coins transactions.
DELETE FROM house_lists;               - Removes the owners of the houses.
DELETE FROM houses;                    - Remove items from houses.
DELETE FROM accounts WHERE coins > 0;  - Removes player coins. 

Credits:

  • dracoalv.

🖥️
🐦