Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
An eager newcomer who wants to learn...
Kyle Offline
Posting Freak

Posts: 911
Threads: 36
Joined: Sep 2010
Reputation: 7
#8
RE: An eager newcomer who wants to learn...

This page shows you all the script functions.

http://wiki.frictionalgames.com/hpl2/amn..._functions

A script function is a series of commands built into one common job, or function. In AngelScript, the programming language that Amnesia uses, you can create your own functions. I also want to note that AngelScript is very similar to C++. A callback is a built in function that calls another function, in which is usually a functon you create. Every function has parameters that are needed to be told in a callback to correctly call the correct function.

void Function01()
{

}

Let's take apart this function. Its type is "void" in which it has no apparent type. Then there is the function name, which is "Function01". The parentheses at the end dictate what it includes in the function. It's blank so it has nothing added to it.

void Function01(string &in asEntity)
{

}

This has a parameter. It is a string, or text. It's name is "asEntity". Whatever asEntity holds in there can be used in the function for other built in callbacks.

07-31-2011, 01:09 PM
Find


Messages In This Thread
RE: An eager newcomer who wants to learn... - by Kyle - 07-31-2011, 01:09 PM



Users browsing this thread: 1 Guest(s)