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
Script Help Colliding props
The chaser Offline
Posting Freak

Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation: 113
#11
RE: Colliding props

(11-01-2012, 04:03 PM)ZodiaC Wrote:
(11-01-2012, 02:42 PM)The chaser Wrote: I know about Angel, but NOTHING of C++. Sorry Sad

Just an example in Angel script, please.
Ok I tried the "do" and the "while" commands with angle script and they worked perfectly
so I will try to explain them but I promise nothing..
Anyway the "do" command is executed at least one time and it syntax is this:

SetLocalVarInt("number", 0);
do
{
//All your commands goes here
AddLocalVarInt("number", 1); //It's necessary to change the number cause if you don't it will loop for ever
while (GetLocalVarInt("number") > 3) //this is where it checks .. if the number is less or equal to 3 the proccess will loop(goto "do") and check again...If the number is equal or bigger than 3 the loop will stop

That's the "do" command

The "while" commands it's the exact opposite of the "do" command!
It's checks in the begining and then loops
syntax:

SetLocalVarInt("number", 0);
while (GetLocalVarInt("number") <= 3) //This is where it checks..If it's less OR equal to 3 the loop will continue(or start) and come back here...
{
//All your commands goes here
AddLocalVarInt("number", 1); //It's necessary to change the number cause if you don't it will loop for ever
} //From here it goes to "while" command (goto while).

So if you look carefully you will notice that both of the commands are doing the exact same thing in this example...
they are ussualy used for searching arrays value.They should work exactly like in C++.
Anyway I hope you understood how they work...
I think I understood it. But, I will give it a more deep look after. Thanks for sharing them Big Grin

THE OTHERWORLD (WIP)
[Image: k6vbdhu]

Aculy iz dolan.
11-01-2012, 05:09 PM
Find


Messages In This Thread
Colliding props - by The chaser - 10-30-2012, 06:53 PM
RE: Colliding props - by FlawlessHappiness - 10-30-2012, 07:02 PM
RE: Colliding props - by The chaser - 10-30-2012, 07:13 PM
RE: Colliding props - by ZodiaC - 10-30-2012, 09:23 PM
RE: Colliding props - by The chaser - 10-30-2012, 09:57 PM
RE: Colliding props - by ZodiaC - 11-01-2012, 02:20 PM
RE: Colliding props - by The chaser - 11-01-2012, 02:42 PM
RE: Colliding props - by ZodiaC - 11-01-2012, 04:03 PM
RE: Colliding props - by The chaser - 11-01-2012, 05:09 PM
RE: Colliding props - by ZodiaC - 11-01-2012, 05:54 PM
RE: Colliding props - by FlawlessHappiness - 10-30-2012, 07:24 PM
RE: Colliding props - by Your Computer - 10-30-2012, 10:05 PM



Users browsing this thread: 1 Guest(s)