Author Topic: Danmakufu Q&A/Problem Thread II  (Read 166252 times)

Lawence Codye

  • The Nine Tails of Subconscious...
  • Come & your desires shall all become reality...
Re: Danmakufu Q&A/Problem Thread II
« Reply #540 on: December 06, 2009, 11:34:51 AM »
wow...guess I wasn't paying much attention to previous posts that day...ouch...
well, thanks Blargel...& with that another question remains...

Now you say that I'll need to store the id somewhere where @MainLoop can access it...would right before @Initialize in the script_player_main be an acceptable location...?

& I'd have to use SetVertexUV to define the coordinates/Vertexes of the graphic on the sheet(file) I want Danmakufu to display, right...?
I am the Nine Tails of Subconscious...

Come & your greatest desires will be reality...

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: Danmakufu Q&A/Problem Thread II
« Reply #541 on: December 06, 2009, 12:07:46 PM »
Question specific for the 3D stage crafters.

Is it me or there seem to be a weird way that Danmakufu places 3D objects in stages. ( not effect objects, just 3D drawing in @BackGround ).

Look at this:
   makemuur(GetCenterX-768,0,f,90); 
   makemuur(GetCenterX+768,0,f,90);

The above are functions to save endless blocks of scripting. First parameter places the wall on the X-axis, second on on the Y-axis, the third one on the Z-axis (aka scrolling technique) and the last parameter is something I added to flip/tilt the wall flexible. Basically I am creating two walls exactly on the opposite side ( minus and plus 768. ) However, this is how it looks ingame.



This is a reversed view ( I am flying backwards ). As you can see, the walls don't even allign proper with eachother. Why is this happening?

Kylesky

  • *The Unknown*
  • Local Unbalanced Danmakufu Idiot Scripter
    • My useless youtube account... (will be useful in the future *I promise*)
Re: Danmakufu Q&A/Problem Thread II
« Reply #542 on: December 06, 2009, 12:56:52 PM »
Question specific for the 3D stage crafters.

Is it me or there seem to be a weird way that Danmakufu places 3D objects in stages. ( not effect objects, just 3D drawing in @BackGround ).

Look at this:
   makemuur(GetCenterX-768,0,f,90); 
   makemuur(GetCenterX+768,0,f,90);

The above are functions to save endless blocks of scripting. First parameter places the wall on the X-axis, second on on the Y-axis, the third one on the Z-axis (aka scrolling technique) and the last parameter is something I added to flip/tilt the wall flexible. Basically I am creating two walls exactly on the opposite side ( minus and plus 768. ) However, this is how it looks ingame.



This is a reversed view ( I am flying backwards ). As you can see, the walls don't even allign proper with eachother. Why is this happening?


is it possible that the walls are placed this way
___________________  <-- black stuff
|                            |  <-- walls
|       floor               |
|                            |
|                            |

                                 <-- empty space and black stuff
       floor

___________________

and in the first one
you're facing this way
___________________   <--black stuff
|                            |  <--walls
|        floor              |
|                            |
|                \           |
                   \
                  \ \|           <--empty space and black stuff
       floor       \|

___________________

then reversing it
___________________  <--black stuff
|                            |  <--walls
|         floor             |
|    |\                     |
|    |\ \                   |
        \
         \
          floor                <--empty space and black stuff

___________________

that way?

since what I'm seeing is in the first picture, the wall doesn't reach the end of the floor, but in the next, the wall does. (what do you mean by reversed view anyway... rotate by 180 degrees?)

now you say that I'll need to store the id somewhere where @MainLoop can access it...would right before @Initialize in the script_player_main be an acceptable location...?

& I'd have to use SetVertexUV to define the coordinates/Vertexes of the graphic on the sheet(file) I want Danmakufu to display, right...?

Before @Initialize is where most people declare id's for objects that they use in the whole script and not just for one part, usually it's where they also declare variables...

SetVertexUV is to define the coordinates on the file you're taking pictures from, yes...
« Last Edit: December 06, 2009, 01:04:11 PM by Kylesky »
Danmakufu Script Thread :V Latest Script: Intertwining Mechanical Intervention (temp name)

Yooooouuutuuuubeeee Channel Latest Video: Contest #8 Entry

Blargel

  • RAWR!
  • I'M AN ANGRY LOLI!
