WIP
This commit is contained in:
parent
9ad991a70e
commit
b41c01e6f7
@ -250,7 +250,7 @@ export class BossReaper extends BossFight {
|
|||||||
this.info.skills = [];
|
this.info.skills = [];
|
||||||
}
|
}
|
||||||
this.info.skills.push({
|
this.info.skills.push({
|
||||||
description: `If the Hero has no ${this.md2Service.stateService.iconHtml(MD2Icon.Mana)}, they take 1 ${this.md2Service.stateService.iconHtml(MD2Icon.Frost)}`,
|
description: `If the Hero has no ${this.md2Service.stateService.iconHtml(MD2Icon.Mana_Color)}, they take 1 ${this.md2Service.stateService.iconHtml(MD2Icon.FrozenToken)}`,
|
||||||
type: MobSkillType.Attack,
|
type: MobSkillType.Attack,
|
||||||
skillRoll: 1
|
skillRoll: 1
|
||||||
} as MD2MobSkill);
|
} as MD2MobSkill);
|
||||||
|
|||||||
@ -8,7 +8,7 @@ import { MD2MobService } from '../../../services/MD2/md2-mob.service';
|
|||||||
import { MD2Service } from '../../../services/MD2/md2.service';
|
import { MD2Service } from '../../../services/MD2/md2.service';
|
||||||
import { MsgBoxService } from '../../../services/msg-box.service';
|
import { MsgBoxService } from '../../../services/msg-box.service';
|
||||||
import { StateService } from '../../../services/state.service';
|
import { StateService } from '../../../services/state.service';
|
||||||
import { ADIcon } from '../../../ui/alert-dlg/alert-dlg.model';
|
import { ADButtons, ADIcon } from '../../../ui/alert-dlg/alert-dlg.model';
|
||||||
import { NumberUtils } from '../../../utilities/number-utils';
|
import { NumberUtils } from '../../../utilities/number-utils';
|
||||||
import { StringUtils } from '../../../utilities/string-utils';
|
import { StringUtils } from '../../../utilities/string-utils';
|
||||||
import { CoreGameRMFactories } from '../factorys/roamingMonsters/CoreGame';
|
import { CoreGameRMFactories } from '../factorys/roamingMonsters/CoreGame';
|
||||||
@ -90,21 +90,30 @@ export class MobsComponent extends MD2ComponentBase implements OnInit {
|
|||||||
|
|
||||||
spawnSpecificMob() {
|
spawnSpecificMob() {
|
||||||
let mobOptions = this.isRoamingMonster ? CoreGameRMFactories.map(f => new DropDownOption(f.mobName, f.mobName)) : this.md2Service.allMobInfos.map(f => new DropDownOption(f.name, f.name));
|
let mobOptions = this.isRoamingMonster ? CoreGameRMFactories.map(f => new DropDownOption(f.mobName, f.mobName)) : this.md2Service.allMobInfos.map(f => new DropDownOption(f.name, f.name));
|
||||||
this.msgBoxService.showInputbox('Spawn', '', { inputType: 'dropdown', dropDownOptions: mobOptions }).pipe(first()).subscribe(mobName => {
|
this.msgBoxService.showInputbox('Spawn', '',
|
||||||
if (mobName) {
|
{
|
||||||
|
inputType: 'dropdown', dropDownOptions: mobOptions,
|
||||||
|
buttons: ADButtons.YesNoCancel,
|
||||||
|
confirmButtonText: 'Spawn',
|
||||||
|
cancelButtonText: 'Random'
|
||||||
|
}).pipe(first()).subscribe(mobName => {
|
||||||
|
|
||||||
let result = this.md2Service.spawnMob(this.isRoamingMonster, mobName);
|
|
||||||
let titleText = result.exitingMob == null ? `${result.mob.description} Shows Up` : `${result.mob.description} Activate One Action Now!`;
|
|
||||||
let actType = result.exitingMob == null ? MobDlgType.Spawn : MobDlgType.Activating;
|
|
||||||
let mob = result.exitingMob == null ? result.mob : result.exitingMob;
|
|
||||||
|
|
||||||
this.dlgService.open(SpawnMobDlgComponent, { context: { title: titleText, mode: actType, mob: mob } })
|
if (mobName || mobName === false) {
|
||||||
.onClose.pipe(first()).subscribe(result => {
|
|
||||||
this.afterSpawn();
|
if (!mobName) { mobName = null; }
|
||||||
});
|
let result = this.md2Service.spawnMob(this.isRoamingMonster, mobName);
|
||||||
this.cdRef.detectChanges();
|
let titleText = result.exitingMob == null ? `${result.mob.description} Shows Up` : `${result.mob.description} Activate One Action Now!`;
|
||||||
}
|
let actType = result.exitingMob == null ? MobDlgType.Spawn : MobDlgType.Activating;
|
||||||
});
|
let mob = result.exitingMob == null ? result.mob : result.exitingMob;
|
||||||
|
|
||||||
|
this.dlgService.open(SpawnMobDlgComponent, { context: { title: titleText, mode: actType, mob: mob } })
|
||||||
|
.onClose.pipe(first()).subscribe(result => {
|
||||||
|
this.afterSpawn();
|
||||||
|
});
|
||||||
|
this.cdRef.detectChanges();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user