Jump to content

Photo

[Solved] Sword beams only with low health?


  • Please log in to reply
16 replies to this topic

#1 bloqm

bloqm

    Newbie

  • Members

Posted 18 February 2020 - 06:28 PM

Hello!

 

I'm trying to come up with a way to make the Wooden Sword fire beams only with LOW health. Ideally, beams will be fired when and only when hearing the "low hp alarm". Other swords should work as usual.

 

I've tried setting the beam requirements to 999 hearts (so the beam won't fire normally) in combination with the Peril Ring (so it fires with low health), but that simply disables beams completely.

Is there another way to achieve this? I don't mind scripting but I'm new to the engine so I'd need a pointer.

 

Tangent: I enabled the Peril Ring at Init Data but it won't show up in the inventory. This is perfect for me, but I'm wondering if perhaps I'm missing something with the setup...

 

Thanks!

 

EDIT-

In sword item, Beam Hearts has to be percentual. This solves the problem:


Change the `Beam Hearts` from `20` to `200`, and check the flag `B.H. is Percent`. That'll work.

Thank you venrob!


Edited by bloqm, 19 February 2020 - 08:22 PM.


#2 Mani Kanina

Mani Kanina

    Rabbits!

  • Members

Posted 18 February 2020 - 07:02 PM

Are you sure you used a new save file after changing the init data? You might not have the peril ring, you could double check using cheat lv3 to see if you have it in your inventory. Been a while since I messed with the peril ring, but IIRC it should still function even if the sword beam don't normally fire.



#3 bloqm

bloqm

    Newbie

  • Members

Posted 18 February 2020 - 08:08 PM

Thank you, with a new save the ring shows up in the inventory. However, the beam still won't fire.

After messing around, I noticed that the peril-rings-class has a hint in the editor that says that the ring divides the damage received when below a health threshold. I haven't found any mention of this ring in the wiki, so I'm actually not sure what is it's actual behaviour.

Any ideas?



#4 Emily

Emily

    Scripter / Dev

  • ZC Developers

Posted 18 February 2020 - 09:00 PM

Thank you, with a new save the ring shows up in the inventory. However, the beam still won't fire.

After messing around, I noticed that the peril-rings-class has a hint in the editor that says that the ring divides the damage received when below a health threshold. I haven't found any mention of this ring in the wiki, so I'm actually not sure what is it's actual behaviour.

Any ideas?

That would be a ring that makes it so you take less damage when your HP is low.

The wiki is HORRENDOUSLY outdated.


  • bloqm likes this

#5 Jamian

Jamian

    ZC enthusiast

  • Members

Posted 19 February 2020 - 03:37 AM

Yes, your problem is that the Peril Ring is not the item you want. You actually want the Peril Beam Scroll.

 

And if you don't want such passive items to show up in your subscreen, just delete them from the subscreen (this doesn't prevent Link from having the item).


  • Mani Kanina and Bagu like this

#6 bloqm

bloqm

    Newbie

  • Members

Posted 19 February 2020 - 09:03 AM

You actually want the Peril Beam Scroll.

Ahh thanks, this is it. Found it at last!

However I'm still having trouble making it fire beams. The scroll won't activate no matter how low my health is. I've tried playing with the scroll settings, deleting save data, etc. but nothing worked.

Am I missing something? Sorry if this is super noob stuff.

 

Also, is there a way to edit/code your own items? (That don't requires recompiling the whole program)



#7 Emily

Emily

    Scripter / Dev

  • ZC Developers

Posted 19 February 2020 - 11:12 AM

Also, is there a way to edit/code your own items? (That don't requires recompiling the whole program)

Scripts.

Am I missing something? Sorry if this is super noob stuff.

Probably? Should work.

#8 Jamian

Jamian

    ZC enthusiast

  • Members

Posted 19 February 2020 - 11:44 AM

It should work. Try resetting the scroll's settings to the default ones, and make sure you actually do have the scroll in-game (you can check via the cheat menu).



#9 bloqm

bloqm

    Newbie

  • Members

Posted 19 February 2020 - 12:05 PM

It should work. Try resetting the scroll's settings to the default ones, and make sure you actually do have the scroll in-game (you can check via the cheat menu).

No luck so far. I actually made Link pickup the scroll just to make sure, and the scroll appears both in cheats and inventory, but still does nothing.

I must be missing something veeery obvious because I'm trying this in a almost-empty quest. Perhaps this is caused by some obscure quest rule?

Just in case, I tried toggling the "1/4 health bar" rule (the only one related to hp and beams, apparently) but that doesn't seem to be the problem.

 

EDIT: I actually went and tested this in a brand new quest, using the "authentic NES" preset -- and it works perfectly there. Once I disable the beams from the wooden sword, the Peril beam scroll stops working.


Edited by bloqm, 19 February 2020 - 12:16 PM.


#10 Jamian

Jamian

    ZC enthusiast

  • Members

Posted 19 February 2020 - 01:32 PM

Could you perhaps upload a file and post a link, because it should work even if the regular beam is disabled.



#11 Mani Kanina

Mani Kanina

    Rabbits!

  • Members

Posted 19 February 2020 - 01:44 PM

Or post a screenshot of your sword configurations.



#12 Emily

Emily

    Scripter / Dev

  • ZC Developers

Posted 19 February 2020 - 02:25 PM

Screenshots of the item editor for both the sword and the peril scroll would be helpful, aye



#13 bloqm

bloqm

    Newbie

  • Members

Posted 19 February 2020 - 06:20 PM

Here you go: https://drive.google...iew?usp=sharing

This is a empty quest, with only the initial screen and the wooden sword modified as such:

b7ylj3I.png

 

Thank you for your time!

 

btw, is there a way to attach files to replies in this forum?


Edited by bloqm, 19 February 2020 - 06:22 PM.


#14 Emily

Emily

    Scripter / Dev

  • ZC Developers

Posted 19 February 2020 - 07:15 PM

No way to attach files.

 

So, I found a fun JANK BULLSHIT in ZC today!

Peril beam will not work unless one of two things is true:

1. The normal sword beam hearts is <= your max hearts (i.e. normal sword beam is enabled)

2. The `B.H. is Percent` (Beam Hearts is Percent) flag is checked.

Therefore, saying "Sword beam requires 20 hearts" means that peril beam will never fire unless your max HP is 20 hearts or higher.

Saying "Sword Beam requires 200% hearts" will allow the peril beam to work fine, while still disabling normal beam.

Why is this the case? FUCK IF I KNOW. Probably something left-over for old quests from before the item editor, I'd have to guess?

 

So, change the `Beam Hearts` from `20` to `200`, and check the flag `B.H. is Percent`. That'll work.



#15 bloqm

bloqm

    Newbie

  • Members

Posted 19 February 2020 - 08:26 PM

So, change the `Beam Hearts` from `20` to `200`, and check the flag `B.H. is Percent`. That'll work.

 

Wow, thank you very much! I could have never found the solution by myself.

I've updated the OP just in case someone comes across this corner case behaviour.

 

Out of curiosity, how did you find out?




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users