Re: Danmakufu Q&A/Problem Thread II
« Reply #543 on: December 06, 2009, 01:36:16 PM »
Oh, I forgot to mention one last fundamental difference between subroutines, functions, and tasks. Functions are the ONLY ones that can return values. For example:

function GetDistance(x1, y1, x2, y2){
    return ((x1-x2)^2+(y1-y2)^2)^0.5;
}


Then, you can do let distanceToPlayer = GetDistance(GetX, GetY, GetPlayerX, GetPlayerY); and the variable will now hold the value that was returned. Of course you can also do stuff like this:

function ObjShot_Create(x, y, speed, angle, graphic, delay){
    let obj = Obj_Create(OBJ_SHOT);
    Obj_SetPosition(obj, x, y);
    Obj_SetSpeed(obj, speed);
    Obj_SetAngle(obj, angle);
    ObjShot_SetGraphic(obj, graphic);
    ObjShot_SetDelay(obj, delay);
    return obj;
}


And then you can go let obj = ObjShot_Create(GetX, GetY, 3, GetAngleToPlayer, RED01, 10); so that you don't have to type out the individual Obj_SetStuff functions every time.
<WorkingKeine> when i get home i just go to the ps3 and beat people up in blazblue with a loli
<Azure> Keine: Danmakufu helper by day, violent loli by night.

Lawence Codye

  • The Nine Tails of Subconscious...
  • Come & your desires shall all become reality...
Re: Danmakufu Q&A/Problem Thread II
« Reply #544 on: December 06, 2009, 01:41:03 PM »
Oh, I forgot to mention one last fundamental difference between subroutines, functions, and tasks. Functions are the ONLY ones that can return values. For example:

function GetDistance(x1, y1, x2, y2){
    return ((x1-x2)^2+(y1-y2)^2)^0.5;
}


Then, you can do let distanceToPlayer = GetDistance(GetX, GetY, GetPlayerX, GetPlayerY); and the variable will now hold the value that was returned. Of course you can also do stuff like this:

function ObjShot_Create(x, y, speed, angle, graphic, delay){
    let obj = Obj_Create(OBJ_SHOT);
    Obj_SetPosition(obj, x, y);
    Obj_SetSpeed(obj, speed);
    Obj_SetAngle(obj, angle);
    ObjShot_SetGraphic(obj, graphic);
    ObjShot_SetDelay(obj, delay);
    return obj;
}


And then you can go let obj = ObjShot_Create(GetX, GetY, 3, GetAngleToPlayer, RED01, 10); so that you don't have to type out the individual Obj_SetStuff functions every time.

actually...that'll help big time...thanks Blargel, & Kylesky...
I am the Nine Tails of Subconscious...

Come & your greatest desires will be reality...

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: Danmakufu Q&A/Problem Thread II
« Reply #545 on: December 06, 2009, 02:06:59 PM »
Kylesky it is exacly as I wrote it. It is a reversed view meaning the camera is turned 180 degree to show the backside where the alligning is not proper. Same goes for the front side aswell, also not alligned proper.

Blargel

  • RAWR!
  • I'M AN ANGRY LOLI!
Re: Danmakufu Q&A/Problem Thread II
« Reply #546 on: December 06, 2009, 02:20:46 PM »
Question specific for the 3D stage crafters.

Is it me or there seem to be a weird way that Danmakufu places 3D objects in stages. ( not effect objects, just 3D drawing in @BackGround ).

Look at this:
   makemuur(GetCenterX-768,0,f,90); 
   makemuur(GetCenterX+768,0,f,90);

The above are functions to save endless blocks of scripting. First parameter places the wall on the X-axis, second on on the Y-axis, the third one on the Z-axis (aka scrolling technique) and the last parameter is something I added to flip/tilt the wall flexible. Basically I am creating two walls exactly on the opposite side ( minus and plus 768. ) However, this is how it looks ingame.



This is a reversed view ( I am flying backwards ). As you can see, the walls don't even allign proper with eachother. Why is this happening?

GetCenterX is the x-center of the 2D playing field, not the x-center of the 3D space.
<WorkingKeine> when i get home i just go to the ps3 and beat people up in blazblue with a loli
<Azure> Keine: Danmakufu helper by day, violent loli by night.

Kylesky

  • *The Unknown*
  • Local Unbalanced Danmakufu Idiot Scripter
    • My useless youtube account... (will be useful in the future *I promise*)
