Jump to content

Photo

small treasure chest that continue to give small items like ammo


  • Please log in to reply
7 replies to this topic

#1 Soarin

Soarin

    Chosen One

  • Members

Posted 19 March 2018 - 05:58 PM

So last night i had this idea The idea is that a player would find a small treasure chest open to get ammo like arrows , money , bombs etc Can this be done with scripting in ZQ?



#2 Avaro

Avaro

    o_o

  • Members
  • Real Name:Robin
  • Location:Germany

Posted 19 March 2018 - 06:30 PM

I don't quite understand. There is the treasure chest combo type.



#3 Soarin

Soarin

    Chosen One

  • Members

Posted 19 March 2018 - 06:39 PM

There is not so scripting can't do this?



#4 Architect Abdiel

Architect Abdiel

    Kingdom Builder

  • Members
  • Real Name:Michael
  • Location:Florida

Posted 19 March 2018 - 08:46 PM

I think he's say he wants the chest to give something like arrows, but then be able to give more arrows if you come back to it later.

#5 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 19 March 2018 - 09:08 PM

I had this script made for a boss that could only be hurt by bombs. It's a chest I put in the boss room that refilled itself with bombs over time.

 

It plays a message when you open the chest. String Controls Codes give you the item(s) you want. Then I set the open chest combo to cycle back into an unopened chest.

// This will check for the specified combo.
// If found, it will play a message.
// If the combo disappears, the check for the combo will reset.
// d0 = String
// d1 = Number of the combo to check for
ffc script comboString
{
    void run(int string, int combo)
    {
        bool hasAppeared = false;
        // Enter the main loop
        while(true)
        {
            // If the combo has not appeared, loop through this while loop...
            while(!hasAppeared)
            {
                // Check if there is an instance of the combo on the screen...
                if(FirstComboOf(combo, 0) != -1)
                {
                    hasAppeared = true;
                    Screen->Message(string); // Play the message.
                }
                Waitframe();
            }
            // If the combo has appeared, loop through this while loop...
            while(hasAppeared)
            {
                // Check if the combo is not still on the screen...
                if(FirstComboOf(combo, 0) == -1)
                {
                    hasAppeared = false;
                }
                Waitframe();
            }
            Waitframe();
        }//!End while(true)
    }//!End void run()
}//!End ffc script comboString

Edited by Cukeman, 19 March 2018 - 09:25 PM.


#6 Cukeman

Cukeman

    "Tra la la, look for Sahasrahla. ... ... ..."

  • Banned
  • Location:Hyrule/USA

Posted 19 March 2018 - 10:27 PM

Actually all you need is a reset room combo to refill a chest...



#7 Alucard648

Alucard648

    Wizard

  • Members
  • Location:castle Dracula

Posted 20 March 2018 - 03:01 AM

Actually all you need is a reset room combo to refill a chest...

Step on this combo after defeating the boss and it will respawn.



#8 Avaro

Avaro

    o_o

  • Members
  • Real Name:Robin
  • Location:Germany

Posted 20 March 2018 - 11:10 AM

Step on this combo after defeating the boss and it will respawn.

Well you can set exceptions in screen data so that the boss would not reset.

 

Either way, not sure if this is even what soarin wanted, but i dont know xD




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users