📧 Message Board Archive

fast dink
i have begun learning dinkc, and want to know how to speed up weapons. is it in each weapons script, or in main.c? thanks
Re: fast dink
: i have begun learning dinkc, and want to know how to speed up weapons. is it in each weapons script, or in main.c? thanks



in the herb boots script i found some codes:



void disarm(void)

{

set_dink_speed(3);

sp_frame_delay(1, 0);

debug("Disarming boots");

kill_this_task();

}



void arm(void)

{

set_dink_speed(2);

sp_frame_delay(1, 30);

debug("arming boots");



init("load_sequence_now graphics\dink\walk\ds-w1- 71 43 38 72 -14 -9 14 9");

init("load_sequence_now graphics\dink\walk\ds-w2- 72 43 37 69 -13 -9 13 9");

init("load_sequence_now graphics\dink\walk\ds-w3- 73 43 38 72 -14 -9 14 9");

init("load_sequence_now graphics\dink\walk\ds-w4- 74 43 38 72 -12 -9 12 9");



init("load_sequence_now graphics\dink\walk\ds-w6- 76 43 38 72 -13 -9 13 9");

init("load_sequence_now graphics\dink\walk\ds-w7- 77 43 38 72 -12 -10 12 10");

init("load_sequence_now graphics\dink\walk\ds-w8- 78 43 37 69 -13 -9 13 9");

init("load_sequence_now graphics\dink\walk\ds-w9- 79 43 38 72 -14 -9 14 9");



init("load_sequence_now graphics\dink\idle\ds-i2- 12 250 33 70 -12 -9 12 9");

init("load_sequence_now graphics\dink\idle\ds-i4- 14 250 30 71 -11 -9 11 9");

init("load_sequence_now graphics\dink\idle\ds-i6- 16 250 36 70 -11 -9 11 9");

init("load_sequence_now graphics\dink\idle\ds-i8- 18 250 32 68 -12 -9 12 9");



init("load_sequence_now graphics\dink\hit\normal\ds-h2- 102 75 60 72 -19 -9 19 9");

init("load_sequence_now graphics\dink\hit\normal\ds-h4- 104 75 61 73 -19 -10 19 10");

init("load_sequence_now graphics\dink\hit\normal\ds-h6- 106 75 58 71 -18 -10 18 10");

init("load_sequence_now graphics\dink\hit\normal\ds-h8- 108 75 61 71 -19 -10 19 10");





int &basehit;

}



I know that set_dink_speed means changing dinks walking speed. I also know that dinks default speed is 3, and that the boots give him speed 2 (i know that dink speed 2 is faster than dink speed 3). i have changed dinks walk speed, and tried changing the weapon speed with set_frame_delay, because the frame delay was different. what is frame delay?
fast animations
: : i have begun learning dinkc, and want to know how to speed up weapons. is it in each weapons script, or in main.c? thanks



: in the herb boots script i found some codes:



: void disarm(void)



: {



: set_dink_speed(3);



: sp_frame_delay(1, 0);



: debug("Disarming boots");



: kill_this_task();



: }



: void arm(void)



: {



: set_dink_speed(2);



: sp_frame_delay(1, 30);



: debug("arming boots");



: init("load_sequence_now graphics\dink\walk\ds-w1- 71 43 38 72 -14 -9 14 9");



: init("load_sequence_now graphics\dink\walk\ds-w2- 72 43 37 69 -13 -9 13 9");



: init("load_sequence_now graphics\dink\walk\ds-w3- 73 43 38 72 -14 -9 14 9");



: init("load_sequence_now graphics\dink\walk\ds-w4- 74 43 38 72 -12 -9 12 9");



: init("load_sequence_now graphics\dink\walk\ds-w6- 76 43 38 72 -13 -9 13 9");



: init("load_sequence_now graphics\dink\walk\ds-w7- 77 43 38 72 -12 -10 12 10");



: init("load_sequence_now graphics\dink\walk\ds-w8- 78 43 37 69 -13 -9 13 9");



: init("load_sequence_now graphics\dink\walk\ds-w9- 79 43 38 72 -14 -9 14 9");



: init("load_sequence_now graphics\dink\idle\ds-i2- 12 250 33 70 -12 -9 12 9");



: init("load_sequence_now graphics\dink\idle\ds-i4- 14 250 30 71 -11 -9 11 9");



: init("load_sequence_now graphics\dink\idle\ds-i6- 16 250 36 70 -11 -9 11 9");



: init("load_sequence_now graphics\dink\idle\ds-i8- 18 250 32 68 -12 -9 12 9");



: init("load_sequence_now graphics\dink\hit\normal\ds-h2- 102 75 60 72 -19 -9 19 9");



: init("load_sequence_now graphics\dink\hit\normal\ds-h4- 104 75 61 73 -19 -10 19 10");



: init("load_sequence_now graphics\dink\hit\normal\ds-h6- 106 75 58 71 -18 -10 18 10");



: init("load_sequence_now graphics\dink\hit\normal\ds-h8- 108 75 61 71 -19 -10 19 10");



: int &basehit;



: }



