Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. Los Santos Tuners
      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. GTA San Andreas

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

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

      1. Classic GTA III
      2. Guides & Strategies
      3. Help & Support
    4. Bugs*

    1. Grand Theft Auto Series

      1. 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. Portable Games

      1. GTA Chinatown Wars
      2. GTA Vice City Stories
      3. GTA Liberty City Stories
    6. 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

      1. GTANet 20th Anniversary
    2. Support

    3. Suggestions

Replace bullets with objects/vehicles?


Reck1501
 Share

Recommended Posts

How do you replace bullets with objects or vehicles? Such as when you shoot, it shoots a dildo instead of the bullet model (lel)

Link to comment
Share on other sites

FixingG00D

I hope someone figures this one out. Has great potential as a mod. Someones done a vehicle canon mod already.

Link to comment
Share on other sites

flocraftMods

I made the vehicle cannon but it just shoot with vehicles additionally

Link to comment
Share on other sites

I'd like to make my own mod, I know alot of menus already have these types of features, but I find coding these mods very interesting

 

I made the vehicle cannon but it just shoot with vehicles additionally

 

How did you do that? :p

Edited by Reck1501
Link to comment
Share on other sites

flocraftMods

I set a car in front of the player and set the speed very fast

Edited by flocraftMods
Link to comment
Share on other sites

hopefully we get source

Edited by Marqurs
Link to comment
Share on other sites

flocraftMods

Ok here is the main code to shoot with random vehicles:

LPCSTR vehicleModels[188] = {"ARMYTANKER", "ASTEROPE", "AIRTUG", "AMBULANCE", "BARRACKS", "BARRACKS2", "BALLER", "BALLER2",	"BJXL", "BANSHEE", "BFINJECTION", "BIFF", "BLAZER", "BLAZER2", "BLAZER3", "BISON", "BISON2",	"BISON3", "BOXVILLE", "BOXVILLE2", "BOXVILLE3", "BOBCATXL", "BODHI2", "BUCCANEER", "BUFFALO", "BUFFALO2", "BULLDOZER",	"BULLET", "BURRITO", "BURRITO2", "BURRITO3", "BURRITO4", "BURRITO5", "CAVALCADE", "CAVALCADE2", "POLICET",	"GBURRITO", "CABLECAR", "CADDY", "CADDY2", "CAMPER", "CARBONIZZARE", "CHEETAH", "COMET2", "COGCABRIO", "COQUETTE",	"CUTTER", "GRESLEY", "DILETTANTE", "DILETTANTE2", "DUNE", "DUNE2", "HOTKNIFE", "DLOADER", "DUBSTA", "DUBSTA2",	"DUMP", "RUBBLE", "DOCKTUG", "DOMINATOR", "EMPEROR", "EMPEROR2", "EMPEROR3", "ENTITYXF", "EXEMPLAR", "ELEGY2",	"F620", "FBI", "FBI2", "FELON", "FELON2", "FELTZER2", "FIRETRUK", "FLATBED", "FORKLIFT", "FQ2",	"FUSILADE", "FUGITIVE", "FUTO", "GRANGER", "GAUNTLET", "HABANERO", "HAULER", "HANDLER", "INFERNUS", "INGOT",	"INTRUDER", "ISSI2", "JACKAL", "JOURNEY", "JB700", "KHAMELION", "LANDSTALKER", "LGUARD", "MANANA", "MESA",	"MESA2", "MESA3", "CRUSADER", "MINIVAN", "MIXER", "MIXER2", "MONROE", "MOWER", "MULE", "MULE2",	"ORACLE", "ORACLE2", "PACKER", "PATRIOT", "PBUS", "PENUMBRA", "PEYOTE", "PHANTOM", "PHOENIX", "PICADOR",	"POUNDER", "POLICE", "POLICE4", "POLICE2", "POLICE3", "POLICEOLD1", "POLICEOLD2", "PONY", "PONY2", "PRAIRIE",	"PRANGER", "PREMIER", "PRIMO",  "RANCHERXL", "RANCHERXL2", "RAPIDGT", "RAPIDGT2", "RADI", "RATLOADER",	"REBEL", "REGINA", "REBEL2", "RENTALBUS", "RUINER", "RUMPO", "RUMPO2", "RHINO", "RIOT", "RIPLEY",	"ROCOTO", "ROMERO", "SABREGT", "SADLER", "SADLER2", "SANDKING", "SANDKING2", "SCHAFTER2", "SCHWARZER", "SCRAP",	"SEMINOLE", "SENTINEL", "SENTINEL2", "ZION", "ZION2", "SERRANO", "SHERIFF", "SHERIFF2", "SPEEDO", "SPEEDO2",	"STANIER", "STINGER", "STINGERGT", "STOCKADE", "STOCKADE3", "STRATUM", "SULTAN", "SUPERD", "SURANO", "SURFER",	"SURFER2", "SURGE", "TAILGATER", "TAXI", "TRASH", "TRACTOR", "TRACTOR2", "TRACTOR3", "TOWTRUCK",	"TOWTRUCK2","UTILLITRUCK", "UTILLITRUCK2", "UTILLITRUCK3"};float offset;Ped playerPed = PLAYER::PLAYER_PED_ID();        DWORD model = GAMEPLAY::GET_HASH_KEY((char *)vehicleModels[rand() % 188]);STREAMING::REQUEST_MODEL(model);while (!STREAMING::HAS_MODEL_LOADED(model)) WAIT(0);if (STREAMING::IS_MODEL_IN_CDIMAGE(model) && STREAMING::IS_MODEL_A_VEHICLE(model)){    Vector3 dim1, dim2;    GAMEPLAY::GET_MODEL_DIMENSIONS(model, &dim1, &dim2);    offset = dim2.y * 1.6;}   Vector3 dir = ENTITY::GET_ENTITY_FORWARD_VECTOR(playerPed);Vector3 pos = ENTITY::GET_ENTITY_COORDS(PLAYER::PLAYER_PED_ID(), 1);float rot = (ENTITY::GET_ENTITY_ROTATION(playerPed, 0)).z;Vehicle veh = VEHICLE::CREATE_VEHICLE(model, pos.x + (dir.x * offset) , pos.y + (dir.y * offset) , pos.z , rot, 1, 1);VEHICLE::SET_VEHICLE_ON_GROUND_PROPERLY(veh);        VEHICLE::SET_VEHICLE_FORWARD_SPEED(veh, 70.0);   STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(model);ENTITY::SET_VEHICLE_AS_NO_LONGER_NEEDED(&veh);

