The Dink Network

Reply to Re: procedure thing

If you don't have an account, just leave the password field blank.
Username:
Password:
Subject:
Antispam: Enter Dink Smallwood's last name (surname) below.
Formatting: :) :( ;( :P ;) :D >( : :s :O evil cat blood
Bold font Italic font hyperlink Code tags
Message:
 
 
September 4th 2006, 11:23 AM
custom_king.png
redink1
King He/Him United States bloop
A mother ducking wizard 
Pretty much.

From the DinkC Reference (Advanced Procedures):

// passing.c
void main(void)
{
int &two = 2;
// You can specify up to 9 parameters by calling a procedure directly.
// Will cause Dink to say "1, 2, 3, 4, 5, 6, 7, 8, 9"
say_stuff(1, &two, 3, 4, 5, 6, 7, 8, 9);

// You can only pass up to 8 parameters when using external.
// Will cause Dink to say "1, 2, 3, 4, 5, 6, 7, 8, 0"
external("passing", "say_stuff", 1, &two, 3, 4, 5, 6, 7, 8);
}

void say_stuff()
{
say("&arg1, &arg2, &arg3, &arg4, &arg5, &arg6, &arg7, &arg8, &arg9", 1);
}