Function Reference

From Sputnik Wiki
(Difference between revisions)
Jump to: navigation, search
(Path Functions)
(String Functions)
Line 513: Line 513:
 
* [[Core Function Scanf|Scanf( <expression>, <def> )]] -- Parses input from a string according to a format
 
* [[Core Function Scanf|Scanf( <expression>, <def> )]] -- Parses input from a string according to a format
 
* [[Core Function SHA1|SHA1( <expression> )]] -- Returns SHA1 hash of string
 
* [[Core Function SHA1|SHA1( <expression> )]] -- Returns SHA1 hash of string
 +
* [[Core Function Serialize|Serialize( <variable> )]] -- Convert a variable, array, class etc a string you can save to file or transfer over the internet
 
* [[Core Function SimilarText|SimilarText( <first>, <second>, <percent> )]] -- Calculates the similarity between two input strings and return a percentage of the matching between the two input strings
 
* [[Core Function SimilarText|SimilarText( <first>, <second>, <percent> )]] -- Calculates the similarity between two input strings and return a percentage of the matching between the two input strings
 
* [[Core Function Split|Split( <expression>, <delim/pattern>, <flag> )]] -- Splits up a string into substrings depending on the given delimiters.
 
* [[Core Function Split|Split( <expression>, <delim/pattern>, <flag> )]] -- Splits up a string into substrings depending on the given delimiters.
Line 556: Line 557:
 
* [[Core Function UUDecode|UUDecode( <expression> )]] -- Decodes a string that was encode using the uuencode algorithm
 
* [[Core Function UUDecode|UUDecode( <expression> )]] -- Decodes a string that was encode using the uuencode algorithm
 
* [[Core Function Unescape|Unescape( <expression>, <custom> )]] -- Remove all escapes from a string
 
* [[Core Function Unescape|Unescape( <expression>, <custom> )]] -- Remove all escapes from a string
 +
* [[Core Function Unserialize|Unserialize( <string> )]] -- Convert a string (Created with Serialize()) into its original variable/class/array etc
 
* [[Core Function VSPrintf|VSPrintf( <format control>, <params>... )]] -- Returns a formatted string (similar to the C sprintf() function) but accepts arrays as the arguments
 
* [[Core Function VSPrintf|VSPrintf( <format control>, <params>... )]] -- Returns a formatted string (similar to the C sprintf() function) but accepts arrays as the arguments
 
* [[Core Function WordWrap|WordWrap( <str>, <width>, <break>, <cut> )]] -- Wraps a string to a given number of characters
 
* [[Core Function WordWrap|WordWrap( <str>, <width>, <break>, <cut> )]] -- Wraps a string to a given number of characters

Revision as of 09:48, 21 June 2015

Contents

Function Reference

How to create a Function

To create your own funtions see the Function page.

Core Functions

If a link is red (unclickable) the function either doesnt exist yet and is pending creation or it has been created but does not yet have a page/example.

Language Features

Parser Engine

Console Functions

Multi-Threading Functions

Variable Type Conversions

Common Variable Functions

Misc
Type Checking
Get Type Directly

Binary Data Management Functions

Binary packer/unpacker
Bit Vector
Bits
BinHex 5.0
ByteBuffer

The ByteBuffer is the replacement for the old Stream functions it is more robust, has more features and is resistant to crashes/errors from bad information etc it works similar to the ByteBuffer in Java

NBT (Named Binary Tag)

Functions on par with Minecrafts NBT system but greatly expanded to include many additional features and improvements specific for Sputnik.

NBTTagCompound
NBTTagList/NBTTagListEx
Misc Binary Functions

Math Functions

String Functions

CharPtr Functions

Note the Fixed statement is tied directly with CharPtr

Array Functions

Linq (Integrated Language Query) Functions

Enum Functions

Process Functions

Environment Management

File Functions

File Create/Read/Write Functions
Misc
Dialogs

Directory Functions

Dialogs

Path Functions

Network Functions

HTTP Functions
MySQL Functions
Sputnik Client/Server Functions (This is just for connecting Sputnik Clients to Sputnik Servers nothing else)
Raw Sockets (TCP/UDP etc)
Misc Network Functions

Memory Functions

Clipboard Functions

Registry Functions

Time & Date Functions

GUI Functions

Dialog Creation Functions
Control Creation Functions
NOT AVAILABLE YET
Window/Control Properties Get/Set Functions

Note - Any options not here are most likely found using GUIGetProp and GUISetProp the bulk of all props can be found/used in them 2 funtions however anything special and not generic will go in the functions below.

Common Dialog/Control Properties Get/Set Functions
Common Dialog/Control Functions
GUI Link (Event) Functions
Other GUI Functions

Bitmap Functions

Keyboard Control Functions

Mouse Control Functions

Window Management Functions

(For info on using <title>, <text> See Window Titles and Text (Advanced) )

Controls

(For info on using <title>, <text> See Window Titles and Text (Advanced) )

NOT AVAILABLE YET

Graphics/Pixel Functions

.NET Functions and Features

Control Flow Functions

  • Return <expressions> -- Immediately ends execution of the current function, and returns its argument as the value of the function call. return will also end the execution of an Eval() statement or script file
  • Throw( <expression> ) -- Throw an exception
  • Die( <expression> ) -- Gives an error and terminates the program
  • Break( <scopes> ) -- Ends execution of the current loop
  • Continue( <scopes> ) -- Continue the execution of a loop at its next iteration
  • Redo( ) -- Continue the execution of a loop at the start of the current iteration

Internal Class Management and Information

Internal Function Management and Information

Internal Enum Management and Information

Internal DLLImport Management and Information

Internal DLLStruct Management and Information

Eval Functions

Misc Functions

User Defined Functions

These functions are created using Sputnik and are not part of the Sputnik core language.

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox