lockMaker FrameWork
Description:
First of all, this is not a single plugin.
This plugin is intended to help people build blocks without changing the original code.
* What is this?
It's a multi-plugin framework to allow developers build their own type of blocks for maps.
* Why you made this?
Because I see too many people asking for support to modify some other plugins for blocks and I think it's very annoying to modify.
* What's change with this plugin framework?
You can make your own block without any needs to modify the core plugin.
* I can do anything with my block?
Yes, you can do anything but I suggest try to limit to function calls available in this framework to avoid high cpu usage in your own block.
* Are you sure this is the best way to manage blocks cpu and resources?
No I don't, but I'm sure it's an approach.
* Can I ask you to make some blocks for me?
No. Read the api, it's very simple. Anything else is up to you.
Features:
Auto snap on blocks
Grab blocks
Save/Restore blocks from files
Menu arquitechture (plugin extension) (Pending)
Extensible... You can create your own blocks!!!
Support for non-standard blocks (wtf is it?). You can setup custom 3D sizes for blocks.
Cvars:
Currently there no cvars
Usage:
This plugin have some commands to let you put blocks in maps.
bm_save
Saves all blocks in current map to a file.
bm_load
Load previous saved blocks for the current map.
bm_cleanup
Remove all blocks from the current map.
bm_list
Lists all registered blocks in framework.
bm_add [blockname] [size]
Create a block where you're aiming.
Code:
blockname: the nickname of the block you can see with bm_list
size: d = default size, s = small, l = large
example:
for generic large blocks: bm_add default l
for autobhop standard blocks: bm_add autobhop d
bm_del
Deletes the block you're aiming.
bm_rotate
Rotates the block you're aiming.
+bm_grab
Use this bind to grab the blocks with aim.
API Documentation:
I'll be updating this information to make it clear to understand how to use the api
The framework is responsible to call block handlers (Spawn, Touch, Think, etc).
Currently there only 5 handlers working.
Those handlers where called from the original engine function (pfn_Touch, client_PreThink, etc)
This is intended to use to modify properties of blocks (ej: make breakable)
PHP Code:
block_Spawn(ent): Called only at block creation
This function may be used to trigger actions when some player touches the block.
PHP Code:
block_Touch(touched, toucher): Called from pfn_Touch with some cache + cooldown control.
You can use this function instead client_PreThink / FM_PlayerPreThink
PHP Code:
block_PlayerPreThink(id): Called from client_PreThink. You have to setup this handler on a player to enable the call.
You can use this function instead client_PostThink / FM_PlayerPostThink
PHP Code:
block_PlayerPostThink(id): Called from client_PostThink. You have to setup this handler on a player to enable the call.
This is where your block thinks.
PHP Code:
block_Think(ent): Called from the register_think function. This is called every think a block needs to think (EV_FL_nextthink).
Pending.
PHP Code:
block_AddToFullPack(): Pending.
Pending.
PHP Code:
block_UpdateClientData(): Pending.
For the blocks plugins side, you have 2 natives
This is used to register the new block in the framework.
You can setup the name of the block, the base name for the model, the type of touch, cooldown time for touch and 3 different sizes (default, small, large). This native returns the ID of the registered block.
PHP Code:
native _reg_block(const name[], const ver[], const model[], const touch, const Float:cdown, const Float:size[], const Float:sizesmall[], const Float:sizelarge[])
touch takes one of the following options
PHP Code:
#define TOUCH_NONE 1<<0
#define TOUCH_ALL 1<<1
#define TOUCH_BOTH 1<<2
#define TOUCH_HEAD 1<<3
#define TOUCH_FOOT 1<<4
#define TOUCH_OTHER 1<<5
The other native is _set_handler is used to setup which handlers could be called from framework plugin to block plugin.
PHP Code:
native _set_handler(const id, const blockid, const value, const Handlers:handler)
Remember you can use this handlers
PHP Code:
enum Handlers {
hSpawn, // called automaticaly
hTouch, // called automaticaly with cooldown control
hThink, // called only when block/plugin enable this handler
hAddToFullPack, // not yet finished
hPlayerPreThink, // called only when block/plugin enable this handler
hPlayerPostThink, // called only when block/plugin enable this handler
hUpdateClientData // not yet finished
}
Changelog:
PHP Code:
- 0.1 - initial release
Credits:
- Necro - Models from BlockMaker 4.01. Some ideas and code from BlockMaker 4.01
- Frk_14 - for tests
- Asd' - for tests & Flash block plugin
Extra info:
I'm uploading .zip files because of includes needed.
This one is fully usable but maybe someone needs a handler that is not yet finished.
The plugins of blocks here are only examples. I'm sure most of them could be optimized.
I suggest to read the block/plugin examples to understand how it works.
All comments and recomendations are welcome.
I'm posting the full source code without any amxx. I suggest you to compile yourself the plugins.
You need to maintain models directory and filename format.
Remember to put the include file in your includes folder.
.zip
BlockMaker Framework
Jump to
- Inregistreaza-te pe Zonek Telecom ca sa vezi toate Subiectele
- -->>Regulile Forumului & Descriere<<--
- ↳ Regulament Forum
- ↳ Prezentare
- ↳ Cereri Parteneriate
- ↳ Intri si tu in reteaua zonek??
- ↳ Sugestiile voastre
- ↳ Raportare bug-uri/probleme forum
- -->>Mica Publicitate & Reclama<<--
- ↳ Reclama diverse siteuri & servere de Counter-Strike
- ↳ Vand
- ↳ Cumpar
- -->>Servere Comunitare NON-STOP<<--
- ↳ Discord Server Zonek Telecom
- ↳ GO.ZONEK.RO
- ↳ ARENA.ZONEK.RO
- ↳ AWP.ZONEK.RO
- ↳ Bucuresti Create Server
- ↳ Evidenta redirect
- ↳ Clan TAG
- zonek.ro - Counter Strike Global Offensive
- ↳ SourceMod Plugins
- ↳ Admin Commands
- ↳ Fun Stuff
- ↳ Gameplay
- ↳ General Purpose
- ↳ Server Management
- ↳ Statistical
- ↳ Technical/Development
- ↳ Tutoriale
- ↳ Probleme la servere si Jocul Counter-Strike: Global Offensive
- -->>Jocuri & Resurse Counter Strike<<--
- ↳ Tutoriale cs 1.6- Server
- ↳ Tutoriale Moduri Counter - Strike [NOU]
- ↳ Tutoriale cs - Install Counter-Strike & HLDS
- ↳ Scripting
- ↳ Mapping / Harti
- ↳ Cereri Tutoriale
- ↳ Download pluginuri
- ↳ Discutii legate de plugin-uri - Cereri Plugin-uri
- ↳ Download zone
- ↳ AdminMod
- ↳ AmxModX
- ↳ Admin Commands
- ↳ General Purpose
- ↳ Statistical
- ↳ Gameplay
- ↳ Event Related
- ↳ Server Management
- ↳ Fun Stuff
- ↳ Technical/Development
- ↳ AmxMod
- ↳ Addons-uri Counter Strike
- ↳ Addonsuri AmxModX
- ↳ Addonsuri AdminMod
- ↳ Addonsuri AmxMod
- ↳ Cereri addonsuri
- ↳ Probleme tehnice
- ↳ HLDS
- ↳ Client 1.6
- ↳ Alte jocuri
- -->>Diverse<<--
- ↳ Discutii diverse
- ↳ Realitatea Baptista Castellon
- ↳ Arta
- ↳ Studentie
- ↳ Auto / Moto
- ↳ Fashion
- ↳ Sanatate
- -->> San Andreas Multi Player <<--
- ↳ Discutii Scripting
- ↳ Probleme GodFather
- ↳ Tutoriale
- ↳ Cerere Tutoriale
- ↳ Salonul Scripturilor
- ↳ Plugins
- ↳ Maps
- ↳ Gamemode
- ↳ FilterScript
- ↳ News Development
- ↳ Ajutor Servere
- -->> Photoshop <<--
- ↳ Photoshop
- ↳ Creatii
- ↳ Gifts
- ↳ Graphic Battle
- ↳ Tutoriale
- ↳ Competitii: - SOTW
- ↳ Resurse
- ↳ Ripperi
- ↳ Cereri Photoshop
- ↳ Da LIKE pe FaceBook si castigi 10 euro saptamanal!!
- -->>Filme & Muzica<<--
- ↳ Filme
- ↳ Muzica
- -->>Minunile Lumii Antince<<--
- ↳ Cele 7 Minuni ale Lumii
- ↳ Minuni uitate ale Lumii Antice
- -->>LOVE & SEX<<--
- ↳ Love & Sex
- ↳ Contraceptia
- ↳ Dragostea
- -->>Hubul dc.zonek.ro al serverelor de Counter-Strike<<--
- ↳ Totul despre hubul dc.zonek.ro
- -->>Culturi si Mistere<<--
- ↳ Culturi ascunse, mistere si fapte inexplicabile
- ↳ Magie
- ↳ Lumea Viselor
- -->>|Messenger| & Curiozitatii<<--
- ↳ <|Mesaje tampite care se dau pe mess|>
- ↳ Intrebari fara raspuns
- ↳ Stiati ca ?
- ↳ Pentru cei nemultumiti
- Manage Holidays/Sarbatori si Zile Onomastice
- ↳ Manage Holidays / Sarbatori si Zile Onomastice
- Recycle Bin
- ↳ Recycle Bin
- ↳ HaoS.ZoneK.Ro [ Public Server ]
- ↳ Regulament
- ↳ Anunturi
- ↳ Cafenea Admini
- ↳ Staff
- ↳ Cerere Admin
- ↳ Cerere Slot
- ↳ Cerere UnBan
- ↳ Reclamatie Admini
- ↳ Lista Banuri
- ↳ Redirecte
- ↳ djs.zonek.ro
- ↳ Regulament
- ↳ Cereri admin / slot pe djs.zonek.ro
- ↳ Cerere UnBan
- ↳ Reclamatii admini / playeri
- ↳ Campionat 2 vs 2
- ↳ Discutii Libere
- ↳ Clanu Dj's
- ↳ Ballas
- ↳ Nortenos
- ↳ Surenos
- ↳ Taxele serverului
- ↳ Vanzari - Cumparari
- ↳ Afaceri
- ↳ Servicii
- ↳ Case
- ↳ Politia Romana
- ↳ Discutii generale despre factiuni
- ↳ Pompieri si Medici
- ↳ Serviciul Roman de informatii
- ↳ Armata Romana
- ↳ Clanul Frusin
- ↳ Clanul Racean
- ↳ Guvernator San Andreas
- ↳ Asasini Platiti
- ↳ Reporteri ProTV
- ↳ Transport Company
- ↳ Instructori
- ↳ Clanul Camataru
- ↳ Job-uri secundare
- ↳ Tow Car Company
- ↳ Tutoriale GTA SA:MP
- ↳ freerunners.zonek.ro
- ↳ Admins only
- ↳ Regulament
- ↳ Anunturi
- ↳ Donatii
- ↳ Echipa nord
- ↳ Cereri admin/slot
- ↳ Cereri unban
- ↳ De ce am dat ban
- ↳ Cine face abuz de admin
- ↳ Discutii libere
- ↳ Evidenta redirecte
- ↳ Ghenaaaaaa.....!!!
- ↳ Grove Street
- ↳ Ballas Family
- ↳ Mayor
- ↳ The Triads
- ↳ The Mafia
- ↳ Varios Los Aztecas
- ↳ License Faction
- ↳ Los Santos Vagos
- ↳ News Reporter
- ↳ Taxi Company
- ↳ National Guard
- ↳ Police Departament
- ↳ Federal Bureau of Investigaton
- ↳ Medics
- ↳ Hitman Agency
- ↳ furien.zonek.ro
- ↳ Regulament Server
- ↳ Anunturi
- ↳ Cerere Admin / Slot
- ↳ Cerere UnBan
- ↳ Cerere Ban
- ↳ Reclamatii
- ↳ Echipa furien.zonek.ro
- ↳ Mariri / degradari
- ↳ Redirecte
- ↳ Discutii Generale
- ↳ Download Redirecte
- ↳ FAN.ZONEK.RO # Fan Curier Server
- ↳ intrudersWOW - www.zonek.ro
- ↳ Announcements / Server info
- ↳ International Zone
- ↳ Romanian
- ↳ German
- ↳ English
- ↳ Requests
- ↳ Ban \ Mute Request
- ↳ Unban / Unmute requests
- ↳ Bug Report
- ↳ Items
- ↳ Other
- ↳ Fixed bugs
- ↳ General Discussion
- ↳ Ze.Zonek.Ro # Intruders Zombie
- ↳ Stream name: ...::: CooLFM :::... - Cel mai tare Radio
- ↳ I'm in love!
- ↳ Request
- ↳ Events - Radio CooLFM
- ↳ Cautam Dj`eitze si DJ-eii
- ↳ Personal Top Ten (?)
- ↳ Zonek SA:MP Official Server
- ↳ Informatii
- ↳ Sugestii
- ↳ Update's
- ↳ Factiuni
- ↳ Police Depatament
- ↳ Federal Bureau of Investigations
- ↳ National Guard
- ↳ Fireman/Paramedics
- ↳ The Mafia
- ↳ The Triads
- ↳ The Mayor
- ↳ Hitman Agency
- ↳ News Reporter
- ↳ Taxi Company
- ↳ License Faction
- ↳ Los Santos Vagos
- ↳ Varios Los Aztecas
- ↳ Ballas
- ↳ Grove Street
- ↳ NFS Club
- ↳ NRG Club
- ↳ Plangeri
- ↳ Admin's Zone
- ↳ Diverse
- ↳ Buguri
- ↳ Statistici WEB
- ↳ LIGHT.ZONEK.RO | Anti-Cheat | Skins |
- ↳ DM.ZONEK.RO
- ↳ WAR3.ZONEK.RO
- ↳ ELITE.ZONEK.RO