Forums WoW Modding Support Archives TrinityCore Discord Archives [DiscordArchive] <@456226577798135808> is it possible to somehow mail several items + Subject/Body with player->SendI

[DiscordArchive] <@456226577798135808> is it possible to somehow mail several items + Subject/Body with player->SendI

[DiscordArchive] <@456226577798135808> is it possible to somehow mail several items + Subject/Body with player->SendI

rektbyfaith
Administrator
0
10-25-2019, 08:41 PM
#1
Archived author: Kitzunu • Posted: 2019-10-25T20:41:05.421000+00:00
Original source

<@456226577798135808> is it possible to somehow mail several items + Subject/Body with player->SendItemRetriavalMail ?
rektbyfaith
10-25-2019, 08:41 PM #1

Archived author: Kitzunu • Posted: 2019-10-25T20:41:05.421000+00:00
Original source

<@456226577798135808> is it possible to somehow mail several items + Subject/Body with player->SendItemRetriavalMail ?

rektbyfaith
Administrator
0
10-25-2019, 08:44 PM
#2
Archived author: Deleted User • Posted: 2019-10-25T20:44:44.817000+00:00
Original source

u shd use maildraft instead then
rektbyfaith
10-25-2019, 08:44 PM #2

Archived author: Deleted User • Posted: 2019-10-25T20:44:44.817000+00:00
Original source

u shd use maildraft instead then

rektbyfaith
Administrator
0
10-25-2019, 08:51 PM
#3
Archived author: Kitzunu • Posted: 2019-10-25T20:51:14.589000+00:00
Original source

Oki, is there any documention of how it works?
rektbyfaith
10-25-2019, 08:51 PM #3

Archived author: Kitzunu • Posted: 2019-10-25T20:51:14.589000+00:00
Original source

Oki, is there any documention of how it works?

rektbyfaith
Administrator
0
10-25-2019, 08:56 PM
#4
Archived author: Exitare • Posted: 2019-10-25T20:56:07.388000+00:00
Original source

<@224931509046345729> yep, the approach I wrote
rektbyfaith
10-25-2019, 08:56 PM #4

Archived author: Exitare • Posted: 2019-10-25T20:56:07.388000+00:00
Original source

<@224931509046345729> yep, the approach I wrote

rektbyfaith
Administrator
0
10-25-2019, 09:08 PM
#5
Archived author: Deleted User • Posted: 2019-10-25T21:08:31.870000+00:00
Original source

u can look at the Player::SendItemRetreivalMail function
rektbyfaith
10-25-2019, 09:08 PM #5

Archived author: Deleted User • Posted: 2019-10-25T21:08:31.870000+00:00
Original source

u can look at the Player::SendItemRetreivalMail function

rektbyfaith
Administrator
0
10-25-2019, 09:09 PM
#6
Archived author: Kitzunu • Posted: 2019-10-25T21:09:01.251000+00:00
Original source

okay, thanks for the help!
rektbyfaith
10-25-2019, 09:09 PM #6

Archived author: Kitzunu • Posted: 2019-10-25T21:09:01.251000+00:00
Original source

okay, thanks for the help!

rektbyfaith
Administrator
0
10-25-2019, 09:20 PM
#7
Archived author: Kitzunu • Posted: 2019-10-25T21:20:47.220000+00:00
Original source

appearently dont have that in my core xd anyways thanks for the help
rektbyfaith
10-25-2019, 09:20 PM #7

Archived author: Kitzunu • Posted: 2019-10-25T21:20:47.220000+00:00
Original source

appearently dont have that in my core xd anyways thanks for the help

rektbyfaith
Administrator
0
10-25-2019, 09:25 PM
#8
Archived author: Deleted User • Posted: 2019-10-25T21:25:17.117000+00:00
Original source

```cpp

void Player::SendItemRetrievalMail(uint32 itemEntry, uint32 count)
{
MailSender sender(MAIL_CREATURE, 34337 /* The Postmaster */);
MailDraft draft("Recovered Item", "We recovered a lost item in the twisting nether and noted that it was yours.$B$BPlease find said object enclosed."); // This is the text used in Cataclysm, it probably wasn't changed.
SQLTransaction trans = CharacterDatabase.BeginTransaction();

if (Item* item = Item::CreateItem(itemEntry, count, nullptr))
{
item->SaveToDB(trans);
draft.AddItem(item);
}

draft.SendMailTo(trans, MailReceiver(this, GetGUID().GetCounter()), sender);
CharacterDatabase.CommitTransaction(trans);
}
```
rektbyfaith
10-25-2019, 09:25 PM #8

Archived author: Deleted User • Posted: 2019-10-25T21:25:17.117000+00:00
Original source

```cpp

void Player::SendItemRetrievalMail(uint32 itemEntry, uint32 count)
{
MailSender sender(MAIL_CREATURE, 34337 /* The Postmaster */);
MailDraft draft("Recovered Item", "We recovered a lost item in the twisting nether and noted that it was yours.$B$BPlease find said object enclosed."); // This is the text used in Cataclysm, it probably wasn't changed.
SQLTransaction trans = CharacterDatabase.BeginTransaction();

if (Item* item = Item::CreateItem(itemEntry, count, nullptr))
{
item->SaveToDB(trans);
draft.AddItem(item);
}

draft.SendMailTo(trans, MailReceiver(this, GetGUID().GetCounter()), sender);
CharacterDatabase.CommitTransaction(trans);
}
```

Recently Browsing
 1 Guest(s)
Recently Browsing
 1 Guest(s)