Extreme Newbie!! Outside the scope of XCode and Applestudio?

Hey guys. Let me preface this by saying that i’m an extreme newbie. I am doing some research on different approached to an application I’d like to build. I’d like to know if what I am trying to build is outside the scope of XCode, Applestudio and Applescript before I spend a ton of time learning it and attempting to develop this app.

What I would like to do, is build an app that will access an online chess server. This application will be required to communicate back and forth with the server. The use of this application will be to streamline a specific set of actions performed on that server. This will entail sending specific commands to the server based upon selections made (either by check box, manual entry, data entry fields, etc) by the user. I also would like this application to provide feedback to the user about certain specific activities or actions or status.

For instance, I want a front end “Console” if you will that will allow the user to ‘chat’ with other folks on the server. Then, the will push a button that will send a command to the server to create a tournament. When this happens, I would like a second screen to pop up that will have details of that specific tournament in it. For instance, it will have check boxes that will allow the user to quickly check of the different variables that they would like to use in this tournament and have the app send those specific commands to the server to setup that tournament. Then, as people join the tournament, have their name shown in a list that will give status’ etc.

This is a general overview for what I have in mind (sorry it is so long). I know that this would not necessarily be ‘easy’. I dont mind putting in the homework to learn how if this is something that can be done with the tools that I have (ASS, XCode, etc.) to use. Is this within the scope or should I be looking elsewhere??

Tom

Using applescript alone, you may not be able to achieve everything you would like in your app. Using Xcode, and all of the tools besides applescript studio, you most certainly should be able to achieve your goals. Xcode offers a wide variety and flexibility in development terms, and should provide you with a pretty complete foundation for accomplishing your task.

What you fail to mention, are details about how you intend to accomplish the task. There are many communications protocols available, and there are some systems which use proprietary or secured communications that are difficult or impossible to tap into. What protocol is the system using? The easy part will be creating the interface and producing a graphical means for the user to interact with the server. The hard part will be implementing the communications with the server and enabling it to occur in real time and without error.

This said, communicating with the internet using applescript alone is not a likely solution for intense communications tasks. Unless you are working with a request-based, predefined system using standard www internet protocols, such as http or ftp, you may be looking at learning more complex languages like cocoa or carbon. Applescript has little support for anything more than querying web addresses and basic text parsing. If you can use a web browser or web page to do all you hope to do in your app, then this may be realistic for you. Otherwise, expect to get dirty learning some other more powerful language(s) trying to get your app to speak with the server and achieve your goals. For chat-type application, applescript may turn out to be a little too cpu- and network-intensive for realistic use. Other languages are more practical and have the resources built in to handle two-way communications, streaming data, and more complex/custom internet protocols. Without knowing more details about the setup, I can offer little more in terms of advice or recommendations.

Good luck,
j

Hi Jobu,
Thanks for the quick response. Ok, I’m getting the sense that perhaps Applescript may be under-manned for what I’m looking to do. I’m reading now about Cocoa programming. As I said in my original post, I’m extreme newbie. Everything I’m doing I will have to learn from scratch. I have no programming experience whatsoever but I’m a pretty quick learner as technical things go.

Is Cocoa programming done In C or some other language??

As far as the communications protocols, I have no idea… yet. I do know that there are many open source applications that successfully connect to the servers that I’m speaking of. There is nothing proprietary nor secure about the protocols. I can connect to these servers using Telnet with no problem at all. Ideas?

Slight correction: Cocoa and Carbon are APIs (Application Programming Interfaces), not languages. Basically large collections of ready-made, general-purpose functions and objects that you can use in your programs, avoiding the need to write your own.

You can use the Cocoa and Carbon APIs from any language that knows how to connect to them, so you’re not limited to just ObjC or C. Any language that can speak C can use Carbon (which is most of them), while any language that speaks ObjC can use Cocoa (e.g. Java, Perl, Python). Many of these other languages provide native libraries that wrap some or all of the lower-level Carbon/Cocoa APIs allowing you to use them directly from that language without having to write your own bridging code, e.g.:

  • Apple provide a Java-Cocoa bridge as part of the OS

  • Perl and Python provide wrappers for much of Carbon plus extensive Cocoa bridges (CamelBones and PyObjC)

  • AppleScript has the Studio framework which wraps a fair amount of Cocoa’s AppKit (a collection of mostly GUI components for building Mac applications), plus the odd bit of Carbon wrapped up as an osax (or, in the case of the Apple Event Manager and OSA APIs, built into the language itself)

  • RealBasic and Revolution heavily repackage various bits of system functionality as a user-friendly ‘faits accomplis’.

BTW, most languages come with tons of their own libraries too, so you’re not limited to Cocoa and Carbon alone when searching for pre-built functionality to use.

HTH