Difference between revisions of "SummerOfCodeProposal lfernando"

From The Battle for Wesnoth Wiki
m
Line 44: Line 44:
  
 
<h4>Have you developed software in a team environment before? (As opposed to hacking on something on your own)</h4>
 
<h4>Have you developed software in a team environment before? (As opposed to hacking on something on your own)</h4>
No! That's one of my main interests to participating on this project, to know how it is to work on a big project. One of my major regrets from the above mentioned projects is that I didn't had the chance to work as a team, as most of the time I was a lone programmer in a musician's world. It wasn't bad at all, but I missed technical feedback from my peers and more experienced people than me(at least technically).   
+
No! That's one of my main interests to participating on this project, to know how it is to work on a big project. One of my major regrets from the above mentioned projects is that I didn't had the chance to work as a team, as most of the time I was a lone programmer in a musician's world. It wasn't bad at all, but I missed feedback from my peers and people more experienced than me(at least technically).   
  
 
<h4>Have you participated to the Google Summer of Code before? As a mentor or a student? In what project? Were you successful? If not, why?</h4>
 
<h4>Have you participated to the Google Summer of Code before? As a mentor or a student? In what project? Were you successful? If not, why?</h4>
Line 81: Line 81:
 
   
 
   
 
<h4>What spoken languages are you fluent in?</h4>
 
<h4>What spoken languages are you fluent in?</h4>
Portuguese and English. I know a little bit of French and Japanese.
+
Portuguese and English.
  
 
<h4>Are you good at interacting with other players? Our developer community is friendly, but the player community can be a bit rough.</h4>
 
<h4>Are you good at interacting with other players? Our developer community is friendly, but the player community can be a bit rough.</h4>
Line 96: Line 96:
  
 
<h4>How autonomous are you when developing ? Would you rather discuss intensively changes and not start coding until you know what you want to do or would you rather code a proof of concept to "see how it turn out", taking the risk of having it thrown away if it doesn't match what the project want?</h4>
 
<h4>How autonomous are you when developing ? Would you rather discuss intensively changes and not start coding until you know what you want to do or would you rather code a proof of concept to "see how it turn out", taking the risk of having it thrown away if it doesn't match what the project want?</h4>
If it's a simple task I'll do it myself.
+
If it's a very simple task I'll do it myself. If it's not the expected result, I'll just redo it the right way.
If it's a bit more complicated, sometimes I'll sketch my idea in an example piece of code or some template files. Then I'll discuss it until I I have a clear idea of what to do. Then I'll code it until it is implemented. Of course, doubts and questions arise as the project flows, and I'm eager to ask them as soon as possible.
+
 
 +
If it's a bit more complicated, sometimes I'll sketch my idea in an example piece of code or some template files. Then I'll discuss it until I have a clear idea of what to do. Then I'll code it until it is implemented. Of course, doubts and questions arise as the project flows, and I'm eager to ask them as soon as I can.
 
<h3>Project</h3>
 
<h3>Project</h3>
  
 
<h4>Did you select a project from our list? If that is the case, what project did you select? What do you want to especially concentrate on?</h4>
 
<h4>Did you select a project from our list? If that is the case, what project did you select? What do you want to especially concentrate on?</h4>
Project described below.
+
See project description.
  
 
<h4>Why did you choose this project?</h4>
 
<h4>Why did you choose this project?</h4>
Line 107: Line 108:
  
 
<h4>Include an estimated timeline for your work on the project. Don't forget to mention special things like "I booked holidays between A and B" and "I got an exam at ABC and won't be doing much then".</h4>
 
<h4>Include an estimated timeline for your work on the project. Don't forget to mention special things like "I booked holidays between A and B" and "I got an exam at ABC and won't be doing much then".</h4>
*April 26 - May 17: Make persistence work for singleplayer.
+
More on that on the project description.
*May 15 - June 4: Make persistence work for multiplayer.
 
*June 6 - August 6: Finish the "gamemaster" for MP.And maybe some MP add-on/map that uses this system.  
 
  
Right now, I'm not enrolled to school disciplines, and I don't have any exams to make. My only time-expensive activity is working on my Master Thesis. I'll keep working on my thesis, but I plan to finish it only by the end of the year. While I'm doing this project, it'll be my first priority to finish it on time.   
+
Right now, I'm not enrolled to school disciplines, and I don't have any exams to make. My only time-expensive activity is my Master thesis. I'll keep working on my thesis, but I plan to finish it only by the end of the year. So while I'm on this project, it'll be first priority to finish it on time.   
  
 
<h4>Include as much technical detail about your implementation as you can</h4>
 
