CLEO Help [LOCK] Weapon ID to Weapon Name ? [LOCK]

CLEO related
Status
Not open for further replies.

Grubitsh

Active member
Joined
Jul 28, 2014
Messages
104
Reaction score
0
Hi,

I want to have the weapon name with from a known weapon id. I could do 50 times [if actor 0@ current_weapon == weap_id then string] but I wonder if their was a smarter way to do it ?

Any suggestion to have weapon name easier ?
 

0B36

Expert
Joined
Jan 6, 2014
Messages
1,324
Reaction score
8
Re: Weapon ID to Weapon Name ?

through this snippet possibly

Code:
call @get_weapon_name_by_id 1 0@ to 1@

:get_weapon_name_by_id
0AC6: 1@ = label @weapons offset
0@ *= 19
005A: 1@ += 0@ // (int)
ret 1 1@

:weapons
hex
"Duke" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 0 }
"Brass Knuckles" 00 00 00 00 00 { 1 }
"Golf Club" 00 00 00 00 00 00 00 00 00 00 { 2 }
"Nite Stick" 00 00 00 00 00 00 00 00 00 { 3 }
"Knife" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 4 }
"Baseball" 00 00 00 00 00 00 00 00 00 00 00 { 5 }
"Shovel" 00 00 00 00 00 00 00 00 00 00 00 00 00 { 6 }
"Pool Cue" 00 00 00 00 00 00 00 00 00 00 00 { 7 }
"Katana" 00 00 00 00 00 00 00 00 00 00 00 00 00 { 8 }
"Chainsaw" 00 00 00 00 00 00 00 00 00 00 00 { 9 }
"Dildo" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 10 }
"Dildo" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 11 }
"Dildo" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 12 }
"Dildo" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 13 }
"Flowers" 00 00 00 00 00 00 00 00 00 00 00 00 { 14 }
"Cane" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 15 }
"Grenade" 00 00 00 00 00 00 00 00 00 00 00 00 { 16 }
"Tear Gas" 00 00 00 00 00 00 00 00 00 00 00 { 17 }
"Molotov" 00 00 00 00 00 00 00 00 00 00 00 00 { 18 }
 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 19 }
 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 20 }
 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 21 }
"Pistol" 00 00 00 00 00 00 00 00 00 00 00 00 00 { 22 }
"Silencer" 00 00 00 00 00 00 00 00 00 00 00 { 23 }
"Deagle" 00 00 00 00 00 00 00 00 00 00 00 00 00 { 24 }
"Shotgun" 00 00 00 00 00 00 00 00 00 00 00 00 { 25 }
"SawnOff" 00 00 00 00 00 00 00 00 00 00 00 00 { 26 }
"Spas12" 00 00 00 00 00 00 00 00 00 00 00 00 00 { 27 }
"Tec9" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 28 }
"MP5" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 29 }
"AK47" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 30 }
"M4" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 31 }
"Mac10" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 32 }
"Rifle" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 33 }
"Sniper" 00 00 00 00 00 00 00 00 00 00 00 00 00 { 34 }
"Rocket Launcher" 00 00 00 00 { 35 }
"HS Rocket Launcher" 00 { 36 }
"Flamethrower" 00 00 00 00 00 00 00 { 37 }
"Minigun" 00 00 00 00 00 00 00 00 00 00 00 00 { 38 }
"C4" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 39 }
"Detonator" 00 00 00 00 00 00 00 00 00 00 { 40 }
"Spray" 00 00 00 00 00 00 00 00 00 00 00 00 00 00 { 41 }
"Fire Extinguisher" 00 00 { 42 }
"Camera" 00 00 00 00 00 00 00 00 00 00 00 00 00 { 43 }
"Nightvision" 00 00 00 00 00 00 00 00 { 44 }
"Infrared Vision" 00 00 00 00 { 45 }
"Parachute" 00 00 00 00 00 00 00 00 00 00 { 46 }
end

Written by some russian guy on BH.
 
Status
Not open for further replies.
Top