xeross155
-
Posts
702 -
Joined
-
Last visited
Never -
Donations
0.00 GBP
Content Type
Profiles
Bug Tracker
Wiki
Release Notes
Forums
Downloads
Blogs
Events
Posts posted by xeross155
-
-
or one could add the mirrors as seperate remote
git remote add NAME git://url/to/repo
Then when master is down they just have to do
git pull NAME
and then
git merge NAME/master
-
@False.Genesis: Check your own signature, PseuWow could possibly be used for it.
-
Shouldn't these scripts for the eye be a part of SD2 ?
-
Why are you using mangos 6628 ?
Edit: Whoops just noticed the thread age.
-
Testing on revision 8587 now, will post results.
-
Cool, congratz on solving it.
-
Well now it uses .gm on/off so that would be sufficient, I might try creating a command like that though. or you could use the GM item version.
-
There's this new mail stationery type "MAIL_STATIONERY_ORP" wonder what it's used for.
-
The default mail expiry is 30 days so that's why it is like that, and well balrok said it should be 3 days.
So there isn't any other thing that uses MAIL_CREATURE else that would yield unexpected results.
Edit: Achievements, etc. also use it so this would make achievement items dissapear in 1 day, not good.
-
Ye just saw fixing, fixed now. compiling it myself too.
-
Hey,
I saw some patches similiar to this one and wrote 2 of my own, made but haven't tested compiling now.
Revision 9199 (Rewrite)
GM Mode Ondiff --git a/contrib/extractor/ad.exe b/contrib/extractor/ad.exe index 105f381..ed50bc2 100755 Binary files a/contrib/extractor/ad.exe and b/contrib/extractor/ad.exe differ diff --git a/src/game/Mail.cpp b/src/game/Mail.cpp index 0509240..90d029d 100644 --- a/src/game/Mail.cpp +++ b/src/game/Mail.cpp @@ -793,6 +793,8 @@ MailSender::MailSender( Object* sender, MailStationery stationery ) : m_statione case TYPEID_PLAYER: m_messageType = MAIL_NORMAL; m_senderId = sender->GetGUIDLow(); + if(static_cast<Player *>(sender)->isGameMaster()) + m_stationery = MAIL_STATIONERY_GM; break; default: m_messageType = MAIL_NORMAL;
Revision 8818
- GM Mode Ondiff --git a/src/game/Mail.cpp b/src/game/Mail.cpp index 061bfbb..8f6291a 100644 --- a/src/game/Mail.cpp +++ b/src/game/Mail.cpp @@ -799,6 +799,11 @@ MailSender::MailSender( Object* sender, MailStationery stationery ) : m_statione case TYPEID_PLAYER: m_messageType = MAIL_NORMAL; m_senderId = sender->GetGUIDLow(); + { + Player* plr = sObjectMgr.GetPlayer(m_senderId); + if(plr && plr->isGameMaster()) + m_stationery = MAIL_STATIONERY_GM; + } break; default: m_messageType = MAIL_NORMAL;
- GM Mode On + Item
diff --git a/src/game/Mail.cpp b/src/game/Mail.cpp index 061bfbb..7c801bc 100644 --- a/src/game/Mail.cpp +++ b/src/game/Mail.cpp @@ -799,6 +799,11 @@ MailSender::MailSender( Object* sender, MailStationery stationery ) : m_statione case TYPEID_PLAYER: m_messageType = MAIL_NORMAL; m_senderId = sender->GetGUIDLow(); + { + Player* plr = sObjectMgr.GetPlayer(m_senderId); + if(plr && plr->isGameMaster() && pl->HasItemCount(18154, 1, false)) + m_stationery = MAIL_STATIONERY_GM; + } break; default: m_messageType = MAIL_NORMAL;
Old
- One that requires for gm mode to be ondiff --git a/src/game/Mail.cpp b/src/game/Mail.cpp index 5dba0b6..26c4ad2 100644 --- a/src/game/Mail.cpp +++ b/src/game/Mail.cpp @@ -273,8 +273,11 @@ void WorldSession::HandleSendMail(WorldPacket & recv_data ) // If theres is an item, there is a one hour delivery delay if sent to another account's character. uint32 deliver_delay = needItemDelay ? sWorld.getConfig(CONFIG_MAIL_DELIVERY_DELAY) : 0; + // Set the mail type + MailStationery mailType = (pl->isGameMaster()) ? MAIL_STATIONERY_GM : MAIL_STATIONERY_NORMAL; + // will delete item or place to receiver mail list - WorldSession::SendMailTo(receive, MAIL_NORMAL, MAIL_STATIONERY_NORMAL, pl->GetGUIDLow(), GUID_LOPART(rc), subject, itemTextId, &mi, money, COD, MAIL_CHECK_MASK_NONE, deliver_delay); + WorldSession::SendMailTo(receive, MAIL_NORMAL, mailType, pl->GetGUIDLow(), GUID_LOPART(rc), subject, itemTextId, &mi, money, COD, MAIL_CHECK_MASK_NONE, deliver_delay); CharacterDatabase.BeginTransaction(); pl->SaveInventoryAndGoldToDB();
- One that requires an item and gm mode to be on
diff --git a/src/game/Mail.cpp b/src/game/Mail.cpp index 5dba0b6..88b1625 100644 --- a/src/game/Mail.cpp +++ b/src/game/Mail.cpp @@ -273,8 +273,11 @@ void WorldSession::HandleSendMail(WorldPacket & recv_data ) // If theres is an item, there is a one hour delivery delay if sent to another account's character. uint32 deliver_delay = needItemDelay ? sWorld.getConfig(CONFIG_MAIL_DELIVERY_DELAY) : 0; + // Set the mail type + MailStationery mailType = (pl->isGameMaster() && pl->HasItemCount(18154, 1, false)) ? MAIL_STATIONERY_GM : MAIL_STATIONERY_NORMAL; + // will delete item or place to receiver mail list - WorldSession::SendMailTo(receive, MAIL_NORMAL, MAIL_STATIONERY_NORMAL, pl->GetGUIDLow(), GUID_LOPART(rc), subject, itemTextId, &mi, money, COD, MAIL_CHECK_MASK_NONE, deliver_delay); + WorldSession::SendMailTo(receive, MAIL_NORMAL, mailType, pl->GetGUIDLow(), GUID_LOPART(rc), subject, itemTextId, &mi, money, COD, MAIL_CHECK_MASK_NONE, deliver_delay); CharacterDatabase.BeginTransaction(); pl->SaveInventoryAndGoldToDB();
Download em here
Regards, Xeross
-
Hey Folks,
As I was making some modifications to the mail system for my own test server balrok said on IRC ( asked him something about it) while you're looking at it try to make the BG Marks mails expire after 3 days (Now they expire after 30), so I thought why not, some extra practice.
However I've checked the code now so far I've found the following
MailStationery (Mail.h)
enum MailStationery { MAIL_STATIONERY_UNKNOWN = 0x01, MAIL_STATIONERY_NORMAL = 0x29, MAIL_STATIONERY_GM = 0x3D, MAIL_STATIONERY_AUCTION = 0x3E, MAIL_STATIONERY_VAL = 0x40, MAIL_STATIONERY_CHR = 0x41 };
The code used to send marks (In Battleground.cpp)
WorldSession::SendMailTo(plr, MAIL_CREATURE, MAIL_STATIONERY_NORMAL, bmEntry, plr->GetGUIDLow(), subject, itemTextId , &mi, 0, 0, MAIL_CHECK_MASK_NONE);
and well the SendMailTo function in Mail.cpp
void WorldSession::SendMailTo(Player* receiver, uint8 messageType, uint8 stationery, uint32 sender_guidlow_or_entry, uint32 receiver_guidlow, std::string subject, uint32 itemTextId, MailItemsInfo* mi, uint32 money, uint32 COD, uint32 checked, uint32 deliver_delay, uint16 mailTemplateId)
Which has
uint32 expire_delay; if(messageType == MAIL_AUCTION && !mi && !money) // auction mail without any items and money expire_delay = HOUR; else expire_delay = (COD > 0) ? 3*DAY : 30*DAY;
So to fix it we would need to add an elseif to the if statement or something similiar. however I don't see any way to determine if an in-game mail is coming from "the BG", well we could check what item is being sent with the mail but I dunno if that's concidered hacky, other then that the stationery is not other then normal mails and so isn't the template.
Like to hear some thoughts, etc. on this.
Regards, Xeross
-
Compiling now, had to edit it a little because I'm using a modified core. no errors so far.
For people that want the patch file : http://files.x3tech.com/115/Intel%20Memory%20Allocator.zip
It's my own file upload site btw.
-
OffTopic: How to update core via git? Ima check if theres any new updates i can use to fix it if i find out how to update core to latest rev.
There's plenty of guides on GIT check the Source Code Management Board.
-
The Patch File = 2MB, is that about right ?
-
-
Hmm I still have patches of my changes but I'd have to make new ones for newer revisions, merges can look over any changes and apply correctly but patch files don't seem to merge as well as a git merge.
-
That seems a bit of a workaround because I used to just merge the master into my own branch.
Maybe somehow revert the master branch to the revision I want and then merge.
Edit:
Just found
http://stackoverflow.com/questions/889984/bring-git-repo-up-to-a-certain-revision
I'll do that.
-
Seperate threads for world and char db seems a good idea.
-
Hey,
MaNGOS has just switched to 3.2.2a however I prefer to say at 3.1.3 for a while till I have the time to properly do the upgrade.
I use a custom branch with my source edits in git and use the following commands to update it to the latest mangos
git pull git merge origin/master
so it just pulls all updates for all branches and then I merge the master branch into my custom branch.
However how can I merge upto a specific branch (or a tag) so I can keep my server at the last 3.1.3 revision ?
Thank you for your time, Xeross
-
So will 3.1.3 get a seperate branch or are we forced to use 3.2.2a from now on if we update.
-
Once it's approved as proper code and working without hacks.
-
indeed...
When you post your threads on new and interesting bikes, can you also include a link to the originating photo/article? Im sure wed also like to read about the specs displacement, weight, etc.. Much appreciated
Jeff
What the hell, damn xrumer.
-
Still what's the problem with this, what isn't working (What part). and to find out the arguments for the mangos functions just search the source for em.
Eye of Acherus.
in OldCore modifications
Posted
ah ok, thanks for the info.