Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More dynamic solution for card details in deck builder #60

Closed
Zomis opened this issue Aug 20, 2015 · 4 comments
Closed

More dynamic solution for card details in deck builder #60

Zomis opened this issue Aug 20, 2015 · 4 comments

Comments

@Zomis
Copy link
Member

Zomis commented Aug 20, 2015

https://github.com/Cardshifter/HTML-Client/blob/game-board/src/deck_builder/controller.js#L75

$scope.showDetails = function(card) {
    var props = card.properties;
    $scope.cardInfo = {
        name: props.name,
        flavor: props.flavor,
        type: props.creatureType,
        health: props.HEALTH,
        attack: props.ATTACK,
        sickness: props.SICKNESS
    };
};

Some mods have other values than that, some might not even have things like sickness. I'd recommend simply copying the properties from props to $scope.cardInfo

@acostarelli
Copy link
Contributor

@Zomis I thought about doing that, but there are some cards with properties that I don't think should be seen (I will try to get an example soon). I deemed these as the most important properties, and the HTML takes care of showing the properties: if a property is undefined, it will not be shown.

Also, by doing it this way, the order makes sense: on some cards, the name would appear near the middle, and the flavor might be at the bottom; it was very inconsistent.

@Zomis
Copy link
Member Author

Zomis commented Aug 20, 2015

Well... in a later step, I think that each mod should be able to specify what values that should be shown or not, and how and where they should be shown. For now, I can understand this current approach, but in the long run, it needs to be changed.

this might be related to #29 ?

@acostarelli
Copy link
Contributor

Yes, I think they are related. I'm not sure of the current status of that right now, but I know that @Phrancis was working on creating a clean design of a card so that all necessary information could be included on it without making the card look ugly; I remember him looking at examples of cards from other games. Read on from here.

@Phrancis
Copy link
Contributor

Also tangentially related to #58

Zomis referenced this issue Aug 23, 2015
Before, when a card name link was clicked, a list of all the card data would be displayed at the top. However, now that there is a card model directive, upon clicking the card name link, a card model directive is loaded which displays all the information about the card in card form.
@Zomis Zomis closed this as completed Aug 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants