Yes, math_counter is a non-networked entity. That means that it doesn't have an index (and edict).
Instead of creating another class we would ideally move the shared code to the BaseEntity class.
Search found 1413 matches
- Thu Nov 26, 2015 5:29 pm
- Forum: Plugin Development Support
- Topic: Accessing math_counters from SP
- Replies: 6
- Views: 4516
- Thu Nov 26, 2015 2:38 pm
- Forum: Plugin Requests
- Topic: Plugins converts from Eventscripts to Source Python
- Replies: 35
- Views: 26646
- Wed Nov 25, 2015 1:16 pm
- Forum: General Discussion
- Topic: Weird behaviour during warmup
- Replies: 7
- Views: 6433
- Wed Nov 25, 2015 12:43 pm
- Forum: General Discussion
- Topic: Weird behaviour during warmup
- Replies: 7
- Views: 6433
- Sun Nov 22, 2015 11:50 am
- Forum: General Discussion
- Topic: SP crashing server No global pointer found for "Server"
- Replies: 4
- Views: 4250
- Sun Nov 22, 2015 12:35 am
- Forum: General Discussion
- Topic: SP crashing server No global pointer found for "Server"
- Replies: 4
- Views: 4250
This should fix the crash (build 140): https://github.com/Source-Python-Dev-Team/Source.Python/commit/89e576c055874c78b33db826358e8828155e80de I changed that in my last commit due to the conversions update, but I forgot to remove the "!". Thanks for reporting! :) Edit: The error you get has nothing ...
- Fri Nov 20, 2015 2:44 pm
- Forum: News & Announcements
- Topic: Updated conversion functions
- Replies: 8
- Views: 26735
- Thu Nov 19, 2015 11:33 pm
- Forum: News & Announcements
- Topic: Updated conversion functions
- Replies: 8
- Views: 26735
The reason for this change was that we only wanted one behaviour and not two depending on the second argument. To be honest, when I decided to return None I was a bit C/C++ driven, where it's common to return "false" on failure and "true" on success (the actual return value is passed as a reference ...
- Thu Nov 19, 2015 2:38 pm
- Forum: News & Announcements
- Topic: Updated conversion functions
- Replies: 8
- Views: 26735
Updated conversion functions
We have updated all conversion functions. They now don't have the optional keyword argument "raise_exception" anymore (defaulting to True). Instead they only accept the value that should be converted and return the converted value. If the conversion failed, a ValueError will be raised. Exa...
- Wed Nov 18, 2015 11:21 pm
- Forum: Plugin Development Support
- Topic: Questions on working with entities IO calls and keyvalues
- Replies: 19
- Views: 13065
Ayuto , do you mean _entities._datamaps.Variant.set_string ? That would be inputdata.value.set_string . As far as I see, it doesn't cast any given string to the needed value type, it just sets it as a string, so the input will be called with a string value. I thought this is exactly what you want? ...
- Wed Nov 18, 2015 7:54 pm
- Forum: Plugin Development Support
- Topic: Questions on working with entities IO calls and keyvalues
- Replies: 19
- Views: 13065
I think you "could" use entity.get_input() to get the input function. Then you only need to call Function.__call__ with your own InputData object, which you filled by using InputData.set_string().
- Tue Nov 17, 2015 9:49 pm
- Forum: Plugin Development Support
- Topic: Csgo motd
- Replies: 21
- Views: 20748
I can't remember if relative paths were working. But if they are working, they would probably need to be relative to the srcds executable. Example:
Syntax: Select all
motd(index, 'test', 'file://cstrike/page.html')
- Tue Nov 17, 2015 3:44 pm
- Forum: Plugin Development Support
- Topic: Csgo motd
- Replies: 21
- Views: 20748
Syntax: Select all
motd(index, 'test', <path to the file on your server>)
- Tue Nov 17, 2015 2:55 pm
- Forum: Plugin Development Support
- Topic: Csgo motd
- Replies: 21
- Views: 20748
- Tue Nov 17, 2015 2:08 pm
- Forum: Plugin Development Support
- Topic: Csgo motd
- Replies: 21
- Views: 20748
- Tue Nov 17, 2015 1:58 pm
- Forum: Plugin Development Support
- Topic: player.switch_team() second argument
- Replies: 3
- Views: 3291
- Sun Nov 15, 2015 5:40 pm
- Forum: API Design
- Topic: Sourcemod (or Mani?) Style Player Filtering
- Replies: 5
- Views: 22707
If we want to be mathematically correct, we would use set operations for filters, because we are actually working with sets. I think the only interesting operations are "union" and "complement". As the notation for unions I would simply use the plus sign (+) and for complements the minus sign (-). H...
- Sat Nov 14, 2015 11:25 am
- Forum: Plugin Development Support
- Topic: Getting a team's player count without iterating?
- Replies: 12
- Views: 8491
I guess the first solutions completes that fast for you, because I'm running the latest SP version and we have recently changed the iterators. While your iterator iterates over Edict objects and uses a different way for filtering, the new iterator iterates over Player objects and accesses dynamic at...
- Sat Nov 14, 2015 11:04 am
- Forum: API Design
- Topic: Adding Entity/PlayerEntity/WeaponEntity attributes via data
- Replies: 4
- Views: 14626
You are missing the "return_type = INT" entry. Are those offsets the same on all games? I doubt, so we will probably need different offsets for the other games. However, I'm not sure if we really want to add that to the data files. It's another offset we need to maintain for a functionality that alr...
- Sat Nov 14, 2015 10:51 am
- Forum: General Discussion
- Topic: [SP SUGGESTION] Plugins Hot Reloading
- Replies: 2
- Views: 3225
Hey, thank you for your suggestion! But I think I agree with Doldol. I know a similar mechanism from the Django framework. At first I though: "Oh, that's cool!", but then I realized that it doesn't always recognize the changes and I had to make another change again. Sometimes I ended up restarting t...