ftb-gamepedia / oredict Goto Github PK
View Code? Open in Web Editor NEWAn extension that mimics the ore dictionary in Minecraft.
Home Page: https://www.mediawiki.org/wiki/Extension:OreDict
License: MIT License
An extension that mimics the ore dictionary in Minecraft.
Home Page: https://www.mediawiki.org/wiki/Extension:OreDict
License: MIT License
This is highly confusing.
I likely did not notice this because I only actually have 8 OreDict entries on my test wiki.
There are two legal issues need to be taken care of by the end of next week.
1.) Licensing
There was discussion on the #gamepedia IRC channel previously about this. I forget what the final open source license was decided on and if it was for OreDict or Tilesheets.
The company(Curse Inc.) is requesting to be able to use OreDict under the MIT license. However, if not MIT then GPLv2 would be acceptable.
Preferably the license would be included in the repository in the root folder titled similar to "LICENSE" in all capital letters.
2.) Repository Ownership
Even though OreDict is used primarily on a Gamepedia wiki the primary maintainers of the OreDict project are not Curse employees or contractors. As such legal has informed us that it would be best that the repository ownership be officially transfer to either the personal Github account of a primary maintainer or a an organization account controlled by the primary maintainers. I will facilitate transferring the repository to the location decided.
At the moment what happens is that if the first call to the oredict for a given tag is set to be shuffled, it retrieves the things from the database in random order (https://github.com/CurseStaff/OreDict/blob/7c42b80236fa2419b98aad3a1d8ec64ceb03a621/OreDict.body.php#L130). It then caches the result and it is never randomized again on further calls, thus defeating the purpose of shuffling.
Ideally what this should do is instead after it gets the array from the cache or database, it should shuffle that each time if CTRL_RAND
is set. Somewhere around here perhaps: https://github.com/CurseStaff/OreDict/blob/7c42b80236fa2419b98aad3a1d8ec64ceb03a621/OreDict.body.php#L166
Also rotation, like shuffling, should also be done to $this->mRawArray
, and not to the cache itself.
Sometimes I want to display all the results of cropOat
and cropOats
but if an item is registered to both I want to display it only once. I need a way to do this.
The extension needs an API. Here's what is needed:
[] = optional
Do all work on the API branch until fully working.
Flags should safely be able to be removed now. All of their functionality which I can find has been achieved through other means.
See Template talk:G
Could an IRC web service be added with the following settings:
Server: irc.esper.net
Port: 6667
Room: #FTB-Wiki-Dev
Nick: OreDict
Branches:
NickServ Password:
SSL: false
Message Without Join: true
No colors: false
Long URL: false
Notice: true
I'm not really sure when this started, but it seems the flags no longer save.
The readme needs to be improved, primarily by install instructions
Sometimes it is useful to have the oredict extension not output the error icon when it does not find any valid entries.
Basically replace this line with setting that to an empty array instead of adding an error entry to the array:
Line 147 in 8d7cf17
Then after this line, check if the result is an empty array. If it is an empty array, check whether a brand new flag is set. If the flag is set, the array should remain empty, otherwise the results should be an array of new OreDictItem($this->mItemName, '', $this->mItemMod,'',0xcf)
.
Line 155 in 8d7cf17
And of course thread that new flag in somehow and make sure nothing breaks when an empty array goes through the system.
The log entry should link to Special:OreDictEntryManager/$id, not Special:Entry/$id.
So, apparently, I also got rid of the only way to delete entries using the web interface.
It should be a button instead of a checkbox anyway.
The deletion logs that I made in #17 are apparently terrible, and I never noticed.
This will be resolved after #1. Just give me some time 😉
Example:
08:08, 2 February 2016 Admin (Talk | contribs | block) deleted entry Admin (Talk | contribs | block)5 (TAG from as Tag)
<TIMESTAMP> <USER> deleted entry <USER><ENTRY ID> (<MOD> from <blank> as <ITEM>)
It should be something like:
08:08, 2 February 2016 Admin (Talk | contribs | block) deleted entry 5 (tag from TAG as Tag)
<TIMESTAMP> <USER> deleted entry <ENTRY ID> (<TAG> from <MOD> as <ITEM>)
As described on FTB-Gamepedia/Tilesheets#96, we can remove uses of global
:
For example
global $wgArticlePath;
becomes
$mainConfig = MediaWikiServices::getInstance()->getMainConfig();
$wgArticlePath = $mainConfig->get('ArticlePath');
We can also remove uses of wf...
: See https://phabricator.wikimedia.org/source/mediawiki/browse/master/docs/Injection.md
Namely lowercased. See the Tilesheet creation code for the invalid characters.
Every entry has the option "Default grid parameters", but it's always empty. What does it does/does it do anything?
It would be useful if links could be predefined using it, as it could avoid the need for using redirects due to it automatically disambiguating the links into Item Name (Mod).
For example, on ftb, it says Displaying entries from #0 to #50 out of #19252 total.
but it actually is displaying the first 50, which would be 1–90 because of the deleted ones in between.
When changing the name of an entry using the Entry Manager, after saving the results the old name is shown. Upon refreshing the page however the new name is shown. This leads me to believe that the name to display is fetched before the edit is actually written to the database.
21:45 (OreDict log) KnightMiner (talk | contribs | block) edited entry #KnightMiner (talk | contribs | block)5 (Unfired Porcelain (Item) from CRCM). Changes: item [Unfired Porcelain (Item) -> Unfired Porcelain (item)] ;
The following special pages contain strings that are not localized (in English)
Pressing that button does nothing.
https://www.mediawiki.org/wiki/Release_notes/1.32
The following deprecated methods have been removed:
- ApiBase::dieUsage() (deprecated in 1.29)
Used in several places
For some reason, viewing the OreDictList returns a database query error. Currently looking into this.
Currently "deleting" an entry just assigns a flag to it that disables it. Ideally deleting an entry would actually delete the row from the database.
It's called "Ore Dict" as well as "OreDict" in many places. We should decide on a single term. Personally, I prefer "OreDict" because it's closer to what people call the Minecraft oreDictionary.
When you update the information of an OreDict, or delete an OreDict, in the OreDictEntryManager, the page updates but the old values are still shown.
If a user calls editoredict
and only specifies odmod
for example, it should only update the mod. It should not set the tag, item name, and parameters to blank. The recent change entries look like everything is fine:
01:58, 13 August 2020 PonyButt talk contribs block points edited entry #10519 (Quintuple Chrome Plate from GregTech 5). Changes: mod [GT -> GT5] ;
But a quick look at the oredictlist shows everything is awful:
Are there any objections to transferring this repository to the @HydraWiki organization? We are working consolidating all of the various wiki repositories under a new organization structure that will allow us to more easily interact with public contributors.
Take a look at http://ftb.gamepedia.com/Carving_Table#Recipe to see what I mean. It looks like some SQL querying in the parser function doesn't work properly. However, the only difference I found in #20 was that we use 'ext_oredict_items' rather than $dbr->tableName('ext_oredict_items');
, and $sLim
is now purely the output limit, rather than "LIMIT 0,".outputLimit
. I'm not really sure how either of these would actually cause the issue, though.
Using the oredictsearch list, the odlimit
seems to actually add that number to 50, returning 50 + the limit results.
Use of "wgAction" is deprecated. Use mw.config instead.
Please see https://gitlab.com/hydrawiki/hydra/issues/5086
There are a number of OreDict API actions that aren't summarized properly in 1.33
Since {{O}} will be in lua once the module I made is pushed, it would make sense to have a lua wrapper to shave off the extra millisecond or whatever that callParserFunction() causes.
I would consider doing this myself, but last time I tried to touch PHP I... you know.
It would be nice to know what pages use a given ore dictionary tag.
For example: 10:35, 6 August 2017 SatanicBot (talk | contribs | block | points) created entry #43095 (Uranium Ingot from Artifice) and assigned it to the ingotUran tag and set the bits $9. (Importing entries.)
Flags were removed a while ago. I guess I forgot to update the log format.
log-description-oredict
The creation functionality does not perform any checks against the data provided so you can literally put nothing and it will create an entry.
In the actual OreDictionary in Minecraft Forge, a prefix refers to a value that can be found using startsWith, essentially.
However, here, it means "all tags between the prefix and ZZZZZZZZ". For example:
OreDictList filter with prefix set to "item", only showing a single entry "itemName":
OreDictList filter with prefix set to "butt", showing "buttButt" and "itemName"
I'm not really sure if we should mimic that part of the oredict, but to me that would make more sense.
Replace Filter by prefix
with Filter by item name
which will do a regex search for entries matching that item name.
Modify Filter by tag
so that it does a regex search instead of only looking for exact matches.
Viewing the Special page Special:Log/oredict appears to crash the wiki.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.