load evidence w command
This commit is contained in:
parent
06ebe3c166
commit
fcd2771e21
@ -113,6 +113,7 @@ const QMap<QString, AOClient::CommandInfo> AOClient::COMMANDS{
|
|||||||
{"loadtestimony", {{ACLRole::CM}, 1, &AOClient::cmdLoadTestimony}},
|
{"loadtestimony", {{ACLRole::CM}, 1, &AOClient::cmdLoadTestimony}},
|
||||||
{"permitsaving", {{ACLRole::MODCHAT}, 1, &AOClient::cmdPermitSaving}},
|
{"permitsaving", {{ACLRole::MODCHAT}, 1, &AOClient::cmdPermitSaving}},
|
||||||
{"saveevidence", {{ACLRole::MODCHAT}, 0, &AOClient::cmdSaveEvidence}},
|
{"saveevidence", {{ACLRole::MODCHAT}, 0, &AOClient::cmdSaveEvidence}},
|
||||||
|
{"loadevidence", {{ACLRole::MODCHAT}, 0, &AOClient::cmdLoadEvidence}},
|
||||||
{"mutepm", {{ACLRole::NONE}, 0, &AOClient::cmdMutePM}},
|
{"mutepm", {{ACLRole::NONE}, 0, &AOClient::cmdMutePM}},
|
||||||
{"toggleadverts", {{ACLRole::NONE}, 0, &AOClient::cmdToggleAdverts}},
|
{"toggleadverts", {{ACLRole::NONE}, 0, &AOClient::cmdToggleAdverts}},
|
||||||
{"ooc_mute", {{ACLRole::MUTE}, 1, &AOClient::cmdOocMute}},
|
{"ooc_mute", {{ACLRole::MUTE}, 1, &AOClient::cmdOocMute}},
|
||||||
|
@ -920,6 +920,7 @@ class AOClient : public QObject
|
|||||||
* @iscommand
|
* @iscommand
|
||||||
*/
|
*/
|
||||||
void cmdSaveEvidence(int argc, QStringList argv);
|
void cmdSaveEvidence(int argc, QStringList argv);
|
||||||
|
void cmdLoadEvidence(int argc, QStringList argv);
|
||||||
void cmdArea(int argc, QStringList argv);
|
void cmdArea(int argc, QStringList argv);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -282,6 +282,7 @@ void AreaData::replaceEvidence(int f_eviId, const AreaData::Evidence &f_newEvi_r
|
|||||||
|
|
||||||
void AreaData::loadInventory(QSettings& settings)
|
void AreaData::loadInventory(QSettings& settings)
|
||||||
{
|
{
|
||||||
|
m_evidence.clear();
|
||||||
// Retrieve all keys from the QSettings object
|
// Retrieve all keys from the QSettings object
|
||||||
QStringList keys = settings.allKeys();
|
QStringList keys = settings.allKeys();
|
||||||
|
|
||||||
|
@ -88,6 +88,17 @@ void AOClient::cmdSaveEvidence(int argc, QStringList argv)
|
|||||||
sendServerMessage("Evidence for this area has been saved.");
|
sendServerMessage("Evidence for this area has been saved.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void AOClient::cmdLoadEvidence(int argc, QStringList argv)
|
||||||
|
{
|
||||||
|
Q_UNUSED(argc);
|
||||||
|
Q_UNUSED(argv);
|
||||||
|
|
||||||
|
AreaData *l_area = server->getAreaById(areaId());
|
||||||
|
QString l_area_name = l_area->name();
|
||||||
|
server->loadInventoryForArea(l_area, l_area_name);
|
||||||
|
sendEvidenceList(l_area);
|
||||||
|
}
|
||||||
|
|
||||||
void AOClient::cmdClearDoc(int argc, QStringList argv)
|
void AOClient::cmdClearDoc(int argc, QStringList argv)
|
||||||
{
|
{
|
||||||
Q_UNUSED(argc);
|
Q_UNUSED(argc);
|
||||||
|
Loading…
Reference in New Issue
Block a user