Asked • 07/29/19

Structuring a Game with Angular.JS?

For a GameJam I'm trying to code a simple web-based text adventure game with sprites and small animations in AngularJS. I'm a little new to Angular and am having some trouble figuring out how to structure it. I think my trouble comes from my struggle with `Controllers` vs `Directives`.My game essentially needs to pull text from a text file and display it within a `DOM element` when clicked. Accompanying that is a separate `DOM` item that displays a character sprite image. When certain bits of text are displayed, the image needs to animate.Can anyone who knows `AngularJS` well walk me through the most clean and efficient way to structure this between my `controllers`, `directives`, and the HTML view?

1 Expert Answer

By:

Rize S. answered • 03/23/23

Tutor
New to Wyzant

Senior IT Certified Trainer, IT Developer & DBA Administrator

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.