I will try to shoot 3D in vehicle cannon v2 :lol:

Edited by flocraftMods
Link to comment
Share on other sites

Ok here is the main code to shoot with random vehicles:

LPCSTR vehicleModels[188] = {"ARMYTANKER", "ASTEROPE", "AIRTUG", "AMBULANCE", "BARRACKS", "BARRACKS2", "BALLER", "BALLER2",	"BJXL", "BANSHEE", "BFINJECTION", "BIFF", "BLAZER", "BLAZER2", "BLAZER3", "BISON", "BISON2",	"BISON3", "BOXVILLE", "BOXVILLE2", "BOXVILLE3", "BOBCATXL", "BODHI2", "BUCCANEER", "BUFFALO", "BUFFALO2", "BULLDOZER",	"BULLET", "BURRITO", "BURRITO2", "BURRITO3", "BURRITO4", "BURRITO5", "CAVALCADE", "CAVALCADE2", "POLICET",	"GBURRITO", "CABLECAR", "CADDY", "CADDY2", "CAMPER", "CARBONIZZARE", "CHEETAH", "COMET2", "COGCABRIO", "COQUETTE",	"CUTTER", "GRESLEY", "DILETTANTE", "DILETTANTE2", "DUNE", "DUNE2", "HOTKNIFE", "DLOADER", "DUBSTA", "DUBSTA2",	"DUMP", "RUBBLE", "DOCKTUG", "DOMINATOR", "EMPEROR", "EMPEROR2", "EMPEROR3", "ENTITYXF", "EXEMPLAR", "ELEGY2",	"F620", "FBI", "FBI2", "FELON", "FELON2", "FELTZER2", "FIRETRUK", "FLATBED", "FORKLIFT", "FQ2",	"FUSILADE", "FUGITIVE", "FUTO", "GRANGER", "GAUNTLET", "HABANERO", "HAULER", "HANDLER", "INFERNUS", "INGOT",	"INTRUDER", "ISSI2", "JACKAL", "JOURNEY", "JB700", "KHAMELION", "LANDSTALKER", "LGUARD", "MANANA", "MESA",	"MESA2", "MESA3", "CRUSADER", "MINIVAN", "MIXER", "MIXER2", "MONROE", "MOWER", "MULE", "MULE2",	"ORACLE", "ORACLE2", "PACKER", "PATRIOT", "PBUS", "PENUMBRA", "PEYOTE", "PHANTOM", "PHOENIX", "PICADOR",	"POUNDER", "POLICE", "POLICE4", "POLICE2", "POLICE3", "POLICEOLD1", "POLICEOLD2", "PONY", "PONY2", "PRAIRIE",	"PRANGER", "PREMIER", "PRIMO",  "RANCHERXL", "RANCHERXL2", "RAPIDGT", "RAPIDGT2", "RADI", "RATLOADER",	"REBEL", "REGINA", "REBEL2", "RENTALBUS", "RUINER", "RUMPO", "RUMPO2", "RHINO", "RIOT", "RIPLEY",	"ROCOTO", "ROMERO", "SABREGT", "SADLER", "SADLER2", "SANDKING", "SANDKING2", "SCHAFTER2", "SCHWARZER", "SCRAP",	"SEMINOLE", "SENTINEL", "SENTINEL2", "ZION", "ZION2", "SERRANO", "SHERIFF", "SHERIFF2", "SPEEDO", "SPEEDO2",	"STANIER", "STINGER", "STINGERGT", "STOCKADE", "STOCKADE3", "STRATUM", "SULTAN", "SUPERD", "SURANO", "SURFER",	"SURFER2", "SURGE", "TAILGATER", "TAXI", "TRASH", "TRACTOR", "TRACTOR2", "TRACTOR3", "TOWTRUCK",	"TOWTRUCK2","UTILLITRUCK", "UTILLITRUCK2", "UTILLITRUCK3"};float offset;Ped playerPed = PLAYER::PLAYER_PED_ID();        DWORD model = GAMEPLAY::GET_HASH_KEY((char *)vehicleModels[rand() % 188]);STREAMING::REQUEST_MODEL(model);while (!STREAMING::HAS_MODEL_LOADED(model)) WAIT(0);if (STREAMING::IS_MODEL_IN_CDIMAGE(model) && STREAMING::IS_MODEL_A_VEHICLE(model)){    Vector3 dim1, dim2;    GAMEPLAY::GET_MODEL_DIMENSIONS(model, &dim1, &dim2);    offset = dim2.y * 1.6;}   Vector3 dir = ENTITY::GET_ENTITY_FORWARD_VECTOR(playerPed);Vector3 pos = ENTITY::GET_ENTITY_COORDS(PLAYER::PLAYER_PED_ID(), 1);float rot = (ENTITY::GET_ENTITY_ROTATION(playerPed, 0)).z;Vehicle veh = VEHICLE::CREATE_VEHICLE(model, pos.x + (dir.x * offset) , pos.y + (dir.y * offset) , pos.z , rot, 1, 1);VEHICLE::SET_VEHICLE_ON_GROUND_PROPERLY(veh);        VEHICLE::SET_VEHICLE_FORWARD_SPEED(veh, 70.0);   STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(model);ENTITY::SET_VEHICLE_AS_NO_LONGER_NEEDED(&veh);

I will try to shoot 3D in vehicle cannon v2 :lol:

 

Oh cool! Thanks for the source mate! :D Also looking forward to version 2 :p

Edited by Reck1501
Link to comment
Share on other sites

flocraftMods

I just linked it with the shooting buttons and the time between the cars is needed to load the models

Link to comment
Share on other sites

I just linked it with the shooting buttons and the time between the cars is needed to load the models

 

I figured it out myself :p But linking it with the shooting buttons is kind of.. unnecessary. It's better to use IS_PED_SHOOTING

Link to comment
Share on other sites

Rooster Mods

Ok here is the main code to shoot with random vehicles:

LPCSTR vehicleModels[188] = {"ARMYTANKER", "ASTEROPE", "AIRTUG", "AMBULANCE", "BARRACKS", "BARRACKS2", "BALLER", "BALLER2",	"BJXL", "BANSHEE", "BFINJECTION", "BIFF", "BLAZER", "BLAZER2", "BLAZER3", "BISON", "BISON2",	"BISON3", "BOXVILLE", "BOXVILLE2", "BOXVILLE3", "BOBCATXL", "BODHI2", "BUCCANEER", "BUFFALO", "BUFFALO2", "BULLDOZER",	"BULLET", "BURRITO", "BURRITO2", "BURRITO3", "BURRITO4", "BURRITO5", "CAVALCADE", "CAVALCADE2", "POLICET",	"GBURRITO", "CABLECAR", "CADDY", "CADDY2", "CAMPER", "CARBONIZZARE", "CHEETAH", "COMET2", "COGCABRIO", "COQUETTE",	"CUTTER", "GRESLEY", "DILETTANTE", "DILETTANTE2", "DUNE", "DUNE2", "HOTKNIFE", "DLOADER", "DUBSTA", "DUBSTA2",	"DUMP", "RUBBLE", "DOCKTUG", "DOMINATOR", "EMPEROR", "EMPEROR2", "EMPEROR3", "ENTITYXF", "EXEMPLAR", "ELEGY2",	"F620", "FBI", "FBI2", "FELON", "FELON2", "FELTZER2", "FIRETRUK", "FLATBED", "FORKLIFT", "FQ2",	"FUSILADE", "FUGITIVE", "FUTO", "GRANGER", "GAUNTLET", "HABANERO", "HAULER", "HANDLER", "INFERNUS", "INGOT",	"INTRUDER", "ISSI2", "JACKAL", "JOURNEY", "JB700", "KHAMELION", "LANDSTALKER", "LGUARD", "MANANA", "MESA",	"MESA2", "MESA3", "CRUSADER", "MINIVAN", "MIXER", "MIXER2", "MONROE", "MOWER", "MULE", "MULE2",	"ORACLE", "ORACLE2", "PACKER", "PATRIOT", "PBUS", "PENUMBRA", "PEYOTE", "PHANTOM", "PHOENIX", "PICADOR",	"POUNDER", "POLICE", "POLICE4", "POLICE2", "POLICE3", "POLICEOLD1", "POLICEOLD2", "PONY", "PONY2", "PRAIRIE",	"PRANGER", "PREMIER", "PRIMO",  "RANCHERXL", "RANCHERXL2", "RAPIDGT", "RAPIDGT2", "RADI", "RATLOADER",	"REBEL", "REGINA", "REBEL2", "RENTALBUS", "RUINER", "RUMPO", "RUMPO2", "RHINO", "RIOT", "RIPLEY",	"ROCOTO", "ROMERO", "SABREGT", "SADLER", "SADLER2", "SANDKING", "SANDKING2", "SCHAFTER2", "SCHWARZER", "SCRAP",	"SEMINOLE", "SENTINEL", "SENTINEL2", "ZION", "ZION2", "SERRANO", "SHERIFF", "SHERIFF2", "SPEEDO", "SPEEDO2",	"STANIER", "STINGER", "STINGERGT", "STOCKADE", "STOCKADE3", "STRATUM", "SULTAN", "SUPERD", "SURANO", "SURFER",	"SURFER2", "SURGE", "TAILGATER", "TAXI", "TRASH", "TRACTOR", "TRACTOR2", "TRACTOR3", "TOWTRUCK",	"TOWTRUCK2","UTILLITRUCK", "UTILLITRUCK2", "UTILLITRUCK3"};float offset;Ped playerPed = PLAYER::PLAYER_PED_ID();        DWORD model = GAMEPLAY::GET_HASH_KEY((char *)vehicleModels[rand() % 188]);STREAMING::REQUEST_MODEL(model);while (!STREAMING::HAS_MODEL_LOADED(model)) WAIT(0);if (STREAMING::IS_MODEL_IN_CDIMAGE(model) && STREAMING::IS_MODEL_A_VEHICLE(model)){    Vector3 dim1, dim2;    GAMEPLAY::GET_MODEL_DIMENSIONS(model, &dim1, &dim2);    offset = dim2.y * 1.6;}   Vector3 dir = ENTITY::GET_ENTITY_FORWARD_VECTOR(playerPed);Vector3 pos = ENTITY::GET_ENTITY_COORDS(PLAYER::PLAYER_PED_ID(), 1);float rot = (ENTITY::GET_ENTITY_ROTATION(playerPed, 0)).z;Vehicle veh = VEHICLE::CREATE_VEHICLE(model, pos.x + (dir.x * offset) , pos.y + (dir.y * offset) , pos.z , rot, 1, 1);VEHICLE::SET_VEHICLE_ON_GROUND_PROPERLY(veh);        VEHICLE::SET_VEHICLE_FORWARD_SPEED(veh, 70.0);   STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(model);ENTITY::SET_VEHICLE_AS_NO_LONGER_NEEDED(&veh);

