roddydennvor Posted October 29, 2014 Share Posted October 29, 2014 Hallo #88,,, In the following script, I have to type the command "/bcase" to bring up the case ... local cases = {} for i,v in ipairs(getElementsByType("player"))do setElementData(v, "bcase", 0) end addCommandHandler("bcase", function(player) if(getResourceState(getResourceFromName("bone_attach")) == "running")then if(getElementType(player) == "player")then if(getElementData(player, "bcase") ~= 1)then setElementData(player, "bcase", 1) case = createObject(1210,0,0,0) exports.bone_attach:attachElementToBone(case,player,12,0,0.05,0.27,0,180,0) cases[player] = case elseif(getElementData(player, "bcase") == 1)then setElementData(player, "bcase", 0) exports.bone_attach:detachElementFromBone(cases[player]) destroyElement(cases[player]) end end else outputChatBox("ERROR #1", player, 255, 50, 0) end end ) Well , how can I make this case arises when I have an item case in my inventory ? Thank you for your assistance, your help is precious Author : ~Bcase Script : simmon95 Link to comment
$@!m HeRO Posted October 30, 2014 Share Posted October 30, 2014 briefcase : https://community.multitheftauto.com/index.php?p= ... ls&id=8503 With this script u can give urself a briefcase! just type /bcase when u want it! and type again to remove. you also need to have bone_attach resource running! bone_attach : https://community.multitheftauto.com/index.php?p= ... ls&id=2540 start both resources and it will work when you'll type /bcase Link to comment
roddydennvor Posted October 31, 2014 Author Share Posted October 31, 2014 no no ... I mean when i have a bag ( item id 40 < Example) the case will arises ? like a toys system ... When you buy a hat you get it on your head ? and other player can see it ... how to do that ? what is the function ? Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now