This wiki is out of date, use the continuation of this wiki instead

Xadvance

From FenixWiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 10:32, 18 April 2007 (edit)
Sandman (Talk | contribs)
m
← Previous diff
Revision as of 11:48, 25 December 2007 (edit) (undo)
Sandman (Talk | contribs)
m
Next diff →
Line 12: Line 12:
{| {|
-| '''INT''' angle || - The angle in which to move the process, in thousandths of a degree.+| '''INT''' angle || - The [[angle]] in which to move the process, in thousandths of a degree.
|- |-
| '''INT''' distance || - The distance to move the process, in pixels. | '''INT''' distance || - The distance to move the process, in pixels.
Line 20: Line 20:
== Returns == == Returns ==
-'''INT''' : Returns [[true|1]] if successful and [[false|0]] if failed.+'''INT''' : Successrate
- +{|
 +| [[true]] || - Success.
 +|-
 +| [[false]] || - Error.
 +|}
== Example == == Example ==
Line 45: Line 49:
y=100; y=100;
- xadvance(90000,10); //moves the process vertically (90 degrees) 10 pixels+ Loop
 + xadvance(90000,10); //moves the process vertically (90 degrees) 10 pixels
 + frame;
 + End
End End
</pre> </pre>
 +
 +{{Funcbox
 + | category = Processinteraction
 +}}

Revision as of 11:48, 25 December 2007


Contents

Definition

INT xadvance ( <INT angle> , <INT distance> )

Moves a process a certain distance in a certain direction.


Parameters

INT angle - The angle in which to move the process, in thousandths of a degree.
INT distance - The distance to move the process, in pixels.


Returns

INT : Successrate

true - Success.
false - Error.

Example

Program example;
Global
    myproc;

Begin
 
    myproc=proc();

    Loop
        frame;
    End
End

Process proc();
Begin

    x=100;
    y=100;

    Loop
        xadvance(90000,10); //moves the process vertically (90 degrees) 10 pixels
        frame;
    End

End


Processinteraction Functions
Advance() • Collision() • Exists() • Get_angle() • Get_dist() • Get_id() • Let_me_alone() • Signal() • Xadvance() •
Personal tools