Why does the grunt wav sound super-low?
December 30th 2012, 05:33 PM
M. Heller
I've replaced the grunt noises Dink makes when he gets attacked, but they are super low-pitched. I'm not sure what to do to make them scripted to the normal pitch.
Thanks
Thanks
December 30th 2012, 05:37 PM
M. Heller
By super low-pitched, I mean in game. The audio files themselves are fine but not on the game itself.
Are you even of the DN, if so what is your screenname?
Who is M. Heller and i can provide only help in nonsense and things I know about.
No offence, well not really but.
Why are you here then? Just wasting your time?
Why are you here then? Just wasting your time?
Dink's grunt sounds have a speed of 22050 Hz, I assume the ones you have are a higher speed and so when the game plays them at 22050 they sound slow.
How to fix this... erm, you'd probably have to edit the sound files to make them 22050 as Dink grunting is done by the engine. Try Audacity.
Grunt. Hehe, pig farmer...
How to fix this... erm, you'd probably have to edit the sound files to make them 22050 as Dink grunting is done by the engine. Try Audacity.
Grunt. Hehe, pig farmer...
LOL Sparrow - you still have it huh
Got another question. I got windinkedit+, but i can't figure out how to export what i have as a .dmod file to upload to this site. Google comes up with Gmod stuff instead so I can't really use that. I wanna show you guys what i'm working on.
Thanks.
Thanks.
go into DFarc
in preferences, turn on developer keys
Now pick your dmod in the list and click package or something like that
Hope that helps
in preferences, turn on developer keys
Now pick your dmod in the list and click package or something like that
Hope that helps
That's what I was looking for, thanks.
Yeah, sorry for asking again but I can't seem to add another graphic to the game. Just some scenery.
I've did the whole load_sequence_now graphics\ blah blah blah blah- then 98 and 75 like the DinkSmallwoodPT tutorial, but it's not showing it's face in the sprite library. Is there any solution to this?
Yeah, sorry for asking again but I can't seem to add another graphic to the game. Just some scenery.
I've did the whole load_sequence_now graphics\ blah blah blah blah- then 98 and 75 like the DinkSmallwoodPT tutorial, but it's not showing it's face in the sprite library. Is there any solution to this?
Do you have a blank space where it should be or does nothing happen at all?
If there's a blank space it may be because the bit depth is too high - 32 bit BMPs won't work, change it to max 24 bit (lower better if it won't ruin the colours, for smaller file size).
If there's a blank space it may be because the bit depth is too high - 32 bit BMPs won't work, change it to max 24 bit (lower better if it won't ruin the colours, for smaller file size).
It can also be a corrupt square (leaves it blue - i get that when i play with things and change too many times) - or you may have misnamed/numbered your pics or not got the correct pathway in the ini file
Edit: try a new square - i start adding at 34
Edit: try a new square - i start adding at 34
It doesn't show up at all, it's still sequence 97, then 99. I've checked the path and everything seems to be right.
If you want - send it to me and I will fix for you Cant really tell whats wrong without seeing it, emails in my profile
I'll just replace existing graphics since i won't be using most of them.
THanks anyways.
THanks anyways.
Is there any way to script an enemy to die when it touches the player, still giving damage to the player?
January 4th 2013, 03:24 AM
shevek
Is there any way to script an enemy to die when it touches the player, still giving damage to the player?
Sure. Set the touch damage to -1, so a script is called. In that script, do whatever you like (that is, make the enemy die and hurt Dink). This happens for slimes in lost forest romp, for example.
Sure. Set the touch damage to -1, so a script is called. In that script, do whatever you like (that is, make the enemy die and hurt Dink). This happens for slimes in lost forest romp, for example.
Beware to set the touch damage to 0 first thing in the script, otherwise you risk the game freezing because it attempts to keep running the touch() procedure.
If the sprite can somehow survive, remember to set the touch damage back to -1 after some delay, otherwise you'll continuously trigger the touch() procedure, which is probably not what you'd want.
If there's no way the sprite can survive, ignore that last paragraph
void main( void ) { // other things here sp_touch_damage(¤t_sprite, -1); } void touch( void ) { sp_touch_damage(¤t_sprite, 0); // other things here. Possibly involving hurt() and code to make it die. }
If the sprite can somehow survive, remember to set the touch damage back to -1 after some delay, otherwise you'll continuously trigger the touch() procedure, which is probably not what you'd want.
If there's no way the sprite can survive, ignore that last paragraph
I tried that and the infe- i mean pillbugs don't do any damage to the player at all.
Hmm.
Hmm.
January 5th 2013, 05:24 AM
shevek
pillbugs don't do any damage to the player at all.
That is correct. Pillbugs hurt Dink through touch damage. If you set that to -1, they will no longer hurt him. However, because your script is run, you can make them hurt Dink in there:
This first makes sure touch() is only called once, then hurts Dink, then sets the sprite's animation to its way to die, which is then run and left at the background with brain 5. If you don't want a death animation, you can simply use sp_active(¤t_sprite, 0); instead.
Note that with the above script, they will always do exactly 5-defense damage, which isn't equivalent of touch damage 5. If you want that, you should compute random (5/2, 5/2) (a random value from the upper half of the touch damage) and use the result.
That is correct. Pillbugs hurt Dink through touch damage. If you set that to -1, they will no longer hurt him. However, because your script is run, you can make them hurt Dink in there:
void touch() { sp_touch_damage(¤t_sprite, 0); hurt(1, 5); sp_seq(¤t_sprite, <insert dying sequence here ; sp_frame(¤t_sprite, 1); sp_brain(¤t_sprite, 5); }
This first makes sure touch() is only called once, then hurts Dink, then sets the sprite's animation to its way to die, which is then run and left at the background with brain 5. If you don't want a death animation, you can simply use sp_active(¤t_sprite, 0); instead.
Note that with the above script, they will always do exactly 5-defense damage, which isn't equivalent of touch damage 5. If you want that, you should compute random (5/2, 5/2) (a random value from the upper half of the touch damage) and use the result.
This method won't give any experience points, or trigger the die() procedure (which triggers the item drops). hurt()ing ¤t_sprite will kill it properly, but still won't award the experience (and you'll see the amount of damage float over the sprite, which you may not want). add_exp() can be used for the former, though I'm not sure if you can trigger die() through the engine without making text appear. You could always call die() manually, though.
More meddling later
Seems like an sp_touch_damage unequal to 0 will trigger the touch() procedure, not just when it's -1. A difference is that a positive value will only trigger touch() every 400 milliseconds, at the same time the damage is dealt. I've confirmed this to be the case for brains 0 and 9, and because it works with brain 0, I expect it to work with every brain.
Also, damage from touching is not random, except the usual 50/50 case when your defense is greater than the damage dealt. hurt() may already do this, not sure. The upper-half thing shevek mentioned is true for sprites that have an attack() procedure and an sp_strength.
More meddling later
Seems like an sp_touch_damage unequal to 0 will trigger the touch() procedure, not just when it's -1. A difference is that a positive value will only trigger touch() every 400 milliseconds, at the same time the damage is dealt. I've confirmed this to be the case for brains 0 and 9, and because it works with brain 0, I expect it to work with every brain.
Also, damage from touching is not random, except the usual 50/50 case when your defense is greater than the damage dealt. hurt() may already do this, not sure. The upper-half thing shevek mentioned is true for sprites that have an attack() procedure and an sp_strength.