Search found 1413 matches
- Sat Aug 11, 2012 3:51 am
- Forum: API Design
- Topic: Player List Filters
- Replies: 20
- Views: 21027
- Fri Aug 10, 2012 6:33 pm
- Forum: API Design
- Topic: Player List Filters
- Replies: 20
- Views: 21027
- Fri Jul 20, 2012 12:01 pm
- Forum: Plugin Releases
- Topic: The first Addon: Hide Disconnect-Reasons
- Replies: 3
- Views: 6712
- Wed Jul 18, 2012 10:49 pm
- Forum: API Design
- Topic: Using __call__ to execute a command on server/client
- Replies: 8
- Views: 9826
- Wed Jul 18, 2012 6:19 am
- Forum: Whatever
- Topic: Help appreciated :)
- Replies: 16
- Views: 15306
- Sun Jul 15, 2012 8:35 pm
- Forum: General Discussion
- Topic: A few questions according for scripts
- Replies: 19
- Views: 17100
Source.Python is still in developement, so some things may change with a new revision. I guess the script you saw was made before the idea with decorators. However here is an example.
Syntax: Select all
from events.decorators import event
@event
def player_say(game_event):
pass
- Sun Jul 15, 2012 2:33 pm
- Forum: API Design
- Topic: Event system discussion
- Replies: 22
- Views: 26385
- Wed Jul 11, 2012 6:30 am
- Forum: API Design
- Topic: Event system discussion
- Replies: 22
- Views: 26385
And again, what if the try/except works but the variable is "supposed" to be a string (like the Event Variable "text" for player_say) but casting it to an integer or float works? Yeah, I haven't thought about this situation. And, changing the Event Variable's value does not actually change anything...
- Wed Jul 11, 2012 6:20 am
- Forum: API Design
- Topic: Coding Style
- Replies: 42
- Views: 216471
- Tue Jul 10, 2012 9:07 pm
- Forum: API Design
- Topic: Event system discussion
- Replies: 22
- Views: 26385
- Mon Jul 09, 2012 5:55 pm
- Forum: API Design
- Topic: Get/Set event variables
- Replies: 6
- Views: 8673
Get/Set event variables
Yesterday, I compiled a version of Source.Python to play arround with the direct access. That's a very cool thing, but I have suggestion. At the moment we need to do the following to get/set an event variable: def player_disconnect(event): # Get the player's steam ID steamid = event.GetS...
Hey,
you can always download the latest revision via a SVN client and compile it by yourself. You can find the code here. http://code.google.com/p/eventscripts-3/source/checkout
I guess the name will be Source Python
you can always download the latest revision via a SVN client and compile it by yourself. You can find the code here. http://code.google.com/p/eventscripts-3/source/checkout
I guess the name will be Source Python
- Sat Jul 07, 2012 2:40 pm
- Forum: API Design
- Topic: Decorators vs the eventscripts way ..
- Replies: 12
- Views: 13292