Author Topic: Falling Tiles  (Read 4022 times)

Uploaded this to RTB yesterday, figured I'd get some last minute comments here before it's hopefully approved.

This is an add-on meant to provide many of the peices required to make a decent, script based, falling platforms server. It is best used with Slayer or some other type of default minigame. Hosts can also add their own events to give the winner the option of say, making all the middle tiles fall, by naming the middle bricks diferently and manually eventing a button to make platforms with that name dissapear.

Bricks --- Admin only
  • Big Tile --- 16x16 plate
  • Normal Tile --- 8x8 plate
  • Small Tile --- 4x4 plate
  • Tiny Tile --- 2x2 plate
  • Grill Tile --- Grill plate
  • Winner spawn --- where the winner spawns.

Events
  • onFall --- Called when a brick dissapears as it falls.
  • onNewWinner --- Called when a new winner is picked (e.g. every round)
  • brick->randomizeTileColors --- will make each tile a random color
  • brick->setPrintWinnerName --- will make it and print bricks to the right of it display the last winner's name
  • client->fallBig --- Makes all tiles but big tiles dissapear.
  • client->fallNormal --- Makes all tiles but normal tiles dissapear.
  • client->fallSmall --- Makes all tiles but small tiles dissapear.
  • client->fallTiny --- Makes all tiles but tiny tiles dissapear.
  • client->fallGrill --- Makes all tiles but grill tiles dissapear.
  • client->fallColor --- First arg is the actual color, second argument is where you can put the name of that color
  • client->randomItems --- Argument is the item. Gives each tile a random chance of becoming a spawn for the set item.
  • client->clearGameItems --- Clears inventories of every player and removes all tile item spawns.
  • player->isInArena --- Sets that the player is in arena. Should be used with a onPlayerTouch on a bridge into the arena, or an onTeledoorExit with a teledoor into the arena.

RTB Prefs
  • Time before fall (ms) --- Sets the amount of time players have to find the right tile before they dissapear.
  • Fallen time (ms) --- Sets how long the tiles will remain gone.
  • Tile messages to everyone --- By default game related messages only get sent to people in the arena, check this to send said messages to everyone in the server
  • Color start --- the randomizeTileColors event randomizes tiles color between two set numbers, the start and end colors
  • Color end --- the end point. If you only want tiles to be the first 6 colors in your color set, set colorStart to 0 and colorend to 5
  • Time between rounds (ms) --- The time between rounds. The winner cannot use events until his round starts
  • Max Round Length (secs) --- After a round goes on for this long, a random winner is chosen and the round ends. A warning occurs at half of this time.
  • Points for winning --- How many points for winning a round, does not include kills or deaths
  • Let anyone build tiles --- Removes admin restrictions. Disabled by default.
  • Falling Brick FX --- Enabled by default. Makes the bricks that won't fall blink.

Commands:
  • /tradeWinner <target> --- Gives your winner away to <target>
  • /newWinner --- Admin only command that ends the round and chooses a random winner.
  • /compileGate <name> --- Will make any brick named <name> owned by the command user a gate, that closes during the rounds.
  • /fallingTiles --- Displays the number of falling tiles. Does not account for tiles that may have been hammered, wanded, undone or otherwise removed.
  • /clearFallingTiles --- Admin only. Removes all falling tiles, and sets the counter back to 0.

This add-on also adds two VCE variables.
var:client:winner (if the client is the current winner) and var:player:inArena (if the player is in the arena currently)

Download:
http://syerjchep.org/Server_FallingTiles.zip






Just updated the mod a bit. (15:51 17.07.2013)
Removed one tiny source of a console error line.
Added checking for RTB before registering prefs.
Added 'let everyone build tiles' option.
Added 'color fx before falling' option.
« Last Edit: July 18, 2013, 11:47:17 AM by DrenDran »

this goes in game modes

this goes in game modes
It is not that kind of gamemode.
Besides, I wouldn't think it matters that much.

It is not a gamemode.
Kind of odd to release it as Gamemode_FallingTiles then.

Kind of odd to release it as Gamemode_FallingTiles then.
Then pretend it's "server_fallingtiles"
How about we get some discussion of the actual add-on now.

are you releasing wordbet too

edit: i'm ignorant
« Last Edit: July 17, 2013, 02:56:17 PM by CharlesSpeaking »


are you releasing wordbet too
he al-Warning - while you were reading a new reply has been posted. You may wish to review your post.

You should add a pref to toggle wether the bricks disappear or are fake killed.

This add-on also adds two VCE variables.
var:client:winner (if the client is the current winner) and var:player:playing (if the player is in the arena currently)
That makes no sense. You registered the second one as var::player::inArena. It's been fixed.
« Last Edit: July 17, 2013, 03:42:30 PM by jes00 »

You should add a pref to toggle wether the bricks disappear or are fake killed.
It's not like it really matters.

ot: /support

That makes no sense. You registered the second one as var::player::inArena.
Whoops, typo.
Fixed.
You should add a pref to toggle wether the bricks disappear or are fake killed.
Eh, that would complicate things. Including the fact the respawn time would be dictated by the minigame, not the script.