<h4>Include as much technical detail about your implementation as you can</h4>
See it on project description below.
+
See below.
  
 
<h4>What do you expect to gain from this project?</h4>
 
<h4>What do you expect to gain from this project?</h4>
Line 120: Line 119:
  
 
<h4>What would make you stay in the Wesnoth community after the conclusion of SOC?</h4>
 
<h4>What would make you stay in the Wesnoth community after the conclusion of SOC?</h4>
Yes, It'll be a pleasure to help the project whenever I have spare time =)
+
Well, I guess that after you start developing, things just aren't the same again. When you see a bug it's not "Cr**, another bug screwed my game. I hope they fix it on next patch." anymore. Your attitude becomes more hands-on, you know you can try fixing it if you want to.
 
+
 +
As for me, it's too early to say. My first impression of the community was very good, though. Also, the code definitely has some programming depth, and I could say I was having fun while I was fixing the bugs. So, that could convince me to lend some more work here whenever I want to help an open source community.
  
 
<h3>Practical considerations</h3>
 
<h3>Practical considerations</h3>

Revision as of 19:51, 8 April 2010


This page is related to Summer of Code 2010
See the list of Summer of Code 2010 Ideas



This is a Summer of Code 2010 student page
Project: SoC Ideas Persistent Gameworld


Contents

 [hide

Description

lfernando - Implement persistent storage of gameworld data between semi-related scenarios

The general idea of this project is introducing variables that are independent from savefiles and campaign lines. They will be accessible from any context and not lose validity once a particular game/campaign has ended. We'll call them global variables.

Global variables will be stored and retrieved using two special tags, [get_global_variable] and [set_global_variable]. They should be used on scenario WML, and their usage will allow that variables, as defined by the [set_variable] family of tags, (from now onwards we will call those ones "local" variables) should be saved to/loaded from an external source.

I'm planning to store global variables on simple wml files with syntax borrowed from uncompressed saves. Each add-on will have its own set of variables, and its own file for global variables.

IRC

lfernando

SoC Application

t127068199898

Questionnaire

Basics

Write a small introduction to yourself.

My name is Luiz Fernando and I'm a 23 years old programmer/gamer/graduate student.

State your preferred email address.

lucifernando@gmail.com

If you have chosen a nick for IRC and Wesnoth forums, what is it?

lfernando

Why do you want to participate in summer of code?

I'm very eager to get involved with the open source world and I want to know how it is to contribute in a big project used by many, many people. GSoC seems like a rewarding way to join an open source project.

What are you studying, subject, level and school?

I'm a master student on UNICAMP(University of Campinas) where I graduated two years ago. My research subject is graph theory.

What country are you from, at what time are you most likely to be able to join IRC?

I'm from Brazil(UTC-3) and I may be able to be on IRC mostly any time of the day on weekdays. IRC meet times should mostly depend on my mentor's time schedule.

Do you have other commitments for the summer period ? Do you plan to take any vacations ? If yes, when.

I just took a week-long vacation on the last week of March, so I don't plan to take any longer break until September. And besides, we have winter here in Brazil on the June - August period =).

Experience

What programs/software have you worked on before?

I've worked on a music technology institute inside my university called NICS, where I started development for a music experimenting tool/improviser called Chord Jammer. Also, I fixed some bugs for a project called Javox. Both projects were implemented on Java.

Have you developed software in a team environment before? (As opposed to hacking on something on your own)

No! That's one of my main interests to participating on this project, to know how it is to work on a big project. One of my major regrets from the above mentioned projects is that I didn't had the chance to work as a team, as most of the time I was a lone programmer in a musician's world. It wasn't bad at all, but I missed feedback from my peers and people more experienced than me(at least technically).

Have you participated to the Google Summer of Code before? As a mentor or a student? In what project? Were you successful? If not, why?

Never participated on any Summer of Code project.

Are you already involved with any open source development projects? If yes, please describe the project and the scope of your involvement.

My first experience with open source is Battle for Wesnoth.

Gaming experience - Are you a gamer?

Yeah!

What type of gamer are you?

Well, I play videogames since I was a little kid(the first game I remember playing was megaman 4 on NES when I was 5 years old). I kept playing until now, so I guess I'm some avid gamer =P. Heck, even while I was fixing the bugs, lots of times I would just take a break and resume playing Httt =P.

What type of games?

Fighting games(Street Fighter, Soul Calibur), strategy games(BfW, Warcraft, Age of Empires, Civilization), rpg's(Final Fantasy series, Chrono Trigger, Fallout, World of Warcraft, lots of other japanese rpgs), action games(Mario, Castlevania), shooters (Half-Life, Quake),

What type of opponents do you prefer?

The clever, unpredictable ones.

Are you more interested in story or gameplay?

Tough question! But I guess videogames are all about "playing", and some games don't even have a discernible story, so I'll choose gameplay. But some games(Fallout 1/2, Breath of Fire 2, Final Fantasy VII, Mother 3) grabbed me for the story alone if not for the great gameplay.

Have you played Wesnoth? If so, tell us roughly for how long and whether you lean towards single player or multiplayer.

I played mainly singleplayer campaigns on Wesnoth.

If you have contributed any patches to Wesnoth, please list them below. You can also list patches that have been submitted but not committed yet and patches that have not been specifically written for GSoC. If you have gained commit access to our SVN (during the evaluation period or earlier) please state so.

Fix for bug #14114, on patch #1538.

Reported minor bug #15601, and fixed it on patch #1525.

Implemented a small example regarding the persistency idea, recorded on http://wesnoth.pastebin.com/g1hMez2J.

3) Communication skills