: I know that set_dink_speed means changing dinks walking speed. I also know that dinks default speed is 3, and that the boots give him speed 2 (i know that dink speed 2 is faster than dink speed 3). i have changed dinks walk speed, and tried changing the weapon speed with set_frame_delay, because the frame delay was different. what is frame delay?



i saw that dinks legs are moving slow, but he walks fast. then its more correct to call it fast animations. ok, i want you to help me with fast animations and hitting rate. must i edit each weapons script? also: how do i make an auto-fire button, like shift is in eot2 while wearing the herb boots magic.
Re: fast animations


set_frame_delay causes a brief pause on that particular frame of the animation.  If you want the entire animation to speed up, then you'll need to change some numbers in Dink.ini AND the script for the weapon.



After the load_squence_now graphics\... line there is a series of numbers.  The first number is the sequence number, leave that only.  The second number is the speed at which the animation is run.  Dinks animations are typically set somewhere around 100.  Make it a lower number to go faster, a higher number to go slower.



Re: fast animations
: set_frame_delay causes a brief pause on that particular frame of the animation. If you want the entire animation to speed up, then you'll need to change some numbers in Dink.ini AND the script for the weapon.



: After the load_squence_now graphics\... line there is a series of numbers. The first number is the sequence number, leave that only. The second number is the speed at which the animation is run. Dinks animations are typically set somewhere around 100. Make it a lower number to go faster, a higher number to go slower.



how do i speed up the hit rate, and what in dink.ini must i change? also: how did you edit your message?
Re: fast animations
: set_frame_delay causes a brief pause on that particular frame of the animation. If you want the entire animation to speed up, then you'll need to change some numbers in Dink.ini AND the script for the weapon.



: After the load_squence_now graphics\... line there is a series of numbers. The first number is the sequence number, leave that only. The second number is the speed at which the animation is run. Dinks animations are typically set somewhere around 100. Make it a lower number to go faster, a higher number to go slower.



does that mean that i must edit the script for every weapon? i'll try. thanks! :o

i am in the chat room now. do you know how i assign auto fire to a button?
Re: fast animations
: : set_frame_delay causes a brief pause on that particular frame of the animation. If you want the entire animation to speed up, then you'll need to change some numbers in Dink.ini AND the script for the weapon.



: : After the load_squence_now graphics\... line there is a series of numbers. The first number is the sequence number, leave that only. The second number is the speed at which the animation is run. Dinks animations are typically set somewhere around 100. Make it a lower number to go faster, a higher number to go slower.



: does that mean that i must edit the script for every weapon? i'll try. thanks! :o



: i am in the chat room now. do you know how i assign auto fire to a button?



here i have the item-sw3 script:

//item sword 3



void use( void )

{

//disallow diagonal punches



if (sp_dir(1, -1) == 1)

   sp_dir(1, 2);

if (sp_dir(1, -1) == 3)

   sp_dir(1, 2);

if (sp_dir(1, -1) == 7)

   sp_dir(1, 8);

if (sp_dir(1, -1) == 9)

   sp_dir(1, 8);



&basehit = sp_dir(1, -1);

&basehit += 100; //100 is the 'base' for the hit animations, we just add

//the direction

sp_seq(1, &basehit);

sp_frame(1, 1); //reset seq to 1st frame

sp_kill_wait(1); //make sure dink will punch right away

sp_nocontrol(1, 1); //dink can't move until anim is done!

wait(200);

playsound(8, 8000,0,0,0);



}



void disarm(void)

{

sp_attack_hit_sound(1, 0);



&strength -= 25;

sp_distance(1, 0);

sp_range(1, 0);

kill_this_task();

}



void arm(void)

{

//sword range

sp_distance(1, 50);

sp_range(1, 40);

//sword strength added

&strength += 25;



sp_attack_hit_sound(1, 10);

sp_attack_hit_sound_speed(1, 8000);

init("load_sequence_now graphics\dink\sword\walk\d-sw1- 71 43 64 69 -14 -10 14 10");

init("load_sequence_now graphics\dink\sword\walk\d-sw2- 72 43 35 70 -21 -10 19 10");

init("load_sequence_now graphics\dink\sword\walk\d-sw3- 73 43 28 69 -13 -9 13 9");

init("load_sequence_now graphics\dink\sword\walk\d-sw4- 74 43 66 75 -14 -12 20 12");



init("load_sequence_now graphics\dink\sword\walk\d-sw6- 76 43 27 69 -23 -10 23 10");

init("load_sequence_now graphics\dink\sword\walk\d-sw7- 77 43 38 94 -20 -10 20 10");

init("load_sequence_now graphics\dink\sword\walk\d-sw8- 78 43 30 96 -15 -12 15 12");

init("load_sequence_now graphics\dink\sword\walk\d-sw9- 79 43 31 80 -13 -9 13 9");



init("load_sequence_now graphics\dink\sword\idle\d-si2- 12 250 74 73 -17 -12 16 9");

init("load_sequence_now graphics\dink\sword\idle\d-si4- 14 250 57 103 -11 -12 16 10");

init("load_sequence_now graphics\dink\sword\idle\d-si6- 16 250 30 92 -15 -9 11 9");

init("load_sequence_now graphics\dink\sword\idle\d-si8- 18 250 35 106 -15 -12 15 9");



init("load_sequence_now graphics\dink\sword\hit\d-sa2- 102 75 52 92 -23 -12 24 11");

init("load_sequence_now graphics\dink\sword\hit\d-sa4- 104 75 74 90 -23 -13 23 14");

init("load_sequence_now graphics\dink\sword\hit\d-sa6- 106 75 33 92 -18 -14 18 10");

init("load_sequence_now graphics\dink\sword\hit\d-sa8- 108 75 46 109 -17 -16 17 10");

int &basehit;

}



