Jump to content
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. Los Santos Drug Wars
      2. Updates
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Red Dead Online

      1. Blood Money
      2. Frontier Pursuits
      3. Find Lobbies & Outlaws
      4. Help & Support
    3. Crews

    1. Grand Theft Auto Series

      1. Bugs*
      2. St. Andrews Cathedral
    2. GTA VI

    3. GTA V

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

      1. The Lost and Damned
      2. The Ballad of Gay Tony
      3. Guides & Strategies
      4. Help & Support
    5. GTA San Andreas

      1. Classic GTA SA
      2. Guides & Strategies
      3. Help & Support
    6. GTA Vice City

      1. Classic GTA VC
      2. Guides & Strategies
      3. Help & Support
    7. GTA III

      1. Classic GTA III
      2. Guides & Strategies
      3. Help & Support
    8. Portable Games

      1. GTA Chinatown Wars
      2. GTA Vice City Stories
      3. GTA Liberty City Stories
    9. Top-Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    1. Red Dead Redemption 2

      1. PC
      2. Help & Support
    2. Red Dead Redemption

    1. GTA Mods

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Red Dead Mods

      1. Documentation
    3. Mod Showroom

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

      1. Design Your Own Mission
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Rockstar Games

    2. Rockstar Collectors

    1. Off-Topic

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

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

    2. Forum Support

    3. Suggestions

SA - One wanted star melee fix


thalilmythos
 Share

Recommended Posts

thalilmythos

So, in my habit of fixing sh*t no one seems to notice i came across a good fix.

 

Have you noticed that. when you have only a one star wanted level and a few cops arrive, only one of them fights you? even the bike cop arrives and they just start walking away casually like you are not fighting one of them right there.

 

In case you are the type to start BLASTING fools before even trying to square up, here, see for yourself.

 

mWUpRQv.png

 

So, since i like a little of POLICE BRUTALITY myself, i fixed this, because, ilike fighting, and ilike fighting cops, so, here, this is what will happen now.

 

2Ym7Iro.png

 

NOW you have a reason to start blasting.

 

HERE:

 

https://sharemods.com/aut41pc3n33e/CLEO_Cops_melee_fix.7z.html
 

Edited by thalilmythos
Link to comment
Share on other sites

Someone will probably call racism at one point, I'll just say this: Awesome 😎

  • Like 2
Link to comment
Share on other sites

Junior_Djjr

You are using 0AE1: in the wrong way, you need to use "find_next 0" first to get the first ped on pool, so you use "find_next 1" to get the next one, otherwise your mod may have problems catching peds, especially if other mods also use this command.

 

The best way to use it:

if 0AE1: 0@ = random_actor_near_point 1@ 2@ 3@ in_radius 10.0 find_next 0 pass_deads 1 //IF and SET 
then
    repeat
        gosub @DoSomethingWithThisActor
    until 8AE1: not 0@ = random_actor_near_point 1@ 2@ 3@ in_radius 10.0 find_next 1 pass_deads 1 //IF and SET 
end

 

Link to comment
Share on other sites

thalilmythos
39 minutes ago, Junior_Djjr said:

You are using 0AE1: in the wrong way, you need to use "find_next 0" first to get the first ped on pool, so you use "find_next 1" to get the next one, otherwise your mod may have problems catching peds, especially if other mods also use this command.

 

The best way to use it:

if 0AE1: 0@ = random_actor_near_point1@ 2@ 3@ in_radius10.0 find_next0 pass_deads1 //IF and SET 
then
    repeat
        gosub@DoSomethingWithThisActor
    until8AE1: not 0@ = random_actor_near_point1@ 2@ 3@ in_radius10.0 find_next1 pass_deads1 //IF and SET 
end

 

You said this to me before, but i don't quite understand yet, that problems what may bring, can you explain to me better?

Edited by thalilmythos
Link to comment
Share on other sites

Junior_Djjr
24 minutes ago, thalilmythos said:

You said this to me before, but i don't quite understand yet, that problems what may bring, can you explain to me better?

When you use "find_next 0" the mod will notify the CLEO Library that you are initiating the pedestrian list (or cars), so the search will be reset to the first pedestrian of the game list, and when using "find_next 1" will go to the next one etc.

If you are not telling CLEO to return to the first ped, it will return the current last one, for example the last one that another mod got.

 

Try to understand the basics but you don't need to understand exactly, just use the code I sent you and will be all fine. Otherwise at some point you will go through headaches and people reporting that your mod is not working or not all the peds are affected.

 

This command is dangerous, even more so if you use "wait" inside the loop. 

