Search found 1776 matches
- Tue Feb 04, 2014 4:44 am
- Forum: Plugin Development Support
- Topic: import from same folder
- Replies: 2
- Views: 3363
Sorry for the double post, but I also need to mention that config is a Source.Python package. This sort of thing is one reason why we decided to not add the plugin to sys.path. It could become very difficult to discern between which config you are wanting to import from. Requiring full import paths ...
- Tue Feb 04, 2014 4:25 am
- Forum: Plugin Development Support
- Topic: import from same folder
- Replies: 2
- Views: 3363
Source.Python, unlike EventScripts, does not add the loaded plugin's package to sys.path. Therefor, you must either be explicit and use the full import path: from <package>.config import * or simply use a period . to denote going up one level from the current module: from .config import * Also, with...
- Mon Feb 03, 2014 10:19 pm
- Forum: Plugin Development Support
- Topic: get_engine_interface
- Replies: 1
- Views: 2560
We decided that importing a function whose sole purpose is to retrieve the instance of an interface was unnecessary. So, instead, we now just expose the interface itself as the imported object:
Code: Select all
from engine_c import GameEngine
- Mon Jan 27, 2014 3:44 pm
- Forum: General Discussion
- Topic: New conversion_c module
- Replies: 3
- Views: 3711
You do not import the object types from conversions_c. You import converting functions: # Converting to an index from other types index_from_edict index_from_basehandle index_from_inthandle index_from_pointer index_from_userid index_from_playerinfo # Converting to an Edict instance from other types ...
- Mon Jan 27, 2014 1:55 pm
- Forum: General Discussion
- Topic: New conversion_c module
- Replies: 3
- Views: 3711
CPlayerGenerator should just be imported itself, still from player_c: from player_c import CPlayerGenerator You then iterate over that to get all PlayerInfo instances. We are removing the leading "C" from the object names, so that will probably become PlayerGenerator in the future. If you have a use...
- Mon Jan 27, 2014 4:32 am
- Forum: News & Announcements
- Topic: New Update!!
- Replies: 4
- Views: 6921
- Mon Jan 27, 2014 1:01 am
- Forum: News & Announcements
- Topic: New Update!!
- Replies: 4
- Views: 6921
New Update!!
In light of all the changes recently, I decided to go ahead and post a new build. https://github.com/Source-Python-Dev-Team/Source.Python/releases Most things should be working fairly well, but there are a lot of changes that now need to be made to the Wiki. If you have any issues with this build, p...
- Sat Jan 25, 2014 11:04 pm
- Forum: Whatever
- Topic: Sorting items in dictionary
- Replies: 3
- Views: 5953
- Wed Jan 22, 2014 4:56 pm
- Forum: Plugin Development Support
- Topic: Subclassing an entity - C++ signature error
- Replies: 9
- Views: 7302
http://www.sourcepython.com/showwiki.php?title=Wiki:CEdict
Methods of a class are also attributes. You can use the BaseEntity class to then call all of the CEdict methods by using the same names.
Satoon
Methods of a class are also attributes. You can use the BaseEntity class to then call all of the CEdict methods by using the same names.
Satoon
- Tue Jan 21, 2014 10:23 pm
- Forum: Plugin Development Support
- Topic: Subclassing an entity - C++ signature error
- Replies: 9
- Views: 7302
- Tue Jan 21, 2014 4:41 pm
- Forum: Plugin Development Support
- Topic: Subclassing an entity - C++ signature error
- Replies: 9
- Views: 7302
- Tue Jan 21, 2014 7:30 am
- Forum: Plugin Development Support
- Topic: Subclassing an entity - C++ signature error
- Replies: 9
- Views: 7302
A couple things with this. First, currently we do not have the ability to instantiate some of the objects with all the types we used to. We are still working on figuring out whether we want to handle things the same and how to handle the objects in general. At some point, inheriting will work perfec...
- Tue Jan 21, 2014 6:36 am
- Forum: Plugin Development Support
- Topic: Source-Python will not load
- Replies: 12
- Views: 8669
Glad you got your compiling issues sorted. As for the error still being there, Ayuto did fix the issue we were having that required us to use the "get" method instead of just instantiating the object. He did fix the Python side as well, by removing the instances of CConVar.get(). You will need to up...
- Mon Jan 20, 2014 9:16 pm
- Forum: Plugin Development Support
- Topic: Source-Python will not load
- Replies: 12
- Views: 8669
- Mon Jan 20, 2014 8:22 pm
- Forum: Plugin Development Support
- Topic: Source-Python will not load
- Replies: 12
- Views: 8669
I honestly do not get that at all, even when trying to build in Debug mode. It would be preferable if you used Release instead, but that probably won't fix this issue for you. I would recommend just going ahead and installing either git or TortoiseGit. I prefer using Bash to execute the commands mys...
- Mon Jan 20, 2014 7:00 pm
- Forum: Plugin Development Support
- Topic: Source-Python will not load
- Replies: 12
- Views: 8669
Ok, but the "master" is just the repo itself. In this state, it is "un-built", meaning you have to build your own binaries. If you do not do this, and simply upload the files, as is, to your server, you are only truly updating the Python API, and not the binaries themselves. You need to build the so...
- Mon Jan 20, 2014 6:31 pm
- Forum: Plugin Development Support
- Topic: Source-Python will not load
- Replies: 12
- Views: 8669
- Sun Jan 19, 2014 8:03 pm
- Forum: General Discussion
- Topic: PlayerEntity crashed csgo server
- Replies: 10
- Views: 9223
- Sat Jan 18, 2014 1:23 am
- Forum: General Discussion
- Topic: cs:go server crashes
- Replies: 13
- Views: 11881
- Sat Jan 18, 2014 1:20 am
- Forum: General Discussion
- Topic: PlayerEntity crashed csgo server
- Replies: 10
- Views: 9223
Ok, figured out what "might" have been your sp is an unknown command issue. If you do not upload the newest translations from ../resource/source-python/translations/ , you will receive a KeyError, which we do not account for, and no error message will be shown. Please update your server's files and ...