Skip to content

Commit 07dd2f2

Browse files
committed
JS
starting on GameObject constructor function
1 parent 6ff51c4 commit 07dd2f2

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

‎assignments/prototypes.js‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,11 @@
1515
* destroy() // prototype method -> returns the string 'Object was removed from the game.'
1616
*/
1717

18+
function GameObject(value){
19+
this.createdAt = value.createdAt;
20+
this.dimensions = value.dimensions;
21+
}
22+
1823
/*
1924
=== CharacterStats ===
2025
* hp

0 commit comments

Comments
 (0)