This pedestrian list is shared with all cleo scripts, if another is using at the same time as you, when the script finds a "wait" and the game processes other scripts, and this script also uses "wait", the scripts will share the same list at same time. If both were "wait 0", your script will take one ped, the other will take another, so both scripts will control half the peds and not know that the other half exists.

If your mod is working, it's luck, it can cause conflicts with other mods also wrong.

 

If you need to use "wait" in the loop, you will need to use a low level (and very ugly) code:

{$cleo}
0000:

while true
    wait 0     
    0A8D: 29@ = read_memory 0xB74490 size 4 virtual_protect 0
    000A: 29@ += 0x4
    0A8D: 29@ = read_memory 29@ size 4 virtual_protect 0
    for 30@ = 0 to 35584 step 0x100
        0A8D: 31@ = read_memory 29@ size 1 virtual_protect 0
        000A: 29@ += 0x1
        if and
        0029:  31@ >= 0x00 
        001B:  0x80 > 31@
        then 
            005A: 31@ += 30@
            
            00A0: store_actor 31@ position_to 1@ 2@ 3@
            016F: create_particle 3 rotation_factor 0.0 size 2.0 intensity 255 flags 0 255 0 at 1@ 2@ 3@
        end
    end
end

You can use a wait, and will work perfectly (you will notice that the light will change the ped each frame, i.e. each frame will control one ped, useful for slow scripts to not impact FPS)

{$cleo}
0000:

while true
    wait 0     
    0A8D: 29@ = read_memory 0xB74490 size 4 virtual_protect 0
    000A: 29@ += 0x4
    0A8D: 29@ = read_memory 29@ size 4 virtual_protect 0
    for 30@ = 0 to 35584 step 0x100
        0A8D: 31@ = read_memory 29@ size 1 virtual_protect 0
        000A: 29@ += 0x1
        if and
        0029:  31@ >= 0x00 
        001B:  0x80 > 31@
        then 
            005A: 31@ += 30@
            
            wait 0
            
            00A0: store_actor 31@ position_to 1@ 2@ 3@
            016F: create_particle 3 rotation_factor 0.0 size 2.0 intensity 255 flags 0 255 0 at 1@ 2@ 3@
        end
    end
end

 

Edited by Junior_Djjr
Link to comment
Share on other sites

thalilmythos
8 hours ago, TWIST_OF_HATE said:

Worth to merge this in SilentPatch ?

No, let's leave silent alone, he's had enough requests for a lifetime.

 

I believe this was a choice of design, so it's okay as it is by default in the game, however i like the fix, and besides, as you can see, there's a problem with the way it is scripted

 

It works and doesn't crash the game tho, so you can still use it, i'll fix that little scripting thing later, shouldn't make a difference for now

Edited by thalilmythos
  • Like 3
Link to comment
Share on other sites

  • 2 weeks later...

@thalilmythos thread simulator:

 

Match any of those sentences:

 

Quote

Worth to merge this in

 

 

with any of those sentences:

 

Quote

SilentPatch
MixSets
Limit Adjuster
your other mods
Gangster Sit Fix

 

 

Edited by Silent
  • Like 2
Link to comment
Share on other sites

thalilmythos
2 hours ago, Silent said:

@thalilmythos thread simulator:

 

Match any of those sentences:

 

 

with any of those sentences:

 

 

Not even one of my mods is good enough to merge with the godly gangster sit fix, Silent sir...

Edited by thalilmythos
Link to comment
Share on other sites

Let's just merge all mods in existence together into 1 because it magically makes it better and allows more choice for the end user 🙄...

 

I guess it's just really hard to install 2 mods seperately?

Link to comment
Share on other sites

Everyone is praising this mod, hope this bug report will not make me a hater

Well, even when star is gone, still the police comes near you and beat you and it's a nightmare during missions.

When even the car color is changed the cop still comes to beat you.

Link to comment
Share on other sites

thalilmythos
16 hours ago, kkjj said:

Everyone is praising this mod, hope this bug report will not make me a hater

Well, even when staris gone, still the police comes near you and beat you and it's a nightmare during missions.

When even the car color is changed the cop still comes to beat you.

Yeah yeah i know, i don't mind it, you ain't no hater my man, purely objective productive criticism, i'll see what i can do about that, but to be quite honest with you, i was not thinking about fixing that, with the police brutality thing in my mind i was thinking like, this guys don't care about an arrest warrant or something like that, anyway i'll see what i can do about it

Edited by thalilmythos
  • Like 2
Link to comment
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
 Share

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

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