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

This section is for any editing topics that don't fit into any of the other forums, any questions on how to mod belong in Editing Discussion

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

 [SA] reduce the maximum number of munitions .

 
terreur69  
Posted: Thursday, Apr 19 2012, 11:55
Quote Post


C2C - Down The Road
Group Icon
Group: Members
Joined: Dec 27, 2010

fr.gif

XXXXX



hi , how to reduce the maximum number of munitions that may have (max is 9999, can pass it to 100?)

if by script it would be perfect .

thank.
Users WebsitePMMSN
  Top
 

 
The_Sorrow  
Posted: Thursday, Apr 19 2012, 12:02
Quote Post


Heaven, I'm in heaven(8)
Group Icon
Group: Members
Joined: May 31, 2010

en.gif

XXXXX



QUOTE (terreur69 @ Thursday, Apr 19 2012, 12:55)
hi , how to reduce the maximum number of munitions that may have (max is 9999, can pass it to 100?)

if by script it would be perfect .

thank.

I assume you mean the amount of ammo a gun is carrying, yes it can be done by script.

For San andreas use this opcode:
CODE
017B: set_actor $PLAYER_ACTOR weapon 22 ammo_to 10


For Vice city use this opcode:
CODE
017A: set_player $PLAYER_CHAR weapon 17 ammo_to 100


And for GTA 3 use this opcode:
CODE
017A: set_player $PLAYER_CHAR weapon 7 ammo_to 0


To give you an example of how to use these, I'm going to put them into a 'Key press' script.

Using SA's code if the key '1' is pressed the amount of ammo in the gun will become 10, Like so:

CODE
{$CLEO}
0000:

:1
wait 0
if
0AB0:  key_pressed 0x31
jf @1

:2
017B: set_actor $PLAYER_ACTOR weapon 22 ammo_to 10 //-- Weapon 22 is a pistol
jump @1


For any future 'Scripting' queries/requests please post in the III Coding thread

P.S - You will see the 'Requests' topic pinned to the top!



This post has been edited by The_Sorrow on Thursday, Apr 19 2012, 12:06
Users WebsitePMMSN
  Top
 

 
lil weasel  
Posted: Thursday, Apr 19 2012, 21:42
Quote Post


Shoot Looters, Hang Pirates!
Group Icon
Group: Members
Joined: Dec 25, 2006

us.gif

Member Award




You do realize that the maximum ammo count DISPLAYED is 9,999. When you exceed 9,999 the game no longer Displays the count. You have over 10,000 when it no longer displays.
PM
  Top
 

 
GTASanAndreas12345  
Posted: Thursday, Apr 19 2012, 23:55
Quote Post


Player Hater
Group Icon
Group: Members
Joined: Sep 7, 2010

XXXXX



There is no theoretical maximum to the ammunition of a weapon. The game stops displaying the amount over 9,999, but you could have much more than that.
PM
  Top
 

 
terreur69  
Posted: Sunday, Apr 22 2012, 07:52
Quote Post


C2C - Down The Road
Group Icon
Group: Members
Joined: Dec 27, 2010

fr.gif

XXXXX



thank sorrow ,

but , it's not really her i seek, in fact, when we did a lot of ammunition, one is a 9999 (or more) so i asked whether it is possible that the maximun number of ammunition for each weapon is 100.
Users WebsitePMMSN
  Top
 

 
The_Sorrow  
Posted: Sunday, Apr 22 2012, 08:27
Quote Post


Heaven, I'm in heaven(8)
Group Icon
Group: Members
Joined: May 31, 2010

en.gif

XXXXX



Yes, This can be done by script.

You just create a 'Checking' script to check if the ammo is over or equal too a hundred (100) and then use the script I gave you to manipulate the ammo, Make it higher (Over 9999) so the ammo isn't show on the gun icon (This happens when you reach 9999 or over)

This gives the impression that 100 is the maximum amount of ammo a gun can carry.
Users WebsitePMMSN
  Top
 

 
Th3MaN1  
Posted: Monday, Apr 23 2012, 15:00
Quote Post


Foot Soldier
Group Icon
Group: Members
Joined: Apr 24, 2011

ro.gif

XXXXX



If you want the limit to be just like in GTA 4,you could use oksa8's script which is right HERE.It's easy to use,just follow the instructions.Plus,you can edit the limit of each weapon's ammo to your liking.
Users WebsitePM
  Top
 

 
terreur69  
Posted: Saturday, Apr 28 2012, 15:50
Quote Post


C2C - Down The Road
Group Icon
Group: Members
Joined: Dec 27, 2010

fr.gif

XXXXX



thank all.
Users WebsitePMMSN
  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