Blockland Forums > Suggestions & Requests

taking event requests

Pages: << < (13/15) > >>

QuadStorm:


--- Code: ---Type: Output
Name: Holebot>setRandomItem
Description:
Gives the bot a random item.
--- End code ---


SWAT One:


--- Quote from: Kinlord999 on October 30, 2013, 03:07:19 PM ---I have a request for a pack:

Type: Output
Target Type: Self/Named Brick
Name: itemSupply
Description: A plane/helicopter (either is fine) flies overhead and drops a supply crate onto the target.
A parachute is attached to the crate, making it slowly float down. When a player clicks on the crate,
 a specified number of a certain item/items is spawned. You can put different items in a single crate.
Example: OnActivate > Self > itemSupply > (Item1) [Item1 amount] (Item 2) [Item2 amount] (Item 3) [Item 3 amount]
 
Type: Output
Target Type: Self/Named Brick
Name: vehicleSupply
Description: Same as itemSupply, except only one specific vehicle is dropped, in a large crate.

--- End quote ---
This already exists somewhere.  It may be binned, but there's no harm in searching.

MARBLE MAN:


--- Quote from: QuadStorm on October 30, 2013, 05:51:58 PM ---
--- End quote ---

registerOutputEvent(Bot,"SetRandomWeapon");
function AIPlayer::setRandomWeapon(%this)
{
   for(%i = 0; %i < DataBlockGroup.getCount(); %i++)
   {
      %obj = DataBlockGroup.getObject(%i);
      if(%obj.getClassName() $= "ItemData" && %obj.uiName !$= "")
         %item[%itemCount++] = %obj;
   }
   %randomitem = getRandom(0,%itemCount);
   %this.setWeapon(%item[%randomitem]);
}


Note to all:
I'll package all of these events and post them in one giant topic

Night Fox:


--- Quote from: MARBLE MAN on October 30, 2013, 05:41:08 PM ---I will not make an event that loops for every player continuously...

--- End quote ---
well I'm not saying you should or anything. I think it's ridiculous to want that when you could so easily do it already

Racerboy:


--- Quote from: Racerboy on October 30, 2013, 02:52:02 PM ---I still need an event for detecting an item coming into contact with a brick, or entering a zone, either one would work. It's for the hockey mod, and since the puck is an item, nothing can detect its presence.

Workarounds for this are also acceptable, like giving the puck its own value or whatever and having it detect the value being passed through somehow, I don't know how this stuff works.

--- End quote ---


Pages: << < (13/15) > >>

Go to full version