Welcome to The Forum

Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads

Learning Sourcepawn.


Recommended Posts

Il give you some pointers on how to get started on learning and also some tools that i use.

If you have no prior experience with programming/scripting i advise to read up on general programming guides before moving on to sourcepawn.

You will need a good editor, i use Sublime Text but the full version requires a license, Notepad++ is a solid choice if you don't wanna go with anything else.

 

Notepad++ syntax highliting and autocomplete based on sourcemod 1.7

 

For sublime i use SourcePawn Completions (autocomplete, build/compile) & SourcePawn Syntax Highlighting

 

These next 2 editors were made by sourcepawn scripters specifically to write plugins, ive never used them so i can't guarantee their quality.

 

BasicPawn

SPEdit

 

Server mangement

 

CSGOSL

I recommend running a local dedicated server to have a place to practise with scripts without having to use someone else's server. CSGOSL is a dedicated server launcher with a full gui for configuration, also comes with the latest sourcemod build installed which you can also use to compile plugins, includes server autoupdates etc.

 

 

Pro tip: trial and error learning is your friend, practise will teach you more than anything else.

  • Like 7
Link to comment
Share on other sites

Resources for learning sourcepawn, as compared to common general scripting and programming languages, for all intents and purposes, suck majorly.

 

evo linked pretty much the best of the best and you won't find much better for sourcepawn resources.

 

 

After you get setup like evo has laid out, and If you have prior experience scripting (outside of shell scripting), or programming languages, you'll find just reading and slightly modifying source code of other people's scripts to be the fastest way to learn.

 

This is especially true for plugins that you've played with in game and that directly modify the game mechanics. Avoid the most poplar 10000+ lines scripts, they'll be so segmented that you probably won't be able to follow yet.

 

Also, when reading source code of sourcemod plugins, the syntax is very loose, sorta like C or Java, meaning that no two scripts are guaranteed to look similar. To fix this, you can use tools meant to format C/C++ code, as they will work fine on sourcepawn code as well.

 

clang-format is what I've used in the past without trouble.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share