Minecraft An Introduction Copyright © 2015 – Curt Hill.

Slides:



Advertisements
Similar presentations
1 Copyright © 2005, Oracle. All rights reserved. Introducing the Java and Oracle Platforms.
Advertisements

Global States.
P5, M1, D1.
Introduction to JavaScript
Dr. Ashraf Armoush Supervisor Oday Jihad Ibrahim Tariq Ziad Yameen.
10 Software Engineering Foundations of Computer Science ã Cengage Learning.
Introduction Rich Internet Applications OpenLaszlo as an RIA Examples Community Competitors OpenLaszlo Architecture OpenLaszlo XML Structure Dealing with.
Chapter 1 Program Design
SM3121 Software Technology Mark Green School of Creative Media.
Software Development Unit 6.
COMPUTER TERMS PART 1. COOKIE A cookie is a small amount of data generated by a website and saved by your web browser. Its purpose is to remember information.
Software Design & Development Software Design & Development Programming Types Event Driven Programming Event driven programming Is a type of programming.
Flash Cards Computer Technology.
1 Software Development Topic 2 Software Development Languages and Environments.
Software Construction and Evolution - CSSE 375 Reverse Engineering Tools and Techniques Shawn & Steve Left – Reengineering from the competition can be.
Java Beserkers Group 4. Start of Java Development began on June of 1991 by a group of computer scientist at the Sun Mircrosystems Company Development.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming 1.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
Scalable Statistical Bug Isolation Ben Liblit, Mayur Naik, Alice Zheng, Alex Aiken, and Michael Jordan, 2005 University of Wisconsin, Stanford University,
11 A First Game Program Session Session Overview  Begin the creation of an arcade game  Learn software design techniques that apply to any form.
Introduction to Programming Peggy Batchelor.
9 Chapter Nine Compiled Web Server Programs. 9 Chapter Objectives Learn about Common Gateway Interface (CGI) Create CGI programs that generate dynamic.
Copyright © Curt Hill Sounds, Resource Packs, JSON What more would you want?
Copyright © 2009 Curt Hill The Picture Object Getting and displaying.
Copyright © 2015 Curt Hill Models and Textures Making your entity interesting.
Copyright © 2015 Curt Hill Environment Establishing one for Minecraft Modding.
Systems Software Operating Systems. What is software? Software is the term that we use for all the programs and data that we use with a computer system.
Copyright © 2015 – Curt Hill Version Control Systems Why use? What systems? What functions?
Copyright © 2013 Curt Hill Database Security An Overview with some SQL.
Component Technology. Challenges Facing the Software Industry Today’s applications are large & complex – time consuming to develop, difficult and costly.
Copyright © Curt Hill First Window Builder Program Easy GUIs in Eclipse.
Chapter 3 Software. Learning Objectives Upon successful completion of this chapter, you will be able to: Define the term software Describe the two primary.
CE Operating Systems Lecture 3 Overview of OS functions and structure.
Copyright © Curt Hill Connectivity Communicating with the Database.
Copyright © 2015 Curt Hill Java for Minecraft Those things you should know.
Copyright © Curt Hill The IF Revisited If part 4 Style and Testing.
Copyright © 2004 – 2013 Curt Hill Java Debugging In Eclipse.
Copyright Curt Hill The C/C++ switch Statement A multi-path decision statement.
M1G Introduction to Programming 2 5. Completing the program.
Copyright © Curt Hill Loop Types and Construction Logical types and construction hints.
 Programming - the process of creating computer programs.
Parser Generation Using SLK and Flex++ Copyright © 2015 Curt Hill.
Web Services An Introduction Copyright © Curt Hill.
Reverse Engineering. Reverse engineering is the general process of analyzing a technology specifically to ascertain how it was designed or how it operates.
11 Computers, C#, XNA, and You Session 1.1. Session Overview  Find out what computers are all about ...and what makes a great programmer  Discover.
The single most important skill for a computer programmer is problem solving Problem solving means the ability to formulate problems, think creatively.
1 Service Oriented Architecture SOA. 2 Service Oriented Architecture (SOA) Definition  SOA is an architecture paradigm that is gaining recently a significant.
Recipes How to craft items from others Copyright © 2015 Curt Hill.
Chapter – 8 Software Tools.
M1G Introduction to Programming 2 2. Creating Classes: Game and Player.
TEALS MINECRAFT PROJECT Lecture 1: Intro to Minecraft Forge.
Program Design. Simple Program Design, Fourth Edition Chapter 1 2 Objectives In this chapter you will be able to: Describe the steps in the program development.
Some of the utilities associated with the development of programs. These program development tools allow users to write and construct programs that the.
OPERATING SYSTEMS (OS) By the end of this lesson you will be able to explain: 1. What an OS is 2. The relationship between the OS & application programs.
Copyright © 2016 Curt Hill Static Code Analysis What it is and does.
Introduction to Object Oriented
Getting and displaying
14 Compilers, Interpreters and Debuggers
Done By: Ashlee Lizarraga Ricky Usher Jacinto Roches Eli Gomez
Not a Language but a series of techniques
Introduction to programming
Getting started in Alice
Net 323 D: Networks Protocols
System And Application Software
Data, Databases, and DBMSs
Applets and HTML Chapter 13.
Unit 20 Software Part 2.
Unit 20 Software Part 2.
The Java switch Statement
Chapter 3 Software.
Presentation transcript:

Minecraft An Introduction Copyright © 2015 – Curt Hill

