Author Topic: The Wiki, Scripting And You! (I made a script).  (Read 609 times)

Offline Soyweiser

  • Survivor
  • ***
  • Posts: 864
    • View Profile
The Wiki, Scripting And You! (I made a script).
« on: August 17, 2016, 06:21:42 AM »
I was messing around with python a bit. And made a script that converts most of the json data (the different 'tags' in the top of the template:trait in the wiki, and the various 'changes_to' fields) into mediawiki content. Which is then easily copy pasted over the old mutation data. (Can't do that automated, as you need to check if there is special content on the page, and some of the mutation names are already taken by other pages).

I'll try to make some more scripts that will increase the ease of updating the wiki.

https://github.com/Soyweiser/CDDA-Wiki-Scripts Here it is. Not documented, and not feature complete by far.

Fyi, I updated all the mutations on the wiki using this script.
« Last Edit: August 24, 2016, 07:01:52 PM by Soyweiser »
"Put me in charge and you'll have finished and polished game with hundreds more new features within two months." -- Lazycat
"Voker57 just was wondering about when did cata turn into contact lenses user simulator"

Offline rremyroy

  • NPC
  • **
  • Posts: 139
    • View Profile
Re: The Wiki, Scripting And You! (I made a script).
« Reply #1 on: August 27, 2016, 03:43:06 PM »
Well done.

Offline StopSignal

  • Survivor
  • ***
  • Posts: 3415
  • Never stop drawing!
    • View Profile
    • You can see my drawings here!
Re: The Wiki, Scripting And You! (I made a script).
« Reply #2 on: August 27, 2016, 06:46:07 PM »
That's awesome! Wasn't there a page that did something like that, but with items?

Offline pisskop

  • Survivor
  • ***
  • Posts: 3363
  • So Noble he farts Helium
    • View Profile
Re: The Wiki, Scripting And You! (I made a script).
« Reply #3 on: August 27, 2016, 07:12:57 PM »
neato

Offline Soyweiser

  • Survivor
  • ***
  • Posts: 864
    • View Profile
Re: The Wiki, Scripting And You! (I made a script).
« Reply #4 on: August 27, 2016, 07:18:16 PM »
That's awesome! Wasn't there a page that did something like that, but with items?

No idea. Probably.

Gonna be some time before I tackle all items I think. Even mutations was exception upon exception. (and later realizing I didn't even understand what the 'chance' value did from the mutation attacks :).

The "MOUTH" part of "using the MOUTH body part, doing 20 points of stab damage." is also pretty ugly. But that is stuff for later. Think I'm going to do CBMs next.

Edit: no not CBMs yet. I still have to update all those mutation lists for the various categories.
« Last Edit: August 27, 2016, 10:39:57 PM by Soyweiser »
"Put me in charge and you'll have finished and polished game with hundreds more new features within two months." -- Lazycat
"Voker57 just was wondering about when did cata turn into contact lenses user simulator"