void pickup(void)

{

Debug("Player now owns this item.");

kill_this_task();

}



void holdingdrop( void )

{

//this is run if the item is dropped while it is armed

init("load_sequence_now graphics\dink\walk\ds-w1- 71 43 38 72 -14 -9 14 9");

init("load_sequence_now graphics\dink\walk\ds-w2- 72 43 37 69 -13 -9 13 9");

init("load_sequence_now graphics\dink\walk\ds-w3- 73 43 38 72 -14 -9 14 9");

init("load_sequence_now graphics\dink\walk\ds-w4- 74 43 38 72 -12 -9 12 9");



init("load_sequence_now graphics\dink\walk\ds-w6- 76 43 38 72 -13 -9 13 9");

init("load_sequence_now graphics\dink\walk\ds-w7- 77 43 38 72 -12 -10 12 10");

init("load_sequence_now graphics\dink\walk\ds-w8- 78 43 37 69 -13 -9 13 9");

init("load_sequence_now graphics\dink\walk\ds-w9- 79 43 38 72 -14 -9 14 9");



init("load_sequence_now graphics\dink\idle\ds-i2- 12 250 33 70 -12 -9 12 9");

init("load_sequence_now graphics\dink\idle\ds-i4- 14 250 30 71 -11 -9 11 9");

init("load_sequence_now graphics\dink\idle\ds-i6- 16 250 36 70 -11 -9 11 9");

init("load_sequence_now graphics\dink\idle\ds-i8- 18 250 32 68 -12 -9 12 9");



}



void drop(void)

{

Debug("Item dropped.");

kill_this_task();

}



what shall i edit? each number in each of the series? also: what about dinks leg speed?
Re: fast animations


: init("load_sequence_now graphics\dink\sword\walk\d-sw1- 71 <<43>> 64 69 -14 -10 14 10");



Change that number for every direction.  That will change how fast the animation is for Dink walking with the sword.



In any animation, if you adjust that second number, it will change how fast the animation is run.  Just make sure you do it for every direction.



Re: fast animations
: : init("load_sequence_now graphics\dink\sword\walk\d-sw1- 71 <<43>> 64 69 -14 -10 14 10");



: Change that number for every direction. That will change how fast the animation is for Dink walking with the sword.



: In any animation, if you adjust that second number, it will change how fast the animation is run. Just make sure you do it for every direction.



thanks for the help, but i can't see any difference :(
Re: fast animations
: : : init("load_sequence_now graphics\dink\sword\walk\d-sw1- 71 <<43>> 64 69 -14 -10 14 10");



: : Change that number for every direction. That will change how fast the animation is for Dink walking with the sword.



: : In any animation, if you adjust that second number, it will change how fast the animation is run. Just make sure you do it for every direction.



: thanks for the help, but i can't see any difference :(



You might need to change the number in Dink.ini as well.  Also, you'll probably need to change by at least 20 or 30 to make any noticable difference.  Setting it to 1 would make it go insanely fast, I don't know exactly what you're shooting for, but I'd suggest changing it to about 40.



About the auto-fire button... can you explain exactly what you mean by this?  If you want to assign a function to a specific key on the keyboard, then you'll need to create a script called "key-number_of_key".  Then put your autofire info in that script.  See Dan Walma's "Keycodes", available in the development section at TDN, for a complete list of the available keys and their corresponding numbers.  Assigning functions to keys is also explained at the beginning of DINK.C under "What's new in this version"



Re: fast animations
The lines you need to edit is are the ones with sequences 102, 104, 106 and 108.



Also that rapid fire effect is directly caused by making it into a spell. Dink automatically casts a spell again when his magic bar is full (or right away for a free spell) if you hold shift down, whereas items are only used once per press of ctrl. I don't know of any way around that.
Re: fast animations
: The lines you need to edit is are the ones with sequences 102, 104, 106 and 108.



: Also that rapid fire effect is directly caused by making it into a spell. Dink automatically casts a spell again when his magic bar is full (or right away for a free spell) if you hold shift down, whereas items are only used once per press of ctrl. I don't know of any way around that.



i edited all the sequences in the item-sw3.c script and the dink hit and dink sword or something in dink.ini, but i do not see any big difference (i made all the second numbers half as big as they were).



There must be a way to make an auto fire button. why not make an invisible thing who is almost the same as magic? i mean with mana and such.