
Microsoft makes it easier to build Minecraft Mods using Visual Studio - Navarr
http://blogs.msdn.com/b/visualstudio/archive/2015/04/30/hello-minecraft-modders-visual-studio-loves-minecraft.aspx
======
burningion
This is incredible. Getting Minecraft modding working in Visual Studio is how
you are going to get the next generation of kids interested in programming.

If you haven't watched a 12 year old play Minecraft, you need to do so. It's
the ultimate fantasy universe, and the way you combine elements to make
something new is very analogous to programming in the vanilla game.

Adding a way to customize this universe will just explode the interest in
programming among young people.

It's really unfortunate that there is so much time being devoted to "teaching
programming" to kids, instead of "teaching playing on computers". "Teaching
programming" feels serious and adult, and doesn't leave room for fun.

I've had said 12 year old try multiple times to "learn programming", only to
give up when things aren't as great as they'd imagined in their head, after
having spent hours just trying to figure out the right version of Python, and
how to get a shell set up, and how to get something on the screen.

Imagine the result of having your for loop create millions of blocks
accidentally in your universe, and seeing that mistake happen in a non-
threatening way. This is the sort of thing that makes computing and abstract
thinking easier for everyone.

Giving an open universe to kids with the blocks to effect their world is just
an insane tool. Kudos to MS for the hard work, and putting it out so early.

~~~
zeidrich
As a kid, my programming career started with Visual Basic, a little bit of
that and qbasic.

But my dad had a copy of Visual Basic with our old computer back in the early
90s. That along with Gorillas on qbasic was really my first entry into
programming.

Back then I was about 9 years old, I really wanted to make computer games, I
was pretty smart, but in 1991, a kid with no resources has a hard time
breaking into programming.

But QBasic had gorillas, which was a GAME! And it was in basic, and so the
source code was right there for me. I didn't have books really, because while
you got QB with your operating system, you didn't get manuals for it or
anything. But the Visual Basic came with books, and help.

Not only that, it used the same language as gorillas, more or less, and I
could drag and drop elements on to the canvas.

By 9 or 10 I made my first "RPG" in visual basic. I used an array of picture
boxes as tiles. I had 4 buttons that were directional arrows. And when you
clicked one of the directional arrows it would figure out where your player
was, see if he could go into the next tile based on what picture it was, and
if it could, it would swap the picture of the destination with the picture of
the player, the original picture of the player with the original picture of
the source. I don't remember if I tracked the position of the player by x/y
coordinates or if I just scanned through all of the tiles to find the first
one with the player image.

But what I do know was that by 9 or 10 I had made myself a little "game" where
you had a top down grid that you could make a player walk around on, and that
moved to something that spawned random encounters that were in another window.

I look at what I had as tools, and it was so little. I didn't even have a
single book about programming. All I had was gorillas and some help docs for
VB. But I was so proud of what I'd made. I ran into some of the pitfalls of
memory management when all of your tiles are giant windows objects in VB.

Later I started to learn to get VGA graphics with mode 13h which I found out
about from a copy of the Peter Norton's Guide to Programming the IBM PC that I
got from the library. I wrote some inline assembler in basic to do some basic
putpixel getpixel stuff. I did a lot of cool stuff there but ran into some of
the limitations of trying to work with BASIC.

From there my dad had a copy of Borland C++ from his office that I used,
mostly just learning C, and when I got access to the internet I started using
turbo pascal.

In high school at about 14-15 I had friends who showed me MUDs, and a few of
us worked on a little MOO. I took some of my knowledge and a copy of Visual
C++, and implemented a little terminal emulator that would connect to the MOO.
Then I had some rooms send some additional codes that the terminal emulator
would parse and display things on the screen. I made a pseudo MMO before MMOs
were a thing. There were MUDs, but very little graphical existed, there were
things like The Realm, which was sort of the same type of idea, but I didn't
know about it at the time.

The reason I'm telling this story isn't to say how great I am. My point is
that I read about these stupid programming curricula in school that are
mandatory for kids. As though sitting them down and forcing them to program is
going to help them. I had to do some of that in my own school career, in
having to do LOGO WRITER stuff in computer class. But doing that, I could
barely even tell that that was programming. And even if the teachers told me
it was, it wasn't the kind of programming I wanted to do. That's just drawing
spirographs on the screen. I wanted to make games.

It's the same way as learning to write "Hello World" and store a variable, and
calculate some tax on a price and all the other incredibly boring stuff that
introductory programming classes have you do.

