Presentation is loading. Please wait.

Presentation is loading. Please wait.

Boardr The Racing Board Game Creation Language. Project Manager: Eric Leung Language and Tools Guru: Shensi Ding System Architect: Seong Jin Park System.

Similar presentations


Presentation on theme: "Boardr The Racing Board Game Creation Language. Project Manager: Eric Leung Language and Tools Guru: Shensi Ding System Architect: Seong Jin Park System."— Presentation transcript:

1 Boardr The Racing Board Game Creation Language

2 Project Manager: Eric Leung Language and Tools Guru: Shensi Ding System Architect: Seong Jin Park System Integrator: Jessica Wang Tester and Validator: Nicholas Chao The Team

3 Boardr: Origins ● Programming Languages and Translators course ● wanted a concept that we were all interested in ● games → board games → racing board games

4 Motivation 1. Winning condition provided. 2. Available for beginning programmers.

5 Development/Runtime Environment ● Java 1.7 - JDK 7 ● ANTLR v4 - ANTLRworks ● git - Github ● Makefile o make game g={pathToGame}

6 Language Highlights: ● Rules ● Board, Players, Die ● Library functions ● Command line game output

7 Hello World Player Hello; //creates a Player named Hello Player World; //creates a Player named World Board HelloWorld = 1; //creates a board with one block Die = 1; //creates a die with one side with maximum (and minimum) value of 1 Number[] i = [ 1 ]; //array of Numbers that contains the positions Rule hello (i) { //creates a new rule, with i as a placeholder String hello = “Hello World”; println(hello); //prints “Hello World!” to the console };

8 Here’s the parse tree!

9 next Token Translator Architecture Lexer Parser CustomListener Symbol Table.boardr file BoardrTranslator token stream AST Java Code Playable Game

10 Semantic Analysis Basic types: Board, Die, Player, Number, String, boolean Type checking! ● Symbol Table ● Type Mismatch ● Undeclared Variable ● Operation Mismatch

11 Testing Plan ● Step 1: Run file through antlr to verify correct parse tree. If incorrect, modify grammar and repeat. ● Step 2: Translate file, using strings to verify correct symbol tables and type checking. We printed out the expected results and compared to the output. If incorrect, modify symbol table or type checking method. ● Step 3: Check output versus parallel java program. If incorrect, analyze and modify Translator or boardr file.

12 Example Test Program Input 1.Player One; 2.Board board = 5; 3.Die = 1; 4.Rule types([1]){ 5.String s = "string"; 6. boolean[] b = [true]; 7.String[] sa = ["hello", 1]; 8. }; Output javac BoardrTranslator.java java BoardrTranslator../testing/typeCheckTest.boardr text is Strings="string"; should be string: "string"; should be boolean: true should be string: "hello" should be string: 1 TypeMismatchError: Type error! Cannot convert Number into String

13 DEMO FunTown and Ladders

14 Timeline of Events Language Reference Manual (3/26) Board idea (early February) Team Formation Grammar implemented (4/20) Basic Hello World (4/25) Code generation complete (5/10) Final Report & Presentation Begin code generation (4/21 onwards)

15 Github Commits Note: All of the earliest commits working on grammar (from late March/early April) were lost because of Github failures.

16 Lessons Learned 1. Listen and be considerate of each others’ opinions. 2. Be flexible with each others’ schedules. 3. Review project continuously. 4. Figure out implementation details carefully.

17 What Worked Well 1. Start early on the final report. 2. Set up a group calendar. 3. Dedicate days to working on the project.

18 Advice 1. Remind each other of due dates. 2. Know the tools that you are using (well).

19 Why use Boardr? ● intuitive ● interactive ● for basic programmers

20 Thank you!


Download ppt "Boardr The Racing Board Game Creation Language. Project Manager: Eric Leung Language and Tools Guru: Shensi Ding System Architect: Seong Jin Park System."

Similar presentations


Ads by Google