MrFreak
getMaNGOS Staff-
Posts
104 -
Joined
-
Last visited
-
Donations
0.00 GBP
Content Type
Profiles
Bug Tracker
Wiki
Release Notes
Forums
Downloads
Blogs
Events
Everything posted by MrFreak
-
Table dbscripts_on_creature_movement has no unique ids for primary key If you look into table dbscripts_on_creature_movement you will notice a problem with the primary keys. To best honest, there are none. SELECT COUNT(ID) FROM dbscripts_on_creature_movement; tells you that there are 672 IDs found but this query SELECT COUNT(DISTINCT ID) FROM dbscripts_on_creature_movement; tells you that there are just 246 unique IDs so a lot of the primary keys are threefold or even more existing in the table. This could be because the primary key field id isn't set as a primary key too! According to this docs: [url]http://docs.getmangos.com/en/latest/database/world/creature-movement.html[/url] This ids are used for this purpose: [quote]script_id If a script should be executed, this references the “dbscripts_on_creature_movement” table tables unique ID for which the entry is valid. If not, set the value to zero.[/quote] You see that the IDs should be unique but in fact they are far away from this. I'm not sure what Mangos does when it tries to execute one of the ids which exist multiple times.
-
[quote=Xenithar]Wiki page is wrong. Look at the "Nullable" column. Every item is set to "NOT NULL", but they default to NULL. Another problem is that a primary key should NEVER be NULL. Base don these two facts, you would be required to put in a zero for a PK, but you should also remember that a PK should not change once set. Seems like that table is in need of a refit![/quote] If you set NULL as the value for a primary key it will increment the value by 1 based on the previously highest number. You have to enable auto_increment for this. I also noticed that the primary keys are the IDs for the realm so they are multiple times occurring. Problem is that a primary key should be unique but we got a lot of rows with the primary key value 1 so that is invalid. There should be a column called uptimeID or something like that which is the primary key. The reference on selecting or deleting stuff would happen on that uptimeID then and not anymore on the realmid which isn't unique. I'm unsure why the column 'starttime' is a primary key. I don't see any use for that. It should be unique but not a primary key.
-
change the '0' values to NULL in the database Look at the uptime table in the realmd db: [url]http://getmangos.eu/wiki/Reference%20Information/DB/realm/uptime.md[/url] The default values are '0' and NULL. We should use NULL because it's faster and it doesn't take space - it just exists virtually. If we use '0' it's a char that needs to be stored and it will take away space on the HDD.
-
use timestamp instead of a string to store a date in the DB For example, look at the uptime table in the realmd db: [url]http://getmangos.eu/wiki/Reference%20Information/DB/realm/uptime.md[/url] [QUOTE] Field 'starttime' The time when the server was started, in Unix time. Field 'startstring' The time when the server started, formated as a readable string. [/QUOTE] Both fields contain the same: a date. But they are stored differently. Every date in the database should be either stored as a string or as a timestamp. It shouldn't be mixed so both exists. I think it is better to use everywhere in the database for a date a timestamp for performance reasons.
-
Ghostlands (Windrunner Spire) NPC issues.
MrFreak commented on Necrovoice's bug in Archived Reports (Two)(Resolved issues)
A quick node on your fix: You have to remove the `mangos`. of your SQL queries so the changes don't apply to a specific database but to the one which is currently open/selected. This prevents issues for people who have more than one database with different names than 'mangos'. -
NPC 3791 - Dalinda Malem
MrFreak commented on madmax's bug in Archived Reports (Zero)(Resolved issues)
Can someone try if this works as a fix: Change the rows faction_A and faction_H of the npc Dalinda Malem to the value 554. -
auto-create missing folders The tools should auto-create the folders it need like the mmap generator should create the folder 'mmaps' by itself without telling the user it's missing and that he/she has to create it manually.
-
MaNGOSPage: Account Registration Page for MaNGOS
MrFreak replied to MrFreak's topic in Community Projects
The option for the admin to set the gameversion came after the option for the user to choose the expansion. I kept the user choice in because sometimes there are users who don't want to play all the available expansions but maybe only to TBC. So they can choose which expansion they can play with. Multiple language support will come by default but only after I added a login system with one or two ingame options in the interface then. You can send me the changes you made but as explained above I don't think that I will take them in yet. If you see a fallacy in my gameversion statement feel free to correct me. Thanks for your feedback! -
Hey, I did code an account registration page for MaNGOS and it's called 'MaNGOSPage'. If you put this script on your webserver and change the database (db) details you got a working website to register accounts online! Link to the script: https://github.com/mangostools/MaNGOSPage If you have suggestions to improve the script, feel free to write me! If you have troubles or errors while setting it up I will help you.
-
[Three] Crushridge Mage doesn't cast spells Hello, can someone explain me how the spell system works in MaNGOS? The creature 'Crushridge Mage' with the id '2255' casts the spell with the id '9672' correctly for the first time but after that the creature runs around and is being bugged.
-
[ALL] Server and database accept different long usernames I looked through the server code and saw a little flaw in it. The database accepts account usernames to be 32 chars long and the WoW client and the login can handle 32 chars long usernames too but if you try to change the username or password of such a 32 chars long account it will fail because the functions to change username and password are checking if the new username or password exceeds [code]MAX_ACCOUNT_STR[/code] which is defined as 16 chars. It's easy to fix: either the [code]MAX_ACCOUNT_STR[/code] gets increased to 32 chars or the realmd database structure for the column username in table account gets decreased from 32 chars to 16 chars.
Contact Us
To contact us
click here
You can also email us at [email protected]
Privacy Policy | Terms & Conditions
You can also email us at [email protected]
Privacy Policy | Terms & Conditions
Copyright © getMaNGOS. All rights Reserved.
This website is in no way associated with or endorsed by Blizzard Entertainment®
This website is in no way associated with or endorsed by Blizzard Entertainment®