I will try to shoot 3D in vehicle cannon v2 :lol:

Do u know how to make a car spawn?

Link to comment
Share on other sites

This is from the Native Trainer :whistle: (Don't know if it's the full code :panic: )

Correct me if it's wrong! :lol:

LPCSTR modelName = vehicleModels[carspawnActiveLineIndex][carspawnActiveItemIndex];            DWORD model = GAMEPLAY::GET_HASH_KEY((char *)modelName);            if (STREAMING::IS_MODEL_IN_CDIMAGE(model) && STREAMING::IS_MODEL_A_VEHICLE(model))            {                STREAMING::REQUEST_MODEL(model);                                while (!STREAMING::HAS_MODEL_LOADED(model)) WAIT(0);                Vector3 coords = ENTITY::GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER::PLAYER_PED_ID(), 0.0, 5.0, 0.0);                Vehicle veh = VEHICLE::CREATE_VEHICLE(model, coords.x, coords.y, coords.z, 0.0, 1, 1);                VEHICLE::SET_VEHICLE_ON_GROUND_PROPERLY(veh);                WAIT(0);                STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(model);                ENTITY::SET_VEHICLE_AS_NO_LONGER_NEEDED(&veh);                return true;            }
Edited by Unknown_Modder
Link to comment
Share on other sites

