|
||
|
|||||||
| New Join Forum So your new to RunUO and looking to work with people that are new, this is the place. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 (permalink) |
|
Forum Expert
Join Date: Feb 2005
Location: Fife,Scotland
Age: 40
Posts: 258
|
i am trying to make it so players dont have to carry gold on them, just be able to have the correct amount of gold in bankbox when buying things, i know this is possible but not sure how to go about it
i have looked in the documentation and cant seem to find what im looking for can someone give me a pointer please? |
|
|
|
|
|
#2 (permalink) | |
|
Account Terminated
|
Quote:
|
|
|
|
|
|
|
#3 (permalink) | |
|
Forum Expert
Join Date: Feb 2005
Location: Fife,Scotland
Age: 40
Posts: 258
|
Quote:
would it be in BaseVendor.cs?and i maybe cant see what it is? |
|
|
|
|
|
|
#4 (permalink) |
|
Forum Expert
Join Date: Feb 2003
Location: East Coast USA
Posts: 1,359
|
This is the relevant code in BaseVendor.cs:
Code:
cont = buyer.Backpack;
if ( !bought && cont != null )
{
if ( cont.ConsumeTotal( typeof( Gold ), totalCost ) )
bought = true;
else if ( totalCost < 2000 )
SayTo( buyer, 500192 );//Begging thy pardon, but thou casnt afford that.
}
if ( !bought && totalCost >= 2000 )
{
cont = buyer.BankBox;
if ( cont != null && cont.ConsumeTotal( typeof( Gold ), totalCost ) )
{
bought = true;
fromBank = true;
}
else
{
SayTo( buyer, 500191 ); //Begging thy pardon, but thy bank account lacks these funds.
}
}
__________________
the-retelling.org : scripts and tech demo |
|
|
|
|
|
#5 (permalink) | |
|
Forum Expert
Join Date: Feb 2005
Location: Fife,Scotland
Age: 40
Posts: 258
|
Quote:
so i can change that 2000 to any number i like really and after that amount it will deduct from bank account ? |
|
|
|
|
|
|
#6 (permalink) | |
|
Forum Expert
Join Date: Feb 2003
Location: East Coast USA
Posts: 1,359
|
Quote:
It will *always* try and deduct the gold from whatever amount the player has in their backpack first tho. And remember there are two "2000"s that you need to change. :>
__________________
the-retelling.org : scripts and tech demo |
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|