Author Topic: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m [Closed, read last post!]  (Read 184760 times)

Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #750 on: April 15, 2014, 02:44:00 AM »
Hi, I was wondering on the following things:
1. How do you make a boss' name appear on the upper left corner and make it disappear after the boss is defeated?
2. I was planning to use a different font for my game, and I can't find a tool of some sort to make this font to be usable in danmakufu.

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #751 on: April 15, 2014, 05:48:39 AM »
Hi, I was wondering on the following things:
1. How do you make a boss' name appear on the upper left corner and make it disappear after the boss is defeated?
2. I was planning to use a different font for my game, and I can't find a tool of some sort to make this font to be usable in danmakufu.
1 - You can use effect objects and pre-drawn boss names (which ZUN also usually does) to spawn/despawn that.
2 - Font changing requires you to edit the graphical font file. A tool isn't really required except for an image editing tool.  As danmakufu reads the images directly from the dnh\img directory.

You can use http://www.shrinemaiden.org/forum/index.php/topic,4731.0.html to extract the default font first.

Sage Ω (Ultima)

  • CEO at Team Eternal Desire
  • ??? X
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #752 on: April 15, 2014, 12:47:15 PM »
2 - Font changing requires you to edit the graphical font file. A tool isn't really required except for an image editing tool.  As danmakufu reads the images directly from the dnhimg directory.

Correct me if I'm wrong but doesn't the font inside of the img/ folder only include the numbers? I assume he's talking about the font in general which is not saved to a file and he would have to make a hardcoded text script like what Blargel did with his StB thing.

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #753 on: April 15, 2014, 01:36:08 PM »
Not quite, It was both numbers and letters. The font image is no longer displayed in the X-files thread which Drake had posted. Imageshack seems to error.

Also what Blargel did was using effect objects in order to create his own font system. It is basically written from scratch and has nothing to do with the default font in Danmakufu.


Sage Ω (Ultima)

  • CEO at Team Eternal Desire
  • ??? X
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #754 on: April 15, 2014, 02:20:33 PM »
Not quite, It was both numbers and letters. The font image is no longer displayed in the X-files thread which Drake had posted. Imageshack seems to error.

Ah, ok. I never touched the game's font files other than removing the numbers probably overlooked it but that was a long time ago. I've always wondered why the font looked so ugly.

Also what Blargel did was using effect objects in order to create his own font system. It is basically written from scratch and has nothing to do with the default font in Danmakufu.

I know, I'm just saying that would be an alternative to using danmakufu's font functions. However, more work is needed because you have to understand how primitives, vertices, and UVs work since 12m doesn't have a automatic 2D sprite functions like ph3 does.

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #755 on: April 16, 2014, 06:55:37 AM »
Same reason why the bullets looked ugly :) I guess to avoid direct data ripping from original touhou games the author just put in some things as 'place holders'.

Regarding Effect Objects, before ph3 existed we had no choice but to grasp primitive triangle, strip and fan. True that we had to grasp lots of knowledge to get it right. Definitely not newbie friendly though such was life with 0.12m and we had to deal with it :V. Good thing indeed ph3 makes rectangle/square sprites easier to implement.

Chuckolator

  • ex-perfecter, good times
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #756 on: April 17, 2014, 02:42:31 PM »
Alright, now that I'm looking in the right topic and I still haven't solved it, I'll ask again. How do I run this on Windows 8, now that applocale is not a thing? Before, it wouldn't even boot, but then I found this, did it...and it boots to the All/Single/Plural/etc screen, but whenever I select something it crashes. I tried the "program compatibility troubleshooter" or something, but same result. What am I missing?
Aiming to perfect every stage in Touhou. loljk don't care anymore You can find my perfects here or here.
Best perfects so far include UFO 6, MoF 4 and IN 6A.

formerly known as Seiga Kaku

Drake

  • *
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #757 on: April 17, 2014, 11:51:12 PM »
Mostly that's just confusing, since most people report DNH working perfectly fine on Win8.
Anyways, all that option does is choose to do one of the following when there's no #Player header in a script:
- Do nothing (default)
- Insert #Player[FREE] in Single scripts
- Insert #Player[FREE] in Single and Plural scripts

Have you tried using AppLocale, in any case? If it's erroring when trying to install you can run the installer from an admin command prompt by using the advanced context menu (right-click bottom left corner of screen).

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

Chuckolator

  • ex-perfecter, good times
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #758 on: April 18, 2014, 01:13:23 AM »
Ah, did the install via command prompt thing and it worked fine. Never would have figured it out on my own though, so thanks.
Aiming to perfect every stage in Touhou. loljk don't care anymore You can find my perfects here or here.
Best perfects so far include UFO 6, MoF 4 and IN 6A.

formerly known as Seiga Kaku

BobTheTanuki

  • Ph3?
  • What is it?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #759 on: April 21, 2014, 04:10:53 AM »