FreeOffset

Here is code I made to spawn pickup objects (40k money bag in this instance), can be anything from http://ecb2.biz/releases/GTAV/lists/pickups.txtand PICKUP_PARACHUTE will be a parachute in your inventory, not money.

if (featureMoneyGun) {        if (PED::IS_PED_SHOOTING(PLAYER::PLAYER_PED_ID()))        {            float tmp[3];            WEAPON::GET_PED_LAST_WEAPON_IMPACT_COORD(PLAYER::PLAYER_PED_ID(), tmp);            OBJECT::CREATE_AMBIENT_PICKUP(GAMEPLAY::GET_HASH_KEY("PICKUP_MONEY_MED_BAG"), tmp[0], tmp[2], tmp[4], 0, 40000, 1, 0, 1);	}}

you could also spawn non pickup objects with any item from this list http://ecb2.biz/releases/GTAV/lists/objects.txtvia

OBJECT::CREATE_OBJECT(GAMEPLAY::GET_HASH_KEY("prop_tree_pine_01"), tmp[0], tmp[2], tmp[4], 0, 0, 1);

instead of CREATE_AMBIENT_PICKUP.

Edited by FreeOffset
Link to comment
Share on other sites

Rooster Mods

Here is code I made to spawn pickup objects (40k money bag in this instance), can be anything from http://ecb2.biz/releases/GTAV/lists/pickups.txtand PICKUP_PARACHUTE will be a parachute in your inventory, not money.

if (featureMoneyGun) {        if (PED::IS_PED_SHOOTING(PLAYER::PLAYER_PED_ID()))        {            float tmp[3];            WEAPON::GET_PED_LAST_WEAPON_IMPACT_COORD(PLAYER::PLAYER_PED_ID(), tmp);            OBJECT::CREATE_AMBIENT_PICKUP(GAMEPLAY::GET_HASH_KEY("PICKUP_MONEY_MED_BAG"), tmp[0], tmp[2], tmp[4], 0, 40000, 1, 0, 1);	}}

you could also spawn non pickup objects with any item from this list http://ecb2.biz/releases/GTAV/lists/objects.txtvia

OBJECT::CREATE_OBJECT(GAMEPLAY::GET_HASH_KEY("prop_tree_pine_01"), tmp[0], tmp[2], tmp[4], 0, 0, 1);

