gbrainy r227 - trunk/src
- From: jmas svn gnome org
- To: svn-commits-list gnome org
- Subject: gbrainy r227 - trunk/src
- Date: Mon, 18 Feb 2008 22:00:25 +0000 (GMT)
Author: jmas
Date: Mon Feb 18 22:00:24 2008
New Revision: 227
URL: http://svn.gnome.org/viewvc/gbrainy?rev=227&view=rev
Log:
* CalculationOperator.cs: Use calculation instead of Math
* gbrainy.cs: Use calculation instead of Math
* CalculationGreatestDivisor.cs: Use calculation instead of Math
* GameManager.cs: Use calculation instead of Math
* CalculatioWhichNumber.cs: Use calculation instead of Math
* GameSession.cs: Use calculation instead of Math
* CalculationTwoNumbers.cs: Use calculation instead of Math
* CalculationArithmetical.cs: Use calculation instead of Math
* CalculationWhichNumber.cs: Use calculation instead of Math
* Makefile.am: Use calculation instead of Math
2008-02-18 Jordi Mas <jmas softcatala org>
Added:
trunk/src/CalculatioWhichNumber.cs
- copied, changed from r224, /trunk/src/MathWhichNumber.cs
trunk/src/CalculationArithmetical.cs
- copied, changed from r226, /trunk/src/MathArithmetical.cs
trunk/src/CalculationGreatestDivisor.cs
- copied, changed from r225, /trunk/src/MathGreaterDivisor.cs
trunk/src/CalculationOperator.cs
- copied, changed from r224, /trunk/src/MathOperator.cs
trunk/src/CalculationTwoNumbers.cs
- copied, changed from r224, /trunk/src/MathTwoNumbers.cs
trunk/src/CalculationWhichNumber.cs
- copied, changed from r226, /trunk/src/MathWhichNumber.cs
Removed:
trunk/src/MathArithmetical.cs
trunk/src/MathGreaterDivisor.cs
trunk/src/MathOperator.cs
trunk/src/MathTwoNumbers.cs
trunk/src/MathWhichNumber.cs
Modified:
trunk/src/ChangeLog
trunk/src/GameManager.cs
trunk/src/GameSession.cs
trunk/src/Makefile.am
trunk/src/gbrainy.cs
Copied: trunk/src/CalculatioWhichNumber.cs (from r224, /trunk/src/MathWhichNumber.cs)
==============================================================================
--- /trunk/src/MathWhichNumber.cs (original)
+++ trunk/src/CalculatioWhichNumber.cs Mon Feb 18 22:00:24 2008
@@ -22,7 +22,7 @@
using System.Text;
using Mono.Unix;
-public class MathWhichNumber : Game
+public class CalculationWhichNumber : Game
{
private double question_num;
private const int options_cnt = 4;
Copied: trunk/src/CalculationArithmetical.cs (from r226, /trunk/src/MathArithmetical.cs)
==============================================================================
--- /trunk/src/MathArithmetical.cs (original)
+++ trunk/src/CalculationArithmetical.cs Mon Feb 18 22:00:24 2008
@@ -22,7 +22,7 @@
using System.Text;
using Mono.Unix;
-public class MathArithmetical : Game
+public class CalculationArithmetical : Game
{
public enum Operation
{
Copied: trunk/src/CalculationGreatestDivisor.cs (from r225, /trunk/src/MathGreaterDivisor.cs)
==============================================================================
--- /trunk/src/MathGreaterDivisor.cs (original)
+++ trunk/src/CalculationGreatestDivisor.cs Mon Feb 18 22:00:24 2008
@@ -22,7 +22,7 @@
using System.Text;
using Mono.Unix;
-public class MathGreaterDivisor : Game
+public class CalculationGreatestDivisor : Game
{
private int []numbers;
private int []answers;
Copied: trunk/src/CalculationOperator.cs (from r224, /trunk/src/MathOperator.cs)
==============================================================================
--- /trunk/src/MathOperator.cs (original)
+++ trunk/src/CalculationOperator.cs Mon Feb 18 22:00:24 2008
@@ -23,7 +23,7 @@
using System.Text;
using Mono.Unix;
-public class MathOperator : Game
+public class CalculationOperator : Game
{
private double number_a, number_b, number_c, total;
private char[] opers = {'*', '+', '-', '/'};
Copied: trunk/src/CalculationTwoNumbers.cs (from r224, /trunk/src/MathTwoNumbers.cs)
==============================================================================
--- /trunk/src/MathTwoNumbers.cs (original)
+++ trunk/src/CalculationTwoNumbers.cs Mon Feb 18 22:00:24 2008
@@ -22,7 +22,7 @@
using System.Text;
using Mono.Unix;
-public class MathTwoNumbers : Game
+public class CalculationTwoNumbers : Game
{
private int number_a, number_b;
private int op1, op2, max_operand;
Copied: trunk/src/CalculationWhichNumber.cs (from r226, /trunk/src/MathWhichNumber.cs)
==============================================================================
--- /trunk/src/MathWhichNumber.cs (original)
+++ trunk/src/CalculationWhichNumber.cs Mon Feb 18 22:00:24 2008
@@ -22,7 +22,7 @@
using System.Text;
using Mono.Unix;
-public class MathWhichNumber : Game
+public class CalculationWhichNumber : Game
{
private double question_num;
private const int options_cnt = 4;
Modified: trunk/src/GameManager.cs
==============================================================================
--- trunk/src/GameManager.cs (original)
+++ trunk/src/GameManager.cs Mon Feb 18 22:00:24 2008
@@ -55,13 +55,13 @@
typeof (PuzzleBuildTriangle),
};
- static Type[] MathTrainers = new Type[]
+ static Type[] CalculationTrainers = new Type[]
{
- typeof (MathArithmetical),
- typeof (MathGreaterDivisor),
- typeof (MathTwoNumbers),
- typeof (MathWhichNumber),
- typeof (MathOperator),
+ typeof (CalculationArithmetical),
+ typeof (CalculationGreatestDivisor),
+ typeof (CalculationTwoNumbers),
+ typeof (CalculationWhichNumber),
+ typeof (CalculationOperator),
};
static Type[] MemoryTrainers = new Type[]
@@ -84,8 +84,8 @@
static GameManager ()
{
Console.WriteLine ("Games registered: {0}: {1} logic puzzles, {2} math trainers, {3} memory trainers",
- LogicPuzzles.Length + MathTrainers.Length + MemoryTrainers.Length,
- LogicPuzzles.Length, MathTrainers.Length, MemoryTrainers.Length);
+ LogicPuzzles.Length + CalculationTrainers.Length + MemoryTrainers.Length,
+ LogicPuzzles.Length, CalculationTrainers.Length, MemoryTrainers.Length);
}
public GameManager ()
@@ -141,9 +141,9 @@
games.Add (LogicPuzzles [i]);
}
- if ((game_type & GameSession.Types.MathTrainers) == GameSession.Types.MathTrainers) {
- for (int i = 0; i < MathTrainers.Length; i++)
- games.Add (MathTrainers [i]);
+ if ((game_type & GameSession.Types.CalculationTrainers) == GameSession.Types.CalculationTrainers) {
+ for (int i = 0; i < CalculationTrainers.Length; i++)
+ games.Add (CalculationTrainers [i]);
}
if ((game_type & GameSession.Types.MemoryTrainers) == GameSession.Types.MemoryTrainers) {
Modified: trunk/src/GameSession.cs
==============================================================================
--- trunk/src/GameSession.cs (original)
+++ trunk/src/GameSession.cs Mon Feb 18 22:00:24 2008
@@ -30,10 +30,10 @@
None = 0,
LogicPuzzles = 2,
MemoryTrainers = 4,
- MathTrainers = 8,
+ CalculationTrainers = 8,
Custom = 16,
- TrainersOnly = MemoryTrainers | MathTrainers,
- AllGames = MemoryTrainers | MathTrainers | LogicPuzzles
+ TrainersOnly = MemoryTrainers | CalculationTrainers,
+ AllGames = MemoryTrainers | CalculationTrainers | LogicPuzzles
}
private enum ScoresType
@@ -41,7 +41,7 @@
None = 0,
LogicPuzzles,
MemoryTrainers,
- MathTrainers,
+ CalculationTrainers,
Last
}
@@ -180,10 +180,10 @@
public int MathScore {
get {
- if (games [(int) ScoresType.MathTrainers] == 0)
+ if (games [(int) ScoresType.CalculationTrainers] == 0)
return 0;
- return scores [(int) ScoresType.MathTrainers] * 10 / games [(int) ScoresType.MathTrainers];
+ return scores [(int) ScoresType.CalculationTrainers] * 10 / games [(int) ScoresType.CalculationTrainers];
}
}
@@ -196,7 +196,7 @@
}
public int MathGamesPlayed {
- get { return games [(int) ScoresType.MathTrainers]; }
+ get { return games [(int) ScoresType.CalculationTrainers]; }
}
public string TimePlayed {
@@ -300,8 +300,8 @@
games [(int) ScoresType.MemoryTrainers]++;
break;
case Game.Types.MathTrainer:
- scores [(int) ScoresType.MathTrainers] += current_game.Score;
- games [(int) ScoresType.MathTrainers]++;
+ scores [(int) ScoresType.CalculationTrainers] += current_game.Score;
+ games [(int) ScoresType.CalculationTrainers]++;
break;
}
Modified: trunk/src/Makefile.am
==============================================================================
--- trunk/src/Makefile.am (original)
+++ trunk/src/Makefile.am Mon Feb 18 22:00:24 2008
@@ -20,7 +20,7 @@
$(srcdir)/PuzzleNumericRelation.cs \
$(srcdir)/PuzzleNextFigure.cs \
$(srcdir)/PuzzleSquareSheets.cs \
- $(srcdir)/MathArithmetical.cs \
+ $(srcdir)/CalculationArithmetical.cs \
$(srcdir)/MemoryColouredFigures.cs \
$(srcdir)/GameSession.cs \
$(srcdir)/MemoryNumbers.cs \
@@ -31,15 +31,15 @@
$(srcdir)/PuzzleFigureLetter.cs \
$(srcdir)/CustomGameDialog.cs \
$(srcdir)/PuzzleDivideCircle.cs \
- $(srcdir)/MathGreaterDivisor.cs \
- $(srcdir)/MathTwoNumbers.cs \
- $(srcdir)/MathWhichNumber.cs \
+ $(srcdir)/CalculationGreatestDivisor.cs \
+ $(srcdir)/CalculationTwoNumbers.cs \
+ $(srcdir)/CalculationWhichNumber.cs \
$(srcdir)/PuzzleMatrixGroups.cs \
$(srcdir)/PuzzleBalance.cs \
$(srcdir)/PuzzlePairs.cs \
$(srcdir)/PuzzleOstracism.cs \
$(srcdir)/MemoryCountDots.cs \
- $(srcdir)/MathOperator.cs \
+ $(srcdir)/CalculationOperator.cs \
$(srcdir)/PuzzleFigurePattern.cs \
$(srcdir)/ColorPalette.cs \
$(srcdir)/PuzzlePeopleTable.cs \
Modified: trunk/src/gbrainy.cs
==============================================================================
--- trunk/src/gbrainy.cs (original)
+++ trunk/src/gbrainy.cs Mon Feb 18 22:00:24 2008
@@ -315,7 +315,7 @@
void OnMathOnly (object sender, EventArgs args)
{
- session.Type = GameSession.Types.MathTrainers;
+ session.Type = GameSession.Types.CalculationTrainers;
OnNewGame ();
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]