0% found this document useful (0 votes)
1K views3 pages

(FC26) Apply Faces + Tattoos (Live Editor Script)

The script updates player records with high-quality face variations and tattoos based on predefined IDs. It checks for valid player IDs and applies corresponding facial and tattoo attributes from specified tables. A message box displays the number of updated faces and tattoos after processing all records.

Uploaded by

kauaivodossm
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1K views3 pages

(FC26) Apply Faces + Tattoos (Live Editor Script)

The script updates player records with high-quality face variations and tattoos based on predefined IDs. It checks for valid player IDs and applies corresponding facial and tattoo attributes from specified tables. A message box displays the number of updated faces and tattoos after processing all records.

Uploaded by

kauaivodossm
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 3

local target_ids = {

[277179] = 0,
[278349] = 0,
[246191] = 1,
[80674] = 0,
[236772] = 1,
[262881] = 0,
[188545] = 1,
[233419] = 1,
[265600] = 0,
[75156] = 0,
[241486] = 1,
[228702] = 1,
[272600] = 0,
[74463] = 0,
[75068] = 0,
[231747] = 1,
[278399] = 0,
[259716] = 0,
[71998] = 0,
[256079] = 0,
[212831] = 1,
[233731] = 0,
[278455] = 0,
[254803] = 0,
[70824] = 0,
[277427] = 0,
[270964] = 0,
[279731] = 0,
[276278] = 0,
[273599] = 0,
[237692] = 1,
[272602] = 0,
[257289] = 0,
[252042] = 0,
[79402] = 0,
[266032] = 1,
[259399] = 0,
[238074] = 1,
[267976] = 0,
[277432] = 0,
[262105] = 0,
[245155] = 1,
[237238] = 0,
[242964] = 1,
[254243] = 0,
[243702] = 0,
[75087] = 0,
[278923] = 0,
[71351] = 0,
[224987] = 0,
[252154] = 0,
[251752] = 0,
[279202] = 0,
[272926] = 0,
[269859] = 0,
[247090] = 0,
}
local tattoos_left_arm = {
[252042] = 70,
[233419] = 71,
[262881] = 72,
[278923] = 73,
}

local tattoos_right_arm = {
[252042] = 70,
[233419] = 71,
[262881] = 72,
[278923] = 73,
}

local tattoos_left_leg = {}
local tattoos_right_leg = {}

if next(target_ids) == nil then


MessageBox("No targets", "Add player IDs to target_ids table before running the
script.")
return
end

local players_table = LE.db:GetTable("players")


local rec = players_table:GetFirstRecord()
local updated_faces, updated_tattoos = 0, 0

local function remaining_count(t)


local n = 0
for _ in pairs(t) do n = n + 1 end
return n
end

while rec and rec > 0 do


local pid = players_table:GetRecordFieldValue(rec, "playerid")
local pid_num = tonumber(pid) or pid

local variation = target_ids[pid_num]


if variation ~= nil then
players_table:SetRecordFieldValue(rec, "hashighqualityhead", 1)
players_table:SetRecordFieldValue(rec, "headclasscode", 0)
players_table:SetRecordFieldValue(rec, "headvariation", variation)
updated_faces = updated_faces + 1
target_ids[pid_num] = nil
if remaining_count(target_ids) == 0 then
end
end

if tattoos_left_arm[pid_num] then
players_table:SetRecordFieldValue(rec, "tattooleftarm",
tattoos_left_arm[pid_num])
updated_tattoos = updated_tattoos + 1
end
if tattoos_right_arm[pid_num] then
players_table:SetRecordFieldValue(rec, "tattoorightarm",
tattoos_right_arm[pid_num])
updated_tattoos = updated_tattoos + 1
end
if tattoos_left_leg[pid_num] then
players_table:SetRecordFieldValue(rec, "tattooleftleg",
tattoos_left_leg[pid_num])
updated_tattoos = updated_tattoos + 1
end
if tattoos_right_leg[pid_num] then
players_table:SetRecordFieldValue(rec, "tattoorightleg",
tattoos_right_leg[pid_num])
updated_tattoos = updated_tattoos + 1
end

rec = players_table:GetNextValidRecord()
end

MessageBox("HQ Faces + Tattoos Applied",


string.format("Faces Updated: %d\nTattoos Updated: %d", updated_faces,
updated_tattoos))

You might also like