Browse Source

Updates the db README (#7436)

Updates the db README
Updates a couple examples from TXT to YML.
Wrap examples in code blocks
Aleos 2 years ago
parent
commit
15e27b3567
1 changed files with 66 additions and 35 deletions
  1. 66 35
      db/readme.md

+ 66 - 35
db/readme.md

@@ -18,6 +18,7 @@ We want to add our own custom achievement that can be given to a player via an N
 
 
 #### /db/import/achievement_db.yml
 #### /db/import/achievement_db.yml
 
 
+```yml
     - Id: 280000
     - Id: 280000
       Group: None
       Group: None
       Name: Emperio
       Name: Emperio
@@ -30,6 +31,7 @@ We want to add our own custom achievement that can be given to a player via an N
       Reward:
       Reward:
         TitleId: 1036
         TitleId: 1036
       Score: 50
       Score: 50
+```
 
 
 
 
 ### Instances
 ### Instances
@@ -38,27 +40,30 @@ We want to add our own customized Housing Instance.
 
 
 #### /db/import/instance_db.yml
 #### /db/import/instance_db.yml
 
 
-	- Id: 35
-	    Name: Home
-        IdleTimeOut: 900
-        Enter:
-          Map: 1@home
-          X: 24
-          Y: 6
-        AdditionalMaps:
-          - Map: 2@home
-          - Map: 3@home
+```yml
+    - Id: 35
+      Name: Home
+      IdleTimeOut: 900
+      Enter:
+        Map: 1@home
+        X: 24
+        Y: 6
+      AdditionalMaps:
+        - Map: 2@home
+        - Map: 3@home
+```
 
 
 
 
 ### Mob Alias
 ### Mob Alias
 ---
 ---
-We want to give a custom mob a Novice player sprite.
+We want to make Porings look like Baphomet.
 
 
-#### /db/import/mob_avail.txt
+#### /db/import/mob_avail.yml
 
 
-    // Structure of Database:
-    // MobID,SpriteID{,Equipment}
-    3850,0
+```yml
+    - Mob: PORING
+      Sprite: BAPHOMET
+```
 
 
 
 
 ### Custom Maps
 ### Custom Maps
@@ -67,45 +72,71 @@ We want to add our own custom maps. For this we need to add our map names to `im
 
 
 #### /db/import/map_index.txt
 #### /db/import/map_index.txt
 
 
+```
     1@home	1250
     1@home	1250
     2@home
     2@home
     3@home
     3@home
     ev_has
     ev_has
     shops
     shops
     prt_pvp
     prt_pvp
+```
 
 
 
 
 ### Item Trade Restrictions
 ### Item Trade Restrictions
 ---
 ---
 We want to ensure that specific items cannot be traded, sold, dropped, placed in storage, etc.
 We want to ensure that specific items cannot be traded, sold, dropped, placed in storage, etc.
 
 
-#### /db/import/item_trade.txt
-
-    // Legend for 'TradeMask' field (bitmask):
-    // 1   - item can't be dropped
-    // 2   - item can't be traded (nor vended)
-    // 4   - wedded partner can override restriction 2
-    // 8   - item can't be sold to npcs
-    // 16  - item can't be placed in the cart
-    // 32  - item can't be placed in the storage
-    // 64  - item can't be placed in the guild storage
-    // 128 - item can't be attached to mail
-    // 256 - item can't be auctioned
-    // Full outright value = 511
-    34000,511,100	// Old Green Box
-    34001,511,100	// House Keys
-    34002,511,100	// Reputation Journal
+#### /db/import/item_db.yml
+
+```yml
+    - Id: 34000 # Old Green Box
+      Trade:
+        NoDrop: true
+        NoTrade: true
+        TradePartner: true
+        NoSell: true
+        NoCart: true
+        NoStorage: true
+        NoGuildStorage: true
+        NoMail: true
+        NoAuction: true
+    - Id: 34001 # House Keys
+      Trade:
+        NoDrop: true
+        NoTrade: true
+        TradePartner: true
+        NoSell: true
+        NoCart: true
+        NoStorage: true
+        NoGuildStorage: true
+        NoMail: true
+        NoAuction: true
+    - Id: 34002 # Reputation Journal
+      Trade:
+        NoDrop: true
+        NoTrade: true
+        TradePartner: true
+        NoSell: true
+        NoCart: true
+        NoStorage: true
+        NoGuildStorage: true
+        NoMail: true
+        NoAuction: true
+```
 
 
 
 
 ### Custom Quests
 ### Custom Quests
 ---
 ---
 We want to add our own custom quests to the quest_db.
 We want to add our own custom quests to the quest_db.
 
 
-#### /db/import/quest_db.txt
+#### /db/import/quest_db.yml
 
 
-    // Quest ID,Time Limit,Target1,Val1,Target2,Val2,Target3,Val3,MobID1,NameID1,Rate1,MobID2,NameID2,Rate2,MobID3,NameID3,Rate3,Quest Title
-    89001,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"Reputation Quest"
-    89002,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"Reputation Quest"
+```yml
+    - Id: 89001
+      Title: "Reputation Quest"
+    - Id: 89002
+      Title: "Reputation Quest"
+```