Quantcast
Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
    1. Welcome to GTAForums!   (85,500 visits to this link)

    2. News

    1. GTA Online

      1. Find Lobbies & Players
      2. Guides & Strategies
      3. Vehicles
      4. Content Creator
      5. Help & Support
    2. Crews

      1. Events
      2. Recruitment
    1. Grand Theft Auto Series

    2. GTA Next

    3. GTA V

      1. PC
      2. Guides & Strategies
      3. Help & Support
    4. GTA IV

      1. Episodes from Liberty City
      2. Multiplayer
      3. Guides & Strategies
      4. Help & Support
      5. GTA Mods
    5. GTA Chinatown Wars

    6. GTA Vice City Stories

    7. GTA Liberty City Stories

    8. GTA San Andreas

      1. Guides & Strategies
      2. Help & Support
      3. GTA Mods
    9. GTA Vice City

      1. Guides & Strategies
      2. Help & Support
      3. GTA Mods
    10. GTA III

      1. Guides & Strategies
      2. Help & Support
      3. GTA Mods
    11. Top Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    12. Wiki

      1. Merchandising
    1. GTA Modding

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Mod Showroom

      1. Scripts & Plugins
      2. Maps
      3. Total Conversions
      4. Vehicles
      5. Textures
      6. Characters
      7. Tools
      8. Other
      9. Workshop
    3. Featured Mods

      1. DYOM
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Red Dead Redemption 2

    2. Red Dead Redemption

    3. Rockstar Games

    1. Off-Topic

      1. General Chat
      2. Gaming
      3. Technology
      4. Programming
      5. Movies & TV
      6. Music
      7. Sports
      8. Vehicles
    2. Expression

      1. Graphics / Visual Arts
      2. GFX Requests & Tutorials
      3. Writers' Discussion
      4. Debates & Discussion
    1. Forum Support

    2. Site Suggestions

Crspy

Gangs CarColor Customizer

Recommended Posts

Crspy

Since this wasn't done before and i would love to do it actually since i like Saints row style , decided to make all the gangs car colors ( even the unused gangs ) completely customizable including the primary and secondary color with a simple INI file. ;)

 

just like that :

 

;--------------------
; Configuration file for mod Gangs CarColor Customizer created by Crspy
;
; you can check the color ids here : http://wiki.sa-mp.com/wiki/Vehicle_Color_IDs
;
; just put the id of your desired color :)
;
;--------------------
;
[ballas]
Primary = 85
Secondary = 85
;
[Grove]
Primary = 86
Secondary = 86
;
[Vagos]
Primary = 6
Secondary = 6
;
[sFRifa]
Primary = 2
Secondary = 2
;
[DaNangBoys]
Primary = 69
Secondary = 69
;
[italianMafia]
Primary = 127
Secondary = 127
;
[Triads]
Primary = 17
Secondary = 17
;
[Aztecas]
Primary = 2
Secondary = 2
;
[RussianMafia]
Primary = 118
Secondary = 118
;
[bikers]
Primary = 0
Secondary = 0
;

 

 

 

Source:

 

 


