Jump to content

Photo

Simple Candle Script


  • Please log in to reply
28 replies to this topic

#16 Jared

Jared

    Bring back what once was mine, what once was mine.

  • Members
  • Real Name:Jared
  • Gender:Male
  • Location:Massachusetts

Posted 18 February 2021 - 04:50 PM

Can't you make a "Wand" that looks like a bow, make it sound like one, disable the harmfulness of the rod, and its combo/enemy defenses are set to arrows/silver arrows? King Aquamentus was able to make a Bait item that triggers Stomp Boots combos and enemy defenses, for instance (the pickup item looking like a bag, and the laid-down bait looking like magic powder).

That sounds awfully convoluted lol. Plus I'm using the wand in my quest.



#17 Venrob

Venrob

    Scripter / Dev

  • ZC Developers
  • Real Name:Rob
  • Gender:Male

Posted 18 February 2021 - 06:48 PM

Oh, it's not that convoluted. You just pick "Arrow" in a dropdown in the item editor and it's done. You could use a second wand for this.


  • Jared likes this

#18 Jared

Jared

    Bring back what once was mine, what once was mine.

  • Members
  • Real Name:Jared
  • Gender:Male
  • Location:Massachusetts

Posted 19 February 2021 - 05:16 PM

Thanks guys!

 

I tried it, and I got the bow sprite to show up, but I can't get it to shoot arrows, or deplete the arrow counter.

 

Edit- it doesn't seem to be playing the arrow shooting sfx, even though I set that as well.


Edited by Jared, 19 February 2021 - 05:28 PM.


#19 P-Tux7

P-Tux7

    Illustrious

  • Members

Posted 19 February 2021 - 10:47 PM

Thanks guys!

 

I tried it, and I got the bow sprite to show up, but I can't get it to shoot arrows, or deplete the arrow counter.

 

Edit- it doesn't seem to be playing the arrow shooting sfx, even though I set that as well.

Oh yeah, one thing I forgot, you have to set there to be item override in the wand and "bow" subscreen elements, otherwise the two Wand class items will show the lowest (if levels are tied) or highest-leveled one in the list in both slots on the active subscreen. Maybe try giving them different levels in addition to the item override in the elements if that doesn't work.

 

Make sure:

 

Data

Class: Wands

 

Action

Cost: 1

Arrows

Do NOT check Only Validate Cost (this new feature means that you will need to have the counter you set be at or over the cost you set, but the using of the weapon does not subtract the cost from the counter)

 

Weapon

Weapon Type: Arrow

Default Defense (Resolution) - whatever you want

Also make sure to set Weapon Range and Weapon Duration to above 0 if this still doesn't work. I suspect "0" functions as infinite/until edge of screen is hit, but just in case that doesn't work.

 

Also, to make the Silver Arrows from LTTP, copy-paste your Wand-Bow item onto a blank item, and make it a highest-leveled item in the Wands class, with the damage and default defense resolution that you want. Make sure to Item Override your Wand's subscreen element so that the "Bow" gets replaced, but the Wand doesn't. Unfortunately, Wands don't have Sparkle sprites for their projectiles so you will have to request or script that.


Edited by P-Tux7, 19 February 2021 - 11:01 PM.

  • Jared likes this

#20 Jared

Jared

    Bring back what once was mine, what once was mine.

  • Members
  • Real Name:Jared
  • Gender:Male
  • Location:Massachusetts

Posted 21 February 2021 - 07:00 PM

Oh yeah, one thing I forgot, you have to set there to be item override in the wand and "bow" subscreen elements, otherwise the two Wand class items will show the lowest (if levels are tied) or highest-leveled one in the list in both slots on the active subscreen. Maybe try giving them different levels in addition to the item override in the elements if that doesn't work.

 

Make sure:

 

Data

Class: Wands

 

Action

Cost: 1

Arrows

Do NOT check Only Validate Cost (this new feature means that you will need to have the counter you set be at or over the cost you set, but the using of the weapon does not subtract the cost from the counter)

 

Weapon

Weapon Type: Arrow

Default Defense (Resolution) - whatever you want

Also make sure to set Weapon Range and Weapon Duration to above 0 if this still doesn't work. I suspect "0" functions as infinite/until edge of screen is hit, but just in case that doesn't work.

 

Also, to make the Silver Arrows from LTTP, copy-paste your Wand-Bow item onto a blank item, and make it a highest-leveled item in the Wands class, with the damage and default defense resolution that you want. Make sure to Item Override your Wand's subscreen element so that the "Bow" gets replaced, but the Wand doesn't. Unfortunately, Wands don't have Sparkle sprites for their projectiles so you will have to request or script that.

Thank you, I got it to work! However, for some reason my other wand is now showing up on the subscreen even though he doesn't actually have the item itself.

 

(And I can't select it unless I put in the cheats that it's available)

 

They're both using item override of their specific items, which is why I'm confused.

 

Also, is there a way to make it so it doesn't pierce enemies?


Edited by Jared, 21 February 2021 - 07:03 PM.


#21 P-Tux7

P-Tux7

    Illustrious

  • Members

Posted 21 February 2021 - 11:11 PM

Thank you, I got it to work! However, for some reason my other wand is now showing up on the subscreen even though he doesn't actually have the item itself.

 

(And I can't select it unless I put in the cheats that it's available)

 

They're both using item override of their specific items, which is why I'm confused.

 

Also, is there a way to make it so it doesn't pierce enemies?

Piercing enemies should be a setting in their defenses. If your enemies aren't set up to do that, please file a bug report.

 