People assume kids are stupid. They assume that they have to give them the
most basic foundations or they will not be able to learn. Teachers don't want
to teach kids to make games, not because they don't want it to be fun, but
because of an idea that a game is way too hard to start with. That you have to
build up the foundations first. That you need to teach the fundamentals,
master them, and then move on to the next marginally more challenging step.

Well, maybe not teachers, I know a lot of good teachers, but the people who
write the curriculum think that. Because you need to be able to test and
evaluate, so you need to know that you can check of a box that says the kid
knows how to do variable assignment, create a function, get input, whatever
else.

But I didn't have that shit. I had gorillas.bas I didn't know what "EGABanana:
'BananaLeft DATA
458758,202116096,471604224,943208448,943208448,943208448,471604224,202116096,0"

meant. Nobody taught me that. But I think BECAUSE nobody taught me that, I
wasn't afraid to just mess with the numbers a little bit, run it and see what
happened. Oh, changing those numbers changes the way that the banana looks? Ok
cool. I mean, there was trigonometry, there was all sorts of stuff that even
now looking again through it it takes me a while to parse.

But I didn't care. I tried to look through for something that I could
understand, I picked it out, I figured out how it worked, and then I had one
piece of the puzzle solved. Now all of the FOR, NEXT loops make sense, and I
can use that in my other program.

Now I imagine the 9 year old me in today's world. I don't have to rely on my
parents having bought VB or Borland C++, I can download Visual Studio for
free. I have the ability to create a minecraft mod in a matter of minutes
which on its own is interesting enough, but it basically means I have a tile-
based game engine at my disposal, but I'm also writing raw code and not just
strapped into some Logo-writer type sandbox. If I have a question the Internet
can answer it 150 different ways.

Honestly, the only thing I worry about is that by the time 11-year old me
starts to work on something like this I will have decided I hate programming
because of the kind of soul-sucking programming curriculum I've had to work on
in computer class so I don't even bother trying.

It's like Math. I think math is really awesome and interesting. It's artistic,
it's simple, it's complex, it's beautiful, it's actually fun and engaging.
Math and programming are very similar in that way. But ask a selection of 10
year olds what they think of Math and they will almost all tell you they hate
it. But it's not math that they hate, it's the way they have had it fed to
them. It's like force feeding someone pureed boiled chicken every day. You ask
them if they like chicken and they'll look at you like you're crazy. Chicken
is disgusting.

~~~
sinatra
Wow, I also stumbled upon programming through Gorillas on QBasic. I used that
code as a guide to write my first game. A lot of copy-pasting that code and
then modifying it just to see what the modification would do. Extremely slow
learning by trial-and-error, but a lot of fun!

------
neovive
This looks great for more experienced programmers. If you're working with
younger kids, using Minecraft as a way to introduce programming, here are some
good options:

