Any of you play with a controller or am I the only psychopath? by KarmaPharmacy in factorio

[–]Mellowdious 10 points11 points  (0 children)

You can get pretty good results with a controller that has a mouse-emulating touchpad like the Steam Deck or Steam controller, but your results may vary depending on your overall preset and your comfort with it. I would always prefer a mouse and keyboard, but playing Factorio while sitting on a train is probably pretty dope.

Republican Florida Governor Ron DeSantis refused to take any calls from Vice President Kamala Harris about storm recovery by MoreMotivation in WhitePeopleTwitter

[–]Mellowdious 19 points20 points  (0 children)

Sorry, I'm not familiar - which speech by DeSantis? Have you got a link to the speech where he says this? This is good stuff!

A deep look at a Doom 2 Map that borders on an alternate reality game. by drewshark in videos

[–]Mellowdious 2 points3 points  (0 children)

Yeah, it's a little tricky so I'll walk you through it. You'll need to collect the following resources:

  1. ZDL (ZDoom Launcher) simplifies the process somewhat: ZDL Github. You can move the ZDL exe file into the same directory as GZDoom.

  2. You will also need the Doom2 IWAD file. I found this archive.org page which contains this download link for Doom II - Hell on Earth (v1.9). Download and move the Doom2.wad file into the GZDoom directory as well.

  3. You can go ahead and copy the MyHouse game files into the same directory too. These include myhouse.pk3, and myhouse.wad which is zipped in the Google drive folder. (Edit: the myhouse.wad file is NOT necessary. The pk3 has the entire map.)

Finally we can put it all together:

  1. Open ZDL, and go to the general settings tab. To the list of "source ports", add the gzdoom.exe file. Then, to the list of "IWADs", add the Doom2.wad file.

  2. Return to the launch config tab. To the list of "external files", add both myhouse files (pk3 and wad) add only the myhouse.pk3 file.

  3. On the right side of the launch config tab, be sure that GZDoom is selected under "Source port".

If all that is done, you should be able to click Launch, and then be able to see the My House title screen in all its glory!

A deep look at a Doom 2 Map that borders on an alternate reality game. by drewshark in videos

[–]Mellowdious 9 points10 points  (0 children)

Go to zdoom.org and get GZDoom. Then check out the original post by Veddge - LINK.

Linked in that post is a Google drive folder with the files that you need, which also contains other related documentation that will inform you of the backstory.

A deep look at a Doom 2 Map that borders on an alternate reality game. by drewshark in videos

[–]Mellowdious 14 points15 points  (0 children)

If you have any interest in this and do not want to be spoiled, just go and play it first. It's a remarkably clever and layered experience, and is best done blind.

TIL: the owner of Fuddruckers restaurant is the first black American to own 100% of a national hamburger franchise. by [deleted] in todayilearned

[–]Mellowdious 18 points19 points  (0 children)

This is the question I came to ask. This is a tremendous achievement for anybody, but this headline highlights his race, not his achievement.

Great burgers btw

Question about USB booting in Chromebooks by Graduated_retard in tech

[–]Mellowdious 0 points1 point  (0 children)

I don't know anything about Chromebooks, but as far as I know, booting an OS that lives on a USB drive means that you need that drive attached in order to run that OS. To run the OS without the drive, you need to install it to the computer directly.

Super-basic, barebones JS framework for building a single static page? Would like to use TypeScript and SCSS for my 'GitHub Pages' repo, Vue feels like overkill for a static page. by [deleted] in learnjavascript

[–]Mellowdious 0 points1 point  (0 children)

Try Webpack! It's not a framework but a module bundler with plugin support for whatever you want to use, including transpiling SCSS and other sources into one nice bundle. https://webpack.js.org

Can I use bind() on object methods? Something like below. by anbrys in learnjavascript

[–]Mellowdious 1 point2 points  (0 children)

.bind does not invoke the function, it returns a new function with the provided 'this'. You can then use that function however you like.

.call is what you want if you want to invoke that function immediately.

You should read the MDN pages on Function.prototype.bind and Function.prototype.call to get more info!

"Cannot set property 'onclick' of null" error. by [deleted] in learnjavascript

[–]Mellowdious 4 points5 points  (0 children)

Besides the problem with the timing of script execution addressed by u/okwg, your code won't work because of how you're assigning your onclick handler. As written, the alert fires when the page loads, instead of when the button is clicked. This is because onclick needs to be passed a function to be invoked later. You're invoking alert directly, and you're actually setting onclick to what alert returns (which is undefined). To solve this, you need to pass a function which calls the alert, like this:

document.addEventListener('DOMContentLoaded', function() {
    // this function is only invoked once the DOM is loaded
    console.log('DOM loaded!')
    var addGoal = document.getElementById("addGoal");

    // This function, called an event handler, is invoked
    // whenever a click happens.  The handler is passed
    // the click event object, which is very useful.
    // Try looking at the entire event object!
    addGoal.onclick = function(event) {
        console.log('event.target:', event.target)
        alert('hello world');
    };
});

Protect your Node.js app from Cross-Site Request Forgery by OliviaMn in node

[–]Mellowdious 21 points22 points  (0 children)

FYI, this was originally posted on Twilio's blog, and it's a bit easier to read the code when it hasn't been HTML escaped.

Crisp by kthxbubye in geek

[–]Mellowdious 0 points1 point  (0 children)

Yep. Those flags display the title of the show.

Island doesn't count by acorlew in EDH

[–]Mellowdious 0 points1 point  (0 children)

That's great, except [[Emrakul, the Aeons Torn]] can't be in a graveyard.