Perhaps try setting only ONE of them to use item override - the one on top of the Wands class list should be it, since ZC considers it lowest-priority in its class.


Edited by P-Tux7, 21 February 2021 - 11:11 PM.

  • Jared likes this

#22 Jared

Jared

    Bring back what once was mine, what once was mine.

  • Members
  • Real Name:Jared
  • Gender:Male
  • Location:Massachusetts

Posted 22 February 2021 - 07:23 PM

Piercing enemies should be a setting in their defenses. If your enemies aren't set up to do that, please file a bug report.

 

Perhaps try setting only ONE of them to use item override - the one on top of the Wands class list should be it, since ZC considers it lowest-priority in its class.

 

Yeah, they're not set up to pierce. I assume it has to do with it being a "wand". I'll file a bug report.



#23 ZoriaRPG

ZoriaRPG

    The Timelord

  • ZC Developers
  • Gender:Unspecified
  • Location:Prydon Academy

Posted 23 February 2021 - 07:19 AM

Why would you need that with my script? That uses the engine to create the flame. So, if the candle can normally only be used once per screen, that would still apply. The script does not create any weapons, only modifying the one created by the engine.

 

I simply emulated how the engine works. 


Piercing enemies should be a setting in their defenses. If your enemies aren't set up to do that, please file a bug report.

 

Perhaps try setting only ONE of them to use item override - the one on top of the Wands class list should be it, since ZC considers it lowest-priority in its class.

 

Piercing is a weapon flag on arrows for the bow item. Wands lack this at present so it would be a feature request


  • Jared likes this

#24 Jared

Jared

    Bring back what once was mine, what once was mine.

  • Members
  • Real Name:Jared
  • Gender:Male
  • Location:Massachusetts

Posted 23 February 2021 - 08:43 AM

Still think it'd be easier for someone to script the little bow sprite in front of the Link sprite :P



#25 Venrob

Venrob

    Scripter / Dev

  • ZC Developers
  • Real Name:Rob
  • Gender:Male

Posted 24 February 2021 - 04:42 AM

I simply emulated how the engine works. 

....why do you need to emulate how the engine works, when the engine is still doing the work? You don't need to emulate using it only once per screen, because the engine is still handling that, even for the script!



#26 P-Tux7

P-Tux7

    Illustrious

  • Members

Posted 24 February 2021 - 07:47 PM

I simply emulated how the engine works. 


 

Piercing is a weapon flag on arrows for the bow item. Wands lack this at present so it would be a feature request

It's not that he wants them to pierce enemies, but that they are doing so despite by all logic they should not, since neither his wands, arrows, or the defenses are set up for piercing.



#27 Mitchfork

Mitchfork

    no fun. not ever.

  • Members
  • Real Name:Mitch
  • Gender:Male
  • Location:Alabama

Posted 24 February 2021 - 09:20 PM

I realize there's like a billion conversations going on in this thread but I'll answer the piercing one...
 
For whatever reason arrows pierce by default - for example, if you create an arrow via script, it will always pierce.  The way that you get around this (in 2.55 only) is by assigning the weapon parent to an arrow item set up in the normal item editor.  This will cause the arrow to inherit the flags of that item... including the (unchecked) pierce flag.
 
I haven't tested this out but you can try the following lweapon script:
lweapon script wandArrowPierceFix {
	void run() {
		this->Parent = 13;	//change this to the item ID of a normal arrow without the piercing flag checked
	}
}
Assign this to a slot and then select it on the W. Script tab of the wand.... let me know if that works for you.

Edited by Mitchfork, 24 February 2021 - 09:20 PM.

  • Jared likes this

#28 Jared

Jared

    Bring back what once was mine, what once was mine.

  • Members
  • Real Name:Jared
  • Gender:Male
  • Location:Massachusetts

Posted 25 February 2021 - 12:08 PM

I realize there's like a billion conversations going on in this thread but I'll answer the piercing one...
 
For whatever reason arrows pierce by default - for example, if you create an arrow via script, it will always pierce.  The way that you get around this (in 2.55 only) is by assigning the weapon parent to an arrow item set up in the normal item editor.  This will cause the arrow to inherit the flags of that item... including the (unchecked) pierce flag.
 
I haven't tested this out but you can try the following lweapon script:

lweapon script wandArrowPierceFix {
	void run() {
		this->Parent = 13;	//change this to the item ID of a normal arrow without the piercing flag checked
	}
}
Assign this to a slot and then select it on the W. Script tab of the wand.... let me know if that works for you.

 

Amidst all this madness, it worked :P Thanks so much Mitch. :)



#29 ZoriaRPG

ZoriaRPG

    The Timelord

  • ZC Developers
  • Gender:Unspecified
  • Location:Prydon Academy

Posted 25 February 2021 - 01:23 PM

I realize there's like a billion conversations going on in this thread but I'll answer the piercing one...
 
For whatever reason arrows pierce by default - for example, if you create an arrow via script, it will always pierce.  The way that you get around this (in 2.55 only) is by assigning the weapon parent to an arrow item set up in the normal item editor.  This will cause the arrow to inherit the flags of that item... including the (unchecked) pierce flag.
 
I haven't tested this out but you can try the following lweapon script:

lweapon script wandArrowPierceFix {
	void run() {
		this->Parent = 13;	//change this to the item ID of a normal arrow without the piercing flag checked
	}
}
Assign this to a slot and then select it on the W. Script tab of the wand.... let me know if that works for you.

 

 

 

Ooooh. I think this is a bug. 




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users