Difference between revisions of "LSL Script Efficiency"
Jump to navigation
Jump to search
(Removed factualy inaccurate material) |
|||
Line 34: | Line 34: | ||
== Things that are faster == | == Things that are faster == | ||
<div style="padding: 0.5em;"> | <div style="padding: 0.5em;"> | ||
++a and a += 1 are equal in speed (they compile to the same bytecode). a++ is slower. | |||
</div></div> | </div></div> |
Revision as of 18:25, 3 April 2007
LSL Portal | Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials |
What is Efficiency
PAGE UNDER CONSTRUCTION!
Efficiency is how long it takes to run a script.
There are many ways to speed up scripts, such as using ++a instead of a++.
Rules for posting
The following code snipit will allow testing of a function.
default { state_entry() { integer i = 0; while (i < 1) { ++a; } } }
Things that are faster
++a and a += 1 are equal in speed (they compile to the same bytecode). a++ is slower.