{$cleo}
0000:
if 8AAB: not file_exists "CLEO\GANGSCC.INI"
then
0ACD: show_text_highpriority "UNABLE TO LOAD ~B~'CLEO/GANGSCC.INI'" time 4000
0A93: end_custom_thread
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "BALLAS" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "BALLAS" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "GROVE" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "GROVE" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "VAGOS" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "VAGOS" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "SFRIFA" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "SFRIFA" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "DaNangBoys" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "DaNangBoys" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "ITALIANMAFIA" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "ITALIANMAFIA" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "TRIADS" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "TRIADS" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "AZTECAS" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "AZTECAS" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "RUSSIANMAFIA" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "RUSSIANMAFIA" key "SECONDARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "BIKERS" key "PRIMARY"
then
end
if 8AF0: not [email protected] = get_int_from_ini_file "CLEO\GANGSCC.INI" section "BIKERS" key "SECONDARY"
then
end
{
A loop that passes through all cars (on the street) structures and check if their Driver's Pedtype is one of the gangs' then execute the car color change, once !
0xB74494 - Contains a pointer to main struct
}
while true
wait 0
0A8D: [email protected] = read_memory 0xB74494 size 4 virtual_protect 0
0A8D: [email protected] = read_memory [email protected] size 4 virtual_protect 0
for [email protected] = 0 to 27904 step 0x100
0A8D: [email protected] = read_memory [email protected] size 1 virtual_protect 0
000A: [email protected] += 0x1
if and
0029: [email protected] >= 0x00
001B: 0x80 > [email protected]
then
03F3: get_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
056D: actor [email protected] defined
jf continue
089F: get_actor [email protected] pedtype_to [email protected]
if and
jf continue
if
0AB1: call_scm_func @Check_VehModel_Belong_to_GangCarGrp{__VehicleModel__,,__GangID__} 2 [email protected] [email protected]
jf continue
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
then
if or
then
0229: set_car [email protected] primary_color_to [email protected] secondary_color_to [email protected]
end
end
end
end
end
:Check_VehModel_Belong_to_GangCarGrp{__VehicleModel__,,__GangID__}
0A8D: [email protected] = read_memory 0x40ACE4 size 4 virtual_protect 0
for [email protected] = 0 to 22
0A8D: [email protected] = read_memory [email protected] size 2 virtual_protect 0
if
[email protected] <> 2000 // 2000 means no more vehicles in this Car group
jf break
if
then
0AB2: ret 0 // return true
end
end
059A: return_false
0AB2: ret 0 // return false

 

 

 

Download Link : GangsCC Customizer.7z

Edited by Crspy

Share this post


Link to post
Share on other sites
Priest14/88

<3

Share this post


Link to post
Share on other sites
Crspy

Mod updated :

 

1.made some optimizations ( less loops )

 

2. fixed the bug that prevented Russian mafia & bikers car colors from being changed by script. ( thanks to kane49 for reporting this )

Edited by Crspy

Share this post


Link to post
Share on other sites
iiCriminnaaL 49

This can be a replacement of the need of adding unique cars for the gangs (like Cholo Sabre, Mafia Sentinel, etc) for SA gangs, in proper way that fits with the game's atmosphere.

 

Great! Good job ;)

 

Btw, the only gang vehicle colors which was bugged were the bikers', Russian Mafia's car colors worked already :p

Edited by Kane49

Share this post


Link to post
Share on other sites
iiCriminnaaL 49

Is it only in my game or it doesn't work with Da Nang Boys? Their vehicles are always black, regardless of which color I set their vehicles to.

Share this post


Link to post
Share on other sites
Crspy

Ops it was a small mistake " getting float number instead of integer " :monocle:

 

Link updated

 

Also , i recreated the script in a high syntax language and less loops so it should be more optimized , source available at the first post.

Edited by Crspy

Share this post


Link to post
Share on other sites
iiCriminnaaL 49

Btw, found another issue. It's caused due to the way mod works on, but I'll state it in case it can be fixed.

 

The mod is set like: Vehicle that's driven by a gang member its color will be the gang car color, that causes when a gang member steals a vehicle, whatever its colors are, its colors will turn to the gang's car colors like it's set in the ini file, no matter if it's a gang car or a normal car.

 

Happened with me when a Balla drove my quad bike, and also when he drove some other pedestrian's car.

Edited by Kane49

Share this post


Link to post
Share on other sites
Crspy

oh it's not actually a bug but there's no way ( i know ) to execute the script on created cars only and not existant ones ...... the script loops through all cars that exist on the street.

i can live with that though since gangs rarely steal vehicles.

 

Link updated , Made more optimization to the script , previously it would change the cars color no matter if it was already changed or not ... now it will check if the car was already changed or not before doing that... which results in the script very light weight ;)

Edited by Crspy

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.