It's interesting to know what are Objects Effects for?Or it's different from DrawLoop where i can change size,angle,position of the graphic?Are they more flexible or what? :derp:

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #760 on: April 21, 2014, 06:44:24 AM »
It's interesting to know what are Objects Effects for?Or it's different from DrawLoop where i can change size,angle,position of the graphic?Are they more flexible or what? :derp:
Have you tried reading our tutorials?
http://en.touhouwiki.net/wiki/Touhou_Danmakufu:_Nuclear_Cheese%27s_Effect_Object_Tutorial
http://www.shrinemaiden.org/forum/index.php/topic,2852.0.html


Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #762 on: April 21, 2014, 08:23:28 AM »
Effect Objects are Objects which, as the name implies, are used for ~ Effects ~. You create them and they can be controlled as most objects. They are not related to the @DrawLoop as that is only used for drawing bosses and familiars. Although you could draw a boss sprite with the effect object as well (for illusional bosses for example). Effect Objects are created as normal objects except the drawing is done using the Vertex approach (covered in the tutorials). It is also considered an intermediate area and requires knowledge of functions, tasking and objects.

If you're wondering where they are all used in:
- The maple leaves when a boss explodes
- The cut-in images
- Illusions for bosses (not multiboss, but clones)
- Spell circle of bosses
- Other effects on screen
- Etc etc (ry

BobTheTanuki

  • Ph3?
  • What is it?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #763 on: April 21, 2014, 09:08:00 AM »
Effect Objects are Objects which, as the name implies, are used for ~ Effects ~. You create them and they can be controlled as most objects. They are not related to the @DrawLoop as that is only used for drawing bosses and familiars. Although you could draw a boss sprite with the effect object as well (for illusional bosses for example). Effect Objects are created as normal objects except the drawing is done using the Vertex approach (covered in the tutorials). It is also considered an intermediate area and requires knowledge of functions, tasking and objects.

If you're wondering where they are all used in:
- The maple leaves when a boss explodes
- The cut-in images
- Illusions for bosses (not multiboss, but clones)
- Spell circle of bosses
- Other effects on screen
- Etc etc (ry

Oh..i think i understood..Thank you Helepolis!

BobTheTanuki

  • Ph3?
  • What is it?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #764 on: April 25, 2014, 12:42:31 PM »
Hi again!How can i connect stages together?How to use SetCommonData?I know that there were explanations for this things..but i can't figure it out! :ohdear:

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #765 on: April 25, 2014, 03:01:25 PM »
There is no such thing as connecting stages together like you would do for spell cards to make a plural. If you want multiple stages, you need to write 1 big stage file and swap the textures, enemies, etc. around when you advance in the stage. For bosses you can call the plural files within the stage file (as you probably already did).

BobTheTanuki

  • Ph3?
  • What is it?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #766 on: April 25, 2014, 03:31:03 PM »
There is no such thing as connecting stages together like you would do for spell cards to make a plural. If you want multiple stages, you need to write 1 big stage file and swap the textures, enemies, etc. around when you advance in the stage. For bosses you can call the plural files within the stage file (as you probably already did).
Is this hard?To write this big stage file?Is this hard to swap textures?Sorry bout that,i'm just stupid  :V

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #767 on: April 25, 2014, 03:35:51 PM »
Define 'hard'. It is a matter of knowledge, let us ask the question different, have you made any stages yet?

BobTheTanuki

  • Ph3?
  • What is it?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #768 on: April 25, 2014, 03:40:27 PM »
Define 'hard'. It is a matter of knowledge, let us ask the question different, have you made any stages yet?

Yup!I have made some  :derp: it isn't so hard

Helepolis

  • Charisma!
  • *
  • O-ojousama!?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #769 on: April 25, 2014, 04:13:00 PM »
Ok, so in order to combine those stages, you need to figure out a way to change the background of your stage. For example a very simple and dirty method:
Code: [Select]
let stageLook = 1;

@BackGround{
if(stageLook == 1) {
// drawing code for stage 1
}
if(stageLook == 2) {
// drawing code for stage 2
}
}
And somewhere in your stage file, after "finishing the boss" you put stageLook to 2 and the game will start drawing your 2nd stage. This method is just an example.

Sparen

  • Danmakufu Artist
  • Git ready, git set, PUUSH!
    • AFCDTech
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #770 on: April 25, 2014, 07:29:38 PM »
Ok, so in order to combine those stages, you need to figure out a way to change the background of your stage. For example a very simple and dirty method:
Code: [Select]
let stageLook = 1;

@BackGround{
if(stageLook == 1) {
// drawing code for stage 1
}
if(stageLook == 2) {
// drawing code for stage 2
}
}
And somewhere in your stage file, after "finishing the boss" you put stageLook to 2 and the game will start drawing your 2nd stage. This method is just an example.

Note that if your background code gets excessively messy, you might want to #include a file containing tasks for the background code and call the tasks inside the if blocks. It will make your code 100% more readable, and if you have a different stage file for different difficulties (don't do this please or your game will be super complicated like PDD), it will greatly simplify the work you need to do.

Chuckolator

  • ex-perfecter, good times
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #771 on: April 30, 2014, 04:45:20 AM »
[00:27:43] <chuckolator> holy crap
[00:27:49] <chuckolator> I don't know what is up with PT
[00:27:53] <chuckolator> it is very strange
[00:27:59] <chuckolator> so I start a regular run
[00:28:07] <chuckolator> after stage 1 I pause and do other things for a minute (sidenote: other things on the computer, not afk)
[00:28:16] <chuckolator> I come back and it's back to the danmakufu title screen
[00:28:20] <chuckolator> wtf, that's annoying, whatever
[00:28:27] <chuckolator> I start again and it's at 150fps! (sidenote: a bit later I notice it's actually 166.67fps)

Has anyone had this happen before, or know why it does? If it's relevant, I usually boot PT by hitting "all" and finding it there, but when I came back to it on the danmakufu menu it was on "directory". I've had it accept my inputs despite it not being the focus before, could I have been fumbling around without knowing it and did something that would cause this? I have no idea, and you probably don't either, but I'm really curious so I thought I'd ask anyway.
Aiming to perfect every stage in Touhou. loljk don't care anymore You can find my perfects here or here.
Best perfects so far include UFO 6, MoF 4 and IN 6A.

formerly known as Seiga Kaku

K+ ~ Bake-Danuki

Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #772 on: May 08, 2014, 10:19:48 PM »
Why hello again~

I was wondering if in a Single continuous script, if there's a way to clear the spell background once its been raised.  Like:

task TaskTask{
//nonspell things
LoadGraphic(graphic);
CutIn(things,cutin,0,0,0,0);
SetScore(1);
//spell things
//Remove the Spell BG for another nonspell
//nonspell 2
}

@Background{//things}

I tried deleting the graphic with DeleteGraphic(); and it just went to black, is there a way to fix this?  Also this is a single script called as a Boss on a stage for the BG purposes.
Thanks!

PhantomSong

  • The Ghost Living through Everyday Life.
  • Eh, it doesn't matter.
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #773 on: May 08, 2014, 10:59:15 PM »

I tried deleting the graphic with DeleteGraphic(); and it just went to black, is there a way to fix this?  Also this is a single script called as a Boss on a stage for the BG purposes.
Thanks!
This is only possible if you make your own spell system which can be a pain in the rear-end.

Drake

  • *
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #774 on: May 08, 2014, 11:00:21 PM »
@BackGround{
  if(spell){
    //render spell bg
  }else{
    //render nonspell bg
  }
}

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

K+ ~ Bake-Danuki

Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #775 on: May 09, 2014, 12:57:07 AM »
<code>
Oh... I can use CommonData with this!  Thanks~

EDIT:
http://prntscr.com/3hid5e
I managed to get this error when I run it... I know my CommonData is set up right (or at least I hope), can anyone translate it?
« Last Edit: May 09, 2014, 01:24:38 AM by K+ »

Sparen

  • Danmakufu Artist
  • Git ready, git set, PUUSH!
    • AFCDTech
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #776 on: May 09, 2014, 02:20:13 AM »
Oh... I can use CommonData with this!  Thanks~

EDIT:
http://prntscr.com/3hid5e
I managed to get this error when I run it... I know my CommonData is set up right (or at least I hope), can anyone translate it?

https://sites.google.com/site/sparensdanmakufututorials/dnh-0-12m-tutorials-part-3/014-intro-to-danmakufu-part-4#TOC-ERR-B08:-

[Ignore that sly comment; it happens to everyone sometime or other]

BobTheTanuki

  • Ph3?
  • What is it?
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #777 on: May 09, 2014, 05:34:53 AM »
Hi again!It's interesting to know how to use SetCommonData CORRECTLY i just can't figure it out  :V can you help me with this?

Drake

  • *
Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #778 on: May 09, 2014, 06:28:43 AM »
K+: I'm just wondering why you need to do it this way. Putting multiple patterns in a Single script? Like, why? Normally you'd have the stage background running in the Stage script, call the Plural script, and for the noncard Single scripts you just don't call SetScore(), while you do call SetScore() in the card Single scripts .
« Last Edit: May 09, 2014, 06:31:33 AM by Drake »

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

K+ ~ Bake-Danuki

Re: ※ Q&A/Problem Thread 7 ※ for Danmakufu version 0.12m
« Reply #779 on: May 10, 2014, 03:39:19 AM »
K+: I'm just wondering why you need to do it this way. Putting multiple patterns in a Single script? Like, why? Normally you'd have the stage background running in the Stage script, call the Plural script, and for the noncard Single scripts you just don't call SetScore(), while you do call SetScore() in the card Single scripts .

It's a little special script as a surprise to show one of my teachers what I can do in this engine, even in a single script.  Its basically a task with tons of subs to make the patterns loop once (or more) and go to another pattern without having a lot of nonspells.  I got this working btw and i like it :D
(I actually may release this script soon, just want to get a bit of feedback from a few people and then tweak it.  Then you'd see what I mean.)
« Last Edit: May 10, 2014, 03:41:36 AM by K+ »