Re: Danmakufu Q&A/Problem Thread II
« Reply #547 on: December 06, 2009, 02:23:59 PM »
GetCenterX is the x-center of the 2D playing field, not the x-center of the 3D space.

oh yeah... forgot about that... *hits head*
Danmakufu Script Thread :V Latest Script: Intertwining Mechanical Intervention (temp name)

Yooooouuutuuuubeeee Channel Latest Video: Contest #8 Entry

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: Danmakufu Q&A/Problem Thread II
« Reply #548 on: December 06, 2009, 03:27:35 PM »
Let me try to add raw numbers then instead of using functions like GetCenter / GetClip

Edit: Yup, you are right Blargel. Using GetClip / GetCenter is not funny. Danmakufu places them totally wrong. Note to self: use raw numbers for 3D drawing.

« Last Edit: December 06, 2009, 04:06:04 PM by Helepolis »

Chronojet ⚙ Dragon

  • The Oddity
  • 今コソ輝ケ、我ガ未来、ソノ可能性!!
Re: Danmakufu Q&A/Problem Thread II
« Reply #549 on: December 06, 2009, 05:46:59 PM »
This:
FadeOutMusic("bgm\bgm.mp3", 6);

...??
« Last Edit: December 07, 2009, 12:26:27 AM by Always お⑨烏 »

Drake

  • *
Re: Danmakufu Q&A/Problem Thread II
« Reply #550 on: December 06, 2009, 07:07:15 PM »
There... is no function to fade out music...

A Colorful Calculating Creative and Cuddly Crafty Callipygous Clever Commander
- original art by Aiけん | ウサホリ -

Chronojet ⚙ Dragon

  • The Oddity
  • 今コソ輝ケ、我ガ未来、ソノ可能性!!
Re: Danmakufu Q&A/Problem Thread II
« Reply #551 on: December 06, 2009, 07:09:23 PM »
There... is no function to fade out music...
Eh, wut? It works with my scripts.

Stuffman

  • *
  • We're having a ball!
Re: Danmakufu Q&A/Problem Thread II
« Reply #552 on: December 06, 2009, 11:35:42 PM »
Actually that function does exist, but it never worked any time I tried to use it.

Fujiwara no Mokou

  • Hourai Incarnate
  • Oh, so this trial of guts is for ME?
    • Profile
Re: Danmakufu Q&A/Problem Thread II
« Reply #553 on: December 07, 2009, 04:38:28 AM »
Eh, wut? It works with my scripts.
Actually that function does exist, but it never worked any time I tried to use it.

Try placing the music in a task of its own, and put in a bunch of yields until you want the music to stop, and then put the actual function. This works for me.

Lawence Codye

  • The Nine Tails of Subconscious...
  • Come & your desires shall all become reality...
Re: Danmakufu Q&A/Problem Thread II
« Reply #554 on: December 07, 2009, 02:57:11 PM »
For Lawence Codye: You'll need to store the id of the object effect that is displaying the options where it can be accessed in the @MainLoop. Then, somewhere in the player script's @MainLoop, you can do

okay...umm how do I do this?...& I'm not asking where as I already know that...
I am the Nine Tails of Subconscious...

Come & your greatest desires will be reality...

Kylesky

  • *The Unknown*
  • Local Unbalanced Danmakufu Idiot Scripter
    • My useless youtube account... (will be useful in the future *I promise*)
Re: Danmakufu Q&A/Problem Thread II
« Reply #555 on: December 07, 2009, 03:59:45 PM »
okay...umm how do I do this?...& I'm not asking where as I already know that...

