The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 786 - File: showthread.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/showthread.php 786 errorHandler->error






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
NPC Tax
Author Message
pinku
Journeyman
*

Posts: 118
Likes Given: 4
Likes Received: 2 in 2 posts
Joined: Apr 2013
Reputation: 4



Post: #1
NPC Tax
Hey guys,

I'll try to explain what I wish to do and if you guys can help me out with a starting point, I'll be really grateful!
This is a King/Mayor system I'm working on, but totally stuck right now.


I'm trying to add a (variable) sale tax to the default NPCs based on what a King/Mayor set.

For example: 10% sale tax; If a horse is worth 100gps, it will cost 110gps instead.

I know, I could probably do this with a region.tag or something similar, but this is not all; I want this tax to be sent to a certain UID. A chest, in this case.

Questions I have:

How can I add the variable tax to my default NPCs?
How can I take the tax of what was sold and send somewhere else?

Some bad ways I thought;
Please, let me know if you guys have better ones... Just adding here some ideas.

When the King sets a new sale tax, I will use

REGION.TAG.VENDORMARKUP=KING_TAX - unsure here

When a character buys something I can...

ON=@ItemBuy
LOCAL.TOTALCOST/KING_TAX = TAX
NEWITEM i_gold
NEWAMOUNT TAX
NEWCONT=MY_UID

Any help? Just throwing something here. xd
(This post was last modified: 02-28-2014 07:07 PM by pinku.)
02-28-2014 07:01 PM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Messages In This Thread
NPC Tax - pinku - 02-28-2014 07:01 PM
RE: NPC Tax - amonvangrell - 02-28-2014, 09:40 PM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)