Though most of our developers are not native English speakers, English is the project's working language. Describe your fluency level in written English.

I'm not a native, but I think my english reading/writing skills are on a good level.

What spoken languages are you fluent in?

Portuguese and English.

Are you good at interacting with other players? Our developer community is friendly, but the player community can be a bit rough.

Yes, I prefer when the conversation is enjoyable, but I can handle angry complaining and trolling too if needed.

Do you give constructive advice?

Of course.

Do you receive advice well?

I think so. If it's the advice is constructive, I'm very attentious.

Are you good at sorting useful criticisms from useless ones?

Yes.

How autonomous are you when developing ? Would you rather discuss intensively changes and not start coding until you know what you want to do or would you rather code a proof of concept to "see how it turn out", taking the risk of having it thrown away if it doesn't match what the project want?

If it's a very simple task I'll do it myself. If it's not the expected result, I'll just redo it the right way.

If it's a bit more complicated, sometimes I'll sketch my idea in an example piece of code or some template files. Then I'll discuss it until I have a clear idea of what to do. Then I'll code it until it is implemented. Of course, doubts and questions arise as the project flows, and I'm eager to ask them as soon as I can.

Project

Did you select a project from our list? If that is the case, what project did you select? What do you want to especially concentrate on?

See project description.

Why did you choose this project?

First of all because I enjoyed playing the game =). Also, it is "minimalist" and has concepts which are very simple to grasp. That suggested some kind of elegance. The community is really friendly and present and answered my begginer questions promptly. And finally, when I downloaded the source and started studying it, it felt like it was made by folks with a firm grasp of C++ and I could learn a lot if I could understand the code and hack through it.

Include an estimated timeline for your work on the project. Don't forget to mention special things like "I booked holidays between A and B" and "I got an exam at ABC and won't be doing much then".

More on that on the project description.

Right now, I'm not enrolled to school disciplines, and I don't have any exams to make. My only time-expensive activity is my Master thesis. I'll keep working on my thesis, but I plan to finish it only by the end of the year. So while I'm on this project, it'll be first priority to finish it on time.

Include as much technical detail about your implementation as you can

See below.

What do you expect to gain from this project?

Having fun with open source development. Learning how to work with many people on a big software project. C++ Enlightenment. =)

What would make you stay in the Wesnoth community after the conclusion of SOC?

Well, I guess that after you start developing, things just aren't the same again. When you see a bug it's not "Cr**, another bug screwed my game. I hope they fix it on next patch." anymore. Your attitude becomes more hands-on, you know you can try fixing it if you want to.

As for me, it's too early to say. My first impression of the community was very good, though. Also, the code definitely has some programming depth, and I could say I was having fun while I was fixing the bugs. So, that could convince me to lend some more work here whenever I want to help an open source community.

Practical considerations

Are you familiar with any of the following tools or languages?

   * Subversion (used for all commits)

Yes.

   * C++ (language used for all the normal source code)

Yes.

   * STL, Boost, Sdl (C++ libraries used by Wesnoth)

STL and some Boost. Never worked with Sdl before.

   * Python (optional, mainly used for tools)

Wrote mostly little programs with it. Seems a really well designed language, eager to use it more on the future.

   * build environments (eg cmake/autotools/scons)

I know SCons and Autotools. Am using SCons to compile Wesnoth builds as for now.

   * WML (the wesnoth specific scenario language)

Started learning it and guess I know it well enough to understand this problem.

   * Lua (used in combination with WML to create scenarios)

