petlahk MacThule
Actually, as you know, when you query infos from blocks, your get a table, no less, no more. As i explain to
Crimson-Artist , it is very restrictive and a new system can allow many implementation by using a database without format (table) and create template on it .
So, I'am working on a totally new database system today, purpose :
- replace old {{infobox block}} tag, complex as to use it correcty (if {{infobox block/Reactor Main}} work) you should make something like that :
{{infobox block
|type=Reactor Main
|hp=100
|Armor=30%
|etc...}}
- add a {{tiny table}} to display only block and id. always in a quick simple action
- allow to make page very dynanic by use {{tag|block|info}} instead of write a value in a page, then if value of block change, all data in pages are update. (armor points, name, HP, etc...)
So I make some quick templates for the 3 last points (and i will make doc to explain all function i make on it to use it)
(todo):
I.E with "reactor main" and value for "HP"
{{blockbox|Reactor Main}} to replace {{infobox block|type=Reactor Main|hp=100|Armor=30%|etc...}}
{{tinyblockbox|Reator Main}} display a little table with only name, icon, ID.
I have to fine tune to prevent blocks to be displayed more than 50% of page (then making 2 lines, 50% or x%, i will see by results)
{{ib|Reactor Main|hp}} return hp of block (or type choosed),
without parameters (type) return name.
if type is image, can add a number parameters for the size of image. {{ib|Reactor Main|image|150}}
To be used very often in pages, have to be really short string, then i'm reflect how to make compressed named block call . By id, or a list to choose (very complex this one), or just shortcut names
{{blocklink|Reactor Main}} (Work in progress) a link of the block page with an icon at size of texte (normal format).
on this one, i will reduce name of template such as {{bl|block}} as it could/should be used very often as {{ib}}...
The really goal : I trying to get an info window onmouseover who display the table of block.. that is a good trick !!
Will have more data for blocks in new database to sorts them and allow to handle more precise:
- category and subcategory (make an ID list page dynaamic)
- specific blocks type such as rate of fire, damages, etc.. for weapons. to make table of weapons and sorts them by their power, rate , or what you seek. could be done for light, and sure others...
- one other powerfull idea I can't still make word on it ... lol.
and that is the result:
ADVERTISE : it is a test with 5 blocks in a new database, so you can't actually use tags for others blocks !
Dbtest - StarMade Wiki
With this kind on new code, could come many other interesting templates:
tables of blocks with sortings option by id, armor, hp, etc...
slideshow of same category blocks (I.E on a chambers page : a slide show of all chambers, instead of display each one)
etc...
And more interesting, people can easily make new tempalte by modify mine !!! (as i already comment all to be explicit) and i will make doc files to explain how to.
But now, have to modify a part of all actual pages of "actual table data block" to "move them" to the new system.
Even if i make all to make this less painfull, and compatible, that's a work....
I'am talking with admin (server-side admins) to get scripts on wiki to get it easier (make it in 5 processor work minutes).
if they can't do anything, i will need help to convert database... hoping not !
If you have request or ideas of template...