instead of CREATE_AMBIENT_PICKUP.

Please help me any 1

this is what I get

http://postimg.org/image/sjdztf6f1/

Edited by Rooster Mods
Link to comment
Share on other sites

FreeOffset

 

Here is code I made to spawn pickup objects (40k money bag in this instance), can be anything from http://ecb2.biz/releases/GTAV/lists/pickups.txtand PICKUP_PARACHUTE will be a parachute in your inventory, not money.

if (featureMoneyGun) {        if (PED::IS_PED_SHOOTING(PLAYER::PLAYER_PED_ID()))        {            float tmp[3];            WEAPON::GET_PED_LAST_WEAPON_IMPACT_COORD(PLAYER::PLAYER_PED_ID(), tmp);            OBJECT::CREATE_AMBIENT_PICKUP(GAMEPLAY::GET_HASH_KEY("PICKUP_MONEY_MED_BAG"), tmp[0], tmp[2], tmp[4], 0, 40000, 1, 0, 1);	}}

you could also spawn non pickup objects with any item from this list http://ecb2.biz/releases/GTAV/lists/objects.txtvia

OBJECT::CREATE_OBJECT(GAMEPLAY::GET_HASH_KEY("prop_tree_pine_01"), tmp[0], tmp[2], tmp[4], 0, 0, 1);

instead of CREATE_AMBIENT_PICKUP.

Please help me any 1

this is what I get

http://postimg.org/image/sjdztf6f1/

 

 

Go to natives.h and update GET_PED_LAST_WEAPON_IMPACT_COORD to this

static Any GET_PED_LAST_WEAPON_IMPACT_COORD(Ped Handle, float* Coords) { return invoke<Any>(0x6C4D0409BA1A2BC2, Handle, Coords); } // 6C4D0409BA1A2BC2 9B266079

natives.h still gets updated even though the sdk doesn't (I don't think it does atleast)

Link to comment
Share on other sites

Rooster Mods

 

 

Here is code I made to spawn pickup objects (40k money bag in this instance), can be anything from http://ecb2.biz/releases/GTAV/lists/pickups.txtand PICKUP_PARACHUTE will be a parachute in your inventory, not money.

if (featureMoneyGun) {        if (PED::IS_PED_SHOOTING(PLAYER::PLAYER_PED_ID()))        {            float tmp[3];            WEAPON::GET_PED_LAST_WEAPON_IMPACT_COORD(PLAYER::PLAYER_PED_ID(), tmp);            OBJECT::CREATE_AMBIENT_PICKUP(GAMEPLAY::GET_HASH_KEY("PICKUP_MONEY_MED_BAG"), tmp[0], tmp[2], tmp[4], 0, 40000, 1, 0, 1);	}}

you could also spawn non pickup objects with any item from this list http://ecb2.biz/releases/GTAV/lists/objects.txtvia

OBJECT::CREATE_OBJECT(GAMEPLAY::GET_HASH_KEY("prop_tree_pine_01"), tmp[0], tmp[2], tmp[4], 0, 0, 1);

instead of CREATE_AMBIENT_PICKUP.

Please help me any 1

this is what I get

http://postimg.org/image/sjdztf6f1/

 

 

Go to natives.h and update GET_PED_LAST_WEAPON_IMPACT_COORD to this

static Any GET_PED_LAST_WEAPON_IMPACT_COORD(Ped Handle, float* Coords) { return invoke<Any>(0x6C4D0409BA1A2BC2, Handle, Coords); } // 6C4D0409BA1A2BC2 9B266079

natives.h still gets updated even though the sdk doesn't (I don't think it does atleast)

 

Why do I freeze when I enable it and then shoot

I think its because im looping it

Edited by Rooster Mods
Link to comment
Share on other sites

FreeOffset

 

 

 

Here is code I made to spawn pickup objects (40k money bag in this instance), can be anything from http://ecb2.biz/releases/GTAV/lists/pickups.txtand PICKUP_PARACHUTE will be a parachute in your inventory, not money.

