Difference between revisions of "Project Phoenix 2 Merchant Information"

From Legends of Aria Admin and Modding Wiki
Jump to: navigation, search
(Create A Merchant)
 
Line 13: Line 13:
 
*Data.UIStyle - this contains the user interface style key for the Style system
 
*Data.UIStyle - this contains the user interface style key for the Style system
 
==Create A Merchant==
 
==Create A Merchant==
The first thing you want to do, is create all the table entries for the above variables. Then create your merchant .xml file. You can
+
The first thing you want to do, is create all the table entries for the above object variables. Then create your merchant .xml file. You can
 
copy paste this...
 
copy paste this...
 
  <?xml version="1.0" encoding="utf-8"?>
 
  <?xml version="1.0" encoding="utf-8"?>

Latest revision as of 17:52, 10 August 2019

Welcome

The Merchant system allows you to create your own custom stores and custom npc node based conversations. The difference between Citadels version and mine is that the Project Phoenix uses a menu based buy and sell system. It also allows for configurations like players needing a object variable like "CityStanding" is greater then 500. It also allows you to exchange the coins to any other resource in the game. Here are some examples of what merchants can do.

  • Your standard merchant who buys and sells.
  • A non player character with no store but instead offers a chain of dialogs.
  • A resource exchange merchant. As a example trading wooden boards for recipes on the vendor.

Object Variables

below is a list of the object variables you will find on the merchants. Check the sub sections on the main merchant page on this wiki.

  • Data.StoreType - this contains the store key for the StoreType table
  • Data.Features - this contains the features key for the Features table
  • Data.Outfit - this contains the outfit key for the Outfit table
  • Data.Dialog - this contains the dialog key for the Dialog table
  • Data.UIStyle - this contains the user interface style key for the Style system

Create A Merchant

The first thing you want to do, is create all the table entries for the above object variables. Then create your merchant .xml file. You can copy paste this...

<?xml version="1.0" encoding="utf-8"?>
<ObjectTemplate xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
	<ClientId>1</ClientId>
	<Hue>172</Hue>
	<Color>0xFFFFFFFF</Color>
	<Name>Merchant</Name>
	<ObjectVariableComponent>
		<StringVariable Name="MobileTeamType">Villagers</StringVariable>
		<StringVariable Name="Data.StoreType">Weaponsmith</StringVariable>
		<StringVariable Name="Data.Features">Human</StringVariable>
		<StringVariable Name="Data.Outfit">CommonMerchant</StringVariable>
		<StringVariable Name="Data.Dialog">EldierVillageBlacksmith</StringVariable>
		<StringVariable Name="Data.UIStyle">Dark</StringVariable>
		<DoubleVariable Name="BaseHealth">300</DoubleVariable>
		<BoolVariable Name="ImportantNPC">True</BoolVariable>
		<DoubleVariable Name="Data.RestockDelay">1800</DoubleVariable>
	</ObjectVariableComponent>
	<ScriptEngineComponent>
		<LuaModule Name="merchants.merchant"/>
	</ScriptEngineComponent>
	<MobileComponent>
		<BaseRunSpeed>1</BaseRunSpeed>
		<MobileType>Friendly</MobileType>
	</MobileComponent>
</ObjectTemplate>