Postado Novembro 16, 2012 12 anos Tenho em meu PC algumas listas copm informações para se colocar em algumas funções que não se acha tão facilmente... - = Slots = - Aposto que muitos já se perguntaram o que por em slot na função getPlayerSlotItem(cid, slot). Abaixo há a resposta: CONST_SLOT_HEAD (1) = helmet CONST_SLOT_NECKLACE (2) = necklace slot CONST_SLOT_BACKPACK (3) = backpack CONST_SLOT_ARMOR (4) = armor CONST_SLOT_LEFT (5) = left hand CONST_SLOT_RIGHT (6) = right hand CONST_SLOT_LEGS (7) = legs CONST_SLOT_FEET (8) = boots CONST_SLOT_RING (9) = ring slot CONST_SLOT_AMMO (10) = ammo slot Exemplo de uso: if getPlayerSlotItem(cid, 10).itemid == 2229 then doPlayerSendTextMessage(cid, 22, "Você tem uma caveirano lugar das munições.") end Que seria o mesmo que: if getPlayerSlotItem(cid, CONST_SLOT_AMMO).itemid == 2229 then doPlayerSendTextMessage(cid, 22, "Você tem uma caveirano lugar das munições.") end Nota: a função getPlayerSlotItem(cid, slot) retorna uma table de três valores: itemid, uid e actionid. description weight defense attack attackspeed weaponType extradef absorbPercentDeath absorbPercentHoly absorbPercentIce absorbPercentEnergy absorbPercentEarth absorbPercentFire absorbPercentPhysical skillShield magiclevelpoints defense weaponType armor slotType weight speed Um exemplo muito usado em scripts de refinamento: doItemSetAttribute(item2.uid,"extradefense",8) Nota: as keys devem sempre ser usadas como uma string, ou seja, entre aspas. Nota2: Aquelas keys listadas não são as únicas, mas são as menos conhecidas. há também aid que representa a action id entre outras(que também precisam ser usadas como string). SKILL_FIST (0) = Fist Fighting SKILL_CLUB (1) = Club Fighting SKILL_SWORD (2) = Sword Fighting SKILL_AXE (3) = Axe Fighting SKILL_DISTANCE (4) = Distance Fighting SKILL_SHIELD (5) = Shielding SKILL_FISHING (6) = Fishing Exemplo: doPlayerAddSkill(cid, 1, 8) Que seria o mesmo que: doPlayerAddSkill(cid, SKILL_CLUB, 8) Espero que tenha ajudado Creditos Antharaz - = Keys = - Outra coisa importante são as keys de itens, usadas nas funções doItemSetAttribute(uid, key, value), doItemEraseAttribute(uid, key) e getItemAttribute(uid, key). Abaixo há uma lista com as keys: - = Skills = - Por último mas não menos importante há os skills, onde são usados em funções como doPlayerAddSkillTry(cid, skillid, n[, useMultiplier]), doPlayerAddSkill(cid, skillid, amount) entre outras. Abaixo segue a lista: Contato; god.marinii [email protected]
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.