[crossfire] (Python)

Mitch Obrian mikeeusaaa at yahoo.com
Tue Oct 11 10:10:31 CDT 2005


I've though of python as something used for special
case items (occiental mage rings, casino slots) and
some interfacing (IPO etc). Big things (weather,
spells, etc) should be done in C. Speed is good. 

Note: for debugging the server I suggest running it in
gdb and questing for a few hours (or atleast running
it for 4,5 hours, doing something sometimes).

Most of the crashes don't happen in the first 5 min...
note: it's still crashing for some reason every few
hours. (And I'm banned from the channel because I'm
not obeying the CF clique, so helping to debug it is
out).

Death To women's Rights

--- Brendan Lally <
     brenlally at gmail.com
     > wrote:

>
      On 10/11/05, Mark Wedel <
      mwedel at sonic.net
      > wrote:
     >
      >
     >
      >   But all this doesn't really answer the question
     >
      - when should something be in
     >
      > python, and when should it be coded in C?
     >
     
     >
      To my way of thinking about it, python is something
     >
      that should for
     >
      the most part be tied to maps or objects. If an
     >
      object needs to do
     >
      something special then python is flexible way to
     >
      have it act in a way
     >
      that is unique without needing to add special cases
     >
      to the server code
     >
      all over the place. This would for example include
     >
      moving grim reapers
     >
      out to a python plugin (though there may be
     >
      performance issues there)
     >
     
     >
      If something doesn't have a particular tie to a
     >
      single map or item,
     >
      then the server core seems a more sensible place for
     >
      it, since many
     >
      things could make use of it.
     >
     
     >
      This would mean that whereas the 'charm monster'
     >
      spell could be done
     >
      in python (but probably shouldn't because it is
     >
      already working in C,
     >
      and porting it would just be a way to introduce
     >
      bugs), fire spells
     >
      shouldn't be because there are lots of them, all of
     >
      which rely fire
     >
      propagating as it normally does - having the server
     >
      deal with the fire
     >
      propagation is far more sensible because more than 1
     >
      object (spell in
     >
      this case) uses it.
     >
     
     >
      The only other consideration is speed, python is
     >
      slower than C to run,
     >
      although the number of times this matters is
     >
      limited.
     >
     
     >
      _______________________________________________
     >
      crossfire mailing list
     >
      
      crossfire at metalforge.org
      
     >
     
     
     http://mailman.metalforge.org/mailman/listinfo/crossfire
     
>
     
     


		
__________________________________ 
Start your day with Yahoo! - Make it your home page! 
     http://www.yahoo.com/r/hs
     
    


More information about the crossfire mailing list