IMG

 
IMG
IMG   IMG
  Welcome to GTAForums! Be sure to check out the Grand Theft Auto V Forum.

You are not registered! (If you are, click here to login) Registering is fast, free and easy and allows you to instantly reply to any topic on GTAForums.
Why wait? Click here to register your own unique username and become part of the ever-growing community!


( Log In | Register | Revalidate Validation E-mail )
Quick Log-In:
  IMG
       
>
Forum Rules GTA Modification Forums

Post mod/code requests in the Mod Requests topic

Post mod releases in the Mod Showroom

Read the Modding Rules BEFORE posting!

GTAGarage.com
free mod hosting from GTANet, simply login with your GTAForums account details

GTAModding.com
GTANet's modding wiki

GTA Modding Chatroom
provided by irc.gtanet.com (Don't have an IRC client? Click here)


  Reply to this topicStart new topicStart Poll

 how do I use this code

 
brandon236  
Posted: Monday, Aug 6 2012, 09:06
Quote Post


Crackhead
Group Icon
Group: Members
Joined: May 27, 2012

XXXXX



So I found some code that is supposed to remove all the peds and all the traffic from the game. What I did was a created a text document and pasted the code on it. I named it commandline and put it in my main GTA IV folder. Now that didn't work. How do you use this type of code

Code:
01EB: set_traffic_density_multiplier_to 0.0
06D0: enable_emergency_traffic 0
06D7: enable_train_traffic 0
0923: enable_air_traffic 0
096A: enable_flying_helis 0
099E: enable_police_patrols 0
072C: generate_police_bikes 0
03DE: set_pedestrians_density_multiplier_to 0.0

PM
  Top
 

 
_Charger_  
Posted: Monday, Aug 6 2012, 13:44
Quote Post


Germany
Group Icon
Group: Members
Joined: Apr 1, 2010

gr.gif

XXXXX



for me it looks like natives... only with external code you can try to call them. use scripthook for it....
PM
  Top
 

 
brandon236  
Posted: Tuesday, Aug 7 2012, 06:28
Quote Post


Crackhead
Group Icon
Group: Members
Joined: May 27, 2012

XXXXX



I've tried using scripthook and it didn't work. Although I'm new to scripthook so I'm not sure if I used it right. Also someone said this works so if I use it correctly then it should work.
PM
  Top
 

 
brandon236  
Posted: Tuesday, Aug 7 2012, 23:27
Quote Post


Crackhead
Group Icon
Group: Members
Joined: May 27, 2012

XXXXX



it's still not working
PM
  Top
 

 
Skorpro  
Posted: Friday, Aug 10 2012, 22:40
Quote Post


GTAholiker
Group Icon
Group: Members
Joined: Jul 19, 2009

eu.gif

XXXXX



Hi,

try this...

ScriptHook (C++)

CustomFiberThread.h
CODE

void SkorproTrafficControl();


CustomFiberThread.cpp
CODE

// Global
int tr_changeTraffic = 1;


CODE

void CustomFiberThread::SkorproTrafficControl()
{
switch(tr_changeTraffic)
{
case 1:
 f32 tcx, tcy, tcz;
 GetCharCoordinates(GetPlayerPed(), &tcx, &tcy, &tcz);
 ClearAreaOfCars(tcx, tcy, tcz, 400.0f);
 ClearAreaOfChars(tcx, tcy, tcz, 400.0f);
 ClearAreaOfCops(tcx, tcy, tcz, 400.0f);
 tr_changeTraffic = 2;
 PrintStringWithLiteralStringNow("STRING","No Traffic",3000,1);
 SetCarDensityMultiplier(0.00);
 SetPedDensityMultiplier(0.00);
 SwitchGarbageTrucks(0);
 SetRandomCarDensityMultiplier(0.00);
 SetParkedCarDensityMultiplier(2.25);
 AllowEmergencyServices(0);
               SwitchRandomBoats(0);
 SwitchRandomTrains(0);
 SwitchAmbientPlanes(0);
 break;
case 2:
 tr_changeTraffic = 3;
 PrintStringWithLiteralStringNow("STRING","Low Traffic",3000,1);
 SetCarDensityMultiplier(0.25);
 SetPedDensityMultiplier(0.50);
 SwitchGarbageTrucks(1);
 SetRandomCarDensityMultiplier(0.25);
 SetParkedCarDensityMultiplier(2.25);
 AllowEmergencyServices(1);
               SwitchRandomBoats(1);
 SwitchRandomTrains(1);
 SwitchAmbientPlanes(1);
 break;
case 3:
 tr_changeTraffic = 4;
 PrintStringWithLiteralStringNow("STRING","Standard",3000,1);
 SetCarDensityMultiplier(1.25);
 SetPedDensityMultiplier(1.50);
 SwitchGarbageTrucks(1);
 SetRandomCarDensityMultiplier(1.25);
 SetParkedCarDensityMultiplier(2.25);
 AllowEmergencyServices(1);
 break;
case 4:
 tr_changeTraffic = 5;
 PrintStringWithLiteralStringNow("STRING","High Traffic",3000,1);
 SetCarDensityMultiplier(3.25);
 SetPedDensityMultiplier(3.50);
 SwitchGarbageTrucks(1);
 SetRandomCarDensityMultiplier(3.25);
 SetParkedCarDensityMultiplier(2.25);
 AllowEmergencyServices(1);
 break;
case 5:
 tr_changeTraffic = 1;
 PrintStringWithLiteralStringNow("STRING","Full Traffic",3000,1);
 SetCarDensityMultiplier(7.25);
 SetPedDensityMultiplier(7.50);
 SwitchGarbageTrucks(1);
 SetRandomCarDensityMultiplier(7.25);
 SetParkedCarDensityMultiplier(2.25);
 AllowEmergencyServices(1);
 break;
default:
 Wait(10);
}
}


CODE

void CustomFiberThread::RunScript()
{
while(IsThreadAlive())
{
if (GetKeyState(16) && (GetKeyState(84) < 0))   // Shift + Key T !
{
SkorproTrafficControl();
Wait(200);
}
}
}


Or simply download my Traffic Control mod! wink.gif

Have fun...
Users WebsitePM
  Top
 

 

1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)

0 Members:

Topic Options Reply to this topicStart new topicStart Poll
Search topic for posted by (exact match)



 
IMG IMG