Go Back   Epic Games Forums > Unreal Tournament 2003/2004 > Programming & UnrealScript

Reply
 
Thread Tools Display Modes
Old 09-11-2008, 04:06 AM   #1
ZippyDSMlee
Senior Member
 
Join Date: Jan 2008
Posts: 200
Default Combining MG ammo and assault ammo for 2 weapons.

Alright I am so lost here I thought gee I could make the AR use MG ammo by changing ammo used in the fire mode...but....now its locking out MG from getting ammo.

What I want to do is have the AR box of bullets dump into MG ammo and have that for both my War monkey special and the MG.

Been trying to replace both the ammo picks up but I am going in circles these past 2 hours.
__________________
I is fuzzy braiwned mew =0-o=
------------------------------------------------------
How the fck do we implement this?!?!
The voices demand it be done!
-----------------------
http://zippydsmlee.wordpress.com/
ZippyDSMlee is offline   Reply With Quote
Old 09-11-2008, 10:27 AM   #2
GreatEmerald
Senior Member
 
GreatEmerald's Avatar
 
Join Date: Nov 2007
Location: Lithuania
Posts: 1,816
Default

Would like to get an answer to this as well. As my Grenades act just like that - you take the ammo, and only the latest ammo users gets it, not all. In UT2003 AR used minigun ammo by default, I wonder what did they change?
GreatEmerald is offline   Reply With Quote
Old 09-11-2008, 10:45 AM   #3
ZippyDSMlee
Senior Member
 
Join Date: Jan 2008
Posts: 200
Default

Quote:
Originally Posted by GreatEmerald View Post
Would like to get an answer to this as well. As my Grenades act just like that - you take the ammo, and only the latest ammo users gets it, not all. In UT2003 AR used minigun ammo by default, I wonder what did they change?
Probably to balance it and force you to use all the weapons your can find ammo for.

I have made 2 versions for my War Monkey, when I have the War Monkey special use MG ammo it locks the MG out of getting ammo...its crazy.


Today I shall try and make a new ammo class and pickup and see if I can get them to share with it, also will dup the MG,MGpickup,MGfire,MGalt fire into my mut and have it call to it...I can get the AR ammo pickup and MG ammo pickup to load ammo into the War monkey but MG gets no ammo, or I can reverse it...I am so confused....

Well I have some stuff to try still will report any improvement ^^
__________________
I is fuzzy braiwned mew =0-o=
------------------------------------------------------
How the fck do we implement this?!?!
The voices demand it be done!
-----------------------
http://zippydsmlee.wordpress.com/
ZippyDSMlee is offline   Reply With Quote
Old 09-11-2008, 06:25 PM   #4
ZippyDSMlee
Senior Member
 
Join Date: Jan 2008
Posts: 200
Default

Well I managed to get the add ammo on pickup function to work for the MG but it only gives you ammo when you pick it up even on the spawn points , you can load up fast tho and gives you more ammo from MG drops,it is not bad to maintain teh flow of the game but.....blah.....

---------------
update
dose not work for weapon lockers..... ZOMG!!
__________________
I is fuzzy braiwned mew =0-o=
------------------------------------------------------
How the fck do we implement this?!?!
The voices demand it be done!
-----------------------
http://zippydsmlee.wordpress.com/

Last edited by ZippyDSMlee; 09-11-2008 at 07:01 PM.
ZippyDSMlee is offline   Reply With Quote
Old 09-13-2008, 04:46 PM   #5
GreatEmerald
Senior Member
 
GreatEmerald's Avatar
 
Join Date: Nov 2007
Location: Lithuania
Posts: 1,816
Default

So, any solution yet? Anyone know how these work?
GreatEmerald is offline   Reply With Quote
Old 09-13-2008, 04:50 PM   #6
ZippyDSMlee
Senior Member
 
Join Date: Jan 2008
Posts: 200
Default

Quote:
Originally Posted by GreatEmerald View Post
So, any solution yet? Anyone know how these work?
the only thing I could l do is to get the MG to pick up ammo on its own pick up and spawn points dosent work for weapon lockers tho.


I think either you need a function or whatever call in the upper ammunition chains or proper code in the ammo code to allow for both weapons to use it, I am unsure what the code would be tho.
__________________
I is fuzzy braiwned mew =0-o=
------------------------------------------------------
How the fck do we implement this?!?!
The voices demand it be done!
-----------------------
http://zippydsmlee.wordpress.com/
ZippyDSMlee is offline   Reply With Quote
Old 11-20-2008, 11:06 AM   #7
GreatEmerald
Senior Member
 