if (featureMoneyGun) {        if (PED::IS_PED_SHOOTING(PLAYER::PLAYER_PED_ID()))        {            float tmp[3];            WEAPON::GET_PED_LAST_WEAPON_IMPACT_COORD(PLAYER::PLAYER_PED_ID(), tmp);            OBJECT::CREATE_AMBIENT_PICKUP(GAMEPLAY::GET_HASH_KEY("PICKUP_MONEY_MED_BAG"), tmp[0], tmp[2], tmp[4], 0, 40000, 1, 0, 1);	}}

you could also spawn non pickup objects with any item from this list http://ecb2.biz/releases/GTAV/lists/objects.txtvia

OBJECT::CREATE_OBJECT(GAMEPLAY::GET_HASH_KEY("prop_tree_pine_01"), tmp[0], tmp[2], tmp[4], 0, 0, 1);

instead of CREATE_AMBIENT_PICKUP.

Please help me any 1

this is what I get

http://postimg.org/image/sjdztf6f1/

 

 

Go to natives.h and update GET_PED_LAST_WEAPON_IMPACT_COORD to this

static Any GET_PED_LAST_WEAPON_IMPACT_COORD(Ped Handle, float* Coords) { return invoke<Any>(0x6C4D0409BA1A2BC2, Handle, Coords); } // 6C4D0409BA1A2BC2 9B266079

natives.h still gets updated even though the sdk doesn't (I don't think it does atleast)

 

Why do I freeze when I enable it and then shoot

I think its because im looping it

 

I put the following code in void update_features() which loops all the code in it. Are you freezing because of the Create Ambient Pickup or Create Pickup calls? or the Get ped last weapon impact coord call? Figure out by commenting out code.

Link to comment
Share on other sites

  • 3 weeks later...
holyswordman

Ok here is the main code to shoot with random vehicles:

LPCSTR vehicleModels[188] = {"ARMYTANKER", "ASTEROPE", "AIRTUG", "AMBULANCE", "BARRACKS", "BARRACKS2", "BALLER", "BALLER2",	"BJXL", "BANSHEE", "BFINJECTION", "BIFF", "BLAZER", "BLAZER2", "BLAZER3", "BISON", "BISON2",	"BISON3", "BOXVILLE", "BOXVILLE2", "BOXVILLE3", "BOBCATXL", "BODHI2", "BUCCANEER", "BUFFALO", "BUFFALO2", "BULLDOZER",	"BULLET", "BURRITO", "BURRITO2", "BURRITO3", "BURRITO4", "BURRITO5", "CAVALCADE", "CAVALCADE2", "POLICET",	"GBURRITO", "CABLECAR", "CADDY", "CADDY2", "CAMPER", "CARBONIZZARE", "CHEETAH", "COMET2", "COGCABRIO", "COQUETTE",	"CUTTER", "GRESLEY", "DILETTANTE", "DILETTANTE2", "DUNE", "DUNE2", "HOTKNIFE", "DLOADER", "DUBSTA", "DUBSTA2",	"DUMP", "RUBBLE", "DOCKTUG", "DOMINATOR", "EMPEROR", "EMPEROR2", "EMPEROR3", "ENTITYXF", "EXEMPLAR", "ELEGY2",	"F620", "FBI", "FBI2", "FELON", "FELON2", "FELTZER2", "FIRETRUK", "FLATBED", "FORKLIFT", "FQ2",	"FUSILADE", "FUGITIVE", "FUTO", "GRANGER", "GAUNTLET", "HABANERO", "HAULER", "HANDLER", "INFERNUS", "INGOT",	"INTRUDER", "ISSI2", "JACKAL", "JOURNEY", "JB700", "KHAMELION", "LANDSTALKER", "LGUARD", "MANANA", "MESA",	"MESA2", "MESA3", "CRUSADER", "MINIVAN", "MIXER", "MIXER2", "MONROE", "MOWER", "MULE", "MULE2",	"ORACLE", "ORACLE2", "PACKER", "PATRIOT", "PBUS", "PENUMBRA", "PEYOTE", "PHANTOM", "PHOENIX", "PICADOR",	"POUNDER", "POLICE", "POLICE4", "POLICE2", "POLICE3", "POLICEOLD1", "POLICEOLD2", "PONY", "PONY2", "PRAIRIE",	"PRANGER", "PREMIER", "PRIMO",  "RANCHERXL", "RANCHERXL2", "RAPIDGT", "RAPIDGT2", "RADI", "RATLOADER",	"REBEL", "REGINA", "REBEL2", "RENTALBUS", "RUINER", "RUMPO", "RUMPO2", "RHINO", "RIOT", "RIPLEY",	"ROCOTO", "ROMERO", "SABREGT", "SADLER", "SADLER2", "SANDKING", "SANDKING2", "SCHAFTER2", "SCHWARZER", "SCRAP",	"SEMINOLE", "SENTINEL", "SENTINEL2", "ZION", "ZION2", "SERRANO", "SHERIFF", "SHERIFF2", "SPEEDO", "SPEEDO2",	"STANIER", "STINGER", "STINGERGT", "STOCKADE", "STOCKADE3", "STRATUM", "SULTAN", "SUPERD", "SURANO", "SURFER",	"SURFER2", "SURGE", "TAILGATER", "TAXI", "TRASH", "TRACTOR", "TRACTOR2", "TRACTOR3", "TOWTRUCK",	"TOWTRUCK2","UTILLITRUCK", "UTILLITRUCK2", "UTILLITRUCK3"};float offset;Ped playerPed = PLAYER::PLAYER_PED_ID();        DWORD model = GAMEPLAY::GET_HASH_KEY((char *)vehicleModels[rand() % 188]);STREAMING::REQUEST_MODEL(model);while (!STREAMING::HAS_MODEL_LOADED(model)) WAIT(0);if (STREAMING::IS_MODEL_IN_CDIMAGE(model) && STREAMING::IS_MODEL_A_VEHICLE(model)){    Vector3 dim1, dim2;    GAMEPLAY::GET_MODEL_DIMENSIONS(model, &dim1, &dim2);    offset = dim2.y * 1.6;}   Vector3 dir = ENTITY::GET_ENTITY_FORWARD_VECTOR(playerPed);Vector3 pos = ENTITY::GET_ENTITY_COORDS(PLAYER::PLAYER_PED_ID(), 1);float rot = (ENTITY::GET_ENTITY_ROTATION(playerPed, 0)).z;Vehicle veh = VEHICLE::CREATE_VEHICLE(model, pos.x + (dir.x * offset) , pos.y + (dir.y * offset) , pos.z , rot, 1, 1);VEHICLE::SET_VEHICLE_ON_GROUND_PROPERLY(veh);        VEHICLE::SET_VEHICLE_FORWARD_SPEED(veh, 70.0);   STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(model);ENTITY::SET_VEHICLE_AS_NO_LONGER_NEEDED(&veh);

