Author Topic: Danmakufu Q&A Thread 4 - V3 Edition.  (Read 5569 times)

0 Members and 1 Guest are viewing this topic.

Sparen

  • Danmakufu Artist
    • YouTube
    • AFCDTech
  • Gender: Male
Re: Danmakufu Q&A Thread 4 - V3 Edition.
« Reply #30 on: August 26, 2020, 01:55:12 PM »
There are some tasks that I can't understand well, like TStageScene() or RunPauseScene() for example; When are this kind of tasks executed in the package? I recently started to create stage scripts with bosses, so I know that maybe I need more experience but I'm just looking for some advice to start with packages because I'd like to do something bigger. I'll accept anything.

Thanks for the answer

Take a look at the package for how they are defined and used. I don't recommend working with packages until you have a firm understanding of how tasks and scripts work in Danmakufu.

Re: Danmakufu Q&A Thread 4 - V3 Edition.
« Reply #31 on: August 28, 2020, 10:08:10 AM »
I really dont understand how does sprite sheets work. I mean, i have 2 questions

1: Where can i find them?

i tried the "The sprite recourses" web (https://www.spriters-resource.com/pc_computer/touhoufuujinrokumountainoffaith/sheet/51906/) but in the image appears all the bosses, but i only need 1

2: The coordinates

Is there a way to know the sprite's coordinates to dont make it glitch in battle? (Same problem with shot sheets)

thanks
« Last Edit: August 28, 2020, 10:33:33 AM by ThisIsShort »

Sparen

  • Danmakufu Artist
    • YouTube
    • AFCDTech
  • Gender: Male
Re: Danmakufu Q&A Thread 4 - V3 Edition.
« Reply #32 on: August 28, 2020, 01:19:51 PM »
I really dont understand how does sprite sheets work. I mean, i have 2 questions

1: Where can i find them?

i tried the "The sprite recourses" web (https://www.spriters-resource.com/pc_computer/touhoufuujinrokumountainoffaith/sheet/51906/) but in the image appears all the bosses, but i only need 1

2: The coordinates

Is there a way to know the sprite's coordinates to dont make it glitch in battle? (Same problem with shot sheets)

thanks

1. You already have what you need. Any image editor can crop the image down to the boss you want

2. Most image editors will tell you the coordinates of a given pixel. In addition, in a sprite sheet, most sprites are the same size, so knowing the height and width of the area with the boss sprites is usually enough to determine the dimensions of a single sprite (e.g. width/#sprites)

xChumbo

  • Beginner
    • Twitter
  • Gender: Male
Stage enemies
« Reply #33 on: August 31, 2020, 01:34:17 AM »
Hello, I'm having troubles creating stage enemies; the thing is, I can create the stage enemies well, but is there a way to make the boss wait until the other enemies are defeated? I've tried some solutions by myself but still all the enemies appear with the boss and I can't make it work.


Another doubt I got is: In the StageEnemy creation, there's the following line: "SetDamageRateAtFrameEnm(objEnemy, 80, 50, 30);". This is a function/task that I'm not really sure what it does; the enemies still work but It would be nice if you can tell me its purpose.

Here's some code if you want to see:

Stage code: [ Attachment: You are not allowed to view attachments ]
STGEnemy code: [ Attachment: You are not allowed to view attachments ]

Thank you for your attention.


Sparen

  • Danmakufu Artist
    • YouTube
    • AFCDTech
  • Gender: Male
Re: Stage enemies
« Reply #34 on: September 01, 2020, 01:24:24 PM »
Hello, I'm having troubles creating stage enemies; the thing is, I can create the stage enemies well, but is there a way to make the boss wait until the other enemies are defeated? I've tried some solutions by myself but still all the enemies appear with the boss and I can't make it work.

Personally, I use this function from Ultima:

Code: [Select]
/* *************************************************************************
*void WaitForZeroEnemy() -- Waits for there to be no enemies on screen
************************************************************************* */
function WaitForZeroEnemy(){ //ULTIMA
    while(length(GetAllEnemyID()) > 0){yield;}
}

Skelly

  • Da-da-daisaku Ikeda
  • Gender: Male
Extend function using item points
« Reply #35 on: November 06, 2020, 02:11:35 PM »
Hello, I'm not so new to danmakufu but have stopped messing with it for a while and wanted to warm up again.

Recently I've been working on a simple function in PH3. Basically a function that extends the player whenever it gets a certain amount of points(Like PCB). The major problem I'm having is with the GetPoint function. It basically doesn't work, not returning the actual points collected.

I have tried checking if my function was written wrong. But I have noticed it works using GetGraze instead. I have also noticed that whenever I try to print the number of points collected(Using text functions), it basically doesn't update the actual count(Notice I am calling the function every frame). So I really wonder if the GetPoint function actually works on PH3...

Here is the function I am refering to(I have called it on the stage script btw): https://pastebin.com/cUxjiM2x

(Apologies if the post is messy, it's my first time posting here.)
Airmoto should be Touhou canon

Sparen

  • Danmakufu Artist
    • YouTube
    • AFCDTech
  • Gender: Male
Re: Extend function using item points
« Reply #36 on: November 08, 2020, 02:21:30 PM »
Recently I've been working on a simple function in PH3. Basically a function that extends the player whenever it gets a certain amount of points(Like PCB). The major problem I'm having is with the GetPoint function. It basically doesn't work, not returning the actual points collected.

I have tried checking if my function was written wrong. But I have noticed it works using GetGraze instead. I have also noticed that whenever I try to print the number of points collected(Using text functions), it basically doesn't update the actual count(Notice I am calling the function every frame). So I really wonder if the GetPoint function actually works on PH3...

Here is the function I am refering to(I have called it on the stage script btw): https://pastebin.com/cUxjiM2x

Danmakufu doesn't actually automatically add points - you need to do so manually via AddPoint.

Personally, I would have a task running in the system script that's checking a CommonData value in order to handle extends, and I'd use a CommonData value to track your custom points.

Skelly

  • Da-da-daisaku Ikeda
  • Gender: Male
Re: Extend function using item points
« Reply #37 on: November 11, 2020, 08:58:43 PM »
Danmakufu doesn't actually automatically add points - you need to do so manually via AddPoint.

Personally, I would have a task running in the system script that's checking a CommonData value in order to handle extends, and I'd use a CommonData value to track your custom points.

I see, gonna check your common data tutorials, thanks for the help!
Airmoto should be Touhou canon

Re: Danmakufu Q&A Thread 4 - V3 Edition.
« Reply #38 on: December 19, 2020, 05:29:02 PM »
Hi, i need help with some bullets. I want to make a hammer fall when the other one is deleted, however, i tried it and this is how it ended: https://gyazo.com/8fcff2a6ef204c393af1559907373f65

Here is the whole code for if i did something wrong with the speed or delay: https://pastebin.com/EEULKn2r

Thanks for the help