Jump to content

Photo

Sword flashes when charged!


  • Please log in to reply
3 replies to this topic

#1 Shane

Shane

    🩶

  • Moderators
  • Location:South Australia

Posted 10 July 2021 - 02:06 PM

This is more a quality of life thing for more accessibility to potential deaf players or even just people who mute ZC which is pretty common. I think relying simply on sound design to alert the player when the sword is charged up, especially when you have items and an editor that can alter timing, might be a bit of bad design on the engine's end. I think it'd be ideal to have an option to make the sword flash when it is charged. As for the Hurricane Spin charge, that's where I'm at a loss. But perhaps we can spitball some ideas if this is considered?

 

(I guess this goes without saying, but the same thing would work for the hammer. I don't think there's anything else that charges up, right?

Edit: Oh! Sword tapping to find a bombable spot. Maybe if we're going far into the request, there can be a spark graphic as visual aid?)


  • Anthus, Jared and P-Tux7 like this

#2 Mitchfork

Mitchfork

    no fun. not ever.

  • Members
  • Real Name:Mitch
  • Location:Alabama

Posted 10 July 2021 - 02:53 PM

Sword tapping for bomb secrets is in-engine in 2.55 at least.
  • Shane likes this

#3 Alucard648

Alucard648

    Wizard

  • Members
  • Location:castle Dracula

Posted 10 July 2021 - 04:49 PM

. As for the Hurricane Spin charge, that's where I'm at a loss. But perhaps we can spitball some ideas if this is considered?

As for different Hurricane Spin, you could alter flash Cset and Aspeed when Hurricane Spin is ready.

 

Here is another similar request. Flashing hammer when charged Quake Hammer and different flash Cset and Aspeed, when Super Quake is ready.


Edited by Alucard648, 10 July 2021 - 04:49 PM.

  • Shane likes this

#4 Mitchfork

Mitchfork

    no fun. not ever.

  • Members
  • Real Name:Mitch
  • Location:Alabama

Posted 10 July 2021 - 05:55 PM

I do think this should be added to the engine, but this is my scripted work-around for Crucible Crest and PoRC:
 

int SWORDLFLASHCOUNT = 0;
bool SWORDFLASHFOUND = false;
lweapon SWORDFLASHTARGET;

const int SWORDFLASHFRAMES = 40;

void swordFlash() {
	if (Hero->Action == LA_CHARGING) {
		SWORDLFLASHCOUNT++;
		if (SWORDLFLASHCOUNT >= SWORDFLASHFRAMES) {
			if (!SWORDFLASHFOUND) {
				for(int i=Screen->NumLWeapons();i==1;i--){
					SWORDFLASHTARGET = Screen->LoadLWeapon(i);
					if(SWORDFLASHTARGET->ID == LW_SWORD) {
						SWORDFLASHFOUND = true;
					}
				}
			}
			if (SWORDFLASHFOUND) {
				if (SWORDLFLASHCOUNT%4 == 0) {
					SWORDFLASHTARGET->CSet = SWORDFLASHTARGET->OriginalCSet;
				}
				else if (SWORDLFLASHCOUNT%2 == 0) {
					SWORDFLASHTARGET->CSet = SWORDFLASHTARGET->OriginalCSet + 1;
				}
			}
		}
	}
	else {
		SWORDLFLASHCOUNT = 0;
		SWORDFLASHFOUND = false;
		if (SWORDFLASHTARGET->isValid()) {
			SWORDFLASHTARGET->CSet = SWORDFLASHTARGET->OriginalCSet;
		}
	}
}

Put swordFlash() into your global or hero active loops. This may be 2.55 only, no clue.  You also need to manually set SWORDFLASHFRAMES to the charging duration.  This can be modified by Charge Rings, which this script doesn't take into account (but it could be added without too much hassle by changing it into a non-constant variable and adding some logic to check for the current Charge Ring's variables).  I honestly can't remember the default value, I think it's something like 70 frames?  


  • Shane likes this


1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users