GreatEmerald's Avatar
 
Join Date: Nov 2007
Location: Lithuania
Posts: 1,816
Default

I dug this up:

Minigun.uc:
Code:
function DropFrom(vector StartLocation)
{
    local Ammunition AssaultAmmo;
    local Weapon AssaultRifle;
    
    Super.DropFrom(StartLocation);
    if ( (Instigator != None) && (Instigator.Health > 0) ) 
    {
        // share ammo with assault rifle, so need to add it back to instigator's inventory
        AssaultAmmo = Ammunition(Instigator.FindInventoryType(class'MinigunAmmo'));
        if ( AssaultAmmo == None )
        {
            AssaultAmmo = spawn(class'MinigunAmmo',Instigator);
            AssaultAmmo.GiveTo( Instigator, None );
        }
        AssaultAmmo.AmmoAmount = 0;
        AssaultRifle = Weapon(Instigator.FindInventoryType(class'AssaultRifle'));
        if ( AssaultRifle != None )
            AssaultRifle.Ammo[0] = AssaultAmmo;
    }    
}
That should do the trick or a half of it.
GreatEmerald is offline   Reply With Quote
Old 11-20-2008, 11:28 AM   #8
ZippyDSMlee
Senior Member
 
Join Date: Jan 2008
Posts: 200
Default

Quote:
Originally Posted by GreatEmerald View Post
I dug this up:

Minigun.uc:
Code:
function DropFrom(vector StartLocation)
{
    local Ammunition AssaultAmmo;
    local Weapon AssaultRifle;
    
    Super.DropFrom(StartLocation);
    if ( (Instigator != None) && (Instigator.Health > 0) ) 
    {
        // share ammo with assault rifle, so need to add it back to instigator's inventory
        AssaultAmmo = Ammunition(Instigator.FindInventoryType(class'MinigunAmmo'));
        if ( AssaultAmmo == None )
        {
            AssaultAmmo = spawn(class'MinigunAmmo',Instigator);
            AssaultAmmo.GiveTo( Instigator, None );
        }
        AssaultAmmo.AmmoAmount = 0;
        AssaultRifle = Weapon(Instigator.FindInventoryType(class'AssaultRifle'));
        if ( AssaultRifle != None )
            AssaultRifle.Ammo[0] = AssaultAmmo;
    }    
}
That should do the trick or a half of it.
Ok! so you have to add what ammo works for the weapon it sin code sets so you'll have to add something like the above code or more presicly the MG portion to the AR weapon, I'll try it when I get home in a few days I dont have my UT04 with me...I have been working on FO3 tho while I am at a relatives for a week.

My last UT04 mod is a few months old got the firing animations worked out

http://www.viddyou.com/viddstream?videoid=41189

Got a new texture for my hellfire cannon minigun mod but I still can;t get wormbros extended hurt radius to work so no self damaging explosive bullets ><
__________________
I is fuzzy braiwned mew =0-o=
------------------------------------------------------
How the fck do we implement this?!?!
The voices demand it be done!
-----------------------
http://zippydsmlee.wordpress.com/
ZippyDSMlee is offline   Reply With Quote
Old 11-20-2008, 12:14 PM   #9
GreatEmerald
Senior Member
 
GreatEmerald's Avatar
 
Join Date: Nov 2007
Location: Lithuania
Posts: 1,816
Default

Hmm, it seems this code alone doesn't do the trick. However, in AssaultRifle.u:
Code:
function bool HandlePickupQuery( pickup Item )
{
    Super(Weapon).HandlePickupQuery(Item);
    return Inventory.HandlePickupQuery(Item);

}
This disables the AR's special treating of ammo. Yet now when you pick up ammo, you get it in both weapons, but they consume it independently Any suggestions?
GreatEmerald is offline   Reply With Quote
Old 01-31-2009, 07:04 PM   #10
ZippyDSMlee
Senior Member
 
Join Date: Jan 2008
Posts: 200
Default

Any luck with this?
__________________
I is fuzzy braiwned mew =0-o=
------------------------------------------------------
How the fck do we implement this?!?!
The voices demand it be done!
-----------------------
http://zippydsmlee.wordpress.com/
ZippyDSMlee is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Video Game Voters Network
 
All times are GMT -4. The time now is 09:27 PM.


Powered by vBulletin
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Copyright ©2009 Epic Games, Inc. All Rights Reserved.