No.

Which tools do you normally use for development? Why do you use them?

Eclipse. Gedit for programming in the small.

What programming languages are you fluent in?

C, C++, Java.

Would you mind talking with your mentor on telephone / internet phone? We would like to have a backup way for communications for the case that somehow emails and IRC do fail. If you are willing to do so, please do list a phone number (including international code) so that we are able to contact you. You should probably *only* add this number in the application for you submit to google since the info in the wiki is available in public. We will *not* make any use of your number unless some case of "there is no way to contact you" does arise!

Yeah! You can have my cell phone number and call me when any problem arise. You can have my family house number too, but if you want to call it'd be better be really important because my mother can't understand any english! =-D

Project Description

Overview

The general idea of this project is introducing variables that are independent from savefiles and campaign lines. They will be accessible from any context and not lose validity once a particular game/campaign has ended. We'll call them global variables.

Global variables will be stored and retrieved using two special tags, [get_global_variable] and [set_global_variable]. They should be used on scenario WML, and their usage will allow that variables, as defined by the [set_variable] family of tags, (from now onwards we will call those ones "local" variables) should be saved to/loaded from an external source.

I'm planning to store global variables on simple wml files with syntax borrowed from uncompressed saves. Each add-on will have its own set of variables, and its own file for global variables.


WML Syntax

Here goes a sample specification for the syntax of [load_global_variable] and [store_global_variable] as suggested by Crab_.

 [get_global_variable]
   side=1
   namespace=my_addon
   from_global=my_variable_name
   to_local=foo
 [/get_global_variable]
 [set_global_variable]
   side=1
   namespace=my_addon
   from_local=my_variable_name
   to_global=foo
 [/set_global_variable]
 [clear_global_variable]
   side=1
   namespace=my_addon
   global=foo
 [/clear_global_variable]


[get_global_variable]

Creates a local variable from the value of a global variable.

  • side: Relevant only in MP. Determines which player on MP will do the load operation.
  • namespace: Used for determining from which add-on this variable should be loaded (default is the add-on of the game being played)
  • from_global: Determines the global value from which the variable is loaded.
  • to_local: Determines the name of the local variable that receives the loaded value.

[set_global_variable]

Stores a local variable as a global variable.

It has the same syntax as [load_global_variable], except for noting that it stores local variable named from_local to a global variable named to_global.

[clear_global_variable]

Deletes a global variable with name foo on namespace.


Global variable files should have very simple wml syntax:

 [variables]
   tutorial_completed=1
   betrayed_darken_volk=1
   dragons_slain=2
   crafted_scepter=0
   king_of_wesnoth=1
   ...
 [/variables]

Gamemaster

The other goal of this project is to not only make users, but also multiplayer scenarios capable of handling persistent storage.

Since currently there are no ways to store to store MP data in a server, implementing it is tricky and requires some tweaking and working around. Fortunately, the workaround is doable by this persistency system.

Suppose you want to make a sequence of multiplayer games so that one game stores data that other games can retrieve. You put in those games an extra, virtual player called a "gamemaster" whose sole purpose is to maintain a set of game variables, (he can do that, because he is a player) manage them during gameplay, and after the game is done, participate on another game with the changed values. It is a system with limitations (for example, games happening in parallel can't share variables between them) but it leads to a lot of interesting scenario possibilities.


Project Schedule

We are imagining this project implementation happening in three separate phases:

Phase one should be the implementation of persistency WML for singleplayer.

Phase two should be the extension of that for multiplayer.

Phase three should be the implementation of the "playerless persistency" via the gamemaster concept.

So, more specifically, phase one will happen in the beginning of the project alongside with the studying of WML and wesnoth code by the candidate. Especially code for WML implementation and save games file structure. That should take roughly three weeks.

Implementation of phase two will happen afterwards, and should be done at the same time that we resolve any bug or issue left from phase 1. Phase two should take roughly three weeks too.

Finally, there are some scenario makers interested for the content for phase 3. In the middle of playerless persistency implementation, we'll contact them and try to build a scenario that uses this concept. It should work as both a showcase and a testcase for our ideas. Phase three should be the most time expensive one, featuring a lot of dish cleaning and feature polishing. It should take about one month and a half or two to get it done.

So, for a timeline, we should expect something along this way:

  • April 26 - May 17: Make persistence work for singleplayer.
  • May 15 - June 4: Make persistence work for multiplayer.
  • June 6 - August 6: Finish the "gamemaster" for MP. And maybe some showcase MP scenario if we have the help/time.

Luiz Fernando