Difference between revisions of "SourceMod"

From AlliedModders Wiki
Jump to: navigation, search
m
 
m (Future Plans)
 
(21 intermediate revisions by 8 users not shown)
Line 1: Line 1:
SourceMod is a Half-Life 2 modification which focuses on modification scripting, server administration, and plugin writing. Plugins are scripted in the Small language, and allow you to script actions on your server and access the Half-Life 2 (Source) engine with easy functions. If you don't like Small, read below!
+
=Introduction=
 +
SourceMod is a [[SourceMM|Metamod:Source]] plugin for [[Half-Life 2]].  It provides comprehensive scripting for the Source engine and mods written using the Source SDK.  It has features for administration systems, commands, console variables, events, network messages, timed actions, math and string routines, entity modification, and more. It also features a safely versioned, object oriented API usable from "extensions" written in C++.  The extension API can be used to add scripting language callbacks and native features.
  
SourceMod is completely extensible, and written on the MetaEng API. MetaEng is a system of layered functionality which lets you connect multiple scripting engines to a common interface. The interface lets you expand the scripting engine functionality and easily maintain plugins which connect from the scripting engine to the host application. For example, you could easily write an interface to let you write Perl plugins in addition to Small ones.
+
SourceMod scripts are written in the SourcePawn language, which is derived from [[Pawn]]. Some of the differences include:
 +
*Passing functions as "objects," instead of by name
 +
*Natively packed and tagged strings
 +
*Dynamic local variables
 +
*A '<tt>decl</tt>' operator for creating uninitialized variables
 +
*A new virtual machine and JIT, both rewritten in C++
 +
*A new file format
  
