E
Evil Puncker
Guest
I'm pretty sure that it is NOT the same error, you need two different dlls:
msvcp100d.dll
msvcr100d.dll
msvcp100d.dll
msvcr100d.dll
I want to know too.There is a function 'setsharedexperience' on party.h, how do I proper implement it at functions.lua so I can make a talkaction using it?
There is a function 'setsharedexperience' on party.h, how do I proper implement it at functions.lua so I can make a talkaction using it?
Maybe you can pull a request on github or share here your functions.The Exp Shared System code is all there, to make it work, you just need to add 3 lua functions
Example:
getPlayerPartyLeader(cid)
isExpShareActivated(cid)
setPartySharedExp(cid, value)
function setPartySharedExp(cid, value)
if isPlayer(cid) == getPlayerPartyLeader(cid) then
setPartySharedExp(cid, true)
end
end
I tried everything, lua is not my think, can u help
I know there isnt. But the other dude was pushing it.There is no LUA function that enables it. I wrote this in my previous post.
bool Party::setSharedExperience(Player* player, bool _sharedExpActive)
{
if(!player || getLeader() != player){
return false;
}
if(sharedExpActive == _sharedExpActive){
return true;
}
sharedExpActive = _sharedExpActive;
if(sharedExpActive){
sharedExpEnabled = canEnableSharedExperience();
if(sharedExpEnabled){
getLeader()->sendTextMessage(MSG_INFO_DESCR, "Shared Experience is now active.");
}
else{
getLeader()->sendTextMessage(MSG_INFO_DESCR, "Shared Experience has been activated," \
" but some members of your party are inactive.");
}
}
else{
getLeader()->sendTextMessage(MSG_INFO_DESCR, "Shared Experience has been deactivated.");
}
updateAllPartyIcons();
return true;
}
local cfg = {
inFightBlock = true,
onlyLeader = true,
}
function onSay(cid, words, param)
local members = getPartyMembers(cid)
if not members then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You are not in a party.")
return false
end
if cfg.onlyLeader and not isPartyLeader(cid) then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Only party leader can enable or disable shared experience.")
return false
end
if cfg.inFightBlock and hasCondition(cid, CONDITION_INFIGHT) then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You need to be out of fight.")
return false
end
local boolean = not isPartySharedExperienceActive(cid)
if setPartySharedExperience(cid, boolean) then
for _, pid in ipairs(members) do
if not isPartyLeader(pid) then
doPlayerSendTextMessage(pid, MESSAGE_INFO_DESCR, "Shared Experience has been "..(boolean and "activated" or "deactivated")..".")
end
end
else
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "There was an error. Try again in few seconds.")
end
return false
end
Here's an example of the Shared Exp TalkAction, now it's with you guys !!!
Code:local cfg = { inFightBlock = true, onlyLeader = true, } function onSay(cid, words, param) local members = getPartyMembers(cid) if not members then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You are not in a party.") return false end if cfg.onlyLeader and not isPartyLeader(cid) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Only party leader can enable or disable shared experience.") return false end if cfg.inFightBlock and hasCondition(cid, CONDITION_INFIGHT) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You need to be out of fight.") return false end local boolean = not isPartySharedExperienceActive(cid) if setPartySharedExperience(cid, boolean) then for _, pid in ipairs(members) do if not isPartyLeader(pid) then doPlayerSendTextMessage(pid, MESSAGE_INFO_DESCR, "Shared Experience has been "..(boolean and "activated" or "deactivated")..".") end end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "There was an error. Try again in few seconds.") end return false end