Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

drober30

macrumors 6502a
Original poster
Jul 5, 2007
848
106
I work at a vocational school and we are discussing new classes for next year. We enroll students in 11th & 12th grade. We thought it would be really cool to have students learn to program for the iPhone/iTouch.

Our concern is that students need instant gratification to keep them interested and to have students learn C++ or in this case Objective C may be to dry/hard before they see results.

We offer a 3D Game Programming class which gets huge enrollment because students don't read pass the word "Game" to see "Programming" but they use a program called Alice which is some sort of drag and drop GUI which makes it easier on the students. They still are learning about programming but they are getting faster results using this program/GUI.

So in other words, is there any program or interface that assists in programming for these devices or is it just straight coding?

What are your thoughts or suggestions on successfully implementing a class like this for High School Juniors/Seniors?

Thanks!
 
So in other words, is there any program or interface that assists in programming for these devices or is it just straight coding?

There are a variety of third-party products that allow iPhone app development without coding, but I don't think they would have any educational value.

If I were teaching the course, I'd handle it in one of two ways:

1) Teach the students how to create an iPhone app from start to finish. This would of course have to be the simplest possible app, perhaps a tip calculator or something similar.

2) Teach the students how to write a more complex part of an app (e.g., 3D animation). But you'd provide them with the app foundation, with most of the interface pre-built, and their task would require filling in some blanks.

The choice depends on whether the goal is to teach them iOS development end-to-end vs. how to program in Objective-C.
 
If the aim is to get something to run on an iphone, rather than teach objective-c, I can heartily recommend Unity. It uses C# and its own flavour of javascript, but the benefit for students is that you can quite easily prepare simple scripts with public variables that students could just drag and drop onto 3d objects that they drop onto their scenes.

The public variables then show up in the inspector, so it becomes gui-like and you can expose as much or as little of some specific script in this way as you like.

For example, I wrote a one-liner script that rotates the object around x,y,z axes at a specified rate. The rates become exposed as properties, so to get an object to spin now, I simply drop the "spin.cs" script onto an object and set the spin properties.

The spin method looked something like this

Code:
using UnityEngine;
using System.Collections;

public class Spin : MonoBehaviour {

	public float spin_x;
	public float spin_y;
	public float spin_z;
	
	// Use this for initialization
	void Start () {
	
	}
	
	// Update is called once per frame
	void Update () {
		transform.Rotate(spin_x,spin_y,spin_z);
	}
}

Where the only thing I had to add were the "public" lines and the transform.Rotate line. The rest is a template whenever you create a new script.

I realise that these cross-platform tools sit in an uncomfortable place in the Apple world, only recently gaining complete Apple approval, but a number of apps in the top 50 are made in Unity, and as someone who loves Mac but finds Objective-C quite difficult, I can't recommend Unity enough. The asset workflow is intuitive and very productive. There is also a very vibrant community and a lot of answers to simple questions about the platform up on the net, which is for me a big differentiator. (e.g. http://answers.unity3d.com

The other advantage for students is that they can play around with Unity at home for free- they wouldn't be able to deploy to an iphone with the free version, but otherwise it is pretty much identical.

Regs,
Mike
Dark Quadrant dev blog
 
If the aim is to get something to run on an iphone, rather than teach objective-c, I can heartily recommend Unity. It uses C# and its own flavour of javascript, but the benefit for students is that you can quite easily prepare simple scripts with public variables that students could just drag and drop onto 3d objects that they drop onto their scenes.

The public variables then show up in the inspector, so it becomes gui-like and you can expose as much or as little of some specific script in this way as you like.

For example, I wrote a one-liner script that rotates the object around x,y,z axes at a specified rate. The rates become exposed as properties, so to get an object to spin now, I simply drop the "spin.cs" script onto an object and set the spin properties.

Screenshot of what I mean here
Screen-shot-2010-10-15-at-09.00.01.png


Let me be clear about this- once you've put together the script, the student wouldn't even necessarily need to see the code beneath (unless they wanted to fiddle with it).

The spin class looked something like this

Code:
using UnityEngine;
using System.Collections;

public class Spin : MonoBehaviour {

	public float spin_x;
	public float spin_y;
	public float spin_z;
	
	// Use this for initialization
	void Start () {
	
	}
	
	// Update is called once per frame
	void Update () {
		transform.Rotate(spin_x,spin_y,spin_z);
	}
}

Where the only thing I had to add were the "public" lines and the transform.Rotate line. The rest is a template whenever you create a new script.

I realise that these cross-platform tools sit in an uncomfortable place in the Apple world, only recently gaining complete Apple approval, but a number of apps in the top 50 are made in Unity, and as someone who loves Mac but finds Objective-C quite difficult, I can't recommend Unity enough. The asset workflow is intuitive and very productive. There is also a very vibrant community and a lot of answers to simple questions about the platform up on the net, which is for me a big differentiator. (e.g. http://answers.unity3d.com

The other advantage for students is that they can play around with Unity at home for free- they wouldn't be able to deploy to an iphone with the free version, but otherwise it is pretty much identical.

Regs,
Mike
Dark Quadrant dev blog
 
oh, and since Unity attempts to be cross-platform, you could quite easily use the indie (read free) version for the students and setup some Input agnostic scripts, which they could test on screen with a mouse, and when complete you could move their projects to the iphone version licensed Unity3d machine with an Apple developer license for deployment to iphone/ipad etc.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.