mirror of
https://github.com/rakion99/shelter-editor.git
synced 2026-09-22 18:12:15 +00:00
Added Max Stats all
This commit is contained in:
1 parent
ee139168e2
commit
c0d3fb4f44
2 files changed
+10
No files matched your search
@@ -119,6 +119,9 @@
|
||||
|
||||
<div class="row box" ng-show="section == 'dwellers'">
|
||||
<div class="dwellers list-group col-sm-4">
|
||||
<div class="row save">
|
||||
<button type="button" class="btn btn-primary pull-right" ng-click="maxSpecialAll()">Max Stats All</button>
|
||||
</div>
|
||||
<a ng-repeat="d in save.dwellers.dwellers" ng-click="editDweller(d);" ng-class="{ 'active': dweller == d }" class="list-group-item">{{ d.name }} {{ d.lastName }}</a>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -228,6 +228,13 @@ app.controller('dwellerController', function ($scope) {
|
||||
$scope.editDweller = function (dweller) {
|
||||
$scope.dweller = dweller;
|
||||
};
|
||||
|
||||
$scope.maxSpecialAll = function () {
|
||||
var sum2 = Object.keys($scope.save.dwellers.dwellers).length;
|
||||
for(i=0; i<sum2; i++)
|
||||
for(i2=0; i2<8; i2++)
|
||||
$scope.save.dwellers.dwellers[i].stats.stats[i2].value = 10;
|
||||
};
|
||||
|
||||
$scope.maxSpecial = function () {
|
||||
$scope.dweller.stats.stats[1].value = 10;
|
||||
|
||||
Reference in new issue
Block a user