COMP1400 – Programming for Designers

Class announcements for Programming for Designers

COMP1400 – Programming for Designers random header image

Games Showcase Tue Oct 19

Posted by on October 12th, 2010 · Uncategorized

Time: 6-8pm, Tues Oct 19
Room: K17 Level 1 Seminar Room

Every year the students in Game Design Workshop (COMP4431) are challenged to design and prototype innovative game ideas in under six weeks. This year the theme was “COLOUR AND EMOTION” which has inspired a number of wonderful arty games. They will be showcasing their games next Tuesday night, Oct 19, in the Level 1 Seminar Room at CSE.

Also presenting is Steve Wang, founder and COO of Micro Forte, one of Australia’s longest running games studios. Steve will be talking about what it is like to work in the games industry. Steve will also be judging the students’ games for the much-coveted Micro Forte prize.

The event is open to all comers. Beer and pizza will be provided. Please RSVP to malcolmr@cse.unsw.edu.au for numbers.

Assignment 3 – submission

Posted by on October 12th, 2010 · Assignments

There are two components you will need to deliver:

1) The completed ScoreKeeper.js script. (due Sunday 17 October 2010, 23:59)

2) A web version of your game. (due Sunday 17 October 2010, 23:59)

[Read more →]

Sample Exam

Posted by on October 10th, 2010 · Uncategorized

As requested, I have made a sample exam available for you to download. This contains the same number and variety of questions as in the final exam, and should be of about the same difficulty.

In the actual exam you will be provided with copies of the Unity Scripting Manual pages for all the important classes referred to in questions (Vector, Random, GameObject, Transform, etc).

Assignment 2 mark is ready to collect

Posted by on October 10th, 2010 · Assignments

Assignment 2 marking is finished and the mark and feedbacks are ready to collect by using the below link:

https://cgi.cse.unsw.edu.au/~give/Student/give.php

You may contact your tutor during your assigned lab session for more information in regards to the marking.

Please report any error in collecting the result (with the exact error message) to cs1400@cse.unsw.edu.au.

Survey

Posted by on October 10th, 2010 · Uncategorized

I have put a web-survey up to get your feedback on the class. Please take a moment to fill it out. Your feedback will help improve the subject.

Assignment 3 – Grouping list

Posted by on October 5th, 2010 · Assignments

The grouping has been done for Assignment 3 and you can check it at

http://www.cse.unsw.edu.au/~cs1400/10s2/groups_assn3.html

PLEASE make sure your grouping is exactly as you had asked.

REPORT any possible mistake to your tutor before Tuesday 12 October 2010.

The grouping is finalized on Tuesday 12 October 2010 and no change will be possible.

Tut 11 – Source debugger

Posted by on October 5th, 2010 · Lab

I have arranged for Unity 3 to be installed on the CHI Lab Macs. It includes the debugger that I demonstrated in the lecture. We’ll use it to step through some code.

  • Download the GrowFlowers.js script from the lecture.
  • Create a project to run it in. Remember to save the scene.
  • Set Preferences to use MonoDevelop as your editor (instructions)
  • Sync your project.
  • Read the debugger instructions.
  • Open GrowFlowers.js in MonoDevelop.
  • Set breakpoints on the line 9 and 23.
  • Start the debugger with Run > Debug
  • In the new Unity window, open the saved scene and press play.
  • The debugger should return showing line 9 highlighted.
  • Use the Step Over button to step through the code.
  • When you get to the end of the Start method, press the Continue button.
  • The debugger will run for a while and then stop at line 23.
  • Use the Step Over button to step through the code.
  • Watch the values change in the Locals window.
  • When you get to the end of the Update method, press the Continue button.

Try this out with different initial values in the heights array to see what happens.

Change the code to make the flowers shrink, starting with the tallest flower. Try running your code in the debugger to see what it does.

Weird Bug

Posted by on September 28th, 2010 · Lectures

In last week’s lecture I had some trouble with the script:

// GUI.js
var label : String;
var rect : Rect; 

function Update() {
   GUI.Label(rect, label);
}

Unity was giving the error:

Assets/GUI.js(5,13): BCE0019: ‘Label’ is not a member of ‘GUI’.

I’ve finally worked out why. When you create this script it makes a new class called “GUI” which overrides the built-in GUI class. So when I try to call GUI.Label() it looks for a Label method on this script. There is none, so it causes an error.

The moral to the story is: Make sure your scripts don’t have the same names as builtin Unity classes. So don’t call your script GUI or Transform or GameObject.

Lab 10 – GUI

Posted by on September 28th, 2010 · Lab

Task 1: Build a GUI with a label and a button. The label should show the number of times the button has been pressed.

Task 2: Build a “Security Panel” GUI with buttons labelled “0” through “9” and an “Enter” button. Allow the player to unlock the panel by entering the correct 4 digit PIN. Demo here.

Ass 3 – High score list

Posted by on September 21st, 2010 · Assignments

Your final assignment is to implement a high score list for a very simple game. The game itself is just a place holder that randomly generates scores. Your job is to keep a list of high-scores and allow the player to page through them.

Requirements

  • Have a “play” button which starts the game.
  • While the game is playing, hide the GUI.
  • When the game is over, display the latest score and the high-scores in descending order, five per page.
  • Provide “Previous” and “Next” buttons to allow the player to page through the scores. Don’t page beyond the end of the list.
  • Optional Bonus: for an extra 10%, prompt the player for a name when the game is over, and show both names and scores in the list.

There is a demo app here. Feel free to make your version prettier if you want, but you must implement all the functionality of this demo.
[Read more →]