* Minecraft Pi - code and run Minecraft mods in Python ([https://www.raspberrypi.org/learning/getting-started-with-mi...](https://www.raspberrypi.org/learning/getting-started-with-minecraft-pi/)). If not running on a Raspberry Pi, you can use Raspberry Juice ([http://dev.bukkit.org/bukkit-plugins/raspberryjuice/](http://dev.bukkit.org/bukkit-plugins/raspberryjuice/)) which implements most of the Minecraft Pi API.

* Scriptcraft ([http://scriptcraftjs.org/](http://scriptcraftjs.org/)) - create mods using Javascript.

* LearnToMod ([http://www.learntomod.com/](http://www.learntomod.com/)) - commercial service that allows modding using a visual language (I think they use Blockly which is similar to Scratch).

~~~
vectorjohn
Why on earth would you get raspberry pi into the mix with Minecraft modding?
Python for mods seems great, but that's just using extra hardware for the sake
of it.

~~~
dmoo
Because the Pi version of minecraft has an api
[http://wiki.vg/Minecraft_Pi_Protocol](http://wiki.vg/Minecraft_Pi_Protocol)
Also if you have younger kids check out
[https://github.com/scratch2mcpi/scratch2mcpi](https://github.com/scratch2mcpi/scratch2mcpi)
run a scratch extension on your pc and place blocks in minecraft on the Pi. It
goes down well at our local coderdojo.

~~~
neovive
The scratch2mcpi sounds great. I mentor at a local coderdojo as well.

------
Macha
Sometimes solutions that have evolved over times end up being ludicrous in
retrospect.

* Microsoft are releasing a game.

* Where they obfuscate the code so people can't read it

* And mod tools

* Built on community scripts

* Which decompile the code and rename the obfuscated variables to give readable names

At what stage does it make more sense for MS to tell Mojang to drop the
obfuscation and move to a "visible source" model?

~~~
iwwr
The objective was to protect Mojang's IP on the (probably mistaken) idea that
if they release the source code it means they lose control over it.

Added to that, my own speculation is that members of the modding community
want to keep the barrier to entry for writing mods relatively high, for some
reason or another. Some modders, including the brilliant Eloraam (maker of
RedPower), want to maintain their own mods as proprietary and obfuscated.

~~~
UberMouse
They don't have to release the source code. They just need to stop running the
bytecode through an obfuscator.

~~~
deathanatos
I don't even think they need go that far: only the bits that would form some
sort of stable API would need to not be obfuscated. They could still do
whatever with anything internal.

------
TOMDM
As an aside, I think it's worth looking at the Minecraft communities thoughts
on the 'official' modding api for the game.

Dinnerbone (aka Nathan Adams, the most community orientated Dev on mojangs
Minecraft team) recently tweeted "Just a reminder: there is no official way to
mod Minecraft & we still do not officially support mods. We are still working
on the plugin API" and the community sentiment shows that they really are
getting sick of the ever prolonged promise of a modding api.

The comments on the reddit thread about dinnerbones tweet are largely hostile.

[http://www.reddit.com/r/Minecraft/comments/34ffag/dinnerbone...](http://www.reddit.com/r/Minecraft/comments/34ffag/dinnerbone_on_twitter_just_a_reminder_there_is_no/)

------
kohsuke
I always thought a better way to combine programming & minecraft for kids
would be something like ComputerCraft
([http://www.computercraft.info/](http://www.computercraft.info/)), where you
can program a robot inside the Minecraft world to do stuff for you, like
building road/bridge, digging tunnels, etc.

ComputerCraft is Lua-based, but I can imagine something similar based on CLR,
and that way you can let kids program in C# from Visual Studio.

Programming a bot is much simpler and even a very simple program (like digging
a tunnel straight) is instantly gratifying. Writing a mod has a much higher
barrier to the entry, AIU.

------
erikb
I love that Minecrosoft under it's new leadership works harder on doing cool
stuff. That really puts it back more in focus, at least for me. Maybe I'm even
switching back one day, who knows.

~~~
nacs
This is a good move by MS but most of this work is done by the Forge team [1]
which is a community of open source people that have been doing the hard work
for years -- they deobfuscate/reverse engineer Minecraft code and build an API
for it.

MS has basically just packaged up a way for working with that API through
Visual studio (before this, you would have used Eclipse or any other Java IDE
and still can).

[1]:
[https://github.com/MinecraftForge/MinecraftForge](https://github.com/MinecraftForge/MinecraftForge)

------
ryanburk
the brilliant long play here is that if I program with my kids using this,
they are growing up on the VS IDE. gets them in the ecosystem really early.

~~~
pbhjpbhj
Was this possibly at the forefront of the decision to buy Minecraft - like how
do we get kids in at the ground floor; or is that so obvious I should kick
myself for not seeing it before. I saw it as a userbase acquisition before but
didn't see how it fed in to their other business outside gaming, smart.

------
dikaiosune
Is this a new venture to support Java in VS? I was under the impression that
they didn't really do Java in the MS IDEs. If so, that's far bigger news than
Minecraft-specific support.

~~~
billyhoffman
I hope so. They would have and some code/features left over from a decade ago
when you could write "java" code in Visual Studio as VisualJ. Conceivable the
interfaces for hooking the debugger, the syntax highlighting, and all that
jazz that VS already has to support could be (re)extended to support the JVM
and JRE once again

~~~
JonathonW
Doesn't look like it; looks like it's all based on open-source tools written
by third parties. Syntax highlighting, Java project support, and the debugger
come from the Java Language Support VS extension [1], and Intellisense support
is being pulled from a bundled Eclipse instance running the Eclipse Java
tools.

[1]
[https://visualstudiogallery.msdn.microsoft.com/bc561769-36ff...](https://visualstudiogallery.msdn.microsoft.com/bc561769-36ff-4a40-9504-e266e8706f93)

------
evo_9
This is pretty awesome. Hopefully they figure out a way to allow me to write
my mods in C#, that would just sweeten the deal that much more (I know
Minecraft is a Java app, just saying that would be a cool feature if they can
work that out).

~~~
Sir_Cmpwn
This project of mine may interest you:
[https://github.com/SirCmpwn/TrueCraft](https://github.com/SirCmpwn/TrueCraft)

~~~
scrollaway
I'm excited. How far along is it?

~~~
Sir_Cmpwn
Check out the blog: [http://truecraft.io](http://truecraft.io)

It's got:

\- Multiplayer support

\- Entities (items, sand, gravel)

\- World and player data persistence

\- Crafting

\- Farming

\- Procedural terrain generation

About 10% of the world logic (i.e. the movement of water, growth of plants,
behavior of doors) is implemented. Notably missing: mobs, combat, redstone,
smelting.

------
smrtinsert
I thought Minecraft had no official SDK for modding? I think that would be a
nicer first step.

~~~
oldmanjay
It seems, although I say this having no actual knowledge, that Microsoft is
preparing to release a .NET version of Minecraft. I suspect that's a big
driver for the ongoing push to federate the framework across the major
platforms. I would imagine any official modding API would happen once that
release is complete.

Granted, I could be totally wrong on this, but it's fun speculation.

~~~
TillE
> a .NET version of Minecraft

That would be really quick. It's only been about seven months since the
acquisition, and Minecraft is not a simple game. I have no doubt they are
rewriting the game (or a sequel) from scratch, but I wouldn't expect to see it
any time soon.

~~~
magicalist
Yeah, the team is still actively tweeting updates about adding features and
refactoring parts of the original code base. There's not even a slight chance
a port would be even out of the planning stages.

Even the most gung-ho C# pusher at Microsoft would also ask what benefit
porting it would give. Years (if we're being realistic) just to get to feature
parity all so it runs on top of .NET?

------
lucasmullens
Gaming gets so many people into programming. I started with GameMaker when I
was 10 and I know plenty of people who've started with modding. This is
fantastic.

------
rurounijones
I keep on getting asked to login, anyone got a non-login site?

------
kristianp
I can't get to the page without logging in to my Microsoft account. Very
strange.

------
istvan__
Finally I got it, all of these new projects from MS, and the real reason is:
to build Mincecraft Mods! :) I could not approve the new direction MS is
taking.

~~~
qbrass
Windows 11 will just be Minecraft with a web browser and the ability to run
Office.

Improving the ability for people to make mods now will provide an ecosystem
for future Windows app development.

~~~
PhasmaFelis
Finally, a solid platform on which to implement the ideas from "Doom as a tool
for system administration."
[http://www.cs.unm.edu/~dlchao/flake/doom/](http://www.cs.unm.edu/~dlchao/flake/doom/)

------
PhasmaFelis
Part of me wants to bitch about what a missed opportunity it was, letting
Microsoft take over and tie this to their own dev environment.

But on the other hand, taking even a single step back from the previous
(effectively) actively hostile approach to the modding community (needlessly
obfuscating the bytecode, promising and then pushing back mod tools) is more
than we had under Notch.

------
emodendroket
I don't have much interest in Minecraft, but it's interesting to see that you
can now use Visual Studio to write Java.

------
giancarlostoro
Microsoft sneaks Java into Visual Studio.

------
voltagex_
And it's open source!

[https://github.com/Microsoft/vsminecraft](https://github.com/Microsoft/vsminecraft)

------
hobarrera
Does anyone have a link that doesn't require registration to read?

------
gcb0
but i still have to $19 to download the windows phone emulator to use with the
free VS2013 comunity edition... sigh

~~~
badlam
no you don't, just click on download link. You may need an account to publish
it.

~~~
gcb0
yes i do.

clicked on the update notification. it took me to a sign up page (after i
logeed in with my MS account) in the browser. i signed up. it said i had to
have a special account and that i could register. the second page on the
registration force me to choose either individual for $19 or enterprise for
some other value.

there is absolutely no way on that flow to download it. i always get to that
page.

~~~
gcb0
OK, after getting the link somewhere else and starting the installer it tells
me that i can't install on windows 7

somehow the download link, directly from VS, sees that I'm on windows 7 and
instead of telling me that keep sending me to the payment screen. clever
Microsoft...

------
malkia
This is some serious fun! My son would love it...

But I no longer have Windows machines (couple of croutonized chromebooks and
iBooks)...

Anyone had an idea?

~~~
nacs
The Forge API [1], which this is basically just a wrapper for, is already
available on every platform (it's Java).

You could use Eclipse or any Java IDE.

[https://github.com/MinecraftForge/MinecraftForge](https://github.com/MinecraftForge/MinecraftForge)

------
deevus
Link seems broken to me

------
yarrel
Won't someone think of the children?