Code: [Select]
script_player_main{
//declare stuff
//declare options

let optiona=Obj_Create(OBJ_EFFECT);
//etc

task Option(position){
//things about your option
}
task optionmove(whatever)
{
//do whatever
}

  @Initialize{
//load stuff
  }


  @MainLoop{
yield;
//everything else you need

  if((GetKeyState(VK_SLOWMOVE)==KEY_PUSH || GetKeyState(VK_SLOWMOVE)==KEY_HOLD)){
//optiona do whatever...
//OR
//what do you want the option to do or task that makes the option do something, etc.
//optionmove(whatever)
  }


  @Missed{
//put anything you may want to put here
  }
  @SpellCard{
//put spell cards
  }


  @DrawLoop{
//draw stuff
}

  @Finalize{
//delete stuff
  }

}
Danmakufu Script Thread :V Latest Script: Intertwining Mechanical Intervention (temp name)

Yooooouuutuuuubeeee Channel Latest Video: Contest #8 Entry

Lawence Codye

  • The Nine Tails of Subconscious...
  • Come & your desires shall all become reality...
Re: Danmakufu Q&A/Problem Thread II
« Reply #556 on: December 07, 2009, 08:12:20 PM »
umm, yeah...thanks kylesky, even though I'm trying something different now...
« Last Edit: December 07, 2009, 09:48:08 PM by Lawence Codye »
I am the Nine Tails of Subconscious...

Come & your greatest desires will be reality...

KrackoCloud

  • I don't mean to be greedy...
  • ... but white rice is my favorite food.
Re: Danmakufu Q&A/Problem Thread II
« Reply #557 on: December 07, 2009, 11:44:39 PM »
I can use SetShotKillTime to delete ShotA bullets, but... they just kinda disappear. What do I use to make them show a deletion animation? You know, like when they kinda have a little "poof" out and whatnot, rather than simply vanish.

nintendonut888

  • So those that live now, pledge on your fists and souls
  • Leave a sign of your life, no matter how small...
Re: Danmakufu Q&A/Problem Thread II
« Reply #558 on: December 08, 2009, 12:24:03 AM »
Hiyo. I can't get Danmakufu to run (or maybe it's just CtC, but I can't get anything to open). I have what I think is the latest version, run it with applocale, and it always brings up a "this program has stopped working" window with no explanation why. Any help? D: I use Vista if that makes a difference.
nintendonut888: Hey Baity. I beat the high score for Sanae B hard on the score.dat you sent me. X3
Baity: For a moment, I thought you broke 1.1billion. Upon looking at my score.dat, I can assume that you destroyed the score that is my failed (first!) 1cc attempt on my first day of playing. Congratulations.

[19:42] <Sapz> I think that's the only time I've ever seen a suicide bullet shoot its own suicide bullet

Blargel

  • RAWR!
  • I'M AN ANGRY LOLI!
Re: Danmakufu Q&A/Problem Thread II
« Reply #559 on: December 08, 2009, 02:33:29 AM »
I can use SetShotKillTime to delete ShotA bullets, but... they just kinda disappear. What do I use to make them show a deletion animation? You know, like when they kinda have a little "poof" out and whatnot, rather than simply vanish.

Unfortunately, there's no good way to do a nice effect for a randomly disappearing ShotA bullet. With object shots, you can do fade deleting, but for ShotA, the best thing you can do is to AddShot a delayed bullet in one frame before the one that's deleting is getting deleted. This second bullet can have SetShotKillTime on it for 0 frames so that as soon as the delay effect is gone, the bullet disappears. In this way, the bullet you want to delete will seem to sort of fade/shrink away.

As an example:
CreateShotA(0, GetX, GetY, 10);
SetShotDataA(0, 0, 3, 90, 0, 0, 0, RED22);
//put more SetShotDataA if you need it
SetShotKillTime(0, 120);
CreateShotA(1, 0, 0, 20);
SetShotDataA(1, 0, 0, 0, 0, 0, 0, RED22);
SetShotKillTime(1, 0);
AddShot(119, 0, 1, 0);
FireShot(0);


No idea about the next question though.
*passes the microphone to the next person*
<WorkingKeine> when i get home i just go to the ps3 and beat people up in blazblue with a loli
<Azure> Keine: Danmakufu helper by day, violent loli by night.

nintendonut888

  • So those that live now, pledge on your fists and souls
  • Leave a sign of your life, no matter how small...
Re: Danmakufu Q&A/Problem Thread II
« Reply #560 on: December 08, 2009, 02:38:38 AM »
Well, I definitely confirmed that it's Danmakufu itself that won't run, because I went to the site and downloaded version 0.12m or whatever the latest version is, ran it with applocale and it brought up the same crash scenario. :(
nintendonut888: Hey Baity. I beat the high score for Sanae B hard on the score.dat you sent me. X3
Baity: For a moment, I thought you broke 1.1billion. Upon looking at my score.dat, I can assume that you destroyed the score that is my failed (first!) 1cc attempt on my first day of playing. Congratulations.

[19:42] <Sapz> I think that's the only time I've ever seen a suicide bullet shoot its own suicide bullet

Re: Danmakufu Q&A/Problem Thread II
« Reply #561 on: December 08, 2009, 03:05:07 AM »
Well, I definitely confirmed that it's Danmakufu itself that won't run, because I went to the site and downloaded version 0.12m or whatever the latest version is, ran it with applocale and it brought up the same crash scenario. :(
I've probably said this too many times already but try running the game with config.exe

Works for me anyways

nintendonut888

  • So those that live now, pledge on your fists and souls
  • Leave a sign of your life, no matter how small...
Re: Danmakufu Q&A/Problem Thread II
« Reply #562 on: December 08, 2009, 03:18:08 AM »
How? The thing is in Japanese.
nintendonut888: Hey Baity. I beat the high score for Sanae B hard on the score.dat you sent me. X3
Baity: For a moment, I thought you broke 1.1billion. Upon looking at my score.dat, I can assume that you destroyed the score that is my failed (first!) 1cc attempt on my first day of playing. Congratulations.

[19:42] <Sapz> I think that's the only time I've ever seen a suicide bullet shoot its own suicide bullet

nintendonut888

  • So those that live now, pledge on your fists and souls
  • Leave a sign of your life, no matter how small...
Re: Danmakufu Q&A/Problem Thread II
« Reply #563 on: December 08, 2009, 03:31:33 AM »
Wait, it worked. o_O For some reason.

Unfortunately, now I can't get Concealed the Conclusion to run because of two indecipherable error messages. I think one of them mentioned FLAN. Should I get screenshots of them?
nintendonut888: Hey Baity. I beat the high score for Sanae B hard on the score.dat you sent me. X3
Baity: For a moment, I thought you broke 1.1billion. Upon looking at my score.dat, I can assume that you destroyed the score that is my failed (first!) 1cc attempt on my first day of playing. Congratulations.

[19:42] <Sapz> I think that's the only time I've ever seen a suicide bullet shoot its own suicide bullet

Re: Danmakufu Q&A/Problem Thread II
« Reply #564 on: December 08, 2009, 03:34:33 AM »
please, it would be helpfull

Re: Danmakufu Q&A/Problem Thread II
« Reply #565 on: December 08, 2009, 03:44:22 AM »
Wait, it worked. o_O For some reason.

Unfortunately, now I can't get Concealed the Conclusion to run because of two indecipherable error messages. I think one of them mentioned FLAN. Should I get screenshots of them?
heh

Also CtC is all kinds of messed up so yeah please post them

nintendonut888

  • So those that live now, pledge on your fists and souls
  • Leave a sign of your life, no matter how small...
Re: Danmakufu Q&A/Problem Thread II
« Reply #566 on: December 08, 2009, 03:45:32 AM »




Far as I can see the only difference between them are a 4 digit number on the first line.
nintendonut888: Hey Baity. I beat the high score for Sanae B hard on the score.dat you sent me. X3
Baity: For a moment, I thought you broke 1.1billion. Upon looking at my score.dat, I can assume that you destroyed the score that is my failed (first!) 1cc attempt on my first day of playing. Congratulations.

[19:42] <Sapz> I think that's the only time I've ever seen a suicide bullet shoot its own suicide bullet

Re: Danmakufu Q&A/Problem Thread II
« Reply #567 on: December 08, 2009, 03:51:44 AM »
Does it come up as soon as you run the script?

nintendonut888

  • So those that live now, pledge on your fists and souls
  • Leave a sign of your life, no matter how small...
Re: Danmakufu Q&A/Problem Thread II
« Reply #568 on: December 08, 2009, 03:52:52 AM »
Yep. As soon as I try and select a shot type it brings them up.
nintendonut888: Hey Baity. I beat the high score for Sanae B hard on the score.dat you sent me. X3
Baity: For a moment, I thought you broke 1.1billion. Upon looking at my score.dat, I can assume that you destroyed the score that is my failed (first!) 1cc attempt on my first day of playing. Congratulations.

[19:42] <Sapz> I think that's the only time I've ever seen a suicide bullet shoot its own suicide bullet

Re: Danmakufu Q&A/Problem Thread II
« Reply #569 on: December 08, 2009, 03:55:40 AM »
What might help, move your CtC folder to the desktop, put the th_dnh folder on the desktop, then take a new screenshot of the error, that way this will shorten the folder directory of the error, letting us see which file is corrupted