Quantcast User talk:MidnightLightning - d20 NPC Wiki
Recent changes Random page
GAMING
Gaming
 
WoWWiki
Halopedia
FFXIclopedia
Age of Conan
Warhammer Online
Grand Theft Wiki
See more...

User talk:MidnightLightning

From d20 NPC Wiki

Jump to: navigation, search

Contents

You are now an admin!

As mentioned on the community portal, you are now an admin! You are also a bureaucrat, which means that you can make new admins if you need them using Special:Makesysop. Take care, and if you need any help, please leave a note for me on Central! Mindspillage (spill yours?) 18:45, 28 March 2006 (UTC)

Template Help

Hey, I'm trying to make the Newstat template a real wiki-template, with all that should entail. I started work at Newstat2, but I have no idea how to make sections of it optional, like you did at CRlink. I looked at the source, but found it too arcane for me at the moment. Could you lend a hand? Fieari 03:56, 27 April 2006 (UTC)

Main Page Redesign?

Hey, have you looked at User:Fieari/Sandbox1 yet? I just included the link to the rules (as well as made the rules page, and hopefully made it easier to read and understand) which should complete it. Do you think we could implement it? Fieari 00:31, 2 May 2006 (UTC)

You know what, I have. And I think it looks great, and since no one else has commented against it, I've changed it! And I protected the three template files that it uses so that only registered users can modify them. --MidnightLightning 12:12, 2 May 2006 (UTC)

Modern Template

Thanks for fixing that page. So, the template didn't exist yet? Good reason why it didn't work. I still don't know how to operate the DnD version, however. PS for the Modern template, the CR link should be different, as Modern CRs don't match up with DnD CRs. PsiSeveredHead 22:19, 16 May 2006 (UTC)

To operate the D&D version of the newstat template ({{newstat2}}), the simplest form you need is to put {{newstat2|name=Character name}} in your article somewhere. That will make:

Character name



From there, you can add in all the detail you want by adding on additional variables after 'name', like {{newstat2|name=Character Name|CR=12|AC=18}}, which gives:

Character Name CR 12


AC 18



The sample code snippit shows all the possible variables you can pass to the newstat2 template. Whitespace (spaces, returns, tabs, etc.) don't matter before and after the pipe (|) separating the variables, so for legibility, they're broken up onto multiple lines. You can make them all on one line if it helps you read it, and ensure that each variable is separated from the next by a pipe symbol.
I'm afraid I won't be much help with the D20 Modern template as I've never played by those rules, so don't know how the newstat2 template would need to be modified to make it work for you.
--MidnightLightning 13:42, 17 May 2006 (UTC)

How did you do that?!

I've recently revisted this site and found a lot of awesome wiki stuff going on!

I'm interested how you got the random roll of Template:DieRoll to work and how to get the if statements to work from Template:DMG22.

Could you point me in the direction of some instructions on how to implement them on my site?

I've spend a bunch of time looking it up on my own and I'm finding the templates here a bit to complex to follow. Many thanks! --Wizardoest 03:38, 17 May 2006 (UTC)

Okay, to explain Template:DieRoll, I borrowed the die rolling JavaScript from d20srd.org and modified it to allow dice rolls like 3d10*5 in addition to 3d6+14 and 2d4-2. In order to use this JavaScript in a Wikicities Wiki, I had to jump through a few hoops. If your wiki is your own website, you have more freedom, and your best bet is to use an extension to get the JavaScript onClick command attached to the link text. The one I wrote for my wiki is:
<?php
# Dice Roller extension
# To activate the extension, include it from your LocalSettings.php
# with: include("extensions/dieroller.php");

$wgExtensionFunctions[] = "wfDieRoller";

function wfDieRoller() {
    global $wgParser;
    $wgParser->setHook( "roll", "rollDice" );
}

# The callback function for converting the input text to HTML output
function rollDice( $input, $argv ) {
	$output = "<a href=\"javascript:void(0);\" class=\"diceRoller\"
onclick=\"rollValue('".$argv['title']."','".$argv['dice']."');\"
title=\"Roll the Dice!\">".$input."</a>";
    return $output;
}
?>
Then, if I use <roll title="Damage" dice="3d6+2">Attack!</roll> it will create the dice link, and then I added the JavaScript to the Monobook header to have it be available on every page.
For working with WikiCities, where I can't just install an extension, I added the JavaScript to the Monobook.js file (which you can access via MediaWiki:Monobook.js, though only SysOps can edit it). And, because I can't define an onClick attribute using Wikitext (it will get stripped off of any HTML tag you put in the aticle body), I had to use some clever JavaScript to, onLoad of the page, find all <span> tags of a specific class, and dynamically add an onClick attribute to them. So, the Template:DieRoll sets up the span with the correct class, and encodes into the class the title and dice code, which the onLoad JavaScript puts into an onClick when the page loads.
That all make sense? :) --MidnightLightning 15:12, 17 May 2006 (UTC)

I came to your talk page to ask you about the dice roller, and found this thread. I don't have the knowledge to repeat what you did, but I'm trying to get a die roller on my campaign wiki, where I am in much the same situation as at WikiCities. Would it be possible for you to post 1) the JavaScript you posted to Monobook.js, 2) the "clever JavaScript" mentioned above? If you could, I would be very grateful. ACodispo 02:17, 16 June 2006 (UTC)

I've just realized how silly my question was. I've gone to Monobook.js and seen the code for myself. Sorry, still getting used to the openness of a Wiki. Forgive the annoyance!

Also, any idea whether or not the code, as it stands now, should work with MediaWiki 5.5? Or is it limited to 6? -- ACodispo 02:33, 16 June 2006 (UTC)

