Ship Simulator

English forum => Small talk => Topic started by: firestar12 on May 02, 2009, 00:50:42

Title: JavaScript.
Post by: firestar12 on May 02, 2009, 00:50:42
Hi Guys, I might be interested in learning Java. Has anyone had any experience with it? Some questions are.
Any help would be appreciated. Thanks!
Title: Re: Java.
Post by: TerryRussell on May 02, 2009, 00:57:15
Javascript or Java?

Despite the very similar names, they are very different things.
Title: Re: Java.
Post by: firestar12 on June 21, 2009, 00:34:42
Well, I finally decided JavaScript. So far after about 30 minutes of JS, I am able to do this:

<html>
<body style="font-family:arial;">
<script type="text/javascript">
function message()
{
alert("This alert is a JavaScript test");
}
</script>
<body onload="message()">

</html>
</body>
Title: Re: Java.
Post by: TerryRussell on June 21, 2009, 08:49:20
To stop your code appearing on the page for people using old browsers or for the considerable number of people who have Java disabled, put this in font of the code:
<!--
and this afterwards:
-->

So:

<html>
<body style="font-family:arial;">
<!--
<script type="text/javascript">
function message()
{
alert("This alert is a JavaScript test");
}
</script>
-->

<body onload="message()">

</html>
</body>
Title: Re: Java.
Post by: llamalord on June 21, 2009, 12:16:18
I personally like the simple // in objective C as opposed to Javascript. :P
Title: Re: Java.
Post by: Captain Spencer on June 21, 2009, 13:02:28
Good luck with Javascript, I could never get on with it myself. More of an ASP man myself ;D
Title: Re: Java.
Post by: firestar12 on June 21, 2009, 15:09:57
To stop your code appearing on the page for people using old browsers or for the considerable number of people who have Java disabled, put this in font of the code:
<!--
and this afterwards:
-->

So:

<html>
<body style="font-family:arial;">
<!--
<script type="text/javascript">
function message()
{
alert("This alert is a JavaScript test");
}
</script>
-->

<body onload="message()">

</html>
</body>
Thanks Terry, will do. You are good at everything, huh? ;D
Title: Re: Java.
Post by: TerryRussell on June 21, 2009, 15:21:35
You would never choose me to play in your soccer team. Nor to speak a foreign language. I am absolutely useless at artistic things.

My atempts at painting or drawing make matchstick men look detailed. I understand the mechanics of it, but the art appreciation side is a complete mystery to me.

So no, not everything. In fact, only at a few things, like everybody.
Title: Re: Java.
Post by: firestar12 on June 21, 2009, 15:37:04
Ah yes. Can I make a program with JS?
Title: Re: JavaScript.
Post by: TerryRussell on June 21, 2009, 18:36:04
Sort of.

There are security issues around Javascript, which prevent it from doing too much. It can't delete your hard disk for example. But, people do make  games and applets (small applications) with it.
Title: Re: JavaScript.
Post by: firestar12 on June 22, 2009, 17:00:37
Ok, I wanted to be able to make programs so I decided to learn C++. I downloaded Visual C++ Express Edition. DO you know of any god starter tutorials that explain things in detail? I haven't found any.
Title: Re: JavaScript.
Post by: llamalord on June 23, 2009, 13:22:16
If you want to learn that type of programming then I suggest that you don't start with C++ or C# but you start with something like just plain old C or more preferably if you see yourself creating games in the future then you should begin with "Objective C" or "Object Oriented C"
Title: Re: JavaScript.
Post by: firestar12 on June 23, 2009, 14:20:35
Ah, just a question, why not?
Title: Re: JavaScript.
Post by: llamalord on June 23, 2009, 15:48:56
C++ is used more for deep level systems that are rooted very close to the Operating System and is, as a result, much more technical.  Objective C is used more for game development because it is a so called Object Oriented language.  This means that it will auto-thread for you in the case of working with many MVC systems such as a ship simulator.
Title: Re: JavaScript.
Post by: firestar12 on June 23, 2009, 15:55:51
Oh, ok. ;D
Title: Re: JavaScript.
Post by: Rik de Leeuw on June 23, 2009, 16:26:06
C++ is used more for deep level systems that are rooted very close to the Operating System and is, as a result, much more technical.  Objective C is used more for game development because it is a so called Object Oriented language.  This means that it will auto-thread for you in the case of working with many MVC systems such as a ship simulator.

Some more information about these languages:
c++: http://en.wikipedia.org/wiki/C%2B%2B (en) http://nl.wikipedia.org/wiki/C%2B%2B (nl)
c#: http://en.wikipedia.org/wiki/C_Sharp_(programming_language) (en) http://nl.wikipedia.org/wiki/C_sharp (nl)
Objective c: http://en.wikipedia.org/wiki/Objective-C (en) http://nl.wikipedia.org/wiki/Objective-C (nl)
c: http://en.wikipedia.org/wiki/C_(programming_language) (en) http://nl.wikipedia.org/wiki/C_(programmeertaal)

imho:
c++ : pointers are to complex for most starting programmers
c: doesn't have object orientation which is a concept that is important to learn
c#: easy to learn language
Objective c: never written in that language

My personal preference would be java because it looks very much like c#
Title: Re: JavaScript.
Post by: firestar12 on June 23, 2009, 16:33:48
Ok, wow, I am going to be like Goldie Lox with all these programming languages! Thanks my Dutch friend! ;D
Title: Re: JavaScript.
Post by: TerryRussell on June 23, 2009, 18:29:04
I write a lot in Perl and VB & Net. But I also write a lot of modules for those programs.

For that, I tend to write in machine code or assembly-language. if I don't feel adventurous, I write in C#. Those languages make the functions lightning fast.

(fastest ones first in the list above)!

If you go to Creators Forum, although the pages are presented by Perl, about 80% of the work is done in C# or Assembly Language or machine code.