You can visit the MetaEng site [http://www.tcwonline.org/~metaeng/ here].
+
=History=
 +
==Initial Project==
 +
SourceMod was officially announced on October 7th, 2004, as a successor to [[AMX Mod X]] for the Half-Life 1 engine. It was targetted as a complete rewrite of AMX Mod X, with the following fundamental changes:
 +
*Use of multiple (pluggable) scripting languages
 +
*JavaScript support
 +
*Unloadability
 +
*An object-oriented module API
  
SourceMod is currently inactive.
+
The Source SDK was released on December 1st, 2004.  A few weeks later, SourceMod released its source code on December 25th.  Then, development began to stagnate.  The concept of multiple languages was over-ambitious and improper.  The system was largely too complex and too unorganized for developers to understand.  Most importantly, the integral calling abstraction layer, designed to let Core talk to plugins without knowing the target scripting layer, was never viable.  Because of this and the inherent complexity of MetaEng, scripts were not testable.
 +
 
 +
By May of 2005, SourceMod had become completely abandoned.  The codebase was scrapped for a rewrite, called "Core 2."  This was also quickly abandoned.  This timeline and the details therein are explained on the SourceMod [http://www.sourcemod.net/devlog/?p=88 Dev Log].  The remaining members of the SourceMod team went back to AMX Mod X.
 +
 
 +
==SourceHook==
 +
By January of 2005, it was apparent that Valve's API would not be sufficient for plugin development in C++.  SourceMod and AMX Mod X Developer Pavol "PM OnoTo" Marko started working on an API for safely hooking virtual functions via vtables. 
 +
 
 +
By March of 2005, it was apparent that this technology would be more useful as a separate project.  Thus, SourceHook broke from SourceMod and the [[SourceMM|Metamod:Source]] project was started.  Metamod:Source was first released on May 26, 2005.
 +
 
 +
==Current Project==
 +
In March of 2006, a public survey was held to determine if the community still wanted SourceMod.  Since the response was good, the project was restarted, but in secret, to avoid the same public relations mistakes.  From March to September, SourcePawn was written, which included:
 +
*A new JIT, written completely in C++
 +
*A new virtual machine and API, written in C++ with object oriented API
 +
*A new file format
 +
*Various new language features
 +
 
 +
From November 2006 to January 2007, SourceMod evolved into a usable scripting platform based on SourcePawn.  As of March 16, 2007, it contained enough scripting-level features to be usable, and builds were made available to the public.
 +
 
 +
SourceMod remains an ongoing development project which now runs on over 38% of all Source servers.
 +
 
 +
=Development Team=
 +
*See the [http://www.sourcemod.net/credits.php credits page].
 +
 
 +
=Future Plans=
 +
As of the time of writing, SourceMod version 1.10 has been released and version 1.11 is under development. The best way to keep up with current development of SourceMod is to view our news section of the forums (linked below).
 +
 
 +
https://forums.alliedmods.net/forumdisplay.php?f=59
 +
 
 +
=License=
 +
SourceMod along with it's extensions & plugins are all licensed under the [[GNU General Public License]].
 +
 
 +
=See Also=
 +
*[[Introduction to SourcePawn]]
 +
*[[Introduction to SourceMod Plugins]]
 +
 
 +
=External Links=
 +
*[http://www.sourcemod.net/ SourceMod Website]
 +
*[http://www.metamodsource.net/ Metamod:Source Website]
 +
 
 +
[[Category:Half-Life_2]]
 +
[[Category:SourceMod]]

Latest revision as of 22:45, 3 June 2020

Introduction

SourceMod is a Metamod:Source plugin for Half-Life 2. It provides comprehensive scripting for the Source engine and mods written using the Source SDK. It has features for administration systems, commands, console variables, events, network messages, timed actions, math and string routines, entity modification, and more. It also features a safely versioned, object oriented API usable from "extensions" written in C++. The extension API can be used to add scripting language callbacks and native features.

SourceMod scripts are written in the SourcePawn language, which is derived from Pawn. Some of the differences include:

  • Passing functions as "objects," instead of by name
  • Natively packed and tagged strings
  • Dynamic local variables
  • A 'decl' operator for creating uninitialized variables
  • A new virtual machine and JIT, both rewritten in C++
  • A new file format

History

Initial Project

SourceMod was officially announced on October 7th, 2004, as a successor to AMX Mod X for the Half-Life 1 engine. It was targetted as a complete rewrite of AMX Mod X, with the following fundamental changes:

  • Use of multiple (pluggable) scripting languages
  • JavaScript support
  • Unloadability
  • An object-oriented module API

The Source SDK was released on December 1st, 2004. A few weeks later, SourceMod released its source code on December 25th. Then, development began to stagnate. The concept of multiple languages was over-ambitious and improper. The system was largely too complex and too unorganized for developers to understand. Most importantly, the integral calling abstraction layer, designed to let Core talk to plugins without knowing the target scripting layer, was never viable. Because of this and the inherent complexity of MetaEng, scripts were not testable.

By May of 2005, SourceMod had become completely abandoned. The codebase was scrapped for a rewrite, called "Core 2." This was also quickly abandoned. This timeline and the details therein are explained on the SourceMod Dev Log. The remaining members of the SourceMod team went back to AMX Mod X.

SourceHook

By January of 2005, it was apparent that Valve's API would not be sufficient for plugin development in C++. SourceMod and AMX Mod X Developer Pavol "PM OnoTo" Marko started working on an API for safely hooking virtual functions via vtables.

By March of 2005, it was apparent that this technology would be more useful as a separate project. Thus, SourceHook broke from SourceMod and the Metamod:Source project was started. Metamod:Source was first released on May 26, 2005.

Current Project

In March of 2006, a public survey was held to determine if the community still wanted SourceMod. Since the response was good, the project was restarted, but in secret, to avoid the same public relations mistakes. From March to September, SourcePawn was written, which included:

  • A new JIT, written completely in C++
  • A new virtual machine and API, written in C++ with object oriented API
  • A new file format
  • Various new language features

From November 2006 to January 2007, SourceMod evolved into a usable scripting platform based on SourcePawn. As of March 16, 2007, it contained enough scripting-level features to be usable, and builds were made available to the public.

SourceMod remains an ongoing development project which now runs on over 38% of all Source servers.

Development Team

Future Plans

As of the time of writing, SourceMod version 1.10 has been released and version 1.11 is under development. The best way to keep up with current development of SourceMod is to view our news section of the forums (linked below).

https://forums.alliedmods.net/forumdisplay.php?f=59

License

SourceMod along with it's extensions & plugins are all licensed under the GNU General Public License.

See Also

External Links