I will try to shoot 3D in vehicle cannon v2 :lol:

 

Cool. will you show us the "3D" vehicle cannon v2 main code? :blush::santa:

Link to comment
Share on other sites

  • 1 month later...
TuckerW2001

The reason the money drop code is making people freeze is because you didn't request the model to do so put this before create_ambient_pickup

 

 

static Any money = GAMEPLAY::GET_HASH_KEY("PICKUP_MONEY_MED_BAG");

STREAMING::REQUEST_MODEL(money)

 

 

this should stop freezing if not i have a money drop code ill look at it and just post it

Edited by TuckerW2001
Link to comment
Share on other sites

  • 1 month later...

Why do I freeze when I enable it and then shoot

 

I think its because im looping it

 

So, this is a 100% working code made by me:

if (money_gun){	DWORD model = GET_HASH_KEY("prop_money_bag_01");	int PickupHash = GET_HASH_KEY("PICKUP_MONEY_CASE");	if (DOES_ENTITY_EXIST(PLAYER_PED_ID()))	{		if (IS_PED_SHOOTING(PLAYER_PED_ID()))		{			float tmp[6];			GET_PED_LAST_WEAPON_IMPACT_COORD(PLAYER_PED_ID(), (Vector3*)tmp);			if (tmp[0] != 0 || tmp[2] != 0 || tmp[4] != 0)			{				REQUEST_MODEL(model);				while (!HAS_MODEL_LOADED(model)) WAIT(0);				{					CREATE_AMBIENT_PICKUP(PickupHash, tmp[0], tmp[2], tmp[4], 0, 40000, model, FALSE, TRUE);					SET_MODEL_AS_NO_LONGER_NEEDED(model);				}			}		}	}}
Edited by Unknown_Modder
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.