Original Post
Hi all.
I have written some very basic network apps and multiplayer 'games' before. I am interested in writing something larger and one of my goals is to create a framework that makes it easy to introduce new entities into the game via Python or similar. I am looking for any useful information or resources regarding this subject.
My main concern is to minimize the amount of low level networking code that must be done when creating these scripted entities. Ideally they would just define some variables and events that are to be synchronized, and the synchronization rules for them. I am using C# and Python so reflection is certainly an option.
Problems that come to mind is that the server's representation of players is different than what other players receive, for example the server may keep track of health but not share this to other players. Does this mean I need two classes to represent the same entity and two sets of send/receive methods? That sounds very inefficient.
Another issue is entity 'ownership'. In a limited game you can assert that entities can only be manipulated by players they represent or the server, but in my game it can be the case that perhaps players p1 and p2 are on the same team and player p3 is an enemy. I want p1 to be able to create some entity that can be in a limited manner controlled by p2, and finally not be controlled by p3 at all and make less data available to him than p2 (say, data that only team members share). This is not only about having a clearly defined design but also about preventing hackers from manipulating things they shouldn't be able to.
I have written some very basic network apps and multiplayer 'games' before. I am interested in writing something larger and one of my goals is to create a framework that makes it easy to introduce new entities into the game via Python or similar. I am looking for any useful information or resources regarding this subject.
My main concern is to minimize the amount of low level networking code that must be done when creating these scripted entities. Ideally they would just define some variables and events that are to be synchronized, and the synchronization rules for them. I am using C# and Python so reflection is certainly an option.
Problems that come to mind is that the server's representation of players is different than what other players receive, for example the server may keep track of health but not share this to other players. Does this mean I need two classes to represent the same entity and two sets of send/receive methods? That sounds very inefficient.
Another issue is entity 'ownership'. In a limited game you can assert that entities can only be manipulated by players they represent or the server, but in my game it can be the case that perhaps players p1 and p2 are on the same team and player p3 is an enemy. I want p1 to be able to create some entity that can be in a limited manner controlled by p2, and finally not be controlled by p3 at all and make less data available to him than p2 (say, data that only team members share). This is not only about having a clearly defined design but also about preventing hackers from manipulating things they shouldn't be able to.