The javascript should stand up just fine in MediaWiki 5.5; the only real earth-shattering change to the 6.0 version (at least from the point of view of how I write code) was the added functionality of having a default value for variables in templates. This function does use a template, but not that feature, so it should work out. --MidnightLightning 13:39, 16 June 2006 (UTC)

Mass Vandalism

Hey, could you take care of the IP vandalizing recently? It's a bit much to do by hand... I understand the admin control panel is pretty good about mass reverting.

While I'm at it, any chance I might be able to be made admin too, in case this comes up again and I see it while you're out? Fieari 02:43, 10 July 2006 (UTC)

There is no mass un-edit command (and no admin 'control panel' either). Though through chatting with the Wikia admins, I did get a few extra hands to make light work of undoing 71.107.251.78's mischief. That IP address has been blocked (making two on the list of mass vandals this Wiki has gotten), so shouldn't happen again anytime soon. Some of the edits included advertisements from Bobby Boulders for the International Society of Vandals (ISV) (sample here). I reported this to Wikia and they recognized the name as one who was on their IRC chat yesterday making threats and promises of attacks against Wikia and Wikipedia, so they're currently searching more more Wikia wikis that were hit by this guy/gal.
Regarding your other comment about becoming an administrator, I've posted your request for nomination to the Community Portal page, and we'll see if there's anyone else has any comments on your nomination. --MidnightLightning 15:54, 10 July 2006 (UTC)

We've been hit one more time by Bobby, who this time created a User Account, and vandalized 39 pages on this wiki. They have all been reverted (thanks to a lot of help from Stanoje), and that user account blocked. --MidnightLightning 16:01, 27 December 2006 (UTC)

"Stanjoe"? :-) --Stanoje
My apologies, Stanoje, my Americanized mind apparently wanted to see the names "Stan" and "Joe" in your name, rather than what was really in front of me. Spelling corrected above. --MidnightLightning 14:57, 28 December 2006 (UTC)
No worries. It's not the first time, believe me :-) --JoeStan

Show/Hide box javascript

I mentioned this in the community portal, but I thought I'd put it on your talk page since you're most likely to be able to help.

I've been trying to add "Click To Show" navigation support to our wiki, as seen on Wikipedia on their Good Article page, where everything is hidden until you click the appropriate "show" link. I've copied their relevant js from [1] and their css from [2], putting it in MediaWiki:Monobook.js and MediaWiki:Monobook.css, respectively, but my test page at User:Fieari/TestNavBar doesn't seem to be working.

Can you see what might be going wrong? Fieari 00:36, 17 September 2006 (UTC)

And this is why I love Firefox. A quick trip to the JavaScript Console figured this one out: "addLoadEvent is not defined". At the end of the JavaScript snipped you copied from Mediawiki, it calls the addLoadEvent function to add the creation of the rollbars to the load event of the page. This isn't a standard JavaScript function, but defined earlier in their Monobook.js file. I copied it to our Monobook.js file, and your page works fine now.
--MidnightLightning 15:11, 18 September 2006 (UTC)

Re: Named Projects Edits

Aryathanjiil, thank you for all your contributions to the various "Named" projects; I'm sure the DMs appreciate your contributions. One request though, from the point of view of an administrator watching this wiki for vandals and appropriate content, editing a page many times a day with minor changes fills up the Special:Recent Changes listing quite quickly with all your edits, making it harder to search through and find any malevolent edits (we have been hit by a vandal several times around the holidays, so I've been keeping my eye on unusually high edits-per-day numbers to make sure they haven't come back). If it's possible in your workflow of adding new content to those project pages, could you keep the page open after your minor changes and not do a final save until you may be done with the page for a while? If this cramps your style too much, don't worry about it; I presume you'll run out of material to search for unlisted fiend and celestial names eventually, and I can work around you for the time being. Thanks! --MidnightLightning 13:48, 8 January 2007 (UTC)

I really appreciate the comments. I had thought to do just as you mentioned (larger and fewer edits) but didn't for some reason. I will do so from now on to make your life easier ;). I would probably add them to a word editor and make a single edit per day at the most. However, just as you mentioned, I am running out of source material. So what is there is probably the bulk of what I can add for now. Feel free to comment or give advice anytime. This is my first step into editing Wiki pages, and I only fumble through the code (html?) until it looks right.

Links to other Wikis

Hi, I found this site through a google search and have found it very helpful! My question was would there be an interest in a link exchange between this wiki and mine at d6d20.com? We have recently launched a d20 Modern SRD wiki, which I think would be of use to the members of your community, and this site would be of use to members of mine. Please let me know if this is something we can work together on.

Bazin

Sure, since your wiki seems to be geared toward SRD content rather than NPC content, it looks like we could co-exist without stealing each others' users. I've added a link to your wiki on the main page, and its up to individual users to make updates to the D20 Modern pages on this wiki to link to the SRD content on yours if they feel the calling. If you'd like to place a reciprocal link, that would be great. --MidnightLightning 03:19, 4 October 2007 (UTC)

I've added a link on the wiki as well as the main site. Bazin

Responded on Talk page, and need help

I responded to your question on my talk page, and I also have a favor to ask you.  SkyeNiTessine (talk · contr) 23:05, 16 June 2008 (UTC)

4EStatBlock template

Do you have an old copy of the 4EStatBlock? I can't easily recreate that... at all. If you do, please send it to terrydu@gmail.com. Otherwise I'm really screwed!  SkyeNiTessine (talk · contr) 02:25, 20 June 2008 (UTC)

No problem, as I mentioned, I (as an admin) can view 'deleted' pages, so I've eMailed you the contents for your personal use. --MidnightLightning 02:57, 20 June 2008 (UTC)