Colors
♥
- Joined
- Mar 22, 2013
- Messages
- 812
- Solutions
- 4
- Reaction score
- 271
join:
Code:function onSay(cid, words, param, channel) local lid = getPlayerByName(""..param.."") local pid = getPlayerByName(""..cid.."") local players = getPlayersOnline() if isInParty(cid) then doPlayerSendCancel(cid, "You are already in party.") doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF) return true end if not getPlayerStorageValue(cid, 9001) == 1 then doPlayerSendCancel(cid, "You Aren't Invited To Any Party") doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF) return true end if(not(getPlayerByName(param))) then doPlayerSendCancel(cid, "There is no such player nor it exists.") doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF) return true end if param == "" then doPlayerSendCancel(cid, "Invalid Param or Player Doesn't Exist") doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF) return true end if(getCreatureCondition(cid, CONDITION_INFIGHT)) then doPlayerSendCancel(cid, "You Are InFight") doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF) return true end if isInParty(lid) and string.lower(getCreatureName(lid)) == string.lower(param) and getPlayerGuildId(lid) == getPlayerGuildId(cid) then doPlayerJoinParty(cid, lid) doSendMagicEffect(getPlayerPosition(cid), CONST_ME_MAGIC_BLUE) doPlayerSetStorageValue(cid, 9001) for i, tid in ipairs(players) do if(getPlayerGuildId(tid) == getPlayerGuildId(cid) and cid ~= tid and isInParty(tid)) then doPlayerSendTextMessage(tid, 27,getCreatureName(cid).." Have Joined Your Party.") end end else doPlayerSendCancel(cid, "Unable to join to party") doPlayerSetStorageValue(cid, 9001) doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF) end return true end
Anyways thx for C++ code
So now you need to have 2 join scripts?...