📧 Message Board Archive

scrip help
I'm not too sure what is going on but this simple script won't make a sprite, can anyone help me?



void main (void)



       {

       preload_seq(383);

       int &sell =  create_sprite(143, 99, 0, 383, 4);

       }
Re: scrip help
Ahem, thank you everybody, but I have tried every single solution individually and together, but none of them work!>( I would like more suggestions, meanwhile, I'll be trying everything I can. Thank you..
Re: scrip help
: I'm not too sure what is going on but this simple script won't make a sprite, can anyone help me?

: void main (void)

:   {

:   preload_seq(383);

:   int &sell = create_sprite(143, 99, 0, 383, 4);

:   }



1. Make sure there is only 1 space after = signs. You have 2 here.

2. If it doesn't help, change &sell to another name (e.g. &_sell)



Re: scrip help
hmm.. in REAL,/b> C/C++, the compiler ignores whitespace, so:



int crap = 10;



is the same as:



int crap =





10;



BUT i dont know if this is the same with dinkC...or is it just with C?? also, i dont know if this is just on a single line, or if it DOES mind newline chars..
Re: scrip help
: hmm.. in REAL,/b> C/C++, the compiler ignores whitespace, so:

: int crap = 10;

: is the same as:

: int crap =

: 10;

: BUT i dont know if this is the same with dinkC...or is it just with C?? also, i dont know if this is just on a single line, or if it DOES mind newline chars..



DinkC is *not* real C.

a =  b; // doesn't work

Re: scrip help
: I'm not too sure what is going on but this simple script won't make a sprite, can anyone help me?

: void main (void)

:         {

:         preload_seq(383);

:         int &sell =  create_sprite(143, 99, 0, 383, 4);

:         }



It looks fine, but sometimes it is not working. I can think of two possible ways to solve this:



 1. Where did you attach this script? If it is a screen script, it might be better to put a wait(1); before creating the sprite. Screen script sometimes does something strange...



 2. use the following script instead:



    int &sell =  create_sprite(143, 99, 0, 0, 0);

    sp_pseq(&sell, 383);

    sp_pframe(&sell, 4);

// The next 3 lines might not be needed

//     sp_brain(&sell, 0);

//     sp_base_walk(&sell, 380);

//     sp_speed(&healer, 0);



Looks o.k. to me.........
: I'm not too sure what is going on but this simple script won't make a sprite, can anyone help me?

: void main (void)

:   {

:   preload_seq(383);

:   int &sell = create_sprite(143, 99, 0, 383, 4);

:   }



there has been once or twice when a proc. of mine wouldn't run until I untabbed it. But then, I still think my computer is possesed..Mwahahaha