Introduction A curious phenomenon! A game with many modes It trades good graphics for in- character environment creation May be played by very young but still has interest for the mature

History Original developer was Markus Persson in 2009 Inspired by several previous games that it was transcended Mojang was the owning company Purchased by Microsoft for 2.5 billion dollars Is available on PCs, Macs, Android, iPad, XBox, PlayStation and numerous other platforms Copyright © 2015 – Curt Hill

Characteristics Open world type First or third person Several modes of play –Survival –Creative –Adventure –Spectator –Demo Single and multiple player Copyright © 2015 – Curt Hill

Modes Survival mode – Scavenger hunt to gather resources –Creating tools is part of game Creative – Create environments and objects –None of the limits of survival mode Adventure – Set down in a created world –Author limited creation and destruction Copyright © 2015 – Curt Hill

Java Minecraft is a game that is completely written in Java This is both good and bad The Good –Nearly platform independent –Lots of Java programmers –Decompilable The Bad –Somewhat slower –Decompilable Copyright © 2015 – Curt Hill

Decompilable The decompiler has been a dream in CS for decades It takes an executable and produces the high level language that produced it In general this is a dream that cannot be done However, in Java it is possible Copyright © 2015 – Curt Hill

What makes Java different? There is only one compiler –Makes it easy to see characteristic code constructions and infer what caused them Each class must be in a file that has the same name –Even when packed into a jar file The reflection feature –ability to examine and modify the structure and behavior of an object at runtime Copyright © 2015 – Curt Hill

Reflection Again Reflection gives us the ability to ask a class if it has a particular method It also allows us to call that method To look for methods not knowing if we will find them and execute them if we do: String s = … Method mthd = foo.getClass().getMethod(s, null); method.invoke(foo, null); We did not know what the name was until we found it Copyright © 2015 – Curt Hill

Good and Bad? The decompilability issue is both good and bad For the owners their code is exposed –They are somewhat protected by copyright –Derived code could be disguised and marketed by a competitor For the modders we can change anything –More power than in most modifiable games Copyright © 2015 – Curt Hill

Obfuscation The owner’s answer is obfuscation The word means to confuse or disguise The process generally involves: –Transforming the names into meaningless ones –Refactoring classes –Reorganizing flow of control To be useful in this case it must be done and undone by program Copyright © 2015 – Curt Hill

Process The author’s need to be able to write, debug and maintain code in its original, highly understandable form They then obfuscate by program The new Java code should execute in a functionally equivalent way –A bug reported in the production code should also be present in the pristine code –Otherwise it is a obfuscation bug Copyright © 2015 – Curt Hill

The Modder’s Problem How can we alter this obfuscated code? Someone has figured this out –There is a de-obfuscator that restores reasonable names The MCP toolkit and Minecraft Forge has the tools needed to de- and re- obfuscate as well as decompilers –Neither of these are officially connected to Mojang Copyright © 2015 – Curt Hill

Relationship Recently Mojang has been rather cooperative with the modders In Curt’s Occasionally Humble Opinion they have legal grounds to eliminate these people or at least harass them enough to make it not worth while –They have chosen not to do so –This is likely that the modding community has increased rather than decreased revenues Copyright © 2015 – Curt Hill

Java Again Recall that Java has dynamic binding When a method call is executed for the first time the class file is loaded from disk or elsewhere –It did not have to be in memory before the call This allows objects to be dynamically loaded into memory without the program knowing anything about it before it started Copyright © 2015 – Curt Hill

Structure of the Game Like many multi-player games there are two main components –A server –A client Both are Java programs and are subject to our change They communicate using packets over the internet Copyright © 2015 – Curt Hill

Client and Server The client is interested in three main things: –Catching and interpreting keyboard commands –Displaying the current scene on the monitor –Communicating with the server on what is going on The server is the communications relay –What has been reported by any client is reported to all the rest Copyright © 2015 – Curt Hill

Infinite Loops The client stays in an infinite loop The goal is to go through the loop 20 times a second –This is a tick The tick based items include updates to the world –Communication to and from the server –Monitoring the keyboard/mouse Rendering is not tick based All the server processing is tick based Copyright © 2015 – Curt Hill

Client Again The Minecraft client is actually somewhat more than that A server was integrated into the client –This facilitates group play on a LAN Thus there are two programs –The server without the client (stand alone or dedicated) –The client with the server We also have the issues of proxies Copyright © 2015 – Curt Hill

Proxies Code in a mod could run in two places: the integrated server (part of the client) or the stand alone server If this code references code in the client then one of two things can happen: –In the integrated server all is good –In the stand alone server it crashes We thus need classes with different methods depending on the location Copyright © 2015 – Curt Hill

Proxies Again A typical solution is to have a common proxy –This determines the needed method signatures We take derivations of this for the server proxy and client proxy An annotation will show the system which one to load Usually client and server have same signatures but do different things –A rendering method would be empty on the server Copyright © 2015 – Curt Hill

Classes Minecraft is largely constructed from a few classes Most of these classes have many derivations In this presentation we will mention them Other presentations will discuss them more fully Copyright © 2015 – Curt Hill

Classes Block –Describes how to draw and how it reacts to events (behavior) Item –Anything that a player can carry such as a sword Entity –Anything that can move around TileEntity –Used when more data than a block is needed Copyright © 2015 – Curt Hill

Finally Plenty of more to consider Licenses Establishing the forge environment Creating a simple mod Lots more Copyright © 2015 – Curt Hill