View Single Post
Plugin Info:     Modification:          Category:          Approver:   Hawk552 (427)
MaximusBrood
Veteran Member
Join Date: Sep 2005
Location: The Netherlands
Old 12-18-2006 , 15:34   Xmas and Easter Presents Spawner (with SQL support)
Reply With Quote #1

Xmas and Easter Presents Spawner (with SQL support) Version 1.5
by MaximusBrood

Description:

This plugin allows you to create spawnpoints, on which Xmas presents or Eastereggs will drop every round.
You can also just drop the presents on command, while being alive or in spectator mode.
With CS there is a money reward, all other mods have to do it without, although Lt. Llama made a modification of my original easteregg mod.

...

Defines:

Code:
#define EASTER
#define XMAS
Comment one of the two lines, depending on which time of the year you currently are.

Code:
#define USING_CSTRIKE
Comment this if you are not serving CS, or if you don't want to enable the cstrike module.
Presents will not yield money if you comment it.

Code:
#define USING_DATABASE
Uncomment this if you want the number of presents collected stored in a database.
You also need to fill in all the DATABASE_ defines.
It's currently not possible to use the database functionality without having USING_CSTRIKE enabled.
(The PHP webpages will be posted shortly)

You will have to add the table manually, this is the layout:

Code:
CREATE TABLE `presentStats` (
  `authid` varchar(32) NOT NULL default '',
  `rank` int(11) NOT NULL default '0',
  `presentAmount` int(11) NOT NULL default '0',
  `moneyAmount` int(11) NOT NULL default '0',
  PRIMARY KEY  (`authid`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
Commands:

amx_spawnpresent - Spawn a present at your current location with a 2,5 sec delay.
fillfillfillfillfillfillfillfillfillfiYou can do this when you are spectator too!

amx_removepresents - Remove all presents on the map.

amx_addpresentspawnpoint - This command will add you current location to a file with spawnpoints.
fillfillfillfillfillfillfillfillfillfillfillf iffFrom then on, every new round, three eggs (default) will fall from that spot.

Cvar's:

sv_presentamount - Amount of presents that will fall from a spawnpoint every round (default is 3)

sv_removepresents - Controls whether to remove all presents before spawning new ones at a new round.
fillfillfillfillfillfillfillfillfillfillfiff This is recommended. If you don't turn this option on, the map will quickly become a mess. (default is 1)

Required Modules:
  • Engine
  • Cstrike (only when having money as reward)
  • SQLx (only when having the database option on)


About the downloads:

You can see two versions of the plugin to download, but in fact, they are both the same.
The only difference is that presentsSpawnerSQL.sma has "#define USING_DATABASE" uncommented, while presentsSpawner.sma has not.

Special TFC Version:

Lt Llama made a very nice modification on my original easteregg plugin, this is for Team Fortress Classic only.
You can find that modification here: http://www.euroskillz.eu/amxmodx/chr.../christmas.zip

Notes:
  • You need 2 models for xmas and 5 models for easter, they are all in the zip. Make sure you got them in your models folder.
  • Also make sure there is an empty folder called presents in your amxmodx/data folder.
    The spawns won't work without the folder ready.
  • You need the language file provided in the zip, I will post a request for translations later.
  • A lot of spawnfiles for various maps already exist. If you don't like them, just delete all files in the addons/amxmodx/data/presents folder.
  • This is a total rewrite of the old (easter-only) plugin.
Attached Files
File Type: zip presentsSpawner.zip (316.7 KB, 4684 views)
File Type: sma Get Plugin or Get Source (presentsSpawner.sma - 5773 views - 18.4 KB)
File Type: sma Get Plugin or Get Source (presentsSpawnerSQL.sma - 4094 views - 18.2 KB)
__________________
Released six formerly private plugins. Not active here since ages.

Last edited by MaximusBrood; 04-05-2007 at 14:58.
MaximusBrood is offline