Chapter 3.2 C++, Java, and Scripting Languages “The major programming languages used in game development.”

Slides:



Advertisements
Similar presentations
CSCE 590E Spring 2007 Game Design II By Jijun Tang.
Advertisements

The road to reliable, autonomous distributed systems
Programming Creating programs that run on your PC
Chapter 3.2 C++, Java, and Scripting Languages. 2 C++ C used to be the most popular language for games Today, C++ is the language of choice for game development.
W4118 Operating Systems OS Overview Junfeng Yang.
SCRIPTING LANGUAGE. The first interactive shells were developed in the 1960s to enable remote operation of the first time-sharing systems, and these,
Chapter 3.1 Teams and Processes. 2 Programming Teams In the 1980s programmers developed the whole game (and did the art and sounds too!) Now programmers.
1 Programming Languages Translation  Lecture Objectives:  Be able to list and explain five features of the Java programming language.  Be able to explain.
Chapter 3.2 C++, Java, and Scripting Languages hacked by jeffery.
Project Proposal Implementing library support for the Virgil programming language Ryan Hall Advisor: Jens Palsberg January 23, 2007.
Automated Testing Nathan Weiss April 23, Overview History of Testing Advantages to Automated Testing Types of Automated Testing Automated Testing.
Programming. Software is made by programmers Computers need all kinds of software, from operating systems to applications People learn how to tell the.
Java How to Program, 9/e Instructor: José M. Reyes Álamo © by Pearson Education, Inc. All Rights Reserved.
Asst.Prof.Dr.Ahmet Ünveren SPRING Computer Engineering Department Asst.Prof.Dr.Ahmet Ünveren SPRING Computer Engineering Department.
Python Introduction.
JAVA v.s. C++ Programming Language Comparison By LI LU SAMMY CHU By LI LU SAMMY CHU.
Chapter Languages, Programming and Architecture.
Programming Languages: Telling the Computers What to Do Chapter 16.
Language Systems Chapter FourModern Programming Languages 1.
C++ Programming. Table of Contents History What is C++? Development of C++ Standardized C++ What are the features of C++? What is Object Orientation?
There are only 10 types of people in the world, those who understand binary and those who don't.
High level & Low level language High level programming languages are more structured, are closer to spoken language and are more intuitive than low level.
Java Introduction Lecture 1. Java Powerful, object-oriented language Free SDK and many resources at
CSCE 552 Spring 2009 Game Design III By Jijun Tang.
CS101 Introduction to Computing Lecture Programming Languages.
Programming language A programming language is an artificial language designed to communicate instructions to a machine,languageinstructionsmachine particularly.
CSCE 552 Spring 2010 Language and Programming By Jijun Tang.
CSCE 552 Spring 2009 Programming Fundamentals By Jijun Tang.
BLU-ICE and the Distributed Control System Constraints for Software Development Strategies Timothy M. McPhillips Stanford Synchrotron Radiation Laboratory.
Chapter 3.5 Memory and I/O Systems. 2 Memory Management Memory problems are one of the leading causes of bugs in programs (60-80%) MUCH worse in languages.
Ch 1. A Python Q&A Session Spring Why do people use Python? Software quality Developer productivity Program portability Support libraries Component.
CPRG 215 Introduction to Object-Oriented Programming with Java Module 1-Introduction to Java Topic 1.1 Basics of Java Produced by Harvey Peters, 2008 Copyright.
Guide to Programming with Python Chapter One Getting Started: The Game Over Program.
1 Geospatial and Business Intelligence Jean-Sébastien Turcotte Executive VP San Francisco - April 2007 Streamlining web mapping applications.
CE Operating Systems Lecture 3 Overview of OS functions and structure.
Eagle: Maturation and Evolution 17th Annual Tcl Conference Joe Mistachkin.
Module 4 Part 2 Introduction To Software Development : Programming & Languages Introduction To Software Development : Programming & Languages.
LANGUAGE SYSTEMS Chapter Four Modern Programming Languages 1.
Computer Programming 2 Why do we study Java….. Java is Simple It has none of the following: operator overloading, header files, pre- processor, pointer.
CSCE 552 Fall 2012 Language and Programming By Jijun Tang.
Siena Computational Crystallography School 2005
1 Compiler Construction (CS-636) Muhammad Bilal Bashir UIIT, Rawalpindi.
Ch 1. A Python Q&A Session. Why do people use Python? Software Quality Developer productivity Program portability Support Libraries Component integration.
 Programming - the process of creating computer programs.
