About creating a sprite from a script attached to the screen
I'm just a beginner, don't shoot me! But I've got this little question when you create a sprite (eg. a knight).
Can you attach a script to this sprite?
Because I want to be able to talk with him. Please do help me!
Thx
Stefanie
Can you attach a script to this sprite?
Because I want to be able to talk with him. Please do help me!
Thx


Depends on the method you make him.. if you make him in DinkEdit, you pick up the sprite, as if you're gonna move it, then hold down SHIFT and click 5, then it asks for the script name, say you have a script called "knight.c", then you enter "knight" (without the .c), and it should work.
If you made the knight with the create_sprite(); command, you must do something like so:
int &knight = create_sprite(values);
sp_script(&knight, "knight");
I think. My DinkC is getting a little rusty, but I think that is how you do it. And if you don't understand what I've just babbled about, I'd suggest you read the txt files in the dink smallwood folder through first.
If you made the knight with the create_sprite(); command, you must do something like so:
int &knight = create_sprite(values);
sp_script(&knight, "knight");
I think. My DinkC is getting a little rusty, but I think that is how you do it. And if you don't understand what I've just babbled about, I'd suggest you read the txt files in the dink smallwood folder through first.
