[Freeciv-Dev] [patch #1792] Move ai function pointer setting to ai code

2010-08-03 Thread Marko Lindqvist

Update of patch #1792 (project freeciv):

  Status:  Ready For Test = Done   
 Assigned to:None = cazfi  
 Open/Closed:Open = Closed 


___

Reply to this item at:

  http://gna.org/patch/?1792

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #1792] Move ai function pointer setting to ai code

2010-08-02 Thread Marko Lindqvist

Follow-up Comment #6, patch #1792 (project freeciv):

 I guess the prefix fcai should be fc_ai, according to the most
 functions using this prefix.

Ok, though most other functions with such a name belong to utility, and this
one refers to ai module name.

(file #9662)
___

Additional Item Attachment:

File name: DefaultAiInit_1792-3.diff  Size:5 KB


___

Reply to this item at:

  http://gna.org/patch/?1792

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #1792] Move ai function pointer setting to ai code

2010-07-30 Thread Matthias Pfafferodt

Follow-up Comment #2, patch #1792 (project freeciv):

updated to current trunk

(file #9636)
___

Additional Item Attachment:

File name:
20100730-01-trunk-Move-ai-function-pointer-setting-to-ai-code.patch Size:5 KB


___

Reply to this item at:

  http://gna.org/patch/?1792

___
  Nachricht geschickt von/durch Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #1792] Move ai function pointer setting to ai code

2010-07-30 Thread Marko Lindqvist

Follow-up Comment #3, patch #1792 (project freeciv):

* Renamed default_ai_init() as fcai_default_setup(). This will be more
correct name after some more patches
* Moved init_ai() call from ai implementation specific fcai_default_setup()
to ai_init() in common server code

 move all code which helps players (autosettler, autoexplorer,
 helper tools like aitools, advisors) into ./server/advisor

Yes, although doing this right requires much more work than simply moving
stuff. Some rewrites are required as well

 the server should only use function from ./server/advisor or
 call the AI via functions pointers; never call AI functions
 directly

This should already be the case after I implemented ai_type and function
pointers in it. This makes it possible to make AI as separately loadable
module.

 the AI should prefer to use functions from ./common over
 functions from ./server (posibility of a client side AI)

I don't see the gain here. Client side AI could use almost no code from
current server side AI. There's no much point in making ai to look like
common code when it still can be used only as server code.

(file #9638)
___

Additional Item Attachment:

File name: DefaultAiInit_1792-2.diff  Size:5 KB


___

Reply to this item at:

  http://gna.org/patch/?1792

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #1792] Move ai function pointer setting to ai code

2010-07-30 Thread pepeto

Follow-up Comment #4, patch #1792 (project freeciv):

I guess the prefix fcai should be fc_ai, according to the most functions
using this prefix.

___

Reply to this item at:

  http://gna.org/patch/?1792

___
  Message posté via/par Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #1792] Move ai function pointer setting to ai code

2010-07-30 Thread Matthias Pfafferodt

Follow-up Comment #5, patch #1792 (project freeciv):

 This should already be the case after I implemented ai_type
 and function pointers in it. This makes it possible to make AI
 as separately loadable module. 

It is not the case. As listed in patch #1785 there are a lot dependencies of
the server on code in ./ai.

 This should already be the case after I implemented ai_type
 and function pointers in it. This makes it possible to make AI
 as separately loadable module. 

Yes; but at the moment the server code and the ai code are really
interconnected (ai_choice, settlermap, ...).

___

Reply to this item at:

  http://gna.org/patch/?1792

___
  Nachricht geschickt von/durch Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #1792] Move ai function pointer setting to ai code

2010-07-29 Thread Marko Lindqvist

URL:
  http://gna.org/patch/?1792

 Summary: Move ai function pointer setting to ai code
 Project: Freeciv
Submitted by: cazfi
Submitted on: Thursday 07/29/2010 at 19:10
Category: ai
Priority: 5 - Normal
  Status: Ready For Test
 Privacy: Public
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any
 Planned Release: 2.3.0

___

Details:

With this patch aiiface.c (common server code) needs to have just one ai
implementation specific function as entry point, default_ai_init(), instead
of all the interface functions. default_ai_init() sets up all the function
pointers.



___

File Attachments:


---
Date: Thursday 07/29/2010 at 19:10  Name: DefaultAiInit.diff  Size: 5kB   By:
cazfi

http://gna.org/patch/download.php?file_id=9624

___

Reply to this item at:

  http://gna.org/patch/?1792

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [patch #1792] Move ai function pointer setting to ai code

2010-07-29 Thread Matthias Pfafferodt

Follow-up Comment #1, patch #1792 (project freeciv):

This is a nice cleanup of the ai specific functions. I will check if I can
port the changes of patch #1778 on top of this.

That are your plans for the ai interface? My ideas:

* move all code which helps players (autosettler, autoexplorer, helper tools
like aitools, advisors) into ./server/advisor

* the server should only use function from ./server/advisor or call the AI
via functions pointers; never call AI functions directly

* the AI should prefer to use functions from ./common over functions from
./server (posibility of a client side AI)

___

Reply to this item at:

  http://gna.org/patch/?1792

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev