-Doc- Posted May 29, 2015 Share Posted May 29, 2015 Hi my code its not working. Wahts the problem . Its server side. function setPedCorrectWalkingStyle() if getElementType(source) == "player" or getElementType(source) == "ped" then local walking = getElementData(source, "style.walking") if walking then setPedWalkingStyle(source, walking) end end end addEventHandler("onElementModelChange", getRootElement(), setPedCorrectWalkingStyle) Link to comment
ALw7sH Posted May 29, 2015 Share Posted May 29, 2015 There's no problem, are you sure you have this element data ? (style.walking) Link to comment
-Doc- Posted May 29, 2015 Author Share Posted May 29, 2015 Some one helped me wrong OMG. I just wanna make for all skins their own walking style Link to comment
-Doc- Posted May 29, 2015 Author Share Posted May 29, 2015 Where i can found all skins their walking styles? Link to comment
Mr.unpredictable. Posted May 29, 2015 Share Posted May 29, 2015 Where i can found all skins their walking styles? What are you talking about? Explain your problem better. Link to comment
-Doc- Posted May 29, 2015 Author Share Posted May 29, 2015 Every time u cant understand me =-= . I wanna make walking style for every skin. Is this possible to make it? Link to comment
Mr.unpredictable. Posted May 29, 2015 Share Posted May 29, 2015 Every time u cant understand me =-= . I wanna make walking style for every skin. Is this possible to make it? Use SetPedWalkingStyle function and these are the walking style id's. MOVE_DEFAULT 0 MOVE_PLAYER 54 MOVE_PLAYER_F 55 MOVE_PLAYER_M 56 MOVE_ROCKET 57 MOVE_ROCKET_F 58 MOVE_ROCKET_M 59 MOVE_ARMED 60 MOVE_ARMED_F 61 MOVE_ARMED_M 62 MOVE_BBBAT 63 MOVE_BBBAT_F 64 MOVE_BBBAT_M 65 MOVE_CSAW 66 MOVE_CSAW_F 67 MOVE_CSAW_M 68 MOVE_SNEAK 69 MOVE_JETPACK 70 MOVE_MAN 118 MOVE_SHUFFLE 119 MOVE_OLDMAN 120 MOVE_GANG1 121 MOVE_GANG2 122 MOVE_OLDFATMAN 123 MOVE_FATMAN 124 MOVE_JOGGER 125 MOVE_DRUNKMAN 126 MOVE_BLINDMAN 127 MOVE_SWAT 128 MOVE_WOMAN 129 MOVE_SHOPPING 130 MOVE_BUSYWOMAN 131 MOVE_SEXYWOMAN 132 MOVE_PRO 133 MOVE_OLDWOMAN 134 MOVE_FATWOMAN 135 MOVE_JOGWOMAN 136 MOVE_OLDFATWOMAN 137 MOVE_SKATE 138 Link to comment
Bilal135 Posted May 29, 2015 Share Posted May 29, 2015 Every time u cant understand me =-= . I wanna make walking style for every skin. Is this possible to make it? If you want male walking styles and girl walking styles, then this should work. (Untested) maleskins = {put male skins here separated by comma} girlskins = {put girl skins here separated by comma} malewalkingstyle = writehere girlwalkingstyle = writehere function onChangeSkin() local skin = getElementModel(source) if skin == maleskins then setPedWalkingStyle(source, malewalkingstyle) elseif skin == girlskins then setPedWalkingStyle(source, girlwalkingstyle) end end addEventHandler("onElementModelChange", root, onChangeSkin) If you want walking style for every skin, then keep repeating elsief for all skins. (Untested) function onChangeSkin() local skin = getElementModel(source) if skin == skinid then setPedWalkingStyle(source, walkingstyleid) elseif skin == skinid then setPedWalkingStyle(source, walkingstyleid) end end addEventHandler("onElementModelChange", root, onChangeSkin) Link to comment
jingzhi Posted June 19, 2015 Share Posted June 19, 2015 Every time u cant understand me =-= . I wanna make walking style for every skin. Is this possible to make it? Blue, no offense, but you really need to explain your problem better if you want other people help you on your scripting, and dont accuse them not understanding your question Link to comment
SunArrow Posted June 19, 2015 Share Posted June 19, 2015 What is there to explain more? He wants that every skin(ped like in singleplayer) has its own walking style 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