Updating data scrappers to new JSON data format and location.
This commit is contained in:
parent
66526fb8da
commit
a9f96e335f
@ -2,5 +2,8 @@ accessing
|
|||||||
collectionFromRepository: jsonFileUrl language: isoCode
|
collectionFromRepository: jsonFileUrl language: isoCode
|
||||||
| rawData |
|
| rawData |
|
||||||
rawData := STON fromString: jsonFileUrl asUrl retrieveContents.
|
rawData := STON fromString: jsonFileUrl asUrl retrieveContents.
|
||||||
^ (rawData at: 'Assets') collect: [:assetDict |
|
^ rawData collect: [:assetDict |
|
||||||
self new fromDictionary: assetDict; language: isoCode ]
|
(assetDict at: #Assets) collect: [ :assetSubdict |
|
||||||
|
self new fromDictionary: assetSubdict; language: isoCode
|
||||||
|
].
|
||||||
|
]
|
@ -1,3 +1,3 @@
|
|||||||
accessing
|
accessing
|
||||||
collectionFromRepostory
|
collectionFromRepostory
|
||||||
^ self collectionFromRepository: 'https://raw.githubusercontent.com/rsek/dataforged/main/assets.json' language: 'en'
|
^ self collectionFromRepository: 'https://raw.githubusercontent.com/rsek/dataforged/main/dist/starforged/assets.json' language: 'en'
|
@ -1,6 +1,6 @@
|
|||||||
accessing
|
accessing
|
||||||
fromDictionary: aDictionary
|
fromDictionary: aDictionary
|
||||||
name := aDictionary at: #Name.
|
name := aDictionary at: #Name.
|
||||||
category := aDictionary at: 'Asset Type'.
|
category := aDictionary at: 'Name'.
|
||||||
abilities := self populateAbilities: (aDictionary at: #Abilities)
|
abilities := self populateAbilities: (aDictionary at: #Abilities)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user