Jump to content

Anulesked

Members
  • Posts

    9
  • Joined

  • Last visited

Details

  • Gang
    wiki

Anulesked's Achievements

Newbie

Newbie (4/54)

0

Reputation

  1. TAPL, i'm sad and tired. i'll theft others' resources because my is failed.
  2. IIYAMA, i get: join.lua:7: Bad argument @ 'getPedClothes' I'm so sad
  3. TAPL, with i get: join.lua:7: Bad argument @ 'getPedClothes'
  4. IIYAMA, look: Step #1 Step #2 Step #3 Step #4 Code: (your without edits) I always get it error.
  5. IIYAMA, i get "bad argument @ addPedClothes" as before. local playerDataTable = {"torso"} function saveSkin(player,clothesType) local account = getPlayerAccount(player) local tex, mod = getPedClothes(player, clothesType) for i, data in ipairs(playerDataTable) do setAccountData(account, data, tex..",".. mod .. "," .. clothesType) --outputChatBox("saved #"..i..": "..getAccountData(account, data[1])) end end addCommandHandler("s", saveSkin) function loadSkin(player) local account = getPlayerAccount(player) for i, data in ipairs(playerDataTable) do local account = getPlayerAccount(player) local clothing = getAccountData(account, data) if clothing and getElementModel(player) == 0 then local table = split(clothing,",") addPedClothes (player,table[1] , table[2],tonumber(table[3])) end --outputChatBox("saved #"..i..": "..getAccountData(account, data[1])) end end addCommandHandler("x", loadSkin) and yet i don't know must i get player account before cycle or after.
  6. IIYAMA, but it's my work... from "a" to "z"...
  7. IIYAMA, very thank for ur reply! but in my full script table is that: local playerDataTable = { {"torso"}, {"something"}, {"yet something"}, ... } what i must rewrite in ur code with that table? I'm very sorry for my bad english.
  8. Help me please, guys: local playerDataTable = { {"torso"} } function saveSkin(player,clothesType) local account = getPlayerAccount(player) local tex, mod = getPedClothes(player, clothesType) for i, data in ipairs(playerDataTable) do setAccountData(account, data[1], "\""..tex.."\",\""..mod.."\"") outputChatBox("saved #"..i..": "..getAccountData(account, data[1])) end end addCommandHandler("s", saveSkin) function loadSkin(player) local account = getPlayerAccount(player) for i, data in ipairs(playerDataTable) do local account = getPlayerAccount(player) addPedClothes (player, getAccountData(account, data[1]), 0) outputChatBox("saved #"..i..": "..getAccountData(account, data[1])) end end addCommandHandler("x", loadSkin)
×
×
  • Create New...