Introduction Mehdi Einali Advanced Programming in Java 1.
COP 3275 Chapter 01 course website: Jonathan C.L. Liu, Ph.D. CISE Department University of Florida.
Lesson 1 1 LESSON 1 l Background information l Introduction to Java Introduction and a Taste of Java.
Java How to Program, 9/e Presented by: José M. Reyes Álamo © by Pearson Education, Inc. All Rights Reserved.
Chapter 11  Getting ready to program  Hardware Model  Software Model  Programming Languages  Facts about C++  Program Development Process  The Hello-world.
ITP 109 Week 2 Trina Gregory Introduction to Java.
CIS 595 MATLAB First Impressions. MATLAB This introduction will give Some basic ideas Main advantages and drawbacks compared to other languages.
Ori Hanegby Pixtazy Blog:
Google Web Toolkit for Mobile Applications Development INGENUITY AT ITS BEST……………….
김민수 Cortex-M4 Processor - Getting Started with the GNU Compiler Collection(gcc)
20-753: Fundamentals of Web Programming Copyright © 1999, Carnegie Mellon. All Rights Reserved. 1 Lecture 15: Java Basics Fundamentals of Web Programming.
Introduction to Computer Programming Concepts M. Uyguroğlu R. Uyguroğlu.
Your Interactive Guide to the Digital World Discovering Computers 2012 Chapter 13 Computer Programs and Programming Languages.
First appeared Features Popular uses Basic This language emphasises on ease of use, allowing general purpose programming to those with a small amount of.
CSCE 552 Spring 2011 Language and Programming By Jijun Tang.
Top 8 Best Programming Languages To Learn
Current Generation Hypervisor Type 1 Type 2.
Basic 1960s It was designed to emphasize ease of use. Became widespread on microcomputers It is relatively simple. Will make it easier for people with.
NOCTI Study Guide #2.
Choosing Technologies
OPERATING SYSTEMS.
(Computer fundamental Lab)
Java Programming Introduction
The Challenge of Cross - Language Interoperability
CMPE419 Mobile Application Development
Presentation transcript:

Chapter 3.2 C++, Java, and Scripting Languages “The major programming languages used in game development.”

2 C++ C used to be the most popular language for games Today, C++ is the language of choice for game development C#, Objective C, ARM-C

3 C++: Strengths Performance Control over low-level functionality (memory management, etc) Can switch to assembly or C whenever necessary Good interface with OS, hardware, and other languages

4 C++: Strengths High-level, object-oriented High-level language features are essential for making today's complex games Has inheritance, polymorphism, templates, and exceptions Strongly typed, so it has improved reliability

5 C++: Strengths C Heritage C++ is the only high-level language that is backwards-compatible with C Has APIs and compiler support in all platforms Easier transition for experienced programmers

6 C++: Strengths Libraries STL (Standard Template Library) Comprehensive set of standard libraries Boost: widely used library with wide variety of functionality Most commercial C++ libraries also available (Open GL, DirectX)

7 C++: Weaknesses Too low-level Still forces programmers to deal with low-level issues (memory allocation) Too error-prone Attention to low-level details is overkill for high-level features or tools If 90% of code is NOT performance critical, is it worth writing it at such a low level

8 C++: Weaknesses Too complicated Because of its C heritage, C++ is very complicated “Historical baggage” left behind in languages like Java, C#, Objective C. Long learning curve to become competent with the language

9 C++: Weaknesses Lacking features No reflection or introspection features Object: What size are you? No method of object serialization Reading from media state of an object. No native support for message passing Not the same as “function calls”. Custom buffer solution.

10 C++: Weaknesses Slow iteration C++ is fully compiled into binary format from source code Compiling large numbers of files can be very very slow This will only become more of a problem as games become more complex Workarounds exist (precompiled headers, dynamic linking, etc.)

11 C++: When to Use It? When performance is crucial (core features may include assembly, register) If your current code base is mostly C and C++ If you have a lot of in-house expertise in C++ Avoid using it for high-level code, such as tools

12 Java for Game Development Why use Java? It's a high-level OO language that simplifies many C++ features Adds several useful high-level features Easy to develop for multiple platforms because of intermediate bytecode Good library support Lower learning curve

13 Java for Game Development Performance Has typically been Java's weak point Has improved in the last few years Still not up to C++ level, but getting close Uses Just-In-Time compiling and HotSpot optimizations Also has access to native functionality Now has high-performance libraries JIN (Java Native Interface)

14 Java for Game Development Platforms Well suited to downloadable and browser- based games Strong player in mobile and handheld platforms Possible to use in full PC games More likely to be embedded into a game Not currently used in consoles

15 Java in Game Development Commercial games using Java Downloadable games like those from PopCap Games: Bejeweled, etc. Online card/table/casino games PC games using Java as a scripting language: Star Wars Galaxies, DDO PC games fully written in Java: You Don't Know Jack, Who Wants to Be a Millionaire

16 Scripting Languages Why use scripting languages? Ease and speed of development Typing, memory management May be simple enough for designers Short iteration time No need to compile Code becomes a separate game asset (AI) Offer additional features and are customizable Reflection, serialization

17 Scripting Languages Drawbacks Slow performance Limited tool support (debugger) Dynamic typing makes it difficult to catch errors Can be awkward to interface with the game Difficult to implement well

18 Scripting Languages Popular scripting languages Python Lua Other off-the-shelf options such as Ruby, Perl, Javascript Custom scripting languages UnrealScript, QuakeC, NWNScript

19 Scripting Languages How to choose a scripting language Consider whether you need one at all What features do you need? What kind of performance do you need? What debugging facilities does the language have? On what platforms does it need to run? What resources and expertise are available?