OSDN Git Service

[Refactor] struct player_type を class PlayerType に置換。
authorDeskull <61610939+sikabane-works@users.noreply.github.com>
Fri, 12 Nov 2021 14:29:27 +0000 (23:29 +0900)
committerDeskull <61610939+sikabane-works@users.noreply.github.com>
Fri, 12 Nov 2021 14:29:27 +0000 (23:29 +0900)
1186 files changed:
src/action/action-limited.cpp
src/action/action-limited.h
src/action/activation-execution.cpp
src/action/activation-execution.h
src/action/movement-execution.cpp
src/action/movement-execution.h
src/action/mutation-execution.cpp
src/action/mutation-execution.h
src/action/open-close-execution.cpp
src/action/open-close-execution.h
src/action/open-util.cpp
src/action/open-util.h
src/action/racial-execution.cpp
src/action/racial-execution.h
src/action/run-execution.cpp
src/action/run-execution.h
src/action/travel-execution.cpp
src/action/travel-execution.h
src/action/tunnel-execution.cpp
src/action/tunnel-execution.h
src/action/weapon-shield.cpp
src/action/weapon-shield.h
src/artifact/fixed-art-generator.cpp
src/artifact/fixed-art-generator.h
src/artifact/random-art-characteristics.cpp
src/artifact/random-art-characteristics.h
src/artifact/random-art-generator.cpp
src/artifact/random-art-generator.h
src/artifact/random-art-misc.cpp
src/artifact/random-art-misc.h
src/autopick/autopick-destroyer.cpp
src/autopick/autopick-destroyer.h
src/autopick/autopick-drawer.cpp
src/autopick/autopick-drawer.h
src/autopick/autopick-editor-command.cpp
src/autopick/autopick-editor-command.h
src/autopick/autopick-entry.cpp
src/autopick/autopick-entry.h
src/autopick/autopick-finder.cpp
src/autopick/autopick-finder.h
src/autopick/autopick-matcher.cpp
src/autopick/autopick-matcher.h
src/autopick/autopick-reader-writer.cpp
src/autopick/autopick-reader-writer.h
src/autopick/autopick-registry.cpp
src/autopick/autopick-registry.h
src/autopick/autopick-util.cpp
src/autopick/autopick-util.h
src/autopick/autopick.cpp
src/autopick/autopick.h
src/avatar/avatar-changer.cpp
src/avatar/avatar-changer.h
src/avatar/avatar.cpp
src/avatar/avatar.h
src/birth/auto-roller.cpp
src/birth/auto-roller.h
src/birth/birth-body-spec.cpp
src/birth/birth-body-spec.h
src/birth/birth-select-class.cpp
src/birth/birth-select-class.h
src/birth/birth-select-personality.cpp
src/birth/birth-select-personality.h
src/birth/birth-select-race.cpp
src/birth/birth-select-race.h
src/birth/birth-select-realm.cpp
src/birth/birth-select-realm.h
src/birth/birth-stat.cpp
src/birth/birth-stat.h
src/birth/birth-util.cpp
src/birth/birth-util.h
src/birth/birth-wizard.cpp
src/birth/birth-wizard.h
src/birth/character-builder.cpp
src/birth/character-builder.h
src/birth/game-play-initializer.cpp
src/birth/game-play-initializer.h
src/birth/history-editor.cpp
src/birth/history-editor.h
src/birth/history-generator.cpp
src/birth/history-generator.h
src/birth/inventory-initializer.cpp
src/birth/inventory-initializer.h
src/birth/quick-start.cpp
src/birth/quick-start.h
src/blue-magic/blue-magic-ball-bolt.cpp
src/blue-magic/blue-magic-ball-bolt.h
src/blue-magic/blue-magic-breath.cpp
src/blue-magic/blue-magic-breath.h
src/blue-magic/blue-magic-caster.cpp
src/blue-magic/blue-magic-caster.h
src/blue-magic/blue-magic-checker.cpp
src/blue-magic/blue-magic-checker.h
src/blue-magic/blue-magic-spirit-curse.cpp
src/blue-magic/blue-magic-spirit-curse.h
src/blue-magic/blue-magic-status.cpp
src/blue-magic/blue-magic-status.h
src/blue-magic/blue-magic-summon.cpp
src/blue-magic/blue-magic-summon.h
src/blue-magic/blue-magic-util.cpp
src/blue-magic/blue-magic-util.h
src/blue-magic/learnt-info.cpp
src/blue-magic/learnt-info.h
src/blue-magic/learnt-power-getter.cpp
src/blue-magic/learnt-power-getter.h
src/cmd-action/cmd-attack.cpp
src/cmd-action/cmd-attack.h
src/cmd-action/cmd-hissatsu.cpp
src/cmd-action/cmd-hissatsu.h
src/cmd-action/cmd-mane.cpp
src/cmd-action/cmd-mane.h
src/cmd-action/cmd-mind.cpp
src/cmd-action/cmd-mind.h
src/cmd-action/cmd-move.cpp
src/cmd-action/cmd-move.h
src/cmd-action/cmd-open-close.cpp
src/cmd-action/cmd-open-close.h
src/cmd-action/cmd-others.cpp
src/cmd-action/cmd-others.h
src/cmd-action/cmd-pet.cpp
src/cmd-action/cmd-pet.h
src/cmd-action/cmd-racial.cpp
src/cmd-action/cmd-racial.h
src/cmd-action/cmd-shoot.cpp
src/cmd-action/cmd-shoot.h
src/cmd-action/cmd-spell.cpp
src/cmd-action/cmd-spell.h
src/cmd-action/cmd-travel.cpp
src/cmd-action/cmd-travel.h
src/cmd-action/cmd-tunnel.cpp
src/cmd-action/cmd-tunnel.h
src/cmd-building/cmd-building.cpp
src/cmd-building/cmd-building.h
src/cmd-building/cmd-inn.cpp
src/cmd-building/cmd-inn.h
src/cmd-io/cmd-autopick.cpp
src/cmd-io/cmd-autopick.h
src/cmd-io/cmd-diary.cpp
src/cmd-io/cmd-diary.h
src/cmd-io/cmd-dump.cpp
src/cmd-io/cmd-dump.h
src/cmd-io/cmd-floor.cpp
src/cmd-io/cmd-floor.h
src/cmd-io/cmd-gameoption.cpp
src/cmd-io/cmd-gameoption.h
src/cmd-io/cmd-help.cpp
src/cmd-io/cmd-help.h
src/cmd-io/cmd-knowledge.cpp
src/cmd-io/cmd-knowledge.h
src/cmd-io/cmd-lore.cpp
src/cmd-io/cmd-lore.h
src/cmd-io/cmd-macro.cpp
src/cmd-io/cmd-macro.h
src/cmd-io/cmd-process-screen.cpp
src/cmd-io/cmd-process-screen.h
src/cmd-io/cmd-save.cpp
src/cmd-io/cmd-save.h
src/cmd-item/cmd-destroy.cpp
src/cmd-item/cmd-destroy.h
src/cmd-item/cmd-eat.cpp
src/cmd-item/cmd-eat.h
src/cmd-item/cmd-equipment.cpp
src/cmd-item/cmd-equipment.h
src/cmd-item/cmd-item.cpp
src/cmd-item/cmd-item.h
src/cmd-item/cmd-magiceat.cpp
src/cmd-item/cmd-magiceat.h
src/cmd-item/cmd-quaff.cpp
src/cmd-item/cmd-quaff.h
src/cmd-item/cmd-read.cpp
src/cmd-item/cmd-read.h
src/cmd-item/cmd-refill.cpp
src/cmd-item/cmd-refill.h
src/cmd-item/cmd-throw.cpp
src/cmd-item/cmd-throw.h
src/cmd-item/cmd-usestaff.cpp
src/cmd-item/cmd-usestaff.h
src/cmd-item/cmd-zaprod.cpp
src/cmd-item/cmd-zaprod.h
src/cmd-item/cmd-zapwand.cpp
src/cmd-item/cmd-zapwand.h
src/cmd-visual/cmd-draw.cpp
src/cmd-visual/cmd-draw.h
src/cmd-visual/cmd-map.cpp
src/cmd-visual/cmd-map.h
src/cmd-visual/cmd-visuals.cpp
src/cmd-visual/cmd-visuals.h
src/combat/attack-accuracy.cpp
src/combat/attack-accuracy.h
src/combat/attack-criticality.cpp
src/combat/attack-criticality.h
src/combat/aura-counterattack.cpp
src/combat/aura-counterattack.h
src/combat/shoot.cpp
src/combat/shoot.h
src/combat/slaying.cpp
src/combat/slaying.h
src/core/asking-player.cpp
src/core/asking-player.h
src/core/disturbance.cpp
src/core/disturbance.h
src/core/game-closer.cpp
src/core/game-closer.h
src/core/game-play.cpp
src/core/game-play.h
src/core/magic-effects-timeout-reducer.cpp
src/core/magic-effects-timeout-reducer.h
src/core/object-compressor.cpp
src/core/object-compressor.h
src/core/player-processor.cpp
src/core/player-processor.h
src/core/scores.cpp
src/core/scores.h
src/core/show-file.cpp
src/core/show-file.h
src/core/stuff-handler.cpp
src/core/stuff-handler.h
src/core/turn-compensator.cpp
src/core/turn-compensator.h
src/core/visuals-reseter.cpp
src/core/visuals-reseter.h
src/core/window-redrawer.cpp
src/core/window-redrawer.h
src/dungeon/dungeon-processor.cpp
src/dungeon/dungeon-processor.h
src/dungeon/dungeon.cpp
src/dungeon/dungeon.h
src/dungeon/quest-completion-checker.cpp
src/dungeon/quest-completion-checker.h
src/dungeon/quest-monster-placer.cpp
src/dungeon/quest-monster-placer.h
src/dungeon/quest.cpp
src/dungeon/quest.h
src/effect/effect-feature.cpp
src/effect/effect-feature.h
src/effect/effect-item.cpp
src/effect/effect-item.h
src/effect/effect-monster-charm.cpp
src/effect/effect-monster-charm.h
src/effect/effect-monster-evil.cpp
src/effect/effect-monster-evil.h
src/effect/effect-monster-lite-dark.cpp
src/effect/effect-monster-lite-dark.h
src/effect/effect-monster-oldies.cpp
src/effect/effect-monster-oldies.h
src/effect/effect-monster-psi.cpp
src/effect/effect-monster-psi.h
src/effect/effect-monster-resist-hurt.cpp
src/effect/effect-monster-resist-hurt.h
src/effect/effect-monster-spirit.cpp
src/effect/effect-monster-spirit.h
src/effect/effect-monster-switcher.cpp
src/effect/effect-monster-switcher.h
src/effect/effect-monster-util.cpp
src/effect/effect-monster-util.h
src/effect/effect-monster.cpp
src/effect/effect-monster.h
src/effect/effect-player-curse.cpp
src/effect/effect-player-curse.h
src/effect/effect-player-oldies.cpp
src/effect/effect-player-oldies.h
src/effect/effect-player-resist-hurt.cpp
src/effect/effect-player-resist-hurt.h
src/effect/effect-player-spirit.cpp
src/effect/effect-player-spirit.h
src/effect/effect-player-switcher.cpp
src/effect/effect-player-switcher.h
src/effect/effect-player.cpp
src/effect/effect-player.h
src/effect/effect-processor.cpp
src/effect/effect-processor.h
src/flavor/flavor-describer.cpp
src/flavor/flavor-describer.h
src/flavor/flavor-util.h
src/flavor/named-item-describer.cpp
src/flavor/named-item-describer.h
src/floor/cave-generator.cpp
src/floor/cave-generator.h
src/floor/cave.cpp
src/floor/cave.h
src/floor/fixed-map-generator.cpp
src/floor/fixed-map-generator.h
src/floor/floor-changer.cpp
src/floor/floor-changer.h
src/floor/floor-events.cpp
src/floor/floor-events.h
src/floor/floor-generator.cpp
src/floor/floor-generator.h
src/floor/floor-leaver.cpp
src/floor/floor-leaver.h
src/floor/floor-mode-changer.cpp
src/floor/floor-mode-changer.h
src/floor/floor-object.cpp
src/floor/floor-object.h
src/floor/floor-save.cpp
src/floor/floor-save.h
src/floor/floor-streams.cpp
src/floor/floor-streams.h
src/floor/floor-util.cpp
src/floor/floor-util.h
src/floor/geometry.cpp
src/floor/geometry.h
src/floor/line-of-sight.cpp
src/floor/line-of-sight.h
src/floor/object-allocator.cpp
src/floor/object-allocator.h
src/floor/object-scanner.cpp
src/floor/object-scanner.h
src/floor/pattern-walk.cpp
src/floor/pattern-walk.h
src/floor/tunnel-generator.cpp
src/floor/tunnel-generator.h
src/floor/wild.cpp
src/floor/wild.h
src/grid/door.cpp
src/grid/door.h
src/grid/feature-generator.cpp
src/grid/feature-generator.h
src/grid/feature.cpp
src/grid/feature.h
src/grid/grid.cpp
src/grid/grid.h
src/grid/object-placer.cpp
src/grid/object-placer.h
src/grid/stair.cpp
src/grid/stair.h
src/grid/trap.cpp
src/grid/trap.h
src/hpmp/hp-mp-processor.cpp
src/hpmp/hp-mp-processor.h
src/hpmp/hp-mp-regenerator.cpp
src/hpmp/hp-mp-regenerator.h
src/info-reader/fixed-map-parser.cpp
src/info-reader/fixed-map-parser.h
src/inventory/floor-item-getter.cpp
src/inventory/floor-item-getter.h
src/inventory/inventory-curse.cpp
src/inventory/inventory-curse.h
src/inventory/inventory-damage.cpp
src/inventory/inventory-damage.h
src/inventory/inventory-describer.cpp
src/inventory/inventory-describer.h
src/inventory/inventory-object.cpp
src/inventory/inventory-object.h
src/inventory/inventory-util.cpp
src/inventory/inventory-util.h
src/inventory/item-getter.cpp
src/inventory/item-getter.h
src/inventory/pack-overflow.cpp
src/inventory/pack-overflow.h
src/inventory/player-inventory.cpp
src/inventory/player-inventory.h
src/inventory/recharge-processor.cpp
src/inventory/recharge-processor.h
src/io-dump/character-dump.cpp
src/io-dump/character-dump.h
src/io-dump/player-status-dump.cpp
src/io-dump/player-status-dump.h
src/io-dump/random-art-info-dumper.cpp
src/io-dump/random-art-info-dumper.h
src/io-dump/special-class-dump.cpp
src/io-dump/special-class-dump.h
src/io/cursor.cpp
src/io/cursor.h
src/io/exit-panic.cpp
src/io/exit-panic.h
src/io/files-util.cpp
src/io/files-util.h
src/io/input-key-processor.cpp
src/io/input-key-processor.h
src/io/input-key-requester.cpp
src/io/input-key-requester.h
src/io/interpret-pref-file.cpp
src/io/interpret-pref-file.h
src/io/mutations-dump.cpp
src/io/mutations-dump.h
src/io/pref-file-expressor.cpp
src/io/pref-file-expressor.h
src/io/read-pref-file.cpp
src/io/read-pref-file.h
src/io/record-play-movie.cpp
src/io/record-play-movie.h
src/io/report.cpp
src/io/report.h
src/io/screen-util.cpp
src/io/signal-handlers.cpp
src/io/uid-checker.cpp
src/io/uid-checker.h
src/io/write-diary.cpp
src/io/write-diary.h
src/knowledge/knowledge-autopick.cpp
src/knowledge/knowledge-autopick.h
src/knowledge/knowledge-experiences.cpp
src/knowledge/knowledge-experiences.h
src/knowledge/knowledge-features.cpp
src/knowledge/knowledge-features.h
src/knowledge/knowledge-inventory.cpp
src/knowledge/knowledge-inventory.h
src/knowledge/knowledge-items.cpp
src/knowledge/knowledge-items.h
src/knowledge/knowledge-monsters.cpp
src/knowledge/knowledge-monsters.h
src/knowledge/knowledge-mutations.cpp
src/knowledge/knowledge-mutations.h
src/knowledge/knowledge-quests.cpp
src/knowledge/knowledge-quests.h
src/knowledge/knowledge-self.cpp
src/knowledge/knowledge-self.h
src/knowledge/knowledge-uniques.cpp
src/knowledge/knowledge-uniques.h
src/load/dummy-loader.cpp
src/load/dummy-loader.h
src/load/dungeon-loader.cpp
src/load/dungeon-loader.h
src/load/extra-loader.cpp
src/load/extra-loader.h
src/load/floor-loader.cpp
src/load/floor-loader.h
src/load/inventory-loader.cpp
src/load/inventory-loader.h
src/load/load-zangband.cpp
src/load/load-zangband.h
src/load/load.cpp
src/load/load.h
src/load/monster/monster-loader-base.h
src/load/monster/monster-loader-factory.cpp
src/load/monster/monster-loader-factory.h
src/load/old/load-v1-5-0.cpp
src/load/old/load-v1-5-0.h
src/load/old/load-v1-7-0.cpp
src/load/old/load-v1-7-0.h
src/load/old/monster-loader-savefile10.cpp
src/load/old/monster-loader-savefile10.h
src/load/player-attack-loader.cpp
src/load/player-attack-loader.h
src/load/player-info-loader.cpp
src/load/player-info-loader.h
src/load/quest-loader.cpp
src/load/quest-loader.h
src/load/store-loader.cpp
src/load/store-loader.h
src/load/world-loader.cpp
src/load/world-loader.h
src/lore/lore-calculator.cpp
src/lore/lore-calculator.h
src/lore/lore-store.cpp
src/lore/lore-store.h
src/lore/magic-types-setter.cpp
src/lore/magic-types-setter.h
src/lore/monster-lore.cpp
src/lore/monster-lore.h
src/main-win.cpp
src/main/angband-initializer.cpp
src/main/angband-initializer.h
src/main/game-data-initializer.cpp
src/main/game-data-initializer.h
src/main/info-initializer.cpp
src/main/info-initializer.h
src/main/scene-table-floor.cpp
src/main/scene-table-floor.h
src/main/scene-table-monster.cpp
src/main/scene-table-monster.h
src/main/scene-table.cpp
src/main/scene-table.h
src/main/sound-of-music.cpp
src/main/sound-of-music.h
src/market/arena.cpp
src/market/arena.h
src/market/bounty.cpp
src/market/bounty.h
src/market/building-craft-fix.cpp
src/market/building-craft-fix.h
src/market/building-craft-weapon.cpp
src/market/building-craft-weapon.h
src/market/building-enchanter.cpp
src/market/building-enchanter.h
src/market/building-monster.cpp
src/market/building-monster.h
src/market/building-quest.cpp
src/market/building-quest.h
src/market/building-recharger.cpp
src/market/building-recharger.h
src/market/building-service.cpp
src/market/building-service.h
src/market/building-util.cpp
src/market/building-util.h
src/market/play-gamble.cpp
src/market/play-gamble.h
src/melee/melee-postprocess.cpp
src/melee/melee-postprocess.h
src/melee/melee-spell-flags-checker.cpp
src/melee/melee-spell-flags-checker.h
src/melee/melee-spell-util.cpp
src/melee/melee-spell-util.h
src/melee/melee-spell.cpp
src/melee/melee-spell.h
src/melee/melee-switcher.cpp
src/melee/melee-switcher.h
src/melee/melee-util.cpp
src/melee/melee-util.h
src/melee/monster-attack-monster.cpp
src/melee/monster-attack-monster.h
src/mind/mind-archer.cpp
src/mind/mind-archer.h
src/mind/mind-berserker.cpp
src/mind/mind-berserker.h
src/mind/mind-blue-mage.cpp
src/mind/mind-blue-mage.h
src/mind/mind-cavalry.cpp
src/mind/mind-cavalry.h
src/mind/mind-chaos-warrior.cpp
src/mind/mind-chaos-warrior.h
src/mind/mind-elementalist.cpp
src/mind/mind-elementalist.h
src/mind/mind-force-trainer.cpp
src/mind/mind-force-trainer.h
src/mind/mind-hobbit.cpp
src/mind/mind-hobbit.h
src/mind/mind-info.cpp
src/mind/mind-info.h
src/mind/mind-mage.cpp
src/mind/mind-mage.h
src/mind/mind-magic-eater.cpp
src/mind/mind-magic-eater.h
src/mind/mind-magic-resistance.cpp
src/mind/mind-magic-resistance.h
src/mind/mind-mindcrafter.cpp
src/mind/mind-mindcrafter.h
src/mind/mind-mirror-master.cpp
src/mind/mind-mirror-master.h
src/mind/mind-monk.cpp
src/mind/mind-monk.h
src/mind/mind-ninja.cpp
src/mind/mind-ninja.h
src/mind/mind-power-getter.cpp
src/mind/mind-power-getter.h
src/mind/mind-priest.cpp
src/mind/mind-priest.h
src/mind/mind-samurai.cpp
src/mind/mind-samurai.h
src/mind/mind-sniper.cpp
src/mind/mind-sniper.h
src/mind/mind-warrior-mage.cpp
src/mind/mind-warrior-mage.h
src/mind/mind-warrior.cpp
src/mind/mind-warrior.h
src/mind/mind-weaponsmith.cpp
src/mind/mind-weaponsmith.h
src/mind/monk-attack.cpp
src/mind/monk-attack.h
src/monster-attack/monster-attack-lose.cpp
src/monster-attack/monster-attack-lose.h
src/monster-attack/monster-attack-player.cpp
src/monster-attack/monster-attack-player.h
src/monster-attack/monster-attack-processor.cpp
src/monster-attack/monster-attack-processor.h
src/monster-attack/monster-attack-status.cpp
src/monster-attack/monster-attack-status.h
src/monster-attack/monster-attack-switcher.cpp
src/monster-attack/monster-attack-switcher.h
src/monster-attack/monster-attack-util.cpp
src/monster-attack/monster-attack-util.h
src/monster-attack/monster-eating.cpp
src/monster-attack/monster-eating.h
src/monster-floor/monster-death-util.cpp
src/monster-floor/monster-death-util.h
src/monster-floor/monster-death.cpp
src/monster-floor/monster-death.h
src/monster-floor/monster-direction.cpp
src/monster-floor/monster-direction.h
src/monster-floor/monster-generator.cpp
src/monster-floor/monster-generator.h
src/monster-floor/monster-lite.cpp
src/monster-floor/monster-lite.h
src/monster-floor/monster-move.cpp
src/monster-floor/monster-move.h
src/monster-floor/monster-object.cpp
src/monster-floor/monster-object.h
src/monster-floor/monster-remover.cpp
src/monster-floor/monster-remover.h
src/monster-floor/monster-runaway.cpp
src/monster-floor/monster-runaway.h
src/monster-floor/monster-safety-hiding.cpp
src/monster-floor/monster-safety-hiding.h
src/monster-floor/monster-summon.cpp
src/monster-floor/monster-summon.h
src/monster-floor/monster-sweep-grid.cpp
src/monster-floor/monster-sweep-grid.h
src/monster-floor/one-monster-placer.cpp
src/monster-floor/one-monster-placer.h
src/monster-floor/quantum-effect.cpp
src/monster-floor/quantum-effect.h
src/monster-floor/special-death-switcher.cpp
src/monster-floor/special-death-switcher.h
src/monster-race/monster-race-hook.cpp
src/monster-race/monster-race-hook.h
src/monster/monster-compaction.cpp
src/monster/monster-compaction.h
src/monster/monster-damage.cpp
src/monster/monster-damage.h
src/monster/monster-describer.cpp
src/monster/monster-describer.h
src/monster/monster-info.cpp
src/monster/monster-info.h
src/monster/monster-list.cpp
src/monster/monster-list.h
src/monster/monster-processor-util.cpp
src/monster/monster-processor.cpp
src/monster/monster-processor.h
src/monster/monster-status-setter.cpp
src/monster/monster-status-setter.h
src/monster/monster-status.cpp
src/monster/monster-status.h
src/monster/monster-update.cpp
src/monster/monster-update.h
src/monster/monster-util.cpp
src/monster/monster-util.h
src/mspell/assign-monster-spell.cpp
src/mspell/assign-monster-spell.h
src/mspell/element-resistance-checker.cpp
src/mspell/element-resistance-checker.h
src/mspell/high-resistance-checker.cpp
src/mspell/high-resistance-checker.h
src/mspell/improper-mspell-remover.cpp
src/mspell/improper-mspell-remover.h
src/mspell/mspell-attack-util.cpp
src/mspell/mspell-attack-util.h
src/mspell/mspell-attack.cpp
src/mspell/mspell-attack.h
src/mspell/mspell-ball.cpp
src/mspell/mspell-ball.h
src/mspell/mspell-bolt.cpp
src/mspell/mspell-bolt.h
src/mspell/mspell-breath.cpp
src/mspell/mspell-breath.h
src/mspell/mspell-checker.cpp
src/mspell/mspell-checker.h
src/mspell/mspell-curse.cpp
src/mspell/mspell-curse.h
src/mspell/mspell-damage-calculator.cpp
src/mspell/mspell-damage-calculator.h
src/mspell/mspell-dispel.cpp
src/mspell/mspell-dispel.h
src/mspell/mspell-floor.cpp
src/mspell/mspell-floor.h
src/mspell/mspell-judgement.cpp
src/mspell/mspell-judgement.h
src/mspell/mspell-learn-checker.cpp
src/mspell/mspell-learn-checker.h
src/mspell/mspell-lite.cpp
src/mspell/mspell-lite.h
src/mspell/mspell-particularity.cpp
src/mspell/mspell-particularity.h
src/mspell/mspell-selector.cpp
src/mspell/mspell-selector.h
src/mspell/mspell-special.cpp
src/mspell/mspell-special.h
src/mspell/mspell-status.cpp
src/mspell/mspell-status.h
src/mspell/mspell-summon.cpp
src/mspell/mspell-summon.h
src/mspell/mspell-util.cpp
src/mspell/mspell-util.h
src/mspell/smart-mspell-util.cpp
src/mspell/smart-mspell-util.h
src/mspell/specified-summon.cpp
src/mspell/specified-summon.h
src/mspell/summon-checker.cpp
src/mspell/summon-checker.h
src/mutation/gain-mutation-switcher.cpp
src/mutation/gain-mutation-switcher.h
src/mutation/lose-mutation-switcher.cpp
src/mutation/lose-mutation-switcher.h
src/mutation/mutation-calculator.cpp
src/mutation/mutation-calculator.h
src/mutation/mutation-investor-remover.cpp
src/mutation/mutation-investor-remover.h
src/mutation/mutation-processor.cpp
src/mutation/mutation-processor.h
src/mutation/mutation-techniques.cpp
src/mutation/mutation-techniques.h
src/object-activation/activation-bolt-ball.cpp
src/object-activation/activation-bolt-ball.h
src/object-activation/activation-breath.cpp
src/object-activation/activation-breath.h
src/object-activation/activation-charm.cpp
src/object-activation/activation-charm.h
src/object-activation/activation-genocide.cpp
src/object-activation/activation-genocide.h
src/object-activation/activation-others.cpp
src/object-activation/activation-others.h
src/object-activation/activation-resistance.cpp
src/object-activation/activation-resistance.h
src/object-activation/activation-switcher.cpp
src/object-activation/activation-switcher.h
src/object-activation/activation-teleport.cpp
src/object-activation/activation-teleport.h
src/object-activation/activation-util.cpp
src/object-activation/activation-util.h
src/object-enchant/apply-magic-amulet.cpp
src/object-enchant/apply-magic-amulet.h
src/object-enchant/apply-magic-armor.cpp
src/object-enchant/apply-magic-armor.h
src/object-enchant/apply-magic-boots.cpp
src/object-enchant/apply-magic-boots.h
src/object-enchant/apply-magic-cloak.cpp
src/object-enchant/apply-magic-cloak.h
src/object-enchant/apply-magic-crown.cpp
src/object-enchant/apply-magic-crown.h
src/object-enchant/apply-magic-gloves.cpp
src/object-enchant/apply-magic-gloves.h
src/object-enchant/apply-magic-helm.cpp
src/object-enchant/apply-magic-helm.h
src/object-enchant/apply-magic-others.cpp
src/object-enchant/apply-magic-others.h
src/object-enchant/apply-magic-ring.cpp
src/object-enchant/apply-magic-ring.h
src/object-enchant/apply-magic-shield.cpp
src/object-enchant/apply-magic-shield.h
src/object-enchant/apply-magic-weapon.cpp
src/object-enchant/apply-magic-weapon.h
src/object-enchant/apply-magic.cpp
src/object-enchant/apply-magic.h
src/object-enchant/enchanter-base.h
src/object-enchant/object-curse.cpp
src/object-enchant/object-curse.h
src/object-enchant/object-ego.h
src/object-enchant/object-smith.cpp
src/object-enchant/object-smith.h
src/object-enchant/smith-info.cpp
src/object-enchant/smith-info.h
src/object-enchant/vorpal-weapon.cpp
src/object-enchant/vorpal-weapon.h
src/object-hook/hook-armor.cpp
src/object-hook/hook-armor.h
src/object-hook/hook-expendable.cpp
src/object-hook/hook-expendable.h
src/object-hook/hook-magic.cpp
src/object-hook/hook-magic.h
src/object-hook/hook-quest.cpp
src/object-hook/hook-quest.h
src/object-hook/hook-weapon.cpp
src/object-hook/hook-weapon.h
src/object-use/item-use-checker.cpp
src/object-use/item-use-checker.h
src/object-use/quaff-execution.cpp
src/object-use/quaff-execution.h
src/object-use/read-execution.cpp
src/object-use/read-execution.h
src/object-use/throw-execution.cpp
src/object-use/throw-execution.h
src/object-use/use-execution.cpp
src/object-use/use-execution.h
src/object-use/zaprod-execution.cpp
src/object-use/zaprod-execution.h
src/object-use/zapwand-execution.cpp
src/object-use/zapwand-execution.h
src/object/item-tester-hooker.cpp
src/object/item-tester-hooker.h
src/object/lite-processor.cpp
src/object/lite-processor.h
src/object/object-broken.cpp
src/object/object-broken.h
src/object/object-info.cpp
src/object/object-info.h
src/object/object-value-calc.h
src/object/object-value.h
src/object/warning.cpp
src/object/warning.h
src/perception/identification.cpp
src/perception/identification.h
src/perception/object-perception.cpp
src/perception/object-perception.h
src/perception/simple-perception.cpp
src/perception/simple-perception.h
src/pet/pet-fall-off.cpp
src/pet/pet-fall-off.h
src/pet/pet-util.cpp
src/pet/pet-util.h
src/player-ability/player-charisma.cpp
src/player-ability/player-charisma.h
src/player-ability/player-constitution.cpp
src/player-ability/player-constitution.h
src/player-ability/player-dexterity.cpp
src/player-ability/player-dexterity.h
src/player-ability/player-intelligence.cpp
src/player-ability/player-intelligence.h
src/player-ability/player-strength.cpp
src/player-ability/player-strength.h
src/player-ability/player-wisdom.cpp
src/player-ability/player-wisdom.h
src/player-attack/attack-chaos-effect.cpp
src/player-attack/attack-chaos-effect.h
src/player-attack/blood-sucking-processor.cpp
src/player-attack/blood-sucking-processor.h
src/player-attack/player-attack.cpp
src/player-attack/player-attack.h
src/player-base/player-class.cpp
src/player-base/player-class.h
src/player-base/player-race.cpp
src/player-base/player-race.h
src/player-info/alignment.cpp
src/player-info/alignment.h
src/player-info/base-status-info.cpp
src/player-info/base-status-info.h
src/player-info/body-improvement-info.cpp
src/player-info/body-improvement-info.h
src/player-info/class-ability-info.cpp
src/player-info/class-ability-info.h
src/player-info/equipment-info.cpp
src/player-info/equipment-info.h
src/player-info/mutation-info.cpp
src/player-info/mutation-info.h
src/player-info/race-ability-info.cpp
src/player-info/race-ability-info.h
src/player-info/race-info.cpp
src/player-info/race-info.h
src/player-info/resistance-info.cpp
src/player-info/resistance-info.h
src/player-info/self-info.cpp
src/player-info/self-info.h
src/player-info/weapon-effect-info.cpp
src/player-info/weapon-effect-info.h
src/player-status/player-basic-statistics.cpp
src/player-status/player-basic-statistics.h
src/player-status/player-energy.cpp
src/player-status/player-energy.h
src/player-status/player-infravision.cpp
src/player-status/player-infravision.h
src/player-status/player-speed.cpp
src/player-status/player-speed.h
src/player-status/player-status-base.cpp
src/player-status/player-status-base.h
src/player-status/player-stealth.cpp
src/player-status/player-stealth.h
src/player/digestion-processor.cpp
src/player/digestion-processor.h
src/player/eldritch-horror.cpp
src/player/eldritch-horror.h
src/player/patron.cpp
src/player/patron.h
src/player/permanent-resistances.cpp
src/player/permanent-resistances.h
src/player/player-damage.cpp
src/player/player-damage.h
src/player/player-move.cpp
src/player/player-move.h
src/player/player-realm.cpp
src/player/player-realm.h
src/player/player-skill.cpp
src/player/player-skill.h
src/player/player-status-flags.cpp
src/player/player-status-flags.h
src/player/player-status-resist.cpp
src/player/player-status-resist.h
src/player/player-status.cpp
src/player/player-status.h
src/player/player-view.cpp
src/player/player-view.h
src/player/process-death.cpp
src/player/process-death.h
src/player/process-name.cpp
src/player/process-name.h
src/player/race-resistances.cpp
src/player/race-resistances.h
src/player/temporary-resistances.cpp
src/player/temporary-resistances.h
src/racial/class-racial-switcher.cpp
src/racial/class-racial-switcher.h
src/racial/mutation-racial-selector.cpp
src/racial/mutation-racial-selector.h
src/racial/race-racial-command-setter.cpp
src/racial/race-racial-command-setter.h
src/racial/racial-android.cpp
src/racial/racial-android.h
src/racial/racial-balrog.cpp
src/racial/racial-balrog.h
src/racial/racial-draconian.cpp
src/racial/racial-draconian.h
src/racial/racial-kutar.cpp
src/racial/racial-kutar.h
src/racial/racial-switcher.cpp
src/racial/racial-switcher.h
src/racial/racial-util.cpp
src/racial/racial-util.h
src/racial/racial-vampire.cpp
src/racial/racial-vampire.h
src/realm/realm-arcane.cpp
src/realm/realm-arcane.h
src/realm/realm-chaos.cpp
src/realm/realm-chaos.h
src/realm/realm-craft.cpp
src/realm/realm-craft.h
src/realm/realm-crusade.cpp
src/realm/realm-crusade.h
src/realm/realm-death.cpp
src/realm/realm-death.h
src/realm/realm-demon.cpp
src/realm/realm-demon.h
src/realm/realm-hex.cpp
src/realm/realm-hex.h
src/realm/realm-hissatsu.cpp
src/realm/realm-hissatsu.h
src/realm/realm-life.cpp
src/realm/realm-life.h
src/realm/realm-nature.cpp
src/realm/realm-nature.h
src/realm/realm-song.cpp
src/realm/realm-song.h
src/realm/realm-sorcery.cpp
src/realm/realm-sorcery.h
src/realm/realm-trump.cpp
src/realm/realm-trump.h
src/room/cave-filler.cpp
src/room/cave-filler.h
src/room/room-generator.cpp
src/room/room-generator.h
src/room/rooms-builder.cpp
src/room/rooms-builder.h
src/room/rooms-city.cpp
src/room/rooms-city.h
src/room/rooms-fractal.cpp
src/room/rooms-fractal.h
src/room/rooms-maze-vault.cpp
src/room/rooms-maze-vault.h
src/room/rooms-normal.cpp
src/room/rooms-normal.h
src/room/rooms-pit-nest.cpp
src/room/rooms-pit-nest.h
src/room/rooms-special.cpp
src/room/rooms-special.h
src/room/rooms-trap.cpp
src/room/rooms-trap.h
src/room/rooms-vault.cpp
src/room/rooms-vault.h
src/room/space-finder.cpp
src/room/space-finder.h
src/room/treasure-deployment.cpp
src/room/treasure-deployment.h
src/room/vault-builder.cpp
src/room/vault-builder.h
src/save/floor-writer.cpp
src/save/floor-writer.h
src/save/player-writer.cpp
src/save/player-writer.h
src/save/save.cpp
src/save/save.h
src/specific-object/blade-turner.cpp
src/specific-object/blade-turner.h
src/specific-object/bloody-moon.cpp
src/specific-object/bloody-moon.h
src/specific-object/chest.cpp
src/specific-object/chest.h
src/specific-object/death-crimson.cpp
src/specific-object/death-crimson.h
src/specific-object/death-scythe.cpp
src/specific-object/death-scythe.h
src/specific-object/monster-ball.cpp
src/specific-object/monster-ball.h
src/specific-object/muramasa.cpp
src/specific-object/muramasa.h
src/specific-object/ring-of-power.cpp
src/specific-object/ring-of-power.h
src/specific-object/stone-of-lore.cpp
src/specific-object/stone-of-lore.h
src/specific-object/toragoroshi.cpp
src/specific-object/toragoroshi.h
src/specific-object/torch.cpp
src/specific-object/torch.h
src/spell-kind/blood-curse.cpp
src/spell-kind/blood-curse.h
src/spell-kind/earthquake.cpp
src/spell-kind/earthquake.h
src/spell-kind/magic-item-recharger.cpp
src/spell-kind/magic-item-recharger.h
src/spell-kind/spells-beam.cpp
src/spell-kind/spells-beam.h
src/spell-kind/spells-charm.cpp
src/spell-kind/spells-charm.h
src/spell-kind/spells-curse-removal.cpp
src/spell-kind/spells-curse-removal.h
src/spell-kind/spells-detection.cpp
src/spell-kind/spells-detection.h
src/spell-kind/spells-enchant.cpp
src/spell-kind/spells-enchant.h
src/spell-kind/spells-equipment.cpp
src/spell-kind/spells-equipment.h
src/spell-kind/spells-fetcher.cpp
src/spell-kind/spells-fetcher.h
src/spell-kind/spells-floor.cpp
src/spell-kind/spells-floor.h
src/spell-kind/spells-genocide.cpp
src/spell-kind/spells-genocide.h
src/spell-kind/spells-grid.cpp
src/spell-kind/spells-grid.h
src/spell-kind/spells-launcher.cpp
src/spell-kind/spells-launcher.h
src/spell-kind/spells-lite.cpp
src/spell-kind/spells-lite.h
src/spell-kind/spells-neighbor.cpp
src/spell-kind/spells-neighbor.h
src/spell-kind/spells-perception.cpp
src/spell-kind/spells-perception.h
src/spell-kind/spells-pet.cpp
src/spell-kind/spells-pet.h
src/spell-kind/spells-polymorph.cpp
src/spell-kind/spells-polymorph.h
src/spell-kind/spells-random.cpp
src/spell-kind/spells-random.h
src/spell-kind/spells-sight.cpp
src/spell-kind/spells-sight.h
src/spell-kind/spells-specific-bolt.cpp
src/spell-kind/spells-specific-bolt.h
src/spell-kind/spells-teleport.cpp
src/spell-kind/spells-teleport.h
src/spell-kind/spells-world.cpp
src/spell-kind/spells-world.h
src/spell-realm/spells-arcane.cpp
src/spell-realm/spells-arcane.h
src/spell-realm/spells-chaos.cpp
src/spell-realm/spells-chaos.h
src/spell-realm/spells-craft.cpp
src/spell-realm/spells-craft.h
src/spell-realm/spells-crusade.cpp
src/spell-realm/spells-crusade.h
src/spell-realm/spells-demon.cpp
src/spell-realm/spells-demon.h
src/spell-realm/spells-hex.cpp
src/spell-realm/spells-hex.h
src/spell-realm/spells-nature.cpp
src/spell-realm/spells-nature.h
src/spell-realm/spells-song.cpp
src/spell-realm/spells-song.h
src/spell-realm/spells-sorcery.cpp
src/spell-realm/spells-sorcery.h
src/spell-realm/spells-trump.cpp
src/spell-realm/spells-trump.h
src/spell/range-calc.cpp
src/spell/range-calc.h
src/spell/spell-info.cpp
src/spell/spell-info.h
src/spell/spells-diceroll.cpp
src/spell/spells-diceroll.h
src/spell/spells-execution.cpp
src/spell/spells-execution.h
src/spell/spells-object.cpp
src/spell/spells-object.h
src/spell/spells-staff-only.cpp
src/spell/spells-staff-only.h
src/spell/spells-status.cpp
src/spell/spells-status.h
src/spell/spells-summon.cpp
src/spell/spells-summon.h
src/status/action-setter.cpp
src/status/action-setter.h
src/status/bad-status-setter.cpp
src/status/bad-status-setter.h
src/status/base-status.cpp
src/status/base-status.h
src/status/body-improvement.cpp
src/status/body-improvement.h
src/status/buff-setter.cpp
src/status/buff-setter.h
src/status/element-resistance.cpp
src/status/element-resistance.h
src/status/experience.cpp
src/status/experience.h
src/status/shape-changer.cpp
src/status/shape-changer.h
src/status/sight-setter.cpp
src/status/sight-setter.h
src/status/temporary-resistance.cpp
src/status/temporary-resistance.h
src/store/black-market.cpp
src/store/black-market.h
src/store/cmd-store.cpp
src/store/cmd-store.h
src/store/home.cpp
src/store/home.h
src/store/museum.cpp
src/store/museum.h
src/store/pricing.cpp
src/store/pricing.h
src/store/purchase-order.cpp
src/store/purchase-order.h
src/store/rumor.cpp
src/store/rumor.h
src/store/say-comments.cpp
src/store/say-comments.h
src/store/sell-order.cpp
src/store/sell-order.h
src/store/service-checker.cpp
src/store/service-checker.h
src/store/store-key-processor.cpp
src/store/store-key-processor.h
src/store/store-util.cpp
src/store/store-util.h
src/store/store.cpp
src/store/store.h
src/system/object-type-definition.h
src/system/player-type-definition.cpp
src/system/player-type-definition.h
src/target/grid-selector.cpp
src/target/grid-selector.h
src/target/projection-path-calculator.cpp
src/target/projection-path-calculator.h
src/target/target-checker.cpp
src/target/target-checker.h
src/target/target-describer.cpp
src/target/target-describer.h
src/target/target-getter.cpp
src/target/target-getter.h
src/target/target-preparation.cpp
src/target/target-preparation.h
src/target/target-setter.cpp
src/target/target-setter.h
src/util/object-sort.cpp
src/util/object-sort.h
src/util/sort.cpp
src/util/sort.h
src/view/display-birth.cpp
src/view/display-birth.h
src/view/display-characteristic.cpp
src/view/display-characteristic.h
src/view/display-inventory.cpp
src/view/display-inventory.h
src/view/display-lore.cpp
src/view/display-lore.h
src/view/display-map.cpp
src/view/display-map.h
src/view/display-messages.cpp
src/view/display-player-middle.cpp
src/view/display-player-middle.h
src/view/display-player-misc-info.cpp
src/view/display-player-misc-info.h
src/view/display-player-stat-info.cpp
src/view/display-player-stat-info.h
src/view/display-player.cpp
src/view/display-player.h
src/view/display-self-info.cpp
src/view/display-self-info.h
src/view/display-store.cpp
src/view/display-store.h
src/view/object-describer.cpp
src/view/object-describer.h
src/view/status-first-page.cpp
src/view/status-first-page.h
src/window/display-sub-window-spells.cpp
src/window/display-sub-window-spells.h
src/window/display-sub-windows.cpp
src/window/display-sub-windows.h
src/window/main-window-equipments.cpp
src/window/main-window-equipments.h
src/window/main-window-left-frame.cpp
src/window/main-window-left-frame.h
src/window/main-window-stat-poster.cpp
src/window/main-window-stat-poster.h
src/window/main-window-util.cpp
src/window/main-window-util.h
src/wizard/artifact-analyzer.cpp
src/wizard/artifact-analyzer.h
src/wizard/cmd-wizard.cpp
src/wizard/cmd-wizard.h
src/wizard/fixed-artifacts-spoiler.cpp
src/wizard/items-spoiler.cpp
src/wizard/monster-info-spoiler.cpp
src/wizard/wizard-game-modifier.cpp
src/wizard/wizard-game-modifier.h
src/wizard/wizard-item-modifier.cpp
src/wizard/wizard-item-modifier.h
src/wizard/wizard-messages.cpp
src/wizard/wizard-messages.h
src/wizard/wizard-player-modifier.cpp
src/wizard/wizard-player-modifier.h
src/wizard/wizard-special-process.cpp
src/wizard/wizard-special-process.h
src/wizard/wizard-spells.cpp
src/wizard/wizard-spells.h
src/wizard/wizard-spoiler.cpp
src/world/world-movement-processor.cpp
src/world/world-movement-processor.h
src/world/world-object.cpp
src/world/world-object.h
src/world/world-turn-processor.cpp
src/world/world-turn-processor.h
src/world/world.cpp
src/world/world.h

index 0cb5dd9..38fc9c4 100644 (file)
@@ -22,7 +22,7 @@
  * @brief 魔法系コマンドが制限されているかを返す。
  * @return 魔法系コマンドを使用可能ならFALSE、不可能ならば理由をメッセージ表示してTRUEを返す。
  */
-bool cmd_limit_cast(player_type *player_ptr)
+bool cmd_limit_cast(PlayerType *player_ptr)
 {
     if (is_in_dungeon(player_ptr) && (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::NO_MAGIC))) {
         msg_print(_("ダンジョンが魔法を吸収した!", "The dungeon absorbs all attempted magic!"));
@@ -43,7 +43,7 @@ bool cmd_limit_cast(player_type *player_ptr)
     return false;
 }
 
-bool cmd_limit_confused(player_type *player_ptr)
+bool cmd_limit_confused(PlayerType *player_ptr)
 {
     if (player_ptr->confused) {
         msg_print(_("混乱していてできない!", "You are too confused!"));
@@ -53,7 +53,7 @@ bool cmd_limit_confused(player_type *player_ptr)
     return false;
 }
 
-bool cmd_limit_image(player_type *player_ptr)
+bool cmd_limit_image(PlayerType *player_ptr)
 {
     if (player_ptr->hallucinated) {
         msg_print(_("幻覚が見えて集中できない!", "Your hallucinations prevent you from concentrating!"));
@@ -63,7 +63,7 @@ bool cmd_limit_image(player_type *player_ptr)
     return false;
 }
 
-bool cmd_limit_stun(player_type *player_ptr)
+bool cmd_limit_stun(PlayerType *player_ptr)
 {
     if (player_ptr->effects()->stun()->is_stunned()) {
         msg_print(_("頭が朦朧としていて集中できない!", "You are too stunned!"));
@@ -73,7 +73,7 @@ bool cmd_limit_stun(player_type *player_ptr)
     return false;
 }
 
-bool cmd_limit_arena(player_type *player_ptr)
+bool cmd_limit_arena(PlayerType *player_ptr)
 {
     if (player_ptr->current_floor_ptr->inside_arena) {
         msg_print(_("アリーナが魔法を吸収した!", "The arena absorbs all attempted magic!"));
@@ -84,7 +84,7 @@ bool cmd_limit_arena(player_type *player_ptr)
     return false;
 }
 
-bool cmd_limit_blind(player_type *player_ptr)
+bool cmd_limit_blind(PlayerType *player_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("目が見えない。", "You can't see anything."));
@@ -99,7 +99,7 @@ bool cmd_limit_blind(player_type *player_ptr)
     return false;
 }
 
-bool cmd_limit_time_walk(player_type *player_ptr)
+bool cmd_limit_time_walk(PlayerType *player_ptr)
 {
     if (player_ptr->timewalk) {
         if (flush_failure)
index 8dc9705..9fcb309 100644 (file)
@@ -4,11 +4,11 @@
  * @brief プレイヤーの行動制約判定ヘッダ
  */
 
-struct player_type;
-bool cmd_limit_cast(player_type *player_ptr);
-bool cmd_limit_arena(player_type *player_ptr);
-bool cmd_limit_time_walk(player_type *player_ptr);
-bool cmd_limit_blind(player_type *player_ptr);
-bool cmd_limit_confused(player_type *player_ptr);
-bool cmd_limit_image(player_type *player_ptr);
-bool cmd_limit_stun(player_type *player_ptr);
+class PlayerType;
+bool cmd_limit_cast(PlayerType *player_ptr);
+bool cmd_limit_arena(PlayerType *player_ptr);
+bool cmd_limit_time_walk(PlayerType *player_ptr);
+bool cmd_limit_blind(PlayerType *player_ptr);
+bool cmd_limit_confused(PlayerType *player_ptr);
+bool cmd_limit_image(PlayerType *player_ptr);
+bool cmd_limit_stun(PlayerType *player_ptr);
index 3a4146b..3565d1d 100644 (file)
@@ -67,7 +67,7 @@ static void decide_activation_level(ae_type *ae_ptr)
         ae_ptr->lev = e_info[ae_ptr->o_ptr->name2].level;
 }
 
-static void decide_chance_fail(player_type *player_ptr, ae_type *ae_ptr)
+static void decide_chance_fail(PlayerType *player_ptr, ae_type *ae_ptr)
 {
     ae_ptr->chance = player_ptr->skill_dev;
     if (player_ptr->confused)
@@ -86,7 +86,7 @@ static void decide_chance_fail(player_type *player_ptr, ae_type *ae_ptr)
         ae_ptr->chance = USE_DEVICE;
 }
 
-static void decide_activation_success(player_type *player_ptr, ae_type *ae_ptr)
+static void decide_activation_success(PlayerType *player_ptr, ae_type *ae_ptr)
 {
     if (player_ptr->pclass == PlayerClassType::BERSERKER) {
         ae_ptr->success = false;
@@ -114,7 +114,7 @@ static bool check_activation_success(ae_type *ae_ptr)
     return false;
 }
 
-static bool check_activation_conditions(player_type *player_ptr, ae_type *ae_ptr)
+static bool check_activation_conditions(PlayerType *player_ptr, ae_type *ae_ptr)
 {
     if (!check_activation_success(ae_ptr))
         return false;
@@ -139,7 +139,7 @@ static bool check_activation_conditions(player_type *player_ptr, ae_type *ae_ptr
  * @param o_ptr 対象のオブジェクト構造体ポインタ
  * @return 発動実行の是非を返す。
  */
-static bool activate_artifact(player_type *player_ptr, object_type *o_ptr)
+static bool activate_artifact(PlayerType *player_ptr, object_type *o_ptr)
 {
     concptr name = k_info[o_ptr->k_idx].name.c_str();
     auto tmp_act_ptr = find_activation_info(o_ptr);
@@ -179,7 +179,7 @@ static bool activate_artifact(player_type *player_ptr, object_type *o_ptr)
     }
 }
 
-static bool activate_whistle(player_type *player_ptr, ae_type *ae_ptr)
+static bool activate_whistle(PlayerType *player_ptr, ae_type *ae_ptr)
 {
     if (ae_ptr->o_ptr->tval != ItemKindType::WHISTLE)
         return false;
@@ -219,7 +219,7 @@ static bool activate_whistle(player_type *player_ptr, ae_type *ae_ptr)
  * the user hits "escape" at the "direction" prompt.
  * </pre>
  */
-void exe_activate(player_type *player_ptr, INVENTORY_IDX item)
+void exe_activate(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     PlayerEnergy(player_ptr).set_player_turn_energy(100);
     ae_type tmp_ae;
index 7855adf..f2ae6a9 100644 (file)
@@ -6,5 +6,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void exe_activate(player_type *player_ptr, INVENTORY_IDX item);
+class PlayerType;
+void exe_activate(PlayerType *player_ptr, INVENTORY_IDX item);
index ce6c5ca..a826d13 100644 (file)
@@ -79,7 +79,7 @@ static bool boundary_floor(grid_type *g_ptr, feature_type *f_ptr, feature_type *
  * any monster which might be in the destination grid.  Previously,\n
  * moving into walls was "free" and did NOT hit invisible monsters.\n
  */
-void exe_movement(player_type *player_ptr, DIRECTION dir, bool do_pickup, bool break_trap)
+void exe_movement(PlayerType *player_ptr, DIRECTION dir, bool do_pickup, bool break_trap)
 {
     POSITION y = player_ptr->y + ddy[dir];
     POSITION x = player_ptr->x + ddx[dir];
index aaf3308..084022d 100644 (file)
@@ -6,5 +6,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void exe_movement(player_type *player_ptr, DIRECTION dir, bool do_pickup, bool break_trap);
+class PlayerType;
+void exe_movement(PlayerType *player_ptr, DIRECTION dir, bool do_pickup, bool break_trap);
index 5d0b763..542c688 100644 (file)
@@ -61,7 +61,7 @@
  * @param power 発動させる突然変異レイシャルのID
  * @return レイシャルを実行した場合TRUE、キャンセルした場合FALSEを返す
  */
-bool exe_mutation_power(player_type *player_ptr, PlayerMutationType power)
+bool exe_mutation_power(PlayerType *player_ptr, PlayerMutationType power)
 {
     DIRECTION dir = 0;
     PLAYER_LEVEL lvl = player_ptr->lev;
index 28ca648..55400a4 100644 (file)
@@ -5,5 +5,5 @@
  */
 
 enum class PlayerMutationType;
-struct player_type;
-bool exe_mutation_power(player_type *player_ptr, PlayerMutationType power);
+class PlayerType;
+bool exe_mutation_power(PlayerType *player_ptr, PlayerMutationType power);
index 19b9ae2..514193b 100644 (file)
@@ -36,7 +36,7 @@
  * @param x 対象を行うマスのX座標
  * @return 連続でコマンドを実行する時のみTRUE、1回きりの時はFALSE
  */
-bool exe_open(player_type *player_ptr, POSITION y, POSITION x)
+bool exe_open(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     feature_type *f_ptr = &f_info[g_ptr->feat];
@@ -91,7 +91,7 @@ bool exe_open(player_type *player_ptr, POSITION y, POSITION x)
  * Returns TRUE if repeated commands may continue
  * @todo 常にFALSEを返している
  */
-bool exe_close(player_type *player_ptr, POSITION y, POSITION x)
+bool exe_close(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     FEAT_IDX old_feat = g_ptr->feat;
@@ -130,7 +130,7 @@ bool exe_close(player_type *player_ptr, POSITION y, POSITION x)
  *     do_cmd_open_test() and exe_open().
  * </pre>
  */
-bool easy_open_door(player_type *player_ptr, POSITION y, POSITION x)
+bool easy_open_door(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     int i, j;
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
@@ -186,7 +186,7 @@ bool easy_open_door(player_type *player_ptr, POSITION y, POSITION x)
  * Returns TRUE if repeated commands may continue
  * </pre>
  */
-bool exe_disarm_chest(player_type *player_ptr, POSITION y, POSITION x, OBJECT_IDX o_idx)
+bool exe_disarm_chest(PlayerType *player_ptr, POSITION y, POSITION x, OBJECT_IDX o_idx)
 {
     bool more = false;
     object_type *o_ptr = &player_ptr->current_floor_ptr->o_list[o_idx];
@@ -242,7 +242,7 @@ bool exe_disarm_chest(player_type *player_ptr, POSITION y, POSITION x, OBJECT_ID
  * </pre>
  */
 
-bool exe_disarm(player_type *player_ptr, POSITION y, POSITION x, DIRECTION dir)
+bool exe_disarm(PlayerType *player_ptr, POSITION y, POSITION x, DIRECTION dir)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     feature_type *f_ptr = &f_info[g_ptr->feat];
@@ -294,7 +294,7 @@ bool exe_disarm(player_type *player_ptr, POSITION y, POSITION x, DIRECTION dir)
  * Returns TRUE if repeated commands may continue
  * </pre>
  */
-bool exe_bash(player_type *player_ptr, POSITION y, POSITION x, DIRECTION dir)
+bool exe_bash(PlayerType *player_ptr, POSITION y, POSITION x, DIRECTION dir)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     feature_type *f_ptr = &f_info[g_ptr->feat];
index aa0e455..7911f61 100644 (file)
@@ -6,10 +6,10 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool exe_open(player_type *player_ptr, POSITION y, POSITION x);
-bool exe_close(player_type *player_ptr, POSITION y, POSITION x);
-bool easy_open_door(player_type *player_ptr, POSITION y, POSITION x);
-bool exe_disarm(player_type *player_ptr, POSITION y, POSITION x, DIRECTION dir);
-bool exe_disarm_chest(player_type *player_ptr, POSITION y, POSITION x, OBJECT_IDX o_idx);
-bool exe_bash(player_type *player_ptr, POSITION y, POSITION x, DIRECTION dir);
+class PlayerType;
+bool exe_open(PlayerType *player_ptr, POSITION y, POSITION x);
+bool exe_close(PlayerType *player_ptr, POSITION y, POSITION x);
+bool easy_open_door(PlayerType *player_ptr, POSITION y, POSITION x);
+bool exe_disarm(PlayerType *player_ptr, POSITION y, POSITION x, DIRECTION dir);
+bool exe_disarm_chest(PlayerType *player_ptr, POSITION y, POSITION x, OBJECT_IDX o_idx);
+bool exe_bash(PlayerType *player_ptr, POSITION y, POSITION x, DIRECTION dir);
index 08d7c5d..68f92bb 100644 (file)
@@ -44,7 +44,7 @@ OBJECT_IDX chest_check(floor_type *floor_ptr, POSITION y, POSITION x, bool trapp
  * @details
  * If requested, count only trapped chests.
  */
-int count_chests(player_type *player_ptr, POSITION *y, POSITION *x, bool trapped)
+int count_chests(PlayerType *player_ptr, POSITION *y, POSITION *x, bool trapped)
 {
     int count = 0;
     for (DIRECTION d = 0; d < 9; d++) {
index 5b06239..cc6adf3 100644 (file)
@@ -7,6 +7,6 @@
 #include "system/angband.h"
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 OBJECT_IDX chest_check(floor_type *floor_ptr, POSITION y, POSITION x, bool trapped);
-int count_chests(player_type *player_ptr, POSITION *y, POSITION *x, bool trapped);
+int count_chests(PlayerType *player_ptr, POSITION *y, POSITION *x, bool trapped);
index ea44551..a8aa919 100644 (file)
@@ -25,7 +25,7 @@
  * @param command 発動するレイシャルのID
  * @return 処理を実際に実行した場合はTRUE、キャンセルした場合FALSEを返す。
  */
-bool exe_racial_power(player_type *player_ptr, const int32_t command)
+bool exe_racial_power(PlayerType *player_ptr, const int32_t command)
 {
     if (command <= -3)
         return switch_class_racial_execution(player_ptr, command);
@@ -41,7 +41,7 @@ bool exe_racial_power(player_type *player_ptr, const int32_t command)
  * @param rpi_ptr 発動したいレイシャル・パワー情報の構造体参照ポインタ
  * @return 成功率(%)を返す
  */
-PERCENTAGE racial_chance(player_type *player_ptr, rpi_type *rpi_ptr)
+PERCENTAGE racial_chance(PlayerType *player_ptr, rpi_type *rpi_ptr)
 {
     if ((player_ptr->lev < rpi_ptr->min_level) || player_ptr->confused)
         return 0;
@@ -86,7 +86,7 @@ PERCENTAGE racial_chance(player_type *player_ptr, rpi_type *rpi_ptr)
         return ((sum * 100) / difficulty) / stat;
 }
 
-static void adjust_racial_power_difficulty(player_type *player_ptr, rpi_type *rpi_ptr, int *difficulty)
+static void adjust_racial_power_difficulty(PlayerType *player_ptr, rpi_type *rpi_ptr, int *difficulty)
 {
     if (*difficulty == 0)
         return;
@@ -110,7 +110,7 @@ static void adjust_racial_power_difficulty(player_type *player_ptr, rpi_type *rp
  * @param rpi_ptr 発動したいレイシャル・パワー情報の構造体参照ポインタ
  * @return racial_level_check_result
  */
-racial_level_check_result check_racial_level(player_type *player_ptr, rpi_type *rpi_ptr)
+racial_level_check_result check_racial_level(PlayerType *player_ptr, rpi_type *rpi_ptr)
 {
     PLAYER_LEVEL min_level = rpi_ptr->min_level;
     int use_stat = rpi_ptr->stat;
index 8eff878..a3ba0f7 100644 (file)
@@ -13,7 +13,7 @@ enum racial_level_check_result {
 };
 
 struct rpi_type;
-struct player_type;
-PERCENTAGE racial_chance(player_type *player_ptr, rpi_type *rpi_ptr);
-racial_level_check_result check_racial_level(player_type *player_ptr, rpi_type *rpi_ptr);
-bool exe_racial_power(player_type *player_ptr, const int32_t command);
+class PlayerType;
+PERCENTAGE racial_chance(PlayerType *player_ptr, rpi_type *rpi_ptr);
+racial_level_check_result check_racial_level(PlayerType *player_ptr, rpi_type *rpi_ptr);
+bool exe_racial_power(PlayerType *player_ptr, const int32_t command);
index 77b871f..44d6d49 100644 (file)
@@ -55,7 +55,7 @@ static bool find_breakleft;
  * @param x 移動元のX座標
  * @return 移動先が既知の壁ならばTRUE
  */
-static bool see_wall(player_type *player_ptr, DIRECTION dir, POSITION y, POSITION x)
+static bool see_wall(PlayerType *player_ptr, DIRECTION dir, POSITION y, POSITION x)
 {
     y += ddy[dir];
     x += ddx[dir];
@@ -99,7 +99,7 @@ static bool see_wall(player_type *player_ptr, DIRECTION dir, POSITION y, POSITIO
  *       \#x\#                  \@x\#\n
  *       \@\@p.                  p\n
  */
-static void run_init(player_type *player_ptr, DIRECTION dir)
+static void run_init(PlayerType *player_ptr, DIRECTION dir)
 {
     find_current = dir;
     find_prevdir = dir;
@@ -164,7 +164,7 @@ static void run_init(player_type *player_ptr, DIRECTION dir)
  * @param x 移動元のX座標
  * @return 移動先が未知の地形ならばTRUE
  */
-static bool see_nothing(player_type *player_ptr, DIRECTION dir, POSITION y, POSITION x)
+static bool see_nothing(PlayerType *player_ptr, DIRECTION dir, POSITION y, POSITION x)
 {
     y += ddy[dir];
     x += ddx[dir];
@@ -190,7 +190,7 @@ static bool see_nothing(player_type *player_ptr, DIRECTION dir, POSITION y, POSI
  * ダッシュ移動が継続できるならばTRUEを返す。
  * Return TRUE if the running should be stopped
  */
-static bool run_test(player_type *player_ptr)
+static bool run_test(PlayerType *player_ptr)
 {
     DIRECTION prev_dir = find_prevdir;
     int max = (prev_dir & 0x01) + 1;
@@ -358,7 +358,7 @@ static bool run_test(player_type *player_ptr)
  * @param player_ptr   プレイヤーへの参照ポインタ
  * @param dir 移動を試みる方向ID
  */
-void run_step(player_type *player_ptr, DIRECTION dir)
+void run_step(PlayerType *player_ptr, DIRECTION dir)
 {
     if (dir) {
         ignore_avoid_run = true;
index c0c3f6d..f4f79a4 100644 (file)
@@ -13,5 +13,5 @@ extern bool ignore_avoid_run;
 extern byte cycle[MAX_RUN_CYCLES];
 extern byte chome[MAX_RUN_CHOME];
 
-struct player_type;
-void run_step(player_type *player_ptr, DIRECTION dir);
+class PlayerType;
+void run_step(PlayerType *player_ptr, DIRECTION dir);
index abb9d1b..9bfa523 100644 (file)
@@ -30,7 +30,7 @@ travel_type travel;
  * @param prev_dir 前回移動を行った元の方角ID
  * @return 次の方向
  */
-static DIRECTION travel_test(player_type *player_ptr, DIRECTION prev_dir)
+static DIRECTION travel_test(PlayerType *player_ptr, DIRECTION prev_dir)
 {
     if (player_ptr->blind || no_lite(player_ptr)) {
         msg_print(_("目が見えない!", "You cannot see!"));
@@ -91,7 +91,7 @@ static DIRECTION travel_test(player_type *player_ptr, DIRECTION prev_dir)
  * Travel command
  * @param player_ptr   プレイヤーへの参照ポインタ
  */
-void travel_step(player_type *player_ptr)
+void travel_step(PlayerType *player_ptr)
 {
     travel.dir = travel_test(player_ptr, travel.dir);
     if (!travel.dir) {
index 4b40c6a..863b13d 100644 (file)
@@ -19,6 +19,6 @@ typedef struct travel_type {
 extern travel_type travel;
 
 struct floor_type;
-struct player_type;
-void travel_step(player_type *player_ptr);
+class PlayerType;
+void travel_step(PlayerType *player_ptr);
 void forget_travel_flow(floor_type *floor_ptr);
index b713ee4..b9b5a4e 100644 (file)
@@ -53,7 +53,7 @@ static bool do_cmd_tunnel_test(floor_type *floor_ptr, POSITION y, POSITION x)
  * Do not use twall anymore
  * Returns TRUE if repeated commands may continue
  */
-bool exe_tunnel(player_type *player_ptr, POSITION y, POSITION x)
+bool exe_tunnel(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr;
     feature_type *f_ptr, *mimic_f_ptr;
index 7709f85..6ecc77e 100644 (file)
@@ -6,5 +6,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool exe_tunnel(player_type *player_ptr, POSITION y, POSITION x);
+class PlayerType;
+bool exe_tunnel(PlayerType *player_ptr, POSITION y, POSITION x);
index 05f3d04..4125fd8 100644 (file)
@@ -20,7 +20,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param item 持ち替えを行いたい装備部位ID
  */
-void verify_equip_slot(player_type *player_ptr, INVENTORY_IDX item)
+void verify_equip_slot(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     object_type *o_ptr, *new_o_ptr;
     GAME_TEXT o_name[MAX_NLEN];
index 0f287e4..7ee5fa3 100644 (file)
@@ -6,5 +6,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void verify_equip_slot(player_type *player_ptr, INVENTORY_IDX item);
+class PlayerType;
+void verify_equip_slot(PlayerType *player_ptr, INVENTORY_IDX item);
index 14e7467..4904193 100644 (file)
@@ -39,7 +39,7 @@
  * 純戦士系職業は追加能力/耐性がもらえる。
  * それ以外では、反感、太古の怨念、呪いが付き追加能力/耐性はもらえない。
  */
-static bool invest_terror_mask(player_type *player_ptr, object_type *o_ptr)
+static bool invest_terror_mask(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (o_ptr->name1 != ART_TERROR)
         return false;
@@ -64,7 +64,7 @@ static bool invest_terror_mask(player_type *player_ptr, object_type *o_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param o_ptr 対象のオブジェクト構造体への参照ポインタ
  */
-static void milim_swimsuit(player_type *player_ptr, object_type *o_ptr)
+static void milim_swimsuit(PlayerType *player_ptr, object_type *o_ptr)
 {
     if ((o_ptr->name1 != ART_MILIM) || (player_ptr->ppersonality != PERSONALITY_SEXY))
         return;
@@ -88,7 +88,7 @@ static void milim_swimsuit(player_type *player_ptr, object_type *o_ptr)
  * @details
  * 対象は村正、ロビントンのハープ、龍争虎鬪、ブラッディムーン、羽衣、天女の羽衣、ミリム
  */
-static void invest_special_artifact_abilities(player_type *player_ptr, object_type *o_ptr)
+static void invest_special_artifact_abilities(PlayerType *player_ptr, object_type *o_ptr)
 {
     switch (o_ptr->name1) {
     case ART_MURAMASA:
@@ -126,7 +126,7 @@ static void invest_special_artifact_abilities(player_type *player_ptr, object_ty
  * @param a_ptr 固定アーティファクト情報への参照ポインタ
  * @param q_ptr オブジェクト情報への参照ポインタ
  */
-static void fixed_artifact_random_abilities(player_type *player_ptr, artifact_type *a_ptr, object_type *o_ptr)
+static void fixed_artifact_random_abilities(PlayerType *player_ptr, artifact_type *a_ptr, object_type *o_ptr)
 {
     auto give_power = false;
     auto give_resistance = false;
@@ -203,7 +203,7 @@ static void invest_curse_to_fixed_artifact(artifact_type *a_ptr, object_type *o_
  * @param o_ptr 生成に割り当てたいオブジェクトの構造体参照ポインタ
  * @return 適用したアーティファクト情報への参照ポインタ
  */
-artifact_type *apply_artifact(player_type *player_ptr, object_type *o_ptr)
+artifact_type *apply_artifact(PlayerType *player_ptr, object_type *o_ptr)
 {
     auto a_ptr = &a_info[o_ptr->name1];
     o_ptr->pval = a_ptr->pval;
@@ -234,7 +234,7 @@ artifact_type *apply_artifact(player_type *player_ptr, object_type *o_ptr)
  * 仮に2個以上存在可能かつ装備品以外の固定アーティファクトが作成されれば
  * drop_near()関数の返り値は信用できなくなる.
  */
-bool create_named_art(player_type *player_ptr, ARTIFACT_IDX a_idx, POSITION y, POSITION x)
+bool create_named_art(PlayerType *player_ptr, ARTIFACT_IDX a_idx, POSITION y, POSITION x)
 {
     auto a_ptr = &a_info[a_idx];
     if (a_ptr->name.empty())
@@ -265,7 +265,7 @@ bool create_named_art(player_type *player_ptr, ARTIFACT_IDX a_idx, POSITION y, P
  * This routine should only be called by "apply_magic()"\n
  * Note -- see "make_artifact_special()" and "apply_magic()"\n
  */
-bool make_artifact(player_type *player_ptr, object_type *o_ptr)
+bool make_artifact(PlayerType *player_ptr, object_type *o_ptr)
 {
     auto floor_ptr = player_ptr->current_floor_ptr;
     if (floor_ptr->dun_level == 0)
@@ -321,7 +321,7 @@ bool make_artifact(player_type *player_ptr, object_type *o_ptr)
  *\n
  * Note -- see "make_artifact()" and "apply_magic()"\n
  */
-bool make_artifact_special(player_type *player_ptr, object_type *o_ptr)
+bool make_artifact_special(PlayerType *player_ptr, object_type *o_ptr)
 {
     KIND_OBJECT_IDX k_idx = 0;
 
index 0fa401c..b40ece6 100644 (file)
@@ -8,8 +8,8 @@
 
 typedef struct artifact_type artifact_type;
 struct object_type;
-struct player_type;
-bool create_named_art(player_type *player_ptr, ARTIFACT_IDX a_idx, POSITION y, POSITION x);
-bool make_artifact(player_type *player_ptr, object_type *o_ptr);
-artifact_type *apply_artifact(player_type *player_ptr, object_type *o_ptr);
-bool make_artifact_special(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool create_named_art(PlayerType *player_ptr, ARTIFACT_IDX a_idx, POSITION y, POSITION x);
+bool make_artifact(PlayerType *player_ptr, object_type *o_ptr);
+artifact_type *apply_artifact(PlayerType *player_ptr, object_type *o_ptr);
+bool make_artifact_special(PlayerType *player_ptr, object_type *o_ptr);
index 3a72677..f273eb2 100644 (file)
@@ -73,7 +73,7 @@ static void add_negative_flags(object_type *o_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param o_ptr 対象のオブジェクト構造体ポインタ
  */
-void curse_artifact(player_type *player_ptr, object_type *o_ptr)
+void curse_artifact(PlayerType *player_ptr, object_type *o_ptr)
 {
     pval_subtraction(o_ptr);
     o_ptr->curse_flags.set({ CurseTraitType::HEAVY_CURSE, CurseTraitType::CURSED });
@@ -144,7 +144,7 @@ void get_random_name(object_type *o_ptr, char *return_name, bool armour, int pow
 }
 
 /*対邪平均ダメージの計算処理*/
-static HIT_POINT calc_arm_avgdamage(player_type *player_ptr, object_type *o_ptr)
+static HIT_POINT calc_arm_avgdamage(PlayerType *player_ptr, object_type *o_ptr)
 {
     auto flgs = object_flags(o_ptr);
     HIT_POINT base, forced, vorpal;
@@ -172,7 +172,7 @@ static HIT_POINT calc_arm_avgdamage(player_type *player_ptr, object_type *o_ptr)
     return dam;
 }
 
-bool has_extreme_damage_rate(player_type *player_ptr, object_type *o_ptr)
+bool has_extreme_damage_rate(PlayerType *player_ptr, object_type *o_ptr)
 {
     auto flgs = object_flags(o_ptr);
     if (flgs.has(TR_VAMPIRIC)) {
index d09039a..6e7c27f 100644 (file)
@@ -5,7 +5,7 @@
  */
 
 struct object_type;
-struct player_type;
-void curse_artifact(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+void curse_artifact(PlayerType *player_ptr, object_type *o_ptr);
 void get_random_name(object_type *o_ptr, char *return_name, bool armour, int power);
-bool has_extreme_damage_rate(player_type *player_ptr, object_type *o_ptr);
+bool has_extreme_damage_rate(PlayerType *player_ptr, object_type *o_ptr);
index 6067cf0..dfa3c4a 100644 (file)
@@ -73,7 +73,7 @@ static bool weakening_artifact(object_type *o_ptr)
     return false;
 }
 
-static void set_artifact_bias(player_type *player_ptr, object_type *o_ptr, int *warrior_artifact_bias)
+static void set_artifact_bias(PlayerType *player_ptr, object_type *o_ptr, int *warrior_artifact_bias)
 {
     switch (player_ptr->pclass) {
     case PlayerClassType::WARRIOR:
@@ -153,7 +153,7 @@ static void set_artifact_bias(player_type *player_ptr, object_type *o_ptr, int *
     }
 }
 
-static void decide_warrior_bias(player_type *player_ptr, object_type *o_ptr, const bool a_scroll)
+static void decide_warrior_bias(PlayerType *player_ptr, object_type *o_ptr, const bool a_scroll)
 {
     int warrior_artifact_bias = 0;
     if (a_scroll && one_in_(4))
@@ -189,7 +189,7 @@ static int decide_random_art_power(const bool a_cursed)
     return powers;
 }
 
-static void invest_powers(player_type *player_ptr, object_type *o_ptr, int *powers, bool *has_pval, const bool a_cursed)
+static void invest_powers(PlayerType *player_ptr, object_type *o_ptr, int *powers, bool *has_pval, const bool a_cursed)
 {
     int max_type = o_ptr->is_weapon_ammo() ? 7 : 5;
     while ((*powers)--) {
@@ -349,7 +349,7 @@ static int decide_random_art_power_level(object_type *o_ptr, const bool a_cursed
     return 3;
 }
 
-static void name_unnatural_random_artifact(player_type *player_ptr, object_type *o_ptr, const bool a_scroll, const int power_level, GAME_TEXT *new_name)
+static void name_unnatural_random_artifact(PlayerType *player_ptr, object_type *o_ptr, const bool a_scroll, const int power_level, GAME_TEXT *new_name)
 {
     if (!a_scroll) {
         get_random_name(o_ptr, new_name, o_ptr->is_armour(), power_level);
@@ -377,7 +377,7 @@ static void name_unnatural_random_artifact(player_type *player_ptr, object_type
 }
 
 static void generate_unnatural_random_artifact(
-    player_type *player_ptr, object_type *o_ptr, const bool a_scroll, const int power_level, const int max_powers, const int total_flags)
+    PlayerType *player_ptr, object_type *o_ptr, const bool a_scroll, const int power_level, const int max_powers, const int total_flags)
 {
     GAME_TEXT new_name[1024];
     strcpy(new_name, "");
@@ -397,7 +397,7 @@ static void generate_unnatural_random_artifact(
  * @param a_scroll アーティファクト生成の巻物上の処理。呪いのアーティファクトが生成対象外となる。
  * @return 常にTRUE(1)を返す
  */
-bool become_random_artifact(player_type *player_ptr, object_type *o_ptr, bool a_scroll)
+bool become_random_artifact(PlayerType *player_ptr, object_type *o_ptr, bool a_scroll)
 {
     o_ptr->artifact_bias = 0;
     o_ptr->name1 = 0;
index b31f449..caef290 100644 (file)
@@ -5,5 +5,5 @@
  */
 
 struct object_type;
-struct player_type;
-bool become_random_artifact(player_type *player_ptr, object_type *o_ptr, bool a_scroll);
+class PlayerType;
+bool become_random_artifact(PlayerType *player_ptr, object_type *o_ptr, bool a_scroll);
index d604fea..7e5e34c 100644 (file)
@@ -246,7 +246,7 @@ static void invest_misc_weak_esps(object_type *o_ptr)
  * @attention オブジェクトのtval、svalに依存したハードコーディング処理がある。
  * @param o_ptr 対象のオブジェクト構造体ポインタ
  */
-void random_misc(player_type *player_ptr, object_type *o_ptr)
+void random_misc(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (switch_misc_bias(o_ptr))
         return;
index ca95f4b..7d3dbc6 100644 (file)
@@ -5,5 +5,5 @@
  */
 
 struct object_type;
-struct player_type;
-void random_misc(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+void random_misc(PlayerType *player_ptr, object_type *o_ptr);
index 3bebed2..35a85f1 100644 (file)
@@ -36,7 +36,7 @@
  * @param o_ptr アイテムへの参照ポインタ
  * @return 特別なクラス、かつそのクラス特有のアイテムであればFALSE、それ以外はTRUE
  */
-static bool is_leave_special_item(player_type *player_ptr, object_type *o_ptr)
+static bool is_leave_special_item(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (!leave_special)
         return true;
@@ -61,7 +61,7 @@ static bool is_leave_special_item(player_type *player_ptr, object_type *o_ptr)
 /*!
  * @brief Automatically destroy items in this grid.
  */
-static bool is_opt_confirm_destroy(player_type *player_ptr, object_type *o_ptr)
+static bool is_opt_confirm_destroy(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (!destroy_items)
         return false;
@@ -99,7 +99,7 @@ static bool is_opt_confirm_destroy(player_type *player_ptr, object_type *o_ptr)
     return true;
 }
 
-void auto_destroy_item(player_type *player_ptr, object_type *o_ptr, int autopick_idx)
+void auto_destroy_item(PlayerType *player_ptr, object_type *o_ptr, int autopick_idx)
 {
     bool destroy = false;
     if (is_opt_confirm_destroy(player_ptr, o_ptr))
index eb91871..da61ccd 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-void auto_destroy_item(player_type *player_ptr, object_type *o_ptr, int autopick_idx);
+class PlayerType;
+void auto_destroy_item(PlayerType *player_ptr, object_type *o_ptr, int autopick_idx);
index f9303df..0ebaf88 100644 (file)
@@ -17,7 +17,7 @@
 
 #define DESCRIPT_HGT 3
 
-static void process_dirty_expression(player_type *player_ptr, text_body_type *tb)
+static void process_dirty_expression(PlayerType *player_ptr, text_body_type *tb)
 {
     if ((tb->dirty_flags & DIRTY_EXPRESSION) == 0)
         return;
@@ -57,7 +57,7 @@ static void process_dirty_expression(player_type *player_ptr, text_body_type *tb
 /*!
  * @brief Draw text
  */
-void draw_text_editor(player_type *player_ptr, text_body_type *tb)
+void draw_text_editor(PlayerType *player_ptr, text_body_type *tb)
 {
     int by1 = 0, by2 = 0;
 
index 565c0ff..1dd4c8e 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct text_body_type;
-struct player_type;
-void draw_text_editor(player_type *player_ptr, text_body_type *tb);
+class PlayerType;
+void draw_text_editor(PlayerType *player_ptr, text_body_type *tb);
index 3fac8f6..819f9ad 100644 (file)
@@ -34,7 +34,7 @@
  * @return
  * @details Execute a single editor command
  */
-ape_quittance do_editor_command(player_type *player_ptr, text_body_type *tb, int com_id)
+ape_quittance do_editor_command(PlayerType *player_ptr, text_body_type *tb, int com_id)
 {
     switch (com_id) {
     case EC_QUIT: {
index f8732c8..6eac11e 100644 (file)
@@ -7,6 +7,6 @@ enum ape_quittance {
        APE_QUIT_AND_SAVE = 2
 };
 
-struct player_type;
+class PlayerType;
 struct text_body_type;
-ape_quittance do_editor_command(player_type *player_ptr, text_body_type *tb, int com_id);
+ape_quittance do_editor_command(PlayerType *player_ptr, text_body_type *tb, int com_id);
index c3d57e8..3150f7a 100644 (file)
@@ -285,7 +285,7 @@ bool autopick_new_entry(autopick_type *entry, concptr str, bool allow_default)
 /*!
  * @brief Get auto-picker entry from o_ptr.
  */
-void autopick_entry_from_object(player_type *player_ptr, autopick_type *entry, object_type *o_ptr)
+void autopick_entry_from_object(PlayerType *player_ptr, autopick_type *entry, object_type *o_ptr)
 {
     /* Assume that object name is to be added */
     bool name = true;
@@ -642,7 +642,7 @@ concptr autopick_line_from_entry_kill(autopick_type *entry)
 /*!
  * @brief Choose an item and get auto-picker entry from it.
  */
-bool entry_from_choosed_object(player_type *player_ptr, autopick_type *entry)
+bool entry_from_choosed_object(PlayerType *player_ptr, autopick_type *entry)
 {
     concptr q = _("どのアイテムを登録しますか? ", "Enter which item? ");
     concptr s = _("アイテムを持っていない。", "You have nothing to enter.");
index c32b5b9..b5b8a26 100644 (file)
@@ -4,9 +4,9 @@
 
 typedef struct autopick_type autopick_type;
 struct object_type;
-struct player_type;
+class PlayerType;
 bool autopick_new_entry(autopick_type *entry, concptr str, bool allow_default);
-void autopick_entry_from_object(player_type *player_ptr, autopick_type *entry, object_type *o_ptr);
+void autopick_entry_from_object(PlayerType *player_ptr, autopick_type *entry, object_type *o_ptr);
 concptr autopick_line_from_entry(autopick_type *entry);
 concptr autopick_line_from_entry_kill(autopick_type *entry);
-bool entry_from_choosed_object(player_type *player_ptr, autopick_type *entry);
+bool entry_from_choosed_object(PlayerType *player_ptr, autopick_type *entry);
index 937f463..3938240 100644 (file)
@@ -33,7 +33,7 @@
  * A function for Auto-picker/destroyer
  * Examine whether the object matches to the list of keywords or not.
  */
-int find_autopick_list(player_type *player_ptr, object_type *o_ptr)
+int find_autopick_list(PlayerType *player_ptr, object_type *o_ptr)
 {
     GAME_TEXT o_name[MAX_NLEN];
     if (o_ptr->tval == ItemKindType::GOLD)
@@ -53,7 +53,7 @@ int find_autopick_list(player_type *player_ptr, object_type *o_ptr)
 /*!
  * @brief Choose an item for search
  */
-bool get_object_for_search(player_type *player_ptr, object_type **o_handle, concptr *search_strp)
+bool get_object_for_search(PlayerType *player_ptr, object_type **o_handle, concptr *search_strp)
 {
     concptr q = _("どのアイテムを検索しますか? ", "Enter which item? ");
     concptr s = _("アイテムを持っていない。", "You have nothing to enter.");
@@ -73,7 +73,7 @@ bool get_object_for_search(player_type *player_ptr, object_type **o_handle, conc
 /*!
  * @brief Prepare for search by destroyed object
  */
-bool get_destroyed_object_for_search(player_type *player_ptr, object_type **o_handle, concptr *search_strp)
+bool get_destroyed_object_for_search(PlayerType *player_ptr, object_type **o_handle, concptr *search_strp)
 {
     if (!autopick_last_destroyed_object.k_idx)
         return false;
@@ -93,7 +93,7 @@ bool get_destroyed_object_for_search(player_type *player_ptr, object_type **o_ha
  * TERM_YELLOW : Overwrite mode
  * TERM_WHITE : Insert mode
  */
-byte get_string_for_search(player_type *player_ptr, object_type **o_handle, concptr *search_strp)
+byte get_string_for_search(PlayerType *player_ptr, object_type **o_handle, concptr *search_strp)
 {
     byte color = TERM_YELLOW;
     char buf[MAX_NLEN + 20];
@@ -288,7 +288,7 @@ byte get_string_for_search(player_type *player_ptr, object_type **o_handle, conc
 /*!
  * @brief Search next line matches for o_ptr
  */
-void search_for_object(player_type *player_ptr, text_body_type *tb, object_type *o_ptr, bool forward)
+void search_for_object(PlayerType *player_ptr, text_body_type *tb, object_type *o_ptr, bool forward)
 {
     autopick_type an_entry, *entry = &an_entry;
     GAME_TEXT o_name[MAX_NLEN];
index 4e9c758..ef56f45 100644 (file)
@@ -3,11 +3,11 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 struct text_body_type;
-int find_autopick_list(player_type *player_ptr, object_type *o_ptr);
-bool get_object_for_search(player_type *player_ptr, object_type **o_handle, concptr *search_strp);
-bool get_destroyed_object_for_search(player_type *player_ptr, object_type **o_handle, concptr *search_strp);
-byte get_string_for_search(player_type *player_ptr, object_type **o_handle, concptr *search_strp);
-void search_for_object(player_type *player_ptr, text_body_type *tb, object_type *o_ptr, bool forward);
+int find_autopick_list(PlayerType *player_ptr, object_type *o_ptr);
+bool get_object_for_search(PlayerType *player_ptr, object_type **o_handle, concptr *search_strp);
+bool get_destroyed_object_for_search(PlayerType *player_ptr, object_type **o_handle, concptr *search_strp);
+byte get_string_for_search(PlayerType *player_ptr, object_type **o_handle, concptr *search_strp);
+void search_for_object(PlayerType *player_ptr, text_body_type *tb, object_type *o_ptr, bool forward);
 void search_for_string(text_body_type *tb, concptr search_str, bool forward);
index 5f2f20f..7bb424e 100644 (file)
@@ -32,7 +32,7 @@
 /*!
  * @brief A function for Auto-picker/destroyer Examine whether the object matches to the entry
  */
-bool is_autopick_match(player_type *player_ptr, object_type *o_ptr, autopick_type *entry, concptr o_name)
+bool is_autopick_match(PlayerType *player_ptr, object_type *o_ptr, autopick_type *entry, concptr o_name)
 {
     concptr ptr = entry->name.c_str();
     if (IS_FLG(FLG_UNAWARE) && o_ptr->is_aware())
index 20402bb..e320450 100644 (file)
@@ -4,5 +4,5 @@
 
 typedef struct autopick_type autopick_type;
 struct object_type;
-struct player_type;
-bool is_autopick_match(player_type *player_ptr, object_type *o_ptr, autopick_type *entry, concptr o_name);
+class PlayerType;
+bool is_autopick_match(PlayerType *player_ptr, object_type *o_ptr, autopick_type *entry, concptr o_name);
index 0e7d4b8..841733c 100644 (file)
@@ -12,7 +12,7 @@
 /*!
  * @brief Load an autopick preference file
  */
-void autopick_load_pref(player_type *player_ptr, bool disp_mes)
+void autopick_load_pref(PlayerType *player_ptr, bool disp_mes)
 {
     GAME_TEXT buf[80];
     init_autopick();
@@ -38,7 +38,7 @@ void autopick_load_pref(player_type *player_ptr, bool disp_mes)
 /*!
  * @brief Get file name for autopick preference
  */
-concptr pickpref_filename(player_type *player_ptr, int filename_mode)
+concptr pickpref_filename(PlayerType *player_ptr, int filename_mode)
 {
     static const char namebase[] = _("picktype", "pickpref");
 
@@ -86,7 +86,7 @@ static std::vector<concptr> read_text_lines(concptr filename)
 /*!
  * @brief Copy the default autopick file to the user directory
  */
-static void prepare_default_pickpref(player_type *player_ptr)
+static void prepare_default_pickpref(PlayerType *player_ptr)
 {
     const concptr messages[] = { _("あなたは「自動拾いエディタ」を初めて起動しました。", "You have activated the Auto-Picker Editor for the first time."),
         _("自動拾いのユーザー設定ファイルがまだ書かれていないので、", "Since user pref file for autopick is not yet created,"),
@@ -132,7 +132,7 @@ static void prepare_default_pickpref(player_type *player_ptr)
  * @brief Read an autopick prefence file to memory
  * Prepare default if no user file is found
  */
-std::vector<concptr> read_pickpref_text_lines(player_type *player_ptr, int *filename_mode_p)
+std::vector<concptr> read_pickpref_text_lines(PlayerType *player_ptr, int *filename_mode_p)
 {
     /* Try a filename with player name */
     *filename_mode_p = PT_WITH_PNAME;
index e5c7ff8..64e852f 100644 (file)
@@ -4,8 +4,8 @@
 
 #include <vector>
 
-struct player_type;
-void autopick_load_pref(player_type *player_ptr, bool disp_mes);
-std::vector<concptr> read_pickpref_text_lines(player_type *player_ptr, int *filename_mode_p);
+class PlayerType;
+void autopick_load_pref(PlayerType *player_ptr, bool disp_mes);
+std::vector<concptr> read_pickpref_text_lines(PlayerType *player_ptr, int *filename_mode_p);
 bool write_text_lines(concptr filename, concptr *lines_list);
-concptr pickpref_filename(player_type *player_ptr, int filename_mode);
+concptr pickpref_filename(PlayerType *player_ptr, int filename_mode);
index c13c0d4..ffd0e1a 100644 (file)
@@ -26,7 +26,7 @@ static const char autoregister_header[] = "?:$AUTOREGISTER";
 /*!
  * @brief Clear auto registered lines in the picktype.prf .
  */
-static bool clear_auto_register(player_type *player_ptr)
+static bool clear_auto_register(PlayerType *player_ptr)
 {
     char pref_file[1024];
     path_build(pref_file, sizeof(pref_file), ANGBAND_DIR_USER, pickpref_filename(player_ptr, PT_WITH_PNAME));
@@ -106,7 +106,7 @@ static bool clear_auto_register(player_type *player_ptr)
 /*!
  * @brief Automatically register an auto-destroy preference line
  */
-bool autopick_autoregister(player_type *player_ptr, object_type *o_ptr)
+bool autopick_autoregister(PlayerType *player_ptr, object_type *o_ptr)
 {
     autopick_type an_entry, *entry = &an_entry;
     int autopick_registered = find_autopick_list(player_ptr, o_ptr);
index f4eec89..88663b1 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool autopick_autoregister(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool autopick_autoregister(PlayerType *player_ptr, object_type *o_ptr);
index 5f029a0..f3ab1ad 100644 (file)
@@ -52,7 +52,7 @@ int get_com_id(char key)
 /*!
  * @brief Auto inscription
  */
-void auto_inscribe_item(player_type *player_ptr, object_type *o_ptr, int idx)
+void auto_inscribe_item(PlayerType *player_ptr, object_type *o_ptr, int idx)
 {
     if (idx < 0 || autopick_list[idx].insc.empty())
         return;
index 10fbb38..c610095 100644 (file)
@@ -80,10 +80,10 @@ typedef struct text_body_type {
 extern std::vector<autopick_type> autopick_list;
 extern object_type autopick_last_destroyed_object;
 
-struct player_type;
+class PlayerType;
 void free_text_lines(std::vector<concptr> &lines_list);
 int get_com_id(char key);
-void auto_inscribe_item(player_type *player_ptr, object_type *o_ptr, int idx);
+void auto_inscribe_item(PlayerType *player_ptr, object_type *o_ptr, int idx);
 int count_line(text_body_type *tb);
 
 /*!
index 9080fb7..41a5727 100644 (file)
@@ -37,7 +37,7 @@
 /*!
  * @brief Auto-destroy marked item
  */
-static void autopick_delayed_alter_aux(player_type *player_ptr, INVENTORY_IDX item)
+static void autopick_delayed_alter_aux(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     object_type *o_ptr;
     o_ptr = ref_item(player_ptr, item);
@@ -63,7 +63,7 @@ static void autopick_delayed_alter_aux(player_type *player_ptr, INVENTORY_IDX it
  * Scan inventry in reverse order to prevent
  * skipping after inven_item_optimize()
  */
-void autopick_delayed_alter(player_type *player_ptr)
+void autopick_delayed_alter(PlayerType *player_ptr)
 {
     for (INVENTORY_IDX item = INVEN_TOTAL - 1; item >= 0; item--)
         autopick_delayed_alter_aux(player_ptr, item);
@@ -84,7 +84,7 @@ void autopick_delayed_alter(player_type *player_ptr)
  * Auto-destroyer works only on inventory or on floor stack only when
  * requested.
  */
-void autopick_alter_item(player_type *player_ptr, INVENTORY_IDX item, bool destroy)
+void autopick_alter_item(PlayerType *player_ptr, INVENTORY_IDX item, bool destroy)
 {
     object_type *o_ptr;
     o_ptr = ref_item(player_ptr, item);
@@ -97,7 +97,7 @@ void autopick_alter_item(player_type *player_ptr, INVENTORY_IDX item, bool destr
 /*!
  * @brief Automatically pickup/destroy items in this grid.
  */
-void autopick_pickup_items(player_type *player_ptr, grid_type *g_ptr)
+void autopick_pickup_items(PlayerType *player_ptr, grid_type *g_ptr)
 {
     for (auto it = g_ptr->o_idx_list.begin(); it != g_ptr->o_idx_list.end();) {
         OBJECT_IDX this_o_idx = *it++;
index 66af9ca..ef673a9 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct grid_type;;
-struct player_type;
-void autopick_alter_item(player_type *player_ptr, INVENTORY_IDX item, bool destroy);
-void autopick_delayed_alter(player_type *player_ptr);
-void autopick_pickup_items(player_type *player_ptr, grid_type *g_ptr);
+class PlayerType;
+void autopick_alter_item(PlayerType *player_ptr, INVENTORY_IDX item, bool destroy);
+void autopick_delayed_alter(PlayerType *player_ptr);
+void autopick_pickup_items(PlayerType *player_ptr, grid_type *g_ptr);
index 912edb7..148de8e 100644 (file)
@@ -23,7 +23,7 @@
 /*!
  * @brief AvaterChangerコンストラクタ
  */
-AvatarChanger::AvatarChanger(player_type *player_ptr, monster_type *m_ptr)
+AvatarChanger::AvatarChanger(PlayerType *player_ptr, monster_type *m_ptr)
     : player_ptr(player_ptr)
     , m_ptr(m_ptr)
 {
index 9172ab1..e9337df 100644 (file)
@@ -3,15 +3,15 @@
 #include "system/angband.h"
 
 struct monster_type;
-struct player_type;
+class PlayerType;
 class AvatarChanger {
 public:
-    AvatarChanger(player_type *player_ptr, monster_type *m_ptr);
+    AvatarChanger(PlayerType *player_ptr, monster_type *m_ptr);
     virtual ~AvatarChanger() = default;
     void change_virtue();
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     monster_type *m_ptr;
     void change_virtue_non_beginner();
     void change_virtue_unique();
index 4218eb9..92af6b4 100644 (file)
@@ -53,7 +53,7 @@ concptr virtue[MAX_VIRTUE] = {
  * @return 比較の真偽値を返す
  * @todo 引数名を直しておく
  */
-bool compare_virtue(player_type *player_ptr, int type, int num, int tekitou)
+bool compare_virtue(PlayerType *player_ptr, int type, int num, int tekitou)
 {
     int vir = virtue_number(player_ptr, type) ? player_ptr->virtues[virtue_number(player_ptr, type) - 1] : 0;
     switch (tekitou) {
@@ -77,7 +77,7 @@ bool compare_virtue(player_type *player_ptr, int type, int num, int tekitou)
  * @param type 確認したい徳のID
  * @return スロットがあるならばスロットのID(0~7)+1、ない場合は0を返す。
  */
-int virtue_number(player_type *player_ptr, int type)
+int virtue_number(PlayerType *player_ptr, int type)
 {
     for (int i = 0; i < 8; i++)
         if (player_ptr->vir_types[i] == type)
@@ -90,7 +90,7 @@ int virtue_number(player_type *player_ptr, int type)
  * @brief プレイヤーの職業や種族に依存しないランダムな徳を取得する / Aux function
  * @param which 確認したい徳のID
  */
-static void get_random_virtue(player_type *player_ptr, int which)
+static void get_random_virtue(PlayerType *player_ptr, int which)
 {
     int type = 0;
     while (!(type) || virtue_number(player_ptr, type)) {
@@ -153,7 +153,7 @@ static void get_random_virtue(player_type *player_ptr, int which)
  * @param realm 魔法領域のID
  * @return 対応する徳のID
  */
-static enum virtue_idx get_realm_virtues(player_type *player_ptr, int16_t realm)
+static enum virtue_idx get_realm_virtues(PlayerType *player_ptr, int16_t realm)
 {
     switch (realm) {
     case REALM_LIFE:
@@ -211,7 +211,7 @@ static enum virtue_idx get_realm_virtues(player_type *player_ptr, int16_t realm)
  * @brief 作成中のプレイヤーキャラクターに徳8種類を与える。 / Select virtues & reset values for a new character
  * @details 職業に応じて1~4種が固定、種族に応じて1種類が与えられ、後は重複なくランダムに選択される。
  */
-void initialize_virtues(player_type *player_ptr)
+void initialize_virtues(PlayerType *player_ptr)
 {
     int i = 0, j = 0;
     int16_t tmp_vir;
@@ -441,7 +441,7 @@ void initialize_virtues(player_type *player_ptr)
  * @param virtue 徳のID
  * @param amount 加減量
  */
-void chg_virtue(player_type *player_ptr, int virtue_id, int amount)
+void chg_virtue(PlayerType *player_ptr, int virtue_id, int amount)
 {
     for (int i = 0; i < 8; i++) {
         if (player_ptr->vir_types[i] != virtue_id)
@@ -499,7 +499,7 @@ void chg_virtue(player_type *player_ptr, int virtue_id, int amount)
  * @param virtue 徳のID
  * @param amount セットしたい値
  */
-void set_virtue(player_type *player_ptr, int virtue_id, int amount)
+void set_virtue(PlayerType *player_ptr, int virtue_id, int amount)
 {
     for (int i = 0; i < 8; i++)
         if (player_ptr->vir_types[i] == virtue_id) {
@@ -512,7 +512,7 @@ void set_virtue(player_type *player_ptr, int virtue_id, int amount)
  * @brief 徳のダンプ表示を行う
  * @param out_file ファイルポインタ
  */
-void dump_virtues(player_type *player_ptr, FILE *out_file)
+void dump_virtues(PlayerType *player_ptr, FILE *out_file)
 {
     if (!out_file)
         return;
index a260288..a7be51e 100644 (file)
@@ -29,11 +29,11 @@ enum virtue_idx {
 #define VIRTUE_LARGE 1
 #define VIRTUE_SMALL 2
 
-struct player_type;
-bool compare_virtue(player_type *player_ptr, int type, int num, int tekitou);
-int virtue_number(player_type *player_ptr, int type);
+class PlayerType;
+bool compare_virtue(PlayerType *player_ptr, int type, int num, int tekitou);
+int virtue_number(PlayerType *player_ptr, int type);
 extern concptr virtue[MAX_VIRTUE];
-void initialize_virtues(player_type *player_ptr);
-void chg_virtue(player_type *player_ptr, int virtue, int amount);
-void set_virtue(player_type *player_ptr, int virtue, int amount);
-void dump_virtues(player_type *player_ptr, FILE *OutFile);
+void initialize_virtues(PlayerType *player_ptr);
+void chg_virtue(PlayerType *player_ptr, int virtue, int amount);
+void set_virtue(PlayerType *player_ptr, int virtue, int amount);
+void dump_virtues(PlayerType *player_ptr, FILE *OutFile);
index 1f15b36..b2fd3e5 100644 (file)
@@ -109,7 +109,7 @@ static int32_t get_autoroller_prob(int *minval)
  * 純メイジ系は耐と魔法の能力が17で腕器16。
  * デュアルかどうかは最大攻撃回数で決定。(4回以上)
  */
-static void decide_initial_stat(player_type *player_ptr, int *cval)
+static void decide_initial_stat(PlayerType *player_ptr, int *cval)
 {
     auto pclass = enum2i(player_ptr->pclass);
     auto &class_ptr = class_info[pclass];
@@ -196,7 +196,7 @@ static void display_autoroller_chance(int *cval)
  * @brief オートローラで得たい能力値の基準を決める。
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-bool get_stat_limits(player_type *player_ptr)
+bool get_stat_limits(PlayerType *player_ptr)
 {
     clear_from(10);
     put_str(_("能力値を抽選します。最低限得たい能力値を設定して下さい。", "Set minimum stats for picking up your charactor."), 10, 10);
@@ -343,7 +343,7 @@ void initialize_chara_limit(chara_limit_type *chara_limit_ptr)
 /*!
  * @brief オートローラで得たい年齢、身長、体重、社会的地位の基準を決める。
  */
-bool get_chara_limits(player_type *player_ptr, chara_limit_type *chara_limit_ptr)
+bool get_chara_limits(PlayerType *player_ptr, chara_limit_type *chara_limit_ptr)
 {
 #define MAXITEMS 8
 
index 5824647..97ba5ce 100644 (file)
@@ -15,7 +15,7 @@ extern int32_t auto_round;
 extern int32_t auto_upper_round;
 extern int32_t autoroll_chance;
 
-struct player_type;
-bool get_stat_limits(player_type *player_ptr);
+class PlayerType;
+bool get_stat_limits(PlayerType *player_ptr);
 void initialize_chara_limit(chara_limit_type *chara_limit_ptr);
-bool get_chara_limits(player_type *player_ptr, chara_limit_type *chara_limit_ptr);
+bool get_chara_limits(PlayerType *player_ptr, chara_limit_type *chara_limit_ptr);
index 11fedde..41f7456 100644 (file)
@@ -8,7 +8,7 @@
 /*!
  * @brief プレイヤーの身長体重を決める / Get character's height and weight
  */
-void get_height_weight(player_type *player_ptr)
+void get_height_weight(PlayerType *player_ptr)
 {
     int deviation;
     switch (player_ptr->psex) {
@@ -30,7 +30,7 @@ void get_height_weight(player_type *player_ptr)
  * @brief プレイヤーの年齢を決める。 / Computes character's age, height, and weight by henkma
  * @details 内部でget_height_weight()も呼び出している。
  */
-void get_ahw(player_type *player_ptr)
+void get_ahw(PlayerType *player_ptr)
 {
     player_ptr->age = rp_ptr->b_age + randint1(rp_ptr->m_age);
     get_height_weight(player_ptr);
@@ -40,7 +40,7 @@ void get_ahw(player_type *player_ptr)
  * @brief プレイヤーの初期所持金を決める。 / Get the player's starting money
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void get_money(player_type *player_ptr)
+void get_money(PlayerType *player_ptr)
 {
     int gold = (player_ptr->sc * 6) + randint1(100) + 300;
     if (player_ptr->pclass == PlayerClassType::TOURIST)
index 45b3ca1..af8f3e5 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void get_height_weight(player_type *player_ptr);
-void get_ahw(player_type *player_ptr);
-void get_money(player_type *player_ptr);
+class PlayerType;
+void get_height_weight(PlayerType *player_ptr);
+void get_ahw(PlayerType *player_ptr);
+void get_money(PlayerType *player_ptr);
index 60c69a4..9a337cd 100644 (file)
@@ -113,7 +113,7 @@ static void interpret_class_select_key_move(char c, int *cs)
     }
 }
 
-static bool select_class(player_type *player_ptr, char *cur, char *sym, int *k)
+static bool select_class(PlayerType *player_ptr, char *cur, char *sym, int *k)
 {
     auto cs = player_ptr->pclass;
     auto os = PlayerClassType::MAX;
@@ -176,7 +176,7 @@ static bool select_class(player_type *player_ptr, char *cur, char *sym, int *k)
 /*!
  * @brief プレイヤーの職業選択を行う / Player class
  */
-bool get_player_class(player_type *player_ptr)
+bool get_player_class(PlayerType *player_ptr)
 {
     clear_from(10);
     put_str(
index ec24b25..ca724dd 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool get_player_class(player_type *player_ptr);
+class PlayerType;
+bool get_player_class(PlayerType *player_ptr);
index e0a2db9..075003a 100644 (file)
@@ -9,7 +9,7 @@
 
 static const char p2 = ')';
 
-static void enumerate_personality_list(player_type *player_ptr, concptr *str, char *sym)
+static void enumerate_personality_list(PlayerType *player_ptr, concptr *str, char *sym)
 {
     char buf[80];
     for (int n = 0; n < MAX_PERSONALITIES; n++) {
@@ -65,7 +65,7 @@ static void display_personality_stat(int cs, int *os, concptr *str, char *cur, c
     *os = cs;
 }
 
-static void interpret_personality_select_key_move(player_type *player_ptr, char c, int *cs)
+static void interpret_personality_select_key_move(PlayerType *player_ptr, char c, int *cs)
 {
     if (c == '8') {
         if (*cs >= 4)
@@ -112,7 +112,7 @@ static void interpret_personality_select_key_move(player_type *player_ptr, char
     }
 }
 
-static bool select_personality(player_type *player_ptr, int *k, concptr *str, char *sym)
+static bool select_personality(PlayerType *player_ptr, int *k, concptr *str, char *sym)
 {
     char cur[80];
     sprintf(cur, "%c%c%s", '*', p2, _("ランダム", "Random"));
@@ -184,7 +184,7 @@ static bool select_personality(player_type *player_ptr, int *k, concptr *str, ch
 /*!
  * @brief プレイヤーの性格選択を行う / Select player's personality
  */
-bool get_player_personality(player_type *player_ptr)
+bool get_player_personality(PlayerType *player_ptr)
 {
     clear_from(10);
     put_str(_("注意:《性格》によってキャラクターの能力やボーナスが変化します。", "Note: Your personality determines various intrinsic abilities and bonuses."),
index e8297ee..dd8c648 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool get_player_personality(player_type *player_ptr);
+class PlayerType;
+bool get_player_personality(PlayerType *player_ptr);
index 0501cd9..34e887d 100644 (file)
@@ -92,7 +92,7 @@ static void interpret_race_select_key_move(char c, int *cs)
     }
 }
 
-static bool select_race(player_type *player_ptr, char *sym, int *k)
+static bool select_race(PlayerType *player_ptr, char *sym, int *k)
 {
     char cur[80];
     sprintf(cur, "%c%c%s", '*', p2, _("ランダム", "Random"));
@@ -153,7 +153,7 @@ static bool select_race(player_type *player_ptr, char *sym, int *k)
 /*!
  * @brief プレイヤーの種族選択を行う / Player race
  */
-bool get_player_race(player_type *player_ptr)
+bool get_player_race(PlayerType *player_ptr)
 {
     clear_from(10);
     put_str(
index 94bc49f..2b3a93a 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool get_player_race(player_type *player_ptr);
+class PlayerType;
+bool get_player_race(PlayerType *player_ptr);
index dd604c6..310851b 100644 (file)
@@ -109,7 +109,7 @@ static birth_realm_type *initialize_birth_realm_type(birth_realm_type *birth_rea
     return birth_realm_ptr;
 }
 
-static void impose_first_realm(const player_type *player_ptr, uint32_t *choices)
+static void impose_first_realm(const PlayerType *player_ptr, uint32_t *choices)
 {
     if (player_ptr->realm2 == REALM_SELECT_CANCEL)
         return;
@@ -124,7 +124,7 @@ static void impose_first_realm(const player_type *player_ptr, uint32_t *choices)
     }
 }
 
-static void analyze_realms(const player_type *player_ptr, const uint32_t choices, birth_realm_type *birth_realm_ptr)
+static void analyze_realms(const PlayerType *player_ptr, const uint32_t choices, birth_realm_type *birth_realm_ptr)
 {
     for (int i = 0; i < 32; i++) {
         if ((choices & (1UL << i)) == 0)
@@ -196,7 +196,7 @@ static void interpret_realm_select_key(birth_realm_type *birth_realm_ptr, char c
     }
 }
 
-static bool get_a_realm(player_type *player_ptr, birth_realm_type *birth_realm_ptr)
+static bool get_a_realm(PlayerType *player_ptr, birth_realm_type *birth_realm_ptr)
 {
     birth_realm_ptr->os = birth_realm_ptr->n;
     while (true) {
@@ -254,7 +254,7 @@ static bool get_a_realm(player_type *player_ptr, birth_realm_type *birth_realm_p
  * @return 選択した魔法領域のID
  * @details 領域数が0 (戦士等)or 1 (観光客等)なら自動での値を返す
  */
-static byte select_realm(player_type *player_ptr, uint32_t choices, int *count)
+static byte select_realm(PlayerType *player_ptr, uint32_t choices, int *count)
 {
     byte auto_select = count_realm_selection(choices, count);
     clear_from(10);
@@ -289,7 +289,7 @@ static void cleanup_realm_selection_window(void)
  * @param count 魔法領域の数
  * @return 選んだ魔法領域で良ければTRUE、再選択ならばFALSE
  */
-static bool check_realm_selection(player_type *player_ptr, int count)
+static bool check_realm_selection(PlayerType *player_ptr, int count)
 {
     if (count < 2) {
         prt(_("何かキーを押してください", "Hit any key."), 0, 0);
@@ -306,7 +306,7 @@ static bool check_realm_selection(player_type *player_ptr, int count)
  * @brief 選択した魔法領域の解説を表示する / Choose the magical realms
  * @return ユーザが魔法領域の確定を選んだらTRUEを返す。
  */
-bool get_player_realms(player_type *player_ptr)
+bool get_player_realms(PlayerType *player_ptr)
 {
     /* Clean up infomation of modifications */
     put_str("                                   ", 3, 40);
index 8990b79..ec348b4 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool get_player_realms(player_type *player_ptr);
+class PlayerType;
+bool get_player_realms(PlayerType *player_ptr);
index dca5868..02f8660 100644 (file)
@@ -59,7 +59,7 @@ int adjust_stat(int value, int amount)
  * calc_bonuses()による、独立ステータスからの副次ステータス算出も行っている。
  * For efficiency, we include a chunk of "calc_bonuses()".\n
  */
-void get_stats(player_type *player_ptr)
+void get_stats(PlayerType *player_ptr)
 {
     while (true) {
         int sum = 0;
@@ -88,7 +88,7 @@ void get_stats(player_type *player_ptr)
 /*!
  * @brief 経験値修正の合計値を計算
  */
-uint16_t get_expfact(player_type *player_ptr)
+uint16_t get_expfact(PlayerType *player_ptr)
 {
     uint16_t expfact = rp_ptr->r_exp;
 
@@ -104,7 +104,7 @@ uint16_t get_expfact(player_type *player_ptr)
 /*!
  * @brief その他「オートローラ中は算出の対象にしない」副次ステータスを処理する / Roll for some info that the auto-roller ignores
  */
-void get_extra(player_type *player_ptr, bool roll_hitdie)
+void get_extra(PlayerType *player_ptr, bool roll_hitdie)
 {
     player_ptr->expfact = get_expfact(player_ptr);
 
@@ -150,7 +150,7 @@ void get_extra(player_type *player_ptr, bool roll_hitdie)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details 新生の薬やステータスシャッフルでもこの関数が呼ばれる
  */
-void get_max_stats(player_type *player_ptr)
+void get_max_stats(PlayerType *player_ptr)
 {
     int dice[6];
     while (true) {
index 493fcc1..d0a5603 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 int adjust_stat(int value, int amount);
-void get_stats(player_type* player_ptr);
-uint16_t get_expfact(player_type *player_ptr);
-void get_extra(player_type *player_ptr, bool roll_hitdie);
+void get_stats(PlayerType* player_ptr);
+uint16_t get_expfact(PlayerType *player_ptr);
+void get_extra(PlayerType *player_ptr, bool roll_hitdie);
 
-void get_max_stats(player_type* player_ptr);
+void get_max_stats(PlayerType* player_ptr);
index 4e50c97..edcb0c5 100644 (file)
@@ -18,14 +18,14 @@ void birth_quit(void)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param helpfile ファイル名
  */
-void show_help(player_type* player_ptr, concptr helpfile)
+void show_help(PlayerType* player_ptr, concptr helpfile)
 {
     screen_save();
     (void)show_file(player_ptr, true, helpfile, nullptr, 0, 0);
     screen_load();
 }
 
-void birth_help_option(player_type *player_ptr, char c, birth_kind bk)
+void birth_help_option(PlayerType *player_ptr, char c, birth_kind bk)
 {
     concptr help_file;
     switch (bk) {
index ac67147..5d0ad8a 100644 (file)
@@ -11,7 +11,7 @@ enum birth_kind
        BK_AUTO_ROLLER,
 };
 
-struct player_type;
+class PlayerType;
 void birth_quit(void);
-void show_help(player_type* player_ptr, concptr helpfile);
-void birth_help_option(player_type *player_ptr, char c, birth_kind bk);
+void show_help(PlayerType* player_ptr, concptr helpfile);
+void birth_help_option(PlayerType *player_ptr, char c, birth_kind bk);
index 5b60929..7fcad59 100644 (file)
@@ -51,7 +51,7 @@
  */
 #define AUTOROLLER_STEP 54321L
 
-static void display_initial_birth_message(player_type *player_ptr)
+static void display_initial_birth_message(PlayerType *player_ptr)
 {
     term_clear();
     put_str(_("名前  :", "Name  :"), 1, 26);
@@ -69,7 +69,7 @@ static void display_initial_birth_message(player_type *player_ptr)
  * @param c 入力したコマンド
  * @details 他の関数名と被りそうだったので少し眺め
  */
-static void display_help_on_sex_select(player_type *player_ptr, char c)
+static void display_help_on_sex_select(PlayerType *player_ptr, char c)
 {
     if (c == '?')
         do_cmd_help(player_ptr);
@@ -87,7 +87,7 @@ static void display_help_on_sex_select(player_type *player_ptr, char c)
  * @buf 表示用バッファ
  * @return やり直すならFALSE、それ以外はTRUE
  */
-static bool get_player_sex(player_type *player_ptr, char *buf)
+static bool get_player_sex(PlayerType *player_ptr, char *buf)
 {
     const char p2 = ')';
     char cur[80];
@@ -158,7 +158,7 @@ static bool get_player_sex(player_type *player_ptr, char *buf)
     return true;
 }
 
-static bool let_player_select_race(player_type *player_ptr)
+static bool let_player_select_race(PlayerType *player_ptr)
 {
     clear_from(10);
     player_ptr->prace = PlayerRaceType::HUMAN;
@@ -188,7 +188,7 @@ static bool let_player_select_race(player_type *player_ptr)
     return true;
 }
 
-static bool let_player_select_class(player_type *player_ptr)
+static bool let_player_select_class(PlayerType *player_ptr)
 {
     clear_from(10);
     player_ptr->pclass = PlayerClassType::WARRIOR;
@@ -218,7 +218,7 @@ static bool let_player_select_class(player_type *player_ptr)
     return true;
 }
 
-static bool let_player_select_personality(player_type *player_ptr)
+static bool let_player_select_personality(PlayerType *player_ptr)
 {
     player_ptr->ppersonality = PERSONALITY_ORDINARY;
     while (true) {
@@ -248,7 +248,7 @@ static bool let_player_select_personality(player_type *player_ptr)
     return true;
 }
 
-static bool let_player_build_character(player_type *player_ptr)
+static bool let_player_build_character(PlayerType *player_ptr)
 {
     char buf[80];
     if (!get_player_sex(player_ptr, buf))
@@ -271,7 +271,7 @@ static bool let_player_build_character(player_type *player_ptr)
     return true;
 }
 
-static void display_initial_options(player_type *player_ptr)
+static void display_initial_options(PlayerType *player_ptr)
 {
     uint16_t expfact = get_expfact(player_ptr) - 100;
     int16_t adj[A_MAX];
@@ -348,7 +348,7 @@ static void auto_roller_count(void)
     auto_upper_round++;
 }
 
-static bool decide_initial_stat(player_type *player_ptr)
+static bool decide_initial_stat(PlayerType *player_ptr)
 {
     if (!autoroller)
         return true;
@@ -364,7 +364,7 @@ static bool decide_initial_stat(player_type *player_ptr)
     return accept;
 }
 
-static bool decide_body_spec(player_type *player_ptr, chara_limit_type chara_limit, bool *accept)
+static bool decide_body_spec(PlayerType *player_ptr, chara_limit_type chara_limit, bool *accept)
 {
     if (!*accept)
         return false;
@@ -386,7 +386,7 @@ static bool decide_body_spec(player_type *player_ptr, chara_limit_type chara_lim
     return *accept;
 }
 
-static bool display_auto_roller_count(player_type *player_ptr, const int col)
+static bool display_auto_roller_count(PlayerType *player_ptr, const int col)
 {
     if ((auto_round % AUTOROLLER_STEP) != 0)
         return false;
@@ -407,7 +407,7 @@ static bool display_auto_roller_count(player_type *player_ptr, const int col)
     return false;
 }
 
-static void exe_auto_roller(player_type *player_ptr, chara_limit_type chara_limit, const int col)
+static void exe_auto_roller(PlayerType *player_ptr, chara_limit_type chara_limit, const int col)
 {
     while (autoroller || autochara) {
         get_stats(player_ptr);
@@ -422,7 +422,7 @@ static void exe_auto_roller(player_type *player_ptr, chara_limit_type chara_limi
     }
 }
 
-static bool display_auto_roller_result(player_type *player_ptr, bool prev, char *c)
+static bool display_auto_roller_result(PlayerType *player_ptr, bool prev, char *c)
 {
     BIT_FLAGS mode = 0;
     while (true) {
@@ -482,7 +482,7 @@ static bool display_auto_roller_result(player_type *player_ptr, bool prev, char
  * @param chara_limit 社会的地位の要求水準
  * @details 2つめの結果以降は、'p'キーで1つ前のロール結果に戻せる。
  */
-static bool display_auto_roller(player_type *player_ptr, chara_limit_type chara_limit)
+static bool display_auto_roller(PlayerType *player_ptr, chara_limit_type chara_limit)
 {
     bool prev = false;
 
@@ -529,7 +529,7 @@ static bool display_auto_roller(player_type *player_ptr, chara_limit_type chara_
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details ついでにステータス限界もここで決めている
  */
-static void set_name_history(player_type *player_ptr)
+static void set_name_history(PlayerType *player_ptr)
 {
     clear_from(23);
     get_name(player_ptr);
@@ -547,7 +547,7 @@ static void set_name_history(player_type *player_ptr)
  * from continuously rolling up characters, which can be VERY
  * expensive CPU wise.  And it cuts down on player stupidity.
  */
-bool player_birth_wizard(player_type *player_ptr)
+bool player_birth_wizard(PlayerType *player_ptr)
 {
     display_initial_birth_message(player_ptr);
     const char p2 = ')';
index 04672db..3f0ea95 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool player_birth_wizard(player_type *player_ptr);
+class PlayerType;
+bool player_birth_wizard(PlayerType *player_ptr);
index 31275b2..0cf3c77 100644 (file)
@@ -43,7 +43,7 @@
  * @brief プレイヤーキャラの作成結果を日記に書く
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void write_birth_diary(player_type *player_ptr)
+static void write_birth_diary(PlayerType *player_ptr)
 {
     concptr indent = "                            ";
 
@@ -85,7 +85,7 @@ static void write_birth_diary(player_type *player_ptr)
  * Note that we may be called with "junk" leftover in the various
  * fields, so we must be sure to clear them first.
  */
-void player_birth(player_type *player_ptr)
+void player_birth(PlayerType *player_ptr)
 {
     w_ptr->play_time = 0;
     wipe_monsters_list(player_ptr);
index c53a595..451717d 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void player_birth(player_type *player_ptr);
+class PlayerType;
+void player_birth(PlayerType *player_ptr);
index c0ce39e..d043d06 100644 (file)
@@ -40,7 +40,7 @@ static void k_info_reset(void)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details 少し長いが、これ1つで処理が完結しているので分割は見送る
  */
-void player_wipe_without_name(player_type *player_ptr)
+void player_wipe_without_name(PlayerType *player_ptr)
 {
 #ifdef SET_UID
     int uid = player_ptr->player_uid;
@@ -170,7 +170,7 @@ void player_wipe_without_name(player_type *player_ptr)
  * @brief ダンジョン内部のクエストを初期化する / Initialize random quests and final quests
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void init_dungeon_quests(player_type *player_ptr)
+void init_dungeon_quests(PlayerType *player_ptr)
 {
     int number_of_quests = MAX_RANDOM_QUEST - MIN_RANDOM_QUEST + 1;
     init_flags = INIT_ASSIGN;
@@ -205,7 +205,7 @@ void init_dungeon_quests(player_type *player_ptr)
  * @details アンデッド系種族は開始時刻を夜からにする / Undead start just sunset
  * @details
  */
-void init_turn(player_type *player_ptr)
+void init_turn(PlayerType *player_ptr)
 {
     if (PlayerRace(player_ptr).life() == PlayerRaceLifeType::UNDEAD) {
         w_ptr->game_turn = (TURNS_PER_TICK * 3 * TOWN_DAWN) / 4 + 1;
index 14119cf..ff36144 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void player_wipe_without_name(player_type *player_ptr);
-void init_dungeon_quests(player_type *player_ptr);
-void init_turn(player_type *player_ptr);
+class PlayerType;
+void player_wipe_without_name(PlayerType *player_ptr);
+void init_dungeon_quests(PlayerType *player_ptr);
+void init_turn(PlayerType *player_ptr);
index 9ae027c..93e4c05 100644 (file)
@@ -12,7 +12,7 @@
  * @brief 生い立ちメッセージを編集する。/Character background edit-mode
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void edit_history(player_type *player_ptr)
+void edit_history(PlayerType *player_ptr)
 {
     char old_history[4][60];
     for (int i = 0; i < 4; i++) {
index 68d76a7..0d7ce7e 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void edit_history(player_type *player_ptr);
+class PlayerType;
+void edit_history(PlayerType *player_ptr);
index dc60f6c..37043eb 100644 (file)
@@ -4,7 +4,7 @@
 #include "system/player-type-definition.h"
 #include "util/buffer-shaper.h"
 
-static int get_history_chart(player_type *player_ptr)
+static int get_history_chart(PlayerType *player_ptr)
 {
     switch (player_ptr->prace) {
     case PlayerRaceType::AMBERITE:
@@ -91,7 +91,7 @@ static int get_history_chart(player_type *player_ptr)
  * @param buf 生い立ち情報のバッファ
  * @details 画面表示と社会的地位の決定が密結合していて分離できない
  */
-static void decide_social_class(player_type *player_ptr, char *buf)
+static void decide_social_class(PlayerType *player_ptr, char *buf)
 {
     int social_class = randint1(4);
     int chart = get_history_chart(player_ptr);
@@ -118,7 +118,7 @@ static void decide_social_class(player_type *player_ptr, char *buf)
 /*!
  * @brief プレイヤーの生い立ちの自動生成を行う。 / Get the racial history, and social class, using the "history charts".
  */
-void get_history(player_type *player_ptr)
+void get_history(PlayerType *player_ptr)
 {
     for (int i = 0; i < 4; i++)
         player_ptr->history[i][0] = '\0';
index d5c35ee..b843996 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void get_history(player_type *player_ptr);
+class PlayerType;
+void get_history(PlayerType *player_ptr);
index fb9b14a..1c4d6a0 100644 (file)
@@ -35,7 +35,7 @@
 /*!
  * @brief 所持状態にあるアイテムの中から一部枠の装備可能なものを装備させる。
  */
-void wield_all(player_type *player_ptr)
+void wield_all(PlayerType *player_ptr)
 {
     object_type object_type_body;
     for (INVENTORY_IDX item = INVEN_PACK - 1; item >= 0; item--) {
@@ -76,7 +76,7 @@ void wield_all(player_type *player_ptr)
  * @details アイテムを既知のものとした上でwield_all()関数により装備させる。
  * @param o_ptr 処理したいオブジェクト構造体の参照ポインタ
  */
-void add_outfit(player_type *player_ptr, object_type *o_ptr)
+void add_outfit(PlayerType *player_ptr, object_type *o_ptr)
 {
     object_aware(player_ptr, o_ptr);
     object_known(o_ptr);
@@ -85,7 +85,7 @@ void add_outfit(player_type *player_ptr, object_type *o_ptr)
     wield_all(player_ptr);
 }
 
-static void decide_initial_items(player_type *player_ptr, object_type *q_ptr)
+static void decide_initial_items(PlayerType *player_ptr, object_type *q_ptr)
 {
     switch (player_ptr->prace) {
     case PlayerRaceType::VAMPIRE:
@@ -139,7 +139,7 @@ static void decide_initial_items(player_type *player_ptr, object_type *q_ptr)
  * @brief 種族/職業/性格などに基づき初期所持アイテムを設定するメインセット関数。 / Init players with some belongings
  * @details Having an item makes the player "aware" of its purpose.
  */
-void player_outfit(player_type *player_ptr)
+void player_outfit(PlayerType *player_ptr)
 {
     object_type *q_ptr;
     object_type forge;
index 953fd45..9e4e2cd 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-void wield_all(player_type *player_ptr);
-void add_outfit(player_type *player_ptr, object_type *o_ptr);
-void player_outfit(player_type *player_ptr);
+class PlayerType;
+void wield_all(PlayerType *player_ptr);
+void add_outfit(PlayerType *player_ptr, object_type *o_ptr);
+void player_outfit(PlayerType *player_ptr);
index 6013d7a..c4a6448 100644 (file)
@@ -25,7 +25,7 @@ birther previous_char;
 /*!
  * @brief クイックスタート処理の問い合わせと実行を行う。/Ask whether the player use Quick Start or not.
  */
-bool ask_quick_start(player_type *player_ptr)
+bool ask_quick_start(PlayerType *player_ptr)
 {
     if (!previous_char.quick_ok)
         return false;
@@ -74,7 +74,7 @@ bool ask_quick_start(player_type *player_ptr)
  * @param birther_ptr クイックスタート構造体の参照ポインタ
  * @return なし。
  */
-void save_prev_data(player_type *player_ptr, birther *birther_ptr)
+void save_prev_data(PlayerType *player_ptr, birther *birther_ptr)
 {
     birther_ptr->psex = player_ptr->psex;
     birther_ptr->prace = player_ptr->prace;
@@ -117,7 +117,7 @@ void save_prev_data(player_type *player_ptr, birther *birther_ptr)
  * @param swap TRUEならば現在のプレイヤー構造体上との内容をスワップする形で読み込む。
  * @return なし。
  */
-void load_prev_data(player_type *player_ptr, bool swap)
+void load_prev_data(PlayerType *player_ptr, bool swap)
 {
     birther temp;
     if (swap)
index 6e5e923..0295798 100644 (file)
@@ -40,7 +40,7 @@ struct birther {
 
 extern birther previous_char;
 
-struct player_type;
-bool ask_quick_start(player_type *player_ptr);
-void save_prev_data(player_type *player_ptr, birther *birther_ptr);
-void load_prev_data(player_type *player_ptr, bool swap);
+class PlayerType;
+bool ask_quick_start(PlayerType *player_ptr);
+void save_prev_data(PlayerType *player_ptr, birther *birther_ptr);
+void load_prev_data(PlayerType *player_ptr, bool swap);
index 1376d8f..02f914a 100644 (file)
@@ -13,7 +13,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool cast_blue_ball_acid(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_acid(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -24,7 +24,7 @@ bool cast_blue_ball_acid(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_elec(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_elec(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -35,7 +35,7 @@ bool cast_blue_ball_elec(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_fire(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_fire(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -46,7 +46,7 @@ bool cast_blue_ball_fire(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_cold(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_cold(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -57,7 +57,7 @@ bool cast_blue_ball_cold(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_pois(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_pois(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -68,7 +68,7 @@ bool cast_blue_ball_pois(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_nuke(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_nuke(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -79,7 +79,7 @@ bool cast_blue_ball_nuke(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_nether(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_nether(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -90,7 +90,7 @@ bool cast_blue_ball_nether(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_chaos(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_chaos(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -108,7 +108,7 @@ bool cast_blue_ball_chaos(player_type *player_ptr, bmc_type *bmc_ptr)
  * @param bmc_ptr 青魔法詠唱への参照ポインタ
  * @details All my worries are blown away.
  */
-bool cast_blue_ball_water(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_water(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -119,7 +119,7 @@ bool cast_blue_ball_water(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_star_burst(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_star_burst(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -130,7 +130,7 @@ bool cast_blue_ball_star_burst(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_dark_storm(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_dark_storm(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -141,7 +141,7 @@ bool cast_blue_ball_dark_storm(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_ball_mana_storm(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_ball_mana_storm(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -152,7 +152,7 @@ bool cast_blue_ball_mana_storm(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_acid(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_acid(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -163,7 +163,7 @@ bool cast_blue_bolt_acid(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_elec(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_elec(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -174,7 +174,7 @@ bool cast_blue_bolt_elec(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_fire(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_fire(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -185,7 +185,7 @@ bool cast_blue_bolt_fire(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_cold(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_cold(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -196,7 +196,7 @@ bool cast_blue_bolt_cold(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_nether(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_nether(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -207,7 +207,7 @@ bool cast_blue_bolt_nether(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_water(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_water(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -218,7 +218,7 @@ bool cast_blue_bolt_water(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_mana(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_mana(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -229,7 +229,7 @@ bool cast_blue_bolt_mana(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_plasma(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_plasma(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -240,7 +240,7 @@ bool cast_blue_bolt_plasma(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_icee(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_icee(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -251,7 +251,7 @@ bool cast_blue_bolt_icee(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_bolt_missile(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_bolt_missile(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
index dbe8e7d..145187d 100644 (file)
@@ -5,27 +5,27 @@
  */
 
 struct bmc_type;
-struct player_type;
-bool cast_blue_ball_acid(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_elec(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_fire(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_cold(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_pois(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_nuke(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_nether(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_chaos(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_water(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_star_burst(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_dark_storm(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_ball_mana_storm(player_type *player_ptr, bmc_type *bmc_ptr);
+class PlayerType;
+bool cast_blue_ball_acid(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_elec(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_fire(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_cold(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_pois(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_nuke(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_nether(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_chaos(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_water(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_star_burst(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_dark_storm(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_ball_mana_storm(PlayerType *player_ptr, bmc_type *bmc_ptr);
 
-bool cast_blue_bolt_acid(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_elec(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_fire(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_cold(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_nether(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_water(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_mana(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_plasma(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_icee(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_bolt_missile(player_type *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_acid(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_elec(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_fire(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_cold(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_nether(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_water(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_mana(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_plasma(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_icee(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_bolt_missile(PlayerType *player_ptr, bmc_type *bmc_ptr);
index 95b8c4f..36d9e25 100644 (file)
@@ -14,7 +14,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool cast_blue_breath_acid(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_acid(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -25,7 +25,7 @@ bool cast_blue_breath_acid(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_elec(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_elec(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -36,7 +36,7 @@ bool cast_blue_breath_elec(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_fire(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_fire(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -47,7 +47,7 @@ bool cast_blue_breath_fire(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_cold(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_cold(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -58,7 +58,7 @@ bool cast_blue_breath_cold(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_pois(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_pois(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -69,7 +69,7 @@ bool cast_blue_breath_pois(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_nether(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_nether(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -80,7 +80,7 @@ bool cast_blue_breath_nether(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_lite(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_lite(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -91,7 +91,7 @@ bool cast_blue_breath_lite(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_dark(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_dark(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -102,7 +102,7 @@ bool cast_blue_breath_dark(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_conf(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_conf(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -113,7 +113,7 @@ bool cast_blue_breath_conf(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_sound(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_sound(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -124,7 +124,7 @@ bool cast_blue_breath_sound(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_chaos(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_chaos(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -135,7 +135,7 @@ bool cast_blue_breath_chaos(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_disenchant(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_disenchant(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -146,7 +146,7 @@ bool cast_blue_breath_disenchant(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_nexus(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_nexus(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -157,7 +157,7 @@ bool cast_blue_breath_nexus(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_time(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_time(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -168,7 +168,7 @@ bool cast_blue_breath_time(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_inertia(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_inertia(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -179,7 +179,7 @@ bool cast_blue_breath_inertia(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_gravity(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_gravity(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -190,7 +190,7 @@ bool cast_blue_breath_gravity(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_shards(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_shards(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -201,7 +201,7 @@ bool cast_blue_breath_shards(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_plasma(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_plasma(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -212,7 +212,7 @@ bool cast_blue_breath_plasma(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_force(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_force(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -223,7 +223,7 @@ bool cast_blue_breath_force(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_mana(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_mana(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -234,7 +234,7 @@ bool cast_blue_breath_mana(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_breath_nuke(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_nuke(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -251,7 +251,7 @@ bool cast_blue_breath_nuke(player_type *player_ptr, bmc_type *bmc_ptr)
  * @param bmc_ptr 青魔法詠唱への参照ポインタ
  * @details 永久の刻は過ぎ去れリ.
  */
-bool cast_blue_breath_disintegration(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_breath_disintegration(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
index d4540bd..2eb9180 100644 (file)
@@ -5,26 +5,26 @@
  */
 
 struct bmc_type;
-struct player_type;
-bool cast_blue_breath_acid(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_elec(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_fire(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_cold(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_pois(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_nether(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_lite(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_dark(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_conf(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_sound(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_chaos(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_disenchant(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_nexus(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_time(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_inertia(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_gravity(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_shards(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_plasma(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_force(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_mana(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_nuke(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_breath_disintegration(player_type *player_ptr, bmc_type *bmc_ptr);
+class PlayerType;
+bool cast_blue_breath_acid(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_elec(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_fire(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_cold(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_pois(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_nether(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_lite(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_dark(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_conf(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_sound(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_chaos(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_disenchant(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_nexus(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_time(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_inertia(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_gravity(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_shards(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_plasma(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_force(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_mana(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_nuke(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_breath_disintegration(PlayerType *player_ptr, bmc_type *bmc_ptr);
index 26673e3..15a23f8 100644 (file)
@@ -44,7 +44,7 @@
 #include "target/target-types.h"
 #include "view/display-messages.h"
 
-static bool cast_blue_dispel(player_type *player_ptr)
+static bool cast_blue_dispel(PlayerType *player_ptr)
 {
     if (!target_set(player_ptr, TARGET_KILL))
         return false;
@@ -58,7 +58,7 @@ static bool cast_blue_dispel(player_type *player_ptr)
     return true;
 }
 
-static bool cast_blue_rocket(player_type *player_ptr, bmc_type *bmc_ptr)
+static bool cast_blue_rocket(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -69,7 +69,7 @@ static bool cast_blue_rocket(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-static bool cast_blue_shoot(player_type *player_ptr, bmc_type *bmc_ptr)
+static bool cast_blue_shoot(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -80,7 +80,7 @@ static bool cast_blue_shoot(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-static bool cast_blue_hand_doom(player_type *player_ptr, bmc_type *bmc_ptr)
+static bool cast_blue_hand_doom(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -90,7 +90,7 @@ static bool cast_blue_hand_doom(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-static bool exe_blue_teleport_back(player_type *player_ptr, GAME_TEXT *m_name)
+static bool exe_blue_teleport_back(PlayerType *player_ptr, GAME_TEXT *m_name)
 {
     monster_type *m_ptr;
     monster_race *r_ptr;
@@ -123,7 +123,7 @@ static bool exe_blue_teleport_back(player_type *player_ptr, GAME_TEXT *m_name)
     return true;
 }
 
-static bool cast_blue_teleport_back(player_type *player_ptr)
+static bool cast_blue_teleport_back(PlayerType *player_ptr)
 {
     if (!target_set(player_ptr, TARGET_KILL))
         return false;
@@ -138,7 +138,7 @@ static bool cast_blue_teleport_back(player_type *player_ptr)
     return true;
 }
 
-static bool cast_blue_teleport_away(player_type *player_ptr, bmc_type *bmc_ptr)
+static bool cast_blue_teleport_away(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -147,7 +147,7 @@ static bool cast_blue_teleport_away(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-static bool cast_blue_psy_spear(player_type *player_ptr, bmc_type *bmc_ptr)
+static bool cast_blue_psy_spear(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -158,7 +158,7 @@ static bool cast_blue_psy_spear(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-static bool cast_blue_make_trap(player_type *player_ptr)
+static bool cast_blue_make_trap(PlayerType *player_ptr)
 {
     if (!target_set(player_ptr, TARGET_KILL))
         return false;
@@ -168,7 +168,7 @@ static bool cast_blue_make_trap(player_type *player_ptr)
     return true;
 }
 
-static bool switch_cast_blue_magic(player_type *player_ptr, bmc_type *bmc_ptr, MonsterAbilityType spell)
+static bool switch_cast_blue_magic(PlayerType *player_ptr, bmc_type *bmc_ptr, MonsterAbilityType spell)
 {
     switch (spell) {
     case MonsterAbilityType::SHRIEK:
@@ -392,7 +392,7 @@ static bool switch_cast_blue_magic(player_type *player_ptr, bmc_type *bmc_ptr, M
  * @param success TRUEは成功時、FALSEは失敗時の処理を行う
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-bool cast_learned_spell(player_type *player_ptr, MonsterAbilityType spell, const bool success)
+bool cast_learned_spell(PlayerType *player_ptr, MonsterAbilityType spell, const bool success)
 {
     bmc_type tmp_bm;
     bmc_type *bmc_ptr = initialize_blue_magic_type(player_ptr, &tmp_bm, success, get_pseudo_monstetr_level);
index 53dde2c..cff0d0c 100644 (file)
@@ -6,5 +6,5 @@
 
 enum class MonsterAbilityType;
 
-struct player_type;
-bool cast_learned_spell(player_type *player_ptr, MonsterAbilityType spell, const bool success);
+class PlayerType;
+bool cast_learned_spell(PlayerType *player_ptr, MonsterAbilityType spell, const bool success);
index 0c7a9b5..e848794 100644 (file)
@@ -30,7 +30,7 @@
  * @brief 青魔法のラーニング判定と成功した場合のラーニング処理
  * @param monspell ラーニングを試みるモンスター攻撃のID
  */
-void learn_spell(player_type *player_ptr, MonsterAbilityType monspell)
+void learn_spell(PlayerType *player_ptr, MonsterAbilityType monspell)
 {
     if (player_ptr->action != ACTION_LEARN)
         return;
index 88c5453..61e60dc 100644 (file)
@@ -10,6 +10,6 @@
 
 enum class BlueMagicType;
 
-struct player_type;
-void learn_spell(player_type *player_ptr, MonsterAbilityType monspell);
+class PlayerType;
+void learn_spell(PlayerType *player_ptr, MonsterAbilityType monspell);
 void set_rf_masks(EnumClassFlagGroup<MonsterAbilityType> &ability_flags, BlueMagicType type);
index 1da5649..18bb215 100644 (file)
@@ -14,7 +14,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool cast_blue_drain_mana(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_drain_mana(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -24,7 +24,7 @@ bool cast_blue_drain_mana(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_mind_blast(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_mind_blast(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -34,7 +34,7 @@ bool cast_blue_mind_blast(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_brain_smash(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_brain_smash(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -44,7 +44,7 @@ bool cast_blue_brain_smash(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_curse_1(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_curse_1(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -54,7 +54,7 @@ bool cast_blue_curse_1(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_curse_2(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_curse_2(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -64,7 +64,7 @@ bool cast_blue_curse_2(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_curse_3(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_curse_3(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -74,7 +74,7 @@ bool cast_blue_curse_3(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_curse_4(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_curse_4(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
index 72fedd3..f3e6516 100644 (file)
@@ -5,11 +5,11 @@
  */
 
 struct bmc_type;
-struct player_type;
-bool cast_blue_drain_mana(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_mind_blast(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_brain_smash(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_curse_1(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_curse_2(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_curse_3(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_curse_4(player_type *player_ptr, bmc_type *bmc_ptr);
+class PlayerType;
+bool cast_blue_drain_mana(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_mind_blast(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_brain_smash(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_curse_1(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_curse_2(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_curse_3(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_curse_4(PlayerType *player_ptr, bmc_type *bmc_ptr);
index 6ea9620..d8f6539 100644 (file)
@@ -10,7 +10,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool cast_blue_scare(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_scare(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -20,7 +20,7 @@ bool cast_blue_scare(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_blind(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_blind(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -29,7 +29,7 @@ bool cast_blue_blind(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_confusion(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_confusion(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -39,7 +39,7 @@ bool cast_blue_confusion(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_slow(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_slow(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
@@ -48,7 +48,7 @@ bool cast_blue_slow(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_sleep(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_sleep(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     if (!get_aim_dir(player_ptr, &bmc_ptr->dir))
         return false;
index a78575d..c3ca2d8 100644 (file)
@@ -5,9 +5,9 @@
  */
 
 struct bmc_type;
-struct player_type;
-bool cast_blue_scare(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_blind(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_confusion(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_slow(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_sleep(player_type *player_ptr, bmc_type *bmc_ptr);
+class PlayerType;
+bool cast_blue_scare(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_blind(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_confusion(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_slow(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_sleep(PlayerType *player_ptr, bmc_type *bmc_ptr);
index 7be7e52..b2a73b2 100644 (file)
@@ -12,7 +12,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-bool cast_blue_summon_kin(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_kin(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("援軍を召喚した。", "You summon one of your kin."));
     for (int k = 0; k < 1; k++) {
@@ -27,7 +27,7 @@ bool cast_blue_summon_kin(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_cyber(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_cyber(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("サイバーデーモンを召喚した!", "You summon a Cyberdemon!"));
     for (int k = 0; k < 1; k++) {
@@ -42,7 +42,7 @@ bool cast_blue_summon_cyber(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_monster(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_monster(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("仲間を召喚した。", "You summon help."));
     for (int k = 0; k < 1; k++) {
@@ -57,7 +57,7 @@ bool cast_blue_summon_monster(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_monsters(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_monsters(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("モンスターを召喚した!", "You summon monsters!"));
     for (int k = 0; k < bmc_ptr->plev / 15 + 2; k++) {
@@ -72,7 +72,7 @@ bool cast_blue_summon_monsters(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_ant(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_ant(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("アリを召喚した。", "You summon ants."));
     if (summon_specific(
@@ -86,7 +86,7 @@ bool cast_blue_summon_ant(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_spider(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_spider(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("蜘蛛を召喚した。", "You summon spiders."));
     if (summon_specific(
@@ -100,7 +100,7 @@ bool cast_blue_summon_spider(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_hound(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_hound(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("ハウンドを召喚した。", "You summon hounds."));
     if (summon_specific(
@@ -114,7 +114,7 @@ bool cast_blue_summon_hound(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_hydra(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_hydra(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("ヒドラを召喚した。", "You summon a hydras."));
     if (summon_specific(
@@ -128,7 +128,7 @@ bool cast_blue_summon_hydra(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_angel(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_angel(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("天使を召喚した!", "You summon an angel!"));
     if (summon_specific(
@@ -142,7 +142,7 @@ bool cast_blue_summon_angel(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_demon(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_demon(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("混沌の宮廷から悪魔を召喚した!", "You summon a demon from the Courts of Chaos!"));
     if (summon_specific(
@@ -156,7 +156,7 @@ bool cast_blue_summon_demon(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_undead(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_undead(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("アンデッドの強敵を召喚した!", "You summon an undead adversary!"));
     if (summon_specific(
@@ -170,7 +170,7 @@ bool cast_blue_summon_undead(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_dragon(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_dragon(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("ドラゴンを召喚した!", "You summon a dragon!"));
     if (summon_specific(
@@ -184,7 +184,7 @@ bool cast_blue_summon_dragon(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_high_undead(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_high_undead(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("強力なアンデッドを召喚した!", "You summon a greater undead!"));
     if (summon_specific(player_ptr, (bmc_ptr->pet ? -1 : 0), player_ptr->y, player_ptr->x, bmc_ptr->summon_lev, SUMMON_HI_UNDEAD,
@@ -198,7 +198,7 @@ bool cast_blue_summon_high_undead(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_high_dragon(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_high_dragon(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("古代ドラゴンを召喚した!", "You summon an ancient dragon!"));
     if (summon_specific(player_ptr, (bmc_ptr->pet ? -1 : 0), player_ptr->y, player_ptr->x, bmc_ptr->summon_lev, SUMMON_HI_DRAGON,
@@ -212,7 +212,7 @@ bool cast_blue_summon_high_dragon(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_amberite(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_amberite(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     msg_print(_("アンバーの王族を召喚した!", "You summon a Lord of Amber!"));
     if (summon_specific(player_ptr, (bmc_ptr->pet ? -1 : 0), player_ptr->y, player_ptr->x, bmc_ptr->summon_lev, SUMMON_AMBERITES,
@@ -226,7 +226,7 @@ bool cast_blue_summon_amberite(player_type *player_ptr, bmc_type *bmc_ptr)
     return true;
 }
 
-bool cast_blue_summon_unique(player_type *player_ptr, bmc_type *bmc_ptr)
+bool cast_blue_summon_unique(PlayerType *player_ptr, bmc_type *bmc_ptr)
 {
     int count = 0;
     msg_print(_("特別な強敵を召喚した!", "You summon a special opponent!"));
index 997045e..79d90b2 100644 (file)
@@ -5,20 +5,20 @@
  */
 
 struct bmc_type;
-struct player_type;
-bool cast_blue_summon_kin(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_cyber(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_monster(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_monsters(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_ant(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_spider(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_hound(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_hydra(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_angel(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_demon(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_undead(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_dragon(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_high_undead(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_high_dragon(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_amberite(player_type *player_ptr, bmc_type *bmc_ptr);
-bool cast_blue_summon_unique(player_type *player_ptr, bmc_type *bmc_ptr);
+class PlayerType;
+bool cast_blue_summon_kin(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_cyber(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_monster(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_monsters(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_ant(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_spider(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_hound(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_hydra(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_angel(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_demon(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_undead(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_dragon(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_high_undead(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_high_dragon(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_amberite(PlayerType *player_ptr, bmc_type *bmc_ptr);
+bool cast_blue_summon_unique(PlayerType *player_ptr, bmc_type *bmc_ptr);
index 3f643fe..2ffeb0e 100644 (file)
@@ -8,7 +8,7 @@
 #include "system/player-type-definition.h"
 
 bmc_type *initialize_blue_magic_type(
-    player_type *player_ptr, bmc_type *bmc_ptr, const bool success, get_pseudo_monstetr_level_pf get_pseudo_monstetr_level)
+    PlayerType *player_ptr, bmc_type *bmc_ptr, const bool success, get_pseudo_monstetr_level_pf get_pseudo_monstetr_level)
 {
     bmc_ptr->plev = (*get_pseudo_monstetr_level)(player_ptr);
     bmc_ptr->summon_lev = player_ptr->lev * 2 / 3 + randint1(player_ptr->lev / 2);
index 575cb35..0ebefb2 100644 (file)
@@ -19,7 +19,7 @@ typedef struct bmc_type {
     BIT_FLAGS g_mode;
 } bmc_type;
 
-struct player_type;
-typedef PLAYER_LEVEL (*get_pseudo_monstetr_level_pf)(player_type *player_ptr);
+class PlayerType;
+typedef PLAYER_LEVEL (*get_pseudo_monstetr_level_pf)(PlayerType *player_ptr);
 bmc_type *initialize_blue_magic_type(
-    player_type *player_ptr, bmc_type *bmc_ptr, const bool success, get_pseudo_monstetr_level_pf get_pseudo_monstetr_level);
+    PlayerType *player_ptr, bmc_type *bmc_ptr, const bool success, get_pseudo_monstetr_level_pf get_pseudo_monstetr_level);
index 07bab31..0ff3342 100644 (file)
@@ -15,7 +15,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param 換算レベル
  */
-PLAYER_LEVEL get_pseudo_monstetr_level(player_type *player_ptr)
+PLAYER_LEVEL get_pseudo_monstetr_level(PlayerType *player_ptr)
 {
     PLAYER_LEVEL monster_level = player_ptr->lev + 40;
     return (monster_level * monster_level - 1550) / 130;
@@ -28,7 +28,7 @@ PLAYER_LEVEL get_pseudo_monstetr_level(player_type *player_ptr)
  * @param msg 表示する文字列
  * @param tmp 返すメッセージを格納する配列
  */
-static void set_bluemage_damage(player_type *player_ptr, MonsterAbilityType ms_type, PLAYER_LEVEL plev, concptr msg, char *tmp)
+static void set_bluemage_damage(PlayerType *player_ptr, MonsterAbilityType ms_type, PLAYER_LEVEL plev, concptr msg, char *tmp)
 {
     int base_damage = monspell_bluemage_damage(player_ptr, ms_type, plev, BASE_DAM);
     int dice_num = monspell_bluemage_damage(player_ptr, ms_type, plev, DICE_NUM);
@@ -46,7 +46,7 @@ static void set_bluemage_damage(player_type *player_ptr, MonsterAbilityType ms_t
  * @param p 情報を返す文字列参照ポインタ
  * @param power モンスター魔法のID
  */
-void learnt_info(player_type *player_ptr, char *p, MonsterAbilityType power)
+void learnt_info(PlayerType *player_ptr, char *p, MonsterAbilityType power)
 {
     PLAYER_LEVEL plev = get_pseudo_monstetr_level(player_ptr);
 
index e1894bc..f073fd3 100644 (file)
@@ -8,6 +8,6 @@
 
 enum class MonsterAbilityType;
 
-struct player_type;
-PLAYER_LEVEL get_pseudo_monstetr_level(player_type *player_ptr);
-void learnt_info(player_type *player_ptr, char *p, MonsterAbilityType power);
+class PlayerType;
+PLAYER_LEVEL get_pseudo_monstetr_level(PlayerType *player_ptr);
+void learnt_info(PlayerType *player_ptr, char *p, MonsterAbilityType power);
index 40a5690..0fdc182 100644 (file)
@@ -250,7 +250,7 @@ static bool switch_blue_magic_choice(char key, int &menu_line, const bluemage_da
  * @param need_mana 青魔法を使うのに必要なMP
  * @return int 失敗率(%)を返す
  */
-int calculate_blue_magic_failure_probability(player_type *player_ptr, const monster_power &mp, int need_mana)
+int calculate_blue_magic_failure_probability(PlayerType *player_ptr, const monster_power &mp, int need_mana)
 {
     auto chance = mp.fail;
     if (player_ptr->lev > mp.level) {
@@ -312,7 +312,7 @@ static void close_blue_magic_name(char *buf, size_t buf_size, int index, int men
  * @param bluemage_data 青魔道士の固有データへの参照
  * @param blue_magics 青魔法のリスト(覚えていないものも含まれているが、覚えていないものは表示をスキップする)
  */
-static void describe_blue_magic_name(player_type *player_ptr, int menu_line, const bluemage_data_type &bluemage_data, const std::vector<MonsterAbilityType> &blue_magics)
+static void describe_blue_magic_name(PlayerType *player_ptr, int menu_line, const bluemage_data_type &bluemage_data, const std::vector<MonsterAbilityType> &blue_magics)
 {
     constexpr TERM_LEN y_base = 1;
     constexpr TERM_LEN x_base = 18;
@@ -360,7 +360,7 @@ static bool confirm_cast_blue_magic(MonsterAbilityType spell)
  * @param blue_magics 青魔法のリスト(覚えていないものも含まれているが、覚えていない物は候補に出ず選択できない)
  * @return 選択した青魔法。選択をキャンセルした場合は std::nullopt
  */
-static std::optional<MonsterAbilityType> select_learnt_spells_by_symbol(player_type *player_ptr, const bluemage_data_type &bluemage_data, std::vector<MonsterAbilityType> spells)
+static std::optional<MonsterAbilityType> select_learnt_spells_by_symbol(PlayerType *player_ptr, const bluemage_data_type &bluemage_data, std::vector<MonsterAbilityType> spells)
 {
     char out_val[80];
     (void)strnfmt(out_val, sizeof(out_val), _("(%c-%c, '*'で一覧, ESC) どの%sを唱えますか?", "(%c-%c, *=List, ESC=exit) Use which %s? "),
@@ -417,7 +417,7 @@ static std::optional<MonsterAbilityType> select_learnt_spells_by_symbol(player_t
  * @param blue_magics 青魔法のリスト(覚えていないものも含まれているが、覚えていない物は候補に出ず選択できない)
  * @return 選択した青魔法。選択をキャンセルした場合は std::nullopt
  */
-static std::optional<MonsterAbilityType> select_learnt_spells_by_menu(player_type *player_ptr, const bluemage_data_type &bluemage_data, std::vector<MonsterAbilityType> spells)
+static std::optional<MonsterAbilityType> select_learnt_spells_by_menu(PlayerType *player_ptr, const bluemage_data_type &bluemage_data, std::vector<MonsterAbilityType> spells)
 {
     char out_val[80];
     angband_strcpy(out_val, _("(ESC=中断) どの魔法を唱えますか?", "(ESC=exit) Use which magic? "), sizeof(out_val));
@@ -472,7 +472,7 @@ static std::optional<MonsterAbilityType> select_learnt_spells_by_menu(player_typ
  * when you run it. It's probably easy to fix but I haven't tried,\n
  * sorry.\n
  */
-std::optional<MonsterAbilityType> get_learned_power(player_type *player_ptr)
+std::optional<MonsterAbilityType> get_learned_power(PlayerType *player_ptr)
 {
     auto bluemage_data = PlayerClass(player_ptr).get_specific_data<bluemage_data_type>();
     if (!bluemage_data) {
index 2fbb2f6..c3049a3 100644 (file)
@@ -9,7 +9,7 @@
 #include <optional>
 
 enum class MonsterAbilityType;
-struct player_type;
+class PlayerType;
 struct monster_power;
-int calculate_blue_magic_failure_probability(player_type *player_ptr, const monster_power &mp, int need_mana);
-std::optional<MonsterAbilityType> get_learned_power(player_type *player_ptr);
+int calculate_blue_magic_failure_probability(PlayerType *player_ptr, const monster_power &mp, int need_mana);
+std::optional<MonsterAbilityType> get_learned_power(PlayerType *player_ptr);
index af2727c..cd984d6 100644 (file)
@@ -66,7 +66,7 @@
  * @param fear 攻撃を受けたモンスターが恐慌状態に陥ったかを返す参照ポインタ
  * @param mdeath 攻撃を受けたモンスターが死亡したかを返す参照ポインタ
  */
-static void natural_attack(player_type *player_ptr, MONSTER_IDX m_idx, PlayerMutationType attack, bool *fear, bool *mdeath)
+static void natural_attack(PlayerType *player_ptr, MONSTER_IDX m_idx, PlayerMutationType attack, bool *fear, bool *mdeath)
 {
     WEIGHT n_weight = 0;
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
@@ -167,7 +167,7 @@ static void natural_attack(player_type *player_ptr, MONSTER_IDX m_idx, PlayerMut
  * @details
  * If no "weapon" is available, then "punch" the monster one time.
  */
-bool do_cmd_attack(player_type *player_ptr, POSITION y, POSITION x, combat_options mode)
+bool do_cmd_attack(PlayerType *player_ptr, POSITION y, POSITION x, combat_options mode)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[g_ptr->m_idx];
index a25e268..62fdd66 100644 (file)
@@ -3,5 +3,5 @@
 #include "combat/combat-options-type.h"
 #include "system/angband.h"
 
-struct player_type;
-bool do_cmd_attack(player_type *player_ptr, POSITION y, POSITION x, combat_options mode);
+class PlayerType;
+bool do_cmd_attack(PlayerType *player_ptr, POSITION y, POSITION x, combat_options mode);
index 9b51e3d..205ab04 100644 (file)
@@ -61,7 +61,7 @@
  * when you run it. It's probably easy to fix but I haven't tried,\n
  * sorry.\n
  */
-static int get_hissatsu_power(player_type *player_ptr, SPELL_IDX *sn)
+static int get_hissatsu_power(PlayerType *player_ptr, SPELL_IDX *sn)
 {
     SPELL_IDX i;
     int j = 0;
@@ -308,7 +308,7 @@ static int get_hissatsu_power(player_type *player_ptr, SPELL_IDX *sn)
 /*!
  * @brief 剣術コマンドのメインルーチン
  */
-void do_cmd_hissatsu(player_type *player_ptr)
+void do_cmd_hissatsu(PlayerType *player_ptr)
 {
     SPELL_IDX n = 0;
     magic_type spell;
@@ -363,7 +363,7 @@ void do_cmd_hissatsu(player_type *player_ptr)
 /*!
  * @brief 剣術コマンドの学習
  */
-void do_cmd_gain_hissatsu(player_type *player_ptr)
+void do_cmd_gain_hissatsu(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     int i, j;
index d328748..cdafa6e 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void do_cmd_hissatsu(player_type *player_ptr);
-void do_cmd_gain_hissatsu(player_type *player_ptr);
+class PlayerType;
+void do_cmd_hissatsu(PlayerType *player_ptr);
+void do_cmd_gain_hissatsu(PlayerType *player_ptr);
index 0aca06d..d791668 100644 (file)
@@ -82,7 +82,7 @@ static int damage;
  * @param power ものまねの効力の種類
  * @param dam ものまねの威力
  */
-static void mane_info(player_type *player_ptr, char *p, MonsterAbilityType power, HIT_POINT dam)
+static void mane_info(PlayerType *player_ptr, char *p, MonsterAbilityType power, HIT_POINT dam)
 {
     PLAYER_LEVEL plev = player_ptr->lev;
 
@@ -139,7 +139,7 @@ static void mane_info(player_type *player_ptr, char *p, MonsterAbilityType power
  * when you run it. It's probably easy to fix but I haven't tried,
  * sorry.
  */
-static int get_mane_power(player_type *player_ptr, int *sn, bool baigaesi)
+static int get_mane_power(PlayerType *player_ptr, int *sn, bool baigaesi)
 {
     int i = 0;
     int num = 0;
@@ -310,7 +310,7 @@ static int get_mane_power(player_type *player_ptr, int *sn, bool baigaesi)
  * @param spell 発動するモンスター攻撃のID
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-static bool use_mane(player_type *player_ptr, MonsterAbilityType spell)
+static bool use_mane(PlayerType *player_ptr, MonsterAbilityType spell)
 {
     DIRECTION dir;
     PLAYER_LEVEL plev = player_ptr->lev;
@@ -1079,7 +1079,7 @@ static bool use_mane(player_type *player_ptr, MonsterAbilityType spell)
  * when you run it. It's probably easy to fix but I haven't tried,
  * sorry.
  */
-bool do_cmd_mane(player_type *player_ptr, bool baigaesi)
+bool do_cmd_mane(PlayerType *player_ptr, bool baigaesi)
 {
     int n = 0;
     PERCENTAGE chance;
index b5aa72a..6338c34 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool do_cmd_mane(player_type *player_ptr, bool baigaesi);
+class PlayerType;
+bool do_cmd_mane(PlayerType *player_ptr, bool baigaesi);
index 0a054b7..d250fab 100644 (file)
@@ -74,7 +74,7 @@ typedef struct cm_type {
 /*!
  * @brief 職業技能処理構造体の初期化
  */
-static cm_type *initialize_cm_type(player_type *player_ptr, cm_type *cm_ptr)
+static cm_type *initialize_cm_type(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     cm_ptr->n = 0;
     cm_ptr->b = 0;
@@ -88,7 +88,7 @@ static cm_type *initialize_cm_type(player_type *player_ptr, cm_type *cm_ptr)
 /*!
  * @brief 職業別の行使可能な技能種別を構造体に付加する
  */
-static void switch_mind_kind(player_type *player_ptr, cm_type *cm_ptr)
+static void switch_mind_kind(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     switch (player_ptr->pclass) {
     case PlayerClassType::MINDCRAFTER:
@@ -118,7 +118,7 @@ static void switch_mind_kind(player_type *player_ptr, cm_type *cm_ptr)
     }
 }
 
-static void decide_mind_ki_chance(player_type *player_ptr, cm_type *cm_ptr)
+static void decide_mind_ki_chance(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     if (cm_ptr->use_mind != MindKindType::KI)
         return;
@@ -141,7 +141,7 @@ static void decide_mind_ki_chance(player_type *player_ptr, cm_type *cm_ptr)
             cm_ptr->mana_cost += (j + 1) * 3 / 2;
 }
 
-static bool check_mind_hp_mp_sufficiency(player_type *player_ptr, cm_type *cm_ptr)
+static bool check_mind_hp_mp_sufficiency(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     if ((cm_ptr->use_mind == MindKindType::BERSERKER) || (cm_ptr->use_mind == MindKindType::NINJUTSU)) {
         if (cm_ptr->mana_cost > player_ptr->chp) {
@@ -162,7 +162,7 @@ static bool check_mind_hp_mp_sufficiency(player_type *player_ptr, cm_type *cm_pt
     return get_check(_("それでも挑戦しますか? ", "Attempt it anyway? "));
 }
 
-static void decide_mind_chance(player_type *player_ptr, cm_type *cm_ptr)
+static void decide_mind_chance(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     if (cm_ptr->chance == 0)
         return;
@@ -193,7 +193,7 @@ static void decide_mind_chance(player_type *player_ptr, cm_type *cm_ptr)
         cm_ptr->chance += 5;
 }
 
-static void check_mind_mindcrafter(player_type *player_ptr, cm_type *cm_ptr)
+static void check_mind_mindcrafter(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     if (cm_ptr->use_mind != MindKindType::MINDCRAFTER)
         return;
@@ -228,7 +228,7 @@ static void check_mind_mindcrafter(player_type *player_ptr, cm_type *cm_ptr)
     player_ptr->csp = std::max(0, player_ptr->csp - cm_ptr->plev * std::max(1, cm_ptr->plev / 10));
 }
 
-static void check_mind_mirror_master(player_type *player_ptr, cm_type *cm_ptr)
+static void check_mind_mirror_master(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     if (cm_ptr->use_mind != MindKindType::MIRROR_MASTER)
         return;
@@ -254,7 +254,7 @@ static void check_mind_mirror_master(player_type *player_ptr, cm_type *cm_ptr)
     player_ptr->csp = std::max(0, player_ptr->csp - cm_ptr->plev * std::max(1, cm_ptr->plev / 10));
 }
 
-static void check_mind_class(player_type *player_ptr, cm_type *cm_ptr)
+static void check_mind_class(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     if ((cm_ptr->use_mind == MindKindType::BERSERKER) || (cm_ptr->use_mind == MindKindType::NINJUTSU))
         return;
@@ -272,7 +272,7 @@ static void check_mind_class(player_type *player_ptr, cm_type *cm_ptr)
     check_mind_mirror_master(player_ptr, cm_ptr);
 }
 
-static bool switch_mind_class(player_type *player_ptr, cm_type *cm_ptr)
+static bool switch_mind_class(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     switch (cm_ptr->use_mind) {
     case MindKindType::MINDCRAFTER:
@@ -299,7 +299,7 @@ static bool switch_mind_class(player_type *player_ptr, cm_type *cm_ptr)
     }
 }
 
-static void mind_turn_passing(player_type *player_ptr, cm_type *cm_ptr)
+static void mind_turn_passing(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     PlayerEnergy energy(player_ptr);
     if (cm_ptr->on_mirror && (player_ptr->pclass == PlayerClassType::MIRROR_MASTER)) {
@@ -312,7 +312,7 @@ static void mind_turn_passing(player_type *player_ptr, cm_type *cm_ptr)
     energy.set_player_turn_energy(100);
 }
 
-static bool judge_mind_chance(player_type *player_ptr, cm_type *cm_ptr)
+static bool judge_mind_chance(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     if (randint0(100) >= cm_ptr->chance) {
         sound(SOUND_ZAP);
@@ -328,7 +328,7 @@ static bool judge_mind_chance(player_type *player_ptr, cm_type *cm_ptr)
     return true;
 }
 
-static void mind_reflection(player_type *player_ptr, cm_type *cm_ptr)
+static void mind_reflection(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     int oops = cm_ptr->mana_cost - cm_ptr->old_csp;
     if ((player_ptr->csp - cm_ptr->mana_cost) < 0)
@@ -345,7 +345,7 @@ static void mind_reflection(player_type *player_ptr, cm_type *cm_ptr)
     (void)dec_stat(player_ptr, A_WIS, 15 + randint1(10), perm);
 }
 
-static void process_hard_concentration(player_type *player_ptr, cm_type *cm_ptr)
+static void process_hard_concentration(PlayerType *player_ptr, cm_type *cm_ptr)
 {
     if ((cm_ptr->use_mind == MindKindType::BERSERKER) || (cm_ptr->use_mind == MindKindType::NINJUTSU)) {
         take_hit(player_ptr, DAMAGE_USELIFE, cm_ptr->mana_cost, _("過度の集中", "concentrating too hard"));
@@ -371,7 +371,7 @@ static void process_hard_concentration(player_type *player_ptr, cm_type *cm_ptr)
 /*!
  * @brief 特殊技能コマンドのメインルーチン /
  */
-void do_cmd_mind(player_type *player_ptr)
+void do_cmd_mind(PlayerType *player_ptr)
 {
     cm_type tmp_cm;
     cm_type *cm_ptr = initialize_cm_type(player_ptr, &tmp_cm);
@@ -400,7 +400,7 @@ void do_cmd_mind(player_type *player_ptr)
     player_ptr->window_flags |= PW_SPELL;
 }
 
-static MindKindType decide_use_mind_browse(player_type *player_ptr)
+static MindKindType decide_use_mind_browse(PlayerType *player_ptr)
 {
     switch (player_ptr->pclass) {
     case PlayerClassType::MINDCRAFTER:
@@ -421,7 +421,7 @@ static MindKindType decide_use_mind_browse(player_type *player_ptr)
 /*!
  * @brief 現在プレイヤーが使用可能な特殊技能の一覧表示 /
  */
-void do_cmd_mind_browse(player_type *player_ptr)
+void do_cmd_mind_browse(PlayerType *player_ptr)
 {
     SPELL_IDX n = 0;
     char temp[62 * 5];
index be51b14..b8d053d 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
-struct player_type;
-void do_cmd_mind(player_type *player_ptr);
-void do_cmd_mind_browse(player_type *player_ptr);
-void do_cmd_mind_browse(player_type *player_ptr);
+class PlayerType;
+void do_cmd_mind(PlayerType *player_ptr);
+void do_cmd_mind_browse(PlayerType *player_ptr);
+void do_cmd_mind_browse(PlayerType *player_ptr);
 
index 8472a06..38d4ffd 100644 (file)
@@ -51,7 +51,7 @@
  * @param down_stair TRUEならば階段を降りる処理、FALSEなら階段を昇る処理による内容
  * @return フロア移動を実際に行うならTRUE、キャンセルする場合はFALSE
  */
-static bool confirm_leave_level(player_type *player_ptr, bool down_stair)
+static bool confirm_leave_level(PlayerType *player_ptr, bool down_stair)
 {
     quest_type *q_ptr = &quest[player_ptr->current_floor_ptr->inside_quest];
     if (confirm_quest && player_ptr->current_floor_ptr->inside_quest
@@ -68,7 +68,7 @@ static bool confirm_leave_level(player_type *player_ptr, bool down_stair)
 /*!
  * @brief 階段を使って階層を昇る処理 / Go up one level
  */
-void do_cmd_go_up(player_type *player_ptr)
+void do_cmd_go_up(PlayerType *player_ptr)
 {
     bool go_up = false;
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[player_ptr->y][player_ptr->x];
@@ -176,7 +176,7 @@ void do_cmd_go_up(player_type *player_ptr)
  * @brief 階段を使って階層を降りる処理 / Go down one level
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_go_down(player_type *player_ptr)
+void do_cmd_go_down(PlayerType *player_ptr)
 {
     bool fall_trap = false;
     int down_num = 0;
@@ -308,7 +308,7 @@ void do_cmd_go_down(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pickup アイテムの自動拾いを行うならTRUE
  */
-void do_cmd_walk(player_type *player_ptr, bool pickup)
+void do_cmd_walk(PlayerType *player_ptr, bool pickup)
 {
     if (command_arg) {
         command_rep = command_arg - 1;
@@ -361,7 +361,7 @@ void do_cmd_walk(player_type *player_ptr, bool pickup)
  * Start running.
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_run(player_type *player_ptr)
+void do_cmd_run(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (cmd_limit_confused(player_ptr))
@@ -382,7 +382,7 @@ void do_cmd_run(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pickup アイテムの自動拾いを行うならTRUE
  */
-void do_cmd_stay(player_type *player_ptr, bool pickup)
+void do_cmd_stay(PlayerType *player_ptr, bool pickup)
 {
     uint32_t mpe_mode = MPE_STAYING | MPE_ENERGY_USE;
     if (command_arg) {
@@ -403,7 +403,7 @@ void do_cmd_stay(player_type *player_ptr, bool pickup)
  * Resting allows a player to safely restore his hp    -RAK-
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_rest(player_type *player_ptr)
+void do_cmd_rest(PlayerType *player_ptr)
 {
     set_action(player_ptr, ACTION_NONE);
     if ((player_ptr->pclass == PlayerClassType::BARD) && ((get_singing_song_effect(player_ptr) != 0) || (get_interrupting_song_effect(player_ptr) != 0)))
index ecd3dd2..9871eaa 100644 (file)
@@ -1,9 +1,9 @@
 #pragma once
 
-struct player_type;
-void do_cmd_go_up(player_type *player_ptr);
-void do_cmd_go_down(player_type *player_ptr);
-void do_cmd_walk(player_type *player_ptr, bool pickup);
-void do_cmd_run(player_type *player_ptr);
-void do_cmd_stay(player_type *player_ptr, bool pickup);
-void do_cmd_rest(player_type *player_ptr);
+class PlayerType;
+void do_cmd_go_up(PlayerType *player_ptr);
+void do_cmd_go_down(PlayerType *player_ptr);
+void do_cmd_walk(PlayerType *player_ptr, bool pickup);
+void do_cmd_run(PlayerType *player_ptr);
+void do_cmd_stay(PlayerType *player_ptr, bool pickup);
+void do_cmd_rest(PlayerType *player_ptr);
index 903f715..f4cc56d 100644 (file)
@@ -39,7 +39,7 @@
  * @details
  * Assume there is no monster blocking the destination
  */
-static bool exe_open_chest(player_type *player_ptr, POSITION y, POSITION x, OBJECT_IDX o_idx)
+static bool exe_open_chest(PlayerType *player_ptr, POSITION y, POSITION x, OBJECT_IDX o_idx)
 {
     bool flag = true;
     bool more = false;
@@ -86,7 +86,7 @@ static bool exe_open_chest(player_type *player_ptr, POSITION y, POSITION x, OBJE
  * @details
  * Unlocking a locked door/chest is worth one experience point.
  */
-void do_cmd_open(player_type *player_ptr)
+void do_cmd_open(PlayerType *player_ptr)
 {
     POSITION y, x;
     DIRECTION dir;
@@ -144,7 +144,7 @@ void do_cmd_open(player_type *player_ptr)
  * @details
  * Unlocking a locked door/chest is worth one experience point.
  */
-void do_cmd_close(player_type *player_ptr)
+void do_cmd_close(PlayerType *player_ptr)
 {
     POSITION y, x;
     DIRECTION dir;
@@ -189,7 +189,7 @@ void do_cmd_close(player_type *player_ptr)
  * @brief 箱、床のトラップ解除処理双方の統合メインルーチン /
  * Disarms a trap, or chest
  */
-void do_cmd_disarm(player_type *player_ptr)
+void do_cmd_disarm(PlayerType *player_ptr)
 {
     POSITION y, x;
     DIRECTION dir;
@@ -257,7 +257,7 @@ void do_cmd_disarm(player_type *player_ptr)
  * Creatures can also open or bash doors, see elsewhere.
  * </pre>
  */
-void do_cmd_bash(player_type *player_ptr)
+void do_cmd_bash(PlayerType *player_ptr)
 {
     POSITION y, x;
     DIRECTION dir;
@@ -306,7 +306,7 @@ void do_cmd_bash(player_type *player_ptr)
  * Let user choose a pile of spikes, perhaps?
  * </pre>
  */
-static bool get_spike(player_type *player_ptr, INVENTORY_IDX *ip)
+static bool get_spike(PlayerType *player_ptr, INVENTORY_IDX *ip)
 {
     for (INVENTORY_IDX i = 0; i < INVEN_PACK; i++) {
         object_type *o_ptr = &player_ptr->inventory_list[i];
@@ -331,7 +331,7 @@ static bool get_spike(player_type *player_ptr, INVENTORY_IDX *ip)
  * This command may NOT be repeated
  * </pre>
  */
-void do_cmd_spike(player_type *player_ptr)
+void do_cmd_spike(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (player_ptr->wild_mode)
index 642226d..68b4c71 100644 (file)
@@ -1,8 +1,8 @@
 #pragma once
 
-struct player_type;
-void do_cmd_open(player_type *player_ptr);
-void do_cmd_close(player_type *player_ptr);
-void do_cmd_disarm(player_type *player_ptr);
-void do_cmd_bash(player_type *player_ptr);
-void do_cmd_spike(player_type *player_ptr);
+class PlayerType;
+void do_cmd_open(PlayerType *player_ptr);
+void do_cmd_close(PlayerType *player_ptr);
+void do_cmd_disarm(PlayerType *player_ptr);
+void do_cmd_bash(PlayerType *player_ptr);
+void do_cmd_spike(PlayerType *player_ptr);
index 4ae3e60..c5de2a5 100644 (file)
@@ -44,7 +44,7 @@
 /*!
  * @brief 探索コマンドのメインルーチン / Simple command to "search" for one turn
  */
-void do_cmd_search(player_type *player_ptr)
+void do_cmd_search(PlayerType *player_ptr)
 {
     if (command_arg) {
         command_rep = command_arg - 1;
@@ -59,7 +59,7 @@ void do_cmd_search(player_type *player_ptr)
         search(player_ptr);
 }
 
-static bool exe_alter(player_type *player_ptr)
+static bool exe_alter(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_rep_dir(player_ptr, &dir, true))
@@ -101,7 +101,7 @@ static bool exe_alter(player_type *player_ptr)
  * @brief 特定のマスに影響を及ぼすための汎用的コマンド / Manipulate an adjacent grid in some way
  * @details
  */
-void do_cmd_alter(player_type *player_ptr)
+void do_cmd_alter(PlayerType *player_ptr)
 {
     PlayerClass(player_ptr).break_samurai_stance({ SamuraiStanceType::MUSOU });
 
@@ -132,7 +132,7 @@ static bool decide_suicide(void)
     return i == '@';
 }
 
-static void accept_winner_message(player_type *player_ptr)
+static void accept_winner_message(PlayerType *player_ptr)
 {
     if (!w_ptr->total_winner || !last_words)
         return;
@@ -155,7 +155,7 @@ static void accept_winner_message(player_type *player_ptr)
  * commit suicide
  * @details
  */
-void do_cmd_suicide(player_type *player_ptr)
+void do_cmd_suicide(PlayerType *player_ptr)
 {
     flush();
     if (w_ptr->total_winner) {
index e6e6574..8c0ac9c 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void do_cmd_search(player_type *player_ptr);
-void do_cmd_alter(player_type *player_ptr);
-void do_cmd_suicide(player_type *player_ptr);
+class PlayerType;
+void do_cmd_search(PlayerType *player_ptr);
+void do_cmd_alter(PlayerType *player_ptr);
+void do_cmd_suicide(PlayerType *player_ptr);
index 0425c8b..a3fb88b 100644 (file)
@@ -70,7 +70,7 @@
 /*!
  * @brief ペットを開放するコマンドのメインルーチン
  */
-void do_cmd_pet_dismiss(player_type *player_ptr)
+void do_cmd_pet_dismiss(PlayerType *player_ptr)
 {
     monster_type *m_ptr;
     bool all_pets = false;
@@ -192,7 +192,7 @@ void do_cmd_pet_dismiss(player_type *player_ptr)
  * @param force 強制的に騎乗/下馬するならばTRUE
  * @return 騎乗/下馬できたらTRUE
  */
-bool do_cmd_riding(player_type *player_ptr, bool force)
+bool do_cmd_riding(PlayerType *player_ptr, bool force)
 {
     POSITION x, y;
     DIRECTION dir = 0;
@@ -303,7 +303,7 @@ bool do_cmd_riding(player_type *player_ptr, bool force)
 /*!
  * @brief ペットに名前をつけるコマンドのメインルーチン
  */
-static void do_name_pet(player_type *player_ptr)
+static void do_name_pet(PlayerType *player_ptr)
 {
     monster_type *m_ptr;
     char out_val[20];
@@ -369,7 +369,7 @@ static void do_name_pet(player_type *player_ptr)
  * @brief ペットに関するコマンドリストのメインルーチン /
  * Issue a pet command
  */
-void do_cmd_pet(player_type *player_ptr)
+void do_cmd_pet(PlayerType *player_ptr)
 {
     COMMAND_CODE i = 0;
     int num;
index 81fd47c..ad49110 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-bool do_cmd_riding(player_type *player_ptr, bool force);
-void do_cmd_pet_dismiss(player_type *player_ptr);
-void do_cmd_pet(player_type *player_ptr);
+class PlayerType;
+bool do_cmd_riding(PlayerType *player_ptr, bool force);
+void do_cmd_pet_dismiss(PlayerType *player_ptr);
+void do_cmd_pet(PlayerType *player_ptr);
index 59984cd..ec8632d 100644 (file)
@@ -55,7 +55,7 @@ static void racial_power_erase_cursor(rc_type *rc_ptr)
  * @param rc_ptr レイシャルパワー情報への参照ポインタ
  * @return キャンセルしたらRC_CANCEL、それ以外ならRC_CONTINUE
  */
-static void racial_power_display_list(player_type *player_ptr, rc_type *rc_ptr)
+static void racial_power_display_list(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     TERM_LEN x = 11;
     char dummy[256];
@@ -118,7 +118,7 @@ static void racial_power_make_prompt(rc_type *rc_ptr)
  * @param rc_ptr レイシャルパワー情報への参照ポインタ
  * @param i カーソル増分
  */
-static void racial_power_add_index(player_type *player_ptr, rc_type *rc_ptr, int i)
+static void racial_power_add_index(PlayerType *player_ptr, rc_type *rc_ptr, int i)
 {
     auto n = rc_ptr->menu_line + i;
     if (i < -1 || i > 1) {
@@ -147,7 +147,7 @@ static void racial_power_add_index(player_type *player_ptr, rc_type *rc_ptr, int
  * @param rc_ptr レイシャルパワー情報への参照ポインタ
  * @return キャンセルならRC_CANCEL、そうでないならRC_CONTINUE
  */
-static bool racial_power_interpret_menu_keys(player_type *player_ptr, rc_type *rc_ptr)
+static bool racial_power_interpret_menu_keys(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     switch (rc_ptr->choice) {
     case '0':
@@ -194,7 +194,7 @@ static bool racial_power_interpret_menu_keys(player_type *player_ptr, rc_type *r
  * @param rc_ptr レイシャルパワー情報への参照ポインタ
  * @return キャンセルしたらRC_CANCEL、それ以外ならRC_CONTINUE
  */
-static bool racial_power_select_by_menu(player_type *player_ptr, rc_type *rc_ptr)
+static bool racial_power_select_by_menu(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     if (!use_menu || rc_ptr->choice == ' ')
         return RC_CONTINUE;
@@ -214,7 +214,7 @@ static bool racial_power_select_by_menu(player_type *player_ptr, rc_type *rc_ptr
  * @param rc_ptr レイシャルパワー情報への参照ポインタ
  * @return コマンド選択していたらtrue、していなかったらfalse
  */
-static bool racial_power_interpret_choise(player_type *player_ptr, rc_type *rc_ptr)
+static bool racial_power_interpret_choise(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     if (use_menu)
         return false;
@@ -277,7 +277,7 @@ static bool ask_invoke_racial_power(rc_type *rc_ptr)
     return get_check(tmp_val);
 }
 
-static void racial_power_display_explanation(player_type *player_ptr, rc_type *rc_ptr)
+static void racial_power_display_explanation(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     auto &rpi = rc_ptr->power_desc[rc_ptr->command_code];
     char temp[62 * 5];
@@ -309,7 +309,7 @@ static void racial_power_display_explanation(player_type *player_ptr, rc_type *r
  * @param rc_ptr レイシャルパワー情報への参照ポインタ
  * @return コマンド選択したらRC_CONTINUE、キャンセルしたらRC_CANCEL
  */
-static bool racial_power_process_input(player_type *player_ptr, rc_type *rc_ptr)
+static bool racial_power_process_input(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     rc_ptr->choice = (always_show_list || use_menu) ? ESCAPE : 1;
 
@@ -345,7 +345,7 @@ static bool racial_power_process_input(player_type *player_ptr, rc_type *rc_ptr)
  * @param rc_ptr レイシャルパワー情報への参照ポインタ
  * @return コマンド選択したらRC_CONTINUE、キャンセルしたらRC_CANCEL
  */
-static bool racial_power_select_power(player_type *player_ptr, rc_type *rc_ptr)
+static bool racial_power_select_power(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     if (repeat_pull(&rc_ptr->command_code) && rc_ptr->command_code >= 0 && rc_ptr->command_code < rc_ptr->power_count())
         return RC_CONTINUE;
@@ -373,7 +373,7 @@ static bool racial_power_select_power(player_type *player_ptr, rc_type *rc_ptr)
  * @details
  * 戻り値の代わりにrc_ptr->castに使用の有無を入れる。
  */
-static void racial_power_cast_power(player_type *player_ptr, rc_type *rc_ptr)
+static void racial_power_cast_power(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     auto *rpi_ptr = &rc_ptr->power_desc[rc_ptr->command_code];
 
@@ -402,7 +402,7 @@ static void racial_power_cast_power(player_type *player_ptr, rc_type *rc_ptr)
  * MPが足りない場合はHPを減らす。
  * 戻り値はHP/MPの再描画が必要か判定するのに使用。
  */
-static bool racial_power_reduce_mana(player_type *player_ptr, rc_type *rc_ptr)
+static bool racial_power_reduce_mana(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     int racial_cost = rc_ptr->power_desc[rc_ptr->command_code].racial_cost;
     if (racial_cost == 0)
@@ -425,7 +425,7 @@ static bool racial_power_reduce_mana(player_type *player_ptr, rc_type *rc_ptr)
  * @brief レイシャル・パワーコマンドのメインルーチン / Allow user to choose a power (racial / mutation) to activate
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_racial_power(player_type *player_ptr)
+void do_cmd_racial_power(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode)
         return;
index a1f0e58..191696d 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_racial_power(player_type *player_ptr);
+class PlayerType;
+void do_cmd_racial_power(PlayerType *player_ptr);
index 29cd929..c8cbd67 100644 (file)
@@ -24,7 +24,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param snipe_type スナイパーの射撃術の種類
  */
-void do_cmd_fire(player_type *player_ptr, SPELL_IDX snipe_type)
+void do_cmd_fire(PlayerType *player_ptr, SPELL_IDX snipe_type)
 {
     OBJECT_IDX item;
     object_type *j_ptr, *ammo_ptr;
index a03cefd..ae6e94a 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void do_cmd_fire(player_type *player_ptr, SPELL_IDX snipe_type);
+class PlayerType;
+void do_cmd_fire(PlayerType *player_ptr, SPELL_IDX snipe_type);
index d76f55f..b8cd357 100644 (file)
@@ -246,7 +246,7 @@ concptr info_weight(WEIGHT weight)
  * @param use_realm 魔法領域ID
  * @return 失敗率(%)
  */
-static bool spell_okay(player_type *player_ptr, int spell, bool learned, bool study_pray, int use_realm)
+static bool spell_okay(PlayerType *player_ptr, int spell, bool learned, bool study_pray, int use_realm)
 {
     const magic_type *s_ptr;
 
@@ -299,7 +299,7 @@ static bool spell_okay(player_type *player_ptr, int spell, bool learned, bool st
  * The "known" should be TRUE for cast/pray, FALSE for study
  * </pre>
  */
-static int get_spell(player_type *player_ptr, SPELL_IDX *sn, concptr prompt, OBJECT_SUBTYPE_VALUE sval, bool learned, int16_t use_realm)
+static int get_spell(PlayerType *player_ptr, SPELL_IDX *sn, concptr prompt, OBJECT_SUBTYPE_VALUE sval, bool learned, int16_t use_realm)
 {
     int i;
     SPELL_IDX spell = -1;
@@ -542,7 +542,7 @@ static int get_spell(player_type *player_ptr, SPELL_IDX *sn, concptr prompt, OBJ
  * @param browse_only 魔法と技能の閲覧を行うならばTRUE
  * @return 魔道書を一冊も持っていないならTRUEを返す
  */
-static void confirm_use_force(player_type *player_ptr, bool browse_only)
+static void confirm_use_force(PlayerType *player_ptr, bool browse_only)
 {
     char which;
     COMMAND_CODE code;
@@ -576,12 +576,12 @@ static void confirm_use_force(player_type *player_ptr, bool browse_only)
     }
 }
 
-static FuncItemTester get_castable_spellbook_tester(player_type *player_ptr)
+static FuncItemTester get_castable_spellbook_tester(PlayerType *player_ptr)
 {
     return FuncItemTester([](auto p_ptr, auto o_ptr) { return check_book_realm(p_ptr, o_ptr->tval, o_ptr->sval); }, player_ptr);
 }
 
-static FuncItemTester get_learnable_spellbook_tester(player_type *player_ptr)
+static FuncItemTester get_learnable_spellbook_tester(PlayerType *player_ptr)
 {
     if (player_ptr->realm2 == REALM_NONE) {
         return get_castable_spellbook_tester(player_ptr);
@@ -601,7 +601,7 @@ static FuncItemTester get_learnable_spellbook_tester(player_type *player_ptr)
  * and in the dark, primarily to allow browsing in stores.
  * </pre>
  */
-void do_cmd_browse(player_type *player_ptr)
+void do_cmd_browse(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     OBJECT_SUBTYPE_VALUE sval;
@@ -714,7 +714,7 @@ void do_cmd_browse(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param next_realm 変更先の魔法領域ID
  */
-static void change_realm2(player_type *player_ptr, int16_t next_realm)
+static void change_realm2(PlayerType *player_ptr, int16_t next_realm)
 {
     int i, j = 0;
     char tmp[80];
@@ -751,7 +751,7 @@ static void change_realm2(player_type *player_ptr, int16_t next_realm)
  * @brief 魔法を学習するコマンドのメインルーチン /
  * Study a book to gain a new spell/prayer
  */
-void do_cmd_study(player_type *player_ptr)
+void do_cmd_study(PlayerType *player_ptr)
 {
     int i;
     OBJECT_IDX item;
@@ -959,7 +959,7 @@ void do_cmd_study(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 詠唱したらtrue
  */
-bool do_cmd_cast(player_type *player_ptr)
+bool do_cmd_cast(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     OBJECT_SUBTYPE_VALUE sval;
index d5fac46..dc2ad55 100644 (file)
@@ -26,7 +26,7 @@ concptr info_power_dice(DICE_NUMBER dice, DICE_SID sides);
 concptr info_radius(POSITION rad);
 concptr info_weight(WEIGHT weight);
 
-struct player_type;
-void do_cmd_browse(player_type *player_ptr);
-void do_cmd_study(player_type *player_ptr);
-bool do_cmd_cast(player_type *player_ptr);
+class PlayerType;
+void do_cmd_browse(PlayerType *player_ptr);
+void do_cmd_study(PlayerType *player_ptr);
+bool do_cmd_cast(PlayerType *player_ptr);
index 3685d3a..e488cbb 100644 (file)
@@ -23,7 +23,7 @@
  * @param x 該当地点のX座標
  * @return コスト値
  */
-static int travel_flow_cost(player_type *player_ptr, POSITION y, POSITION x)
+static int travel_flow_cost(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     int cost = 1;
     auto *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
@@ -67,7 +67,7 @@ static int travel_flow_cost(player_type *player_ptr, POSITION y, POSITION x)
  * @param n 現在のコスト
  * @param wall プレイヤーが壁の中にいるならばTRUE
  */
-static void travel_flow_aux(player_type *player_ptr, POSITION y, POSITION x, int n, bool wall)
+static void travel_flow_aux(PlayerType *player_ptr, POSITION y, POSITION x, int n, bool wall)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
@@ -111,7 +111,7 @@ static void travel_flow_aux(player_type *player_ptr, POSITION y, POSITION x, int
  * @param ty 目標地点のY座標
  * @param tx 目標地点のX座標
  */
-static void travel_flow(player_type *player_ptr, POSITION ty, POSITION tx)
+static void travel_flow(PlayerType *player_ptr, POSITION ty, POSITION tx)
 {
     flow_head = flow_tail = 0;
     bool wall = false;
@@ -137,7 +137,7 @@ static void travel_flow(player_type *player_ptr, POSITION ty, POSITION tx)
 /*!
  * @brief トラベル処理のメインルーチン
  */
-void do_cmd_travel(player_type *player_ptr)
+void do_cmd_travel(PlayerType *player_ptr)
 {
     POSITION x, y;
     if ((travel.x != 0) && (travel.y != 0) && (travel.x != player_ptr->x) && (travel.y != player_ptr->y)
index 0eb7ad6..d4a34b6 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_travel(player_type *player_ptr);
+class PlayerType;
+void do_cmd_travel(PlayerType *player_ptr);
index b8f073e..b849b57 100644 (file)
@@ -32,7 +32,7 @@
  * accomplished by strong players using heavy weapons.
  * </pre>
  */
-void do_cmd_tunnel(player_type *player_ptr)
+void do_cmd_tunnel(PlayerType *player_ptr)
 {
     bool more = false;
     PlayerClass(player_ptr).break_samurai_stance({ SamuraiStanceType::MUSOU });
index 2377117..264ba96 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_tunnel(player_type *player_ptr);
+class PlayerType;
+void do_cmd_tunnel(PlayerType *player_ptr);
index 5e6dcd4..0a13361 100644 (file)
@@ -80,7 +80,7 @@ bool reinit_wilderness = false;
  * @brief 町に関するヘルプを表示する / Display town history
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void town_history(player_type *player_ptr)
+static void town_history(PlayerType *player_ptr)
 {
     screen_save();
     (void)show_file(player_ptr, true, _("jbldg.txt", "bldg.txt"), nullptr, 0, 0);
@@ -93,7 +93,7 @@ static void town_history(player_type *player_ptr)
  * @param bldg 施設構造体の参照ポインタ
  * @param i 実行したい施設のサービステーブルの添字
  */
-static void bldg_process_command(player_type *player_ptr, building_type *bldg, int i)
+static void bldg_process_command(PlayerType *player_ptr, building_type *bldg, int i)
 {
     msg_flag = false;
     msg_erase();
@@ -297,7 +297,7 @@ static void bldg_process_command(player_type *player_ptr, building_type *bldg, i
  * @brief 施設入り口にプレイヤーが乗った際の処理 / Do building commands
  * @param プレイヤーへの参照ポインタ
  */
-void do_cmd_building(player_type *player_ptr)
+void do_cmd_building(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode)
         return;
index a8a8357..90107dc 100644 (file)
@@ -21,5 +21,5 @@ extern int battle_odds;
 extern PRICE kakekin;
 extern int sel_monster;
 
-struct player_type;
-void do_cmd_building(player_type *player_ptr);
+class PlayerType;
+void do_cmd_building(PlayerType *player_ptr);
index 9838035..4101f88 100644 (file)
@@ -26,7 +26,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 満腹ならFALSE、そうでないならTRUE
  */
-static bool buy_food(player_type *player_ptr)
+static bool buy_food(PlayerType *player_ptr)
 {
     if (player_ptr->food >= PY_FOOD_FULL) {
         msg_print(_("今は満腹だ。", "You are full now."));
@@ -43,7 +43,7 @@ static bool buy_food(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 毒でも切り傷でもないならTRUE、そうでないならFALSE
  */
-static bool is_healthy_stay(player_type *player_ptr)
+static bool is_healthy_stay(PlayerType *player_ptr)
 {
     if (!player_ptr->poisoned && !player_ptr->effects()->cut()->is_cut()) {
         return true;
@@ -56,7 +56,7 @@ static bool is_healthy_stay(player_type *player_ptr)
 }
 
 #ifdef JP
-static bool is_player_undead(player_type *player_ptr)
+static bool is_player_undead(PlayerType *player_ptr)
 {
     return PlayerRace(player_ptr, true).life() == PlayerRaceLifeType::UNDEAD;
 }
@@ -67,7 +67,7 @@ static bool is_player_undead(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param prev_hour 宿屋に入った直後のゲーム内時刻
  */
-static void write_diary_stay_inn(player_type *player_ptr, int prev_hour)
+static void write_diary_stay_inn(PlayerType *player_ptr, int prev_hour)
 {
     if ((prev_hour >= 6) && (prev_hour < 18)) {
         concptr stay_message = _(is_player_undead(player_ptr) ? "宿屋に泊まった。" : "日が暮れるまで宿屋で過ごした。", "stayed during the day at the inn.");
@@ -100,7 +100,7 @@ static void pass_game_turn_by_stay(void)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 悪夢モードならばTRUE
  */
-static bool has_a_nightmare(player_type *player_ptr)
+static bool has_a_nightmare(PlayerType *player_ptr)
 {
     if (!ironman_nightmare)
         return false;
@@ -122,7 +122,7 @@ static bool has_a_nightmare(player_type *player_ptr)
  * @brief 体調を元に戻す
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void back_to_health(player_type *player_ptr)
+static void back_to_health(PlayerType *player_ptr)
 {
     BadStatusSetter bss(player_ptr);
     (void)bss.blindness(0);
@@ -136,7 +136,7 @@ static void back_to_health(player_type *player_ptr)
  * @brief 魔道具術師の取り込んだ魔法をすべて完全に回復した状態にする
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void charge_magic_eating_energy(player_type *player_ptr)
+static void charge_magic_eating_energy(PlayerType *player_ptr)
 {
     auto magic_eater_data = PlayerClass(player_ptr).get_specific_data<magic_eater_data_type>();
     if (!magic_eater_data) {
@@ -158,7 +158,7 @@ static void charge_magic_eating_energy(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param prev_hour 宿屋に入った直後のゲーム内時刻
  */
-static void display_stay_result(player_type *player_ptr, int prev_hour)
+static void display_stay_result(PlayerType *player_ptr, int prev_hour)
 {
     if ((prev_hour >= 6) && (prev_hour < 18)) {
 #if JP
@@ -183,7 +183,7 @@ static void display_stay_result(player_type *player_ptr, int prev_hour)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 泊まれたらTRUE
  */
-static bool stay_inn(player_type *player_ptr)
+static bool stay_inn(PlayerType *player_ptr)
 {
     if (!is_healthy_stay(player_ptr))
         return false;
@@ -225,7 +225,7 @@ static bool stay_inn(player_type *player_ptr)
  * Resting at night is also a quick way to restock stores -KMW-
  * @todo 悪夢を見る前後に全回復しているが、何か意図がある?
  */
-bool inn_comm(player_type *player_ptr, int cmd)
+bool inn_comm(PlayerType *player_ptr, int cmd)
 {
     switch (cmd) {
     case BACT_FOOD:
index 21819d1..d98267d 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool inn_comm(player_type *player_ptr, int cmd);
+class PlayerType;
+bool inn_comm(PlayerType *player_ptr, int cmd);
index 0dea5b6..03c7293 100644 (file)
@@ -80,7 +80,7 @@ static int analyze_move_key(text_body_type *tb, int skey)
  * In-game editor of Object Auto-picker/Destoryer
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_edit_autopick(player_type *player_ptr)
+void do_cmd_edit_autopick(PlayerType *player_ptr)
 {
        static int cx_save = 0;
        static int cy_save = 0;
index d16c0f3..32a19c9 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_edit_autopick(player_type *player_ptr);
+class PlayerType;
+void do_cmd_edit_autopick(PlayerType *player_ptr);
index 0ca2345..398c2ce 100644 (file)
@@ -21,7 +21,7 @@
  * @brief 日記のタイトル表記と内容出力
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_diary(player_type *player_ptr)
+static void display_diary(PlayerType *player_ptr)
 {
     char diary_title[256];
     GAME_TEXT file_name[MAX_NLEN];
@@ -50,7 +50,7 @@ static void display_diary(player_type *player_ptr)
 /*!
  * @brief 日記に任意の内容を表記するコマンドのメインルーチン /
  */
-static void add_diary_note(player_type *player_ptr)
+static void add_diary_note(PlayerType *player_ptr)
 {
     char tmp[80] = "\0";
     char bunshou[80] = "\0";
@@ -63,7 +63,7 @@ static void add_diary_note(player_type *player_ptr)
 /*!
  * @brief 最後に取得したアイテムの情報を日記に追加するメインルーチン /
  */
-static void do_cmd_last_get(player_type *player_ptr)
+static void do_cmd_last_get(PlayerType *player_ptr)
 {
     if (record_o_name[0] == '\0')
         return;
@@ -110,7 +110,7 @@ static void do_cmd_erase_diary(void)
  * @brief 日記コマンド
  * @param crerature_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_diary(player_type *player_ptr)
+void do_cmd_diary(PlayerType *player_ptr)
 {
     screen_save();
     while (true) {
index 0cf8191..dea2d48 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_diary(player_type *player_ptr);
+class PlayerType;
+void do_cmd_diary(PlayerType *player_ptr);
index 106f9d4..308de13 100644 (file)
@@ -46,7 +46,7 @@
  * @details
  * Allow absolute file names?
  */
-void do_cmd_pref(player_type *player_ptr)
+void do_cmd_pref(PlayerType *player_ptr)
 {
     char buf[80];
     strcpy(buf, "");
@@ -59,7 +59,7 @@ void do_cmd_pref(player_type *player_ptr)
 /*
  * Interact with "colors"
  */
-void do_cmd_colors(player_type *player_ptr)
+void do_cmd_colors(PlayerType *player_ptr)
 {
     int i;
     char tmp[160];
@@ -203,7 +203,7 @@ void do_cmd_version(void)
  * Note that "feeling" is set to zero unless some time has passed.
  * Note that this is done when the level is GENERATED, not entered.
  */
-void do_cmd_feeling(player_type *player_ptr)
+void do_cmd_feeling(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode)
         return;
@@ -240,7 +240,7 @@ void do_cmd_feeling(player_type *player_ptr)
  * Display the time and date
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_time(player_type *player_ptr)
+void do_cmd_time(PlayerType *player_ptr)
 {
     int day, hour, min;
     extract_day_hour_min(player_ptr, &day, &hour, &min);
index 4fc9b57..1932e96 100644 (file)
@@ -1,9 +1,9 @@
 #pragma once
 
-struct player_type;
-void do_cmd_pref(player_type *player_ptr);
-void do_cmd_colors(player_type *player_ptr);
+class PlayerType;
+void do_cmd_pref(PlayerType *player_ptr);
+void do_cmd_colors(PlayerType *player_ptr);
 void do_cmd_note(void);
 void do_cmd_version(void);
-void do_cmd_feeling(player_type *player_ptr);
-void do_cmd_time(player_type *player_ptr);
+void do_cmd_feeling(PlayerType *player_ptr);
+void do_cmd_time(PlayerType *player_ptr);
index 3f64fe6..2f32e26 100644 (file)
@@ -21,7 +21,7 @@
  * @brief ターゲットを設定するコマンドのメインルーチン
  * Target command
  */
-void do_cmd_target(player_type *player_ptr)
+void do_cmd_target(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode)
         return;
@@ -36,7 +36,7 @@ void do_cmd_target(player_type *player_ptr)
  * @brief 周囲を見渡すコマンドのメインルーチン
  * Look command
  */
-void do_cmd_look(player_type *player_ptr)
+void do_cmd_look(PlayerType *player_ptr)
 {
     set_bits(player_ptr->window_flags, PW_MONSTER_LIST | PW_FLOOR_ITEM_LIST);
     handle_stuff(player_ptr);
@@ -48,7 +48,7 @@ void do_cmd_look(player_type *player_ptr)
  * @brief 位置を確認するコマンドのメインルーチン
  * Allow the player to examine other sectors on the map
  */
-void do_cmd_locate(player_type *player_ptr)
+void do_cmd_locate(PlayerType *player_ptr)
 {
     DIRECTION dir;
     POSITION y1, x1;
index c9e6a47..b6db78b 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void do_cmd_target(player_type *player_ptr);
-void do_cmd_look(player_type *player_ptr);
-void do_cmd_locate(player_type *player_ptr);
+class PlayerType;
+void do_cmd_target(PlayerType *player_ptr);
+void do_cmd_look(PlayerType *player_ptr);
+void do_cmd_locate(PlayerType *player_ptr);
index 3f65e55..e8414bd 100644 (file)
@@ -89,7 +89,7 @@ static int16_t toggle_frequency(int16_t current)
  * @brief 自動セーブオプションを変更するコマンドのメインルーチン
  * @param info 表示メッセージ
  */
-static void do_cmd_options_autosave(player_type *player_ptr, concptr info)
+static void do_cmd_options_autosave(PlayerType *player_ptr, concptr info)
 {
     char ch;
     int i, k = 0, n = 2;
@@ -213,7 +213,7 @@ static void clear_window_flag(int x, int y)
  * @brief ウィンドウオプションを変更するコマンドのメインルーチン /
  * Modify the "window" options
  */
-static void do_cmd_options_win(player_type *player_ptr)
+static void do_cmd_options_win(PlayerType *player_ptr)
 {
     int i, j, d;
     TERM_LEN y = 0;
@@ -318,7 +318,7 @@ static void do_cmd_options_win(player_type *player_ptr)
  * Interact with some options for cheating
  * @param info 表示メッセージ
  */
-static void do_cmd_options_cheat(player_type *player_ptr, concptr info)
+static void do_cmd_options_cheat(PlayerType *player_ptr, concptr info)
 {
     term_clear();
     auto k = 0U;
@@ -422,7 +422,7 @@ void extract_option_vars(void)
  * in any options which control "visual" aspects of the game.
  * </pre>
  */
-void do_cmd_options(player_type *player_ptr)
+void do_cmd_options(PlayerType *player_ptr)
 {
     char k;
     int d, skey;
@@ -617,7 +617,7 @@ void do_cmd_options(player_type *player_ptr)
  * @param page オプションページ番号
  * @param info 表示メッセージ
  */
-void do_cmd_options_aux(player_type *player_ptr, game_option_types page, concptr info)
+void do_cmd_options_aux(PlayerType *player_ptr, game_option_types page, concptr info)
 {
     char ch;
     int i, k = 0, n = 0, l;
index f21323d..fa9b023 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 #include "system/game-option-types.h"
 
-struct player_type;
+class PlayerType;
 void extract_option_vars(void);
-void do_cmd_options_aux(player_type *player_ptr, game_option_types page, concptr info);
-void do_cmd_options(player_type *player_ptr);
+void do_cmd_options_aux(PlayerType *player_ptr, game_option_types page, concptr info);
+void do_cmd_options(PlayerType *player_ptr);
index d90630b..5ff571d 100644 (file)
@@ -9,7 +9,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details
  */
-void do_cmd_help(player_type *player_ptr)
+void do_cmd_help(PlayerType *player_ptr)
 {
        screen_save();
        (void)show_file(player_ptr, true, _("jhelp.hlp", "help.hlp"), nullptr, 0, 0);
index bb631e0..f3ed4a0 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_help(player_type *player_ptr);
+class PlayerType;
+void do_cmd_help(PlayerType *player_ptr);
index 80b67c1..77fc2f5 100644 (file)
@@ -22,7 +22,7 @@
 /*
  * Interact with "knowledge"
  */
-void do_cmd_knowledge(player_type *player_ptr)
+void do_cmd_knowledge(PlayerType *player_ptr)
 {
     int i, p = 0;
     bool need_redraw = false;
index 7f4cacd..f0a92df 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_knowledge(player_type *player_ptr);
+class PlayerType;
+void do_cmd_knowledge(PlayerType *player_ptr);
index 1e786fd..bb8f7aa 100644 (file)
@@ -34,7 +34,7 @@
  * Note that the player ghosts are ignored.
  * </pre>
  */
-void do_cmd_query_symbol(player_type *player_ptr)
+void do_cmd_query_symbol(PlayerType *player_ptr)
 {
     char sym, query;
     char buf[256];
index 4e402bf..e4b2b42 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_query_symbol(player_type *player_ptr);
+class PlayerType;
+void do_cmd_query_symbol(PlayerType *player_ptr);
index f6a1ead..cdd5615 100644 (file)
@@ -146,7 +146,7 @@ static errr keymap_dump(concptr fname)
  * Could use some helpful instructions on this page.
  * </pre>
  */
-void do_cmd_macros(player_type *player_ptr)
+void do_cmd_macros(PlayerType *player_ptr)
 {
     char tmp[1024];
     char buf[1024];
index 8ad9137..0f95108 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_macros(player_type *player_ptr);
+class PlayerType;
+void do_cmd_macros(PlayerType *player_ptr);
index 5b28e47..1808edb 100644 (file)
@@ -336,7 +336,7 @@ static bool do_cmd_save_screen_text(int wid, int hgt)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 記念撮影直前のグラフィックオプション
  */
-static bool update_use_graphics(player_type *player_ptr)
+static bool update_use_graphics(PlayerType *player_ptr)
 {
        if (!use_graphics) return true;
 
@@ -352,7 +352,7 @@ static bool update_use_graphics(player_type *player_ptr)
  * Save a screen dump to a file
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_save_screen(player_type *player_ptr)
+void do_cmd_save_screen(PlayerType *player_ptr)
 {
        prt(_("記念撮影しますか? [(y)es/(h)tml/(n)o] ", "Save screen dump? [(y)es/(h)tml/(n)o] "), 0, 0);
        bool html_dump;
index 424448b..42b81c3 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 void do_cmd_save_screen_html_aux(char *filename, int message);
-void do_cmd_save_screen(player_type *player_ptr);
+void do_cmd_save_screen(PlayerType *player_ptr);
 void do_cmd_load_screen(void);
index b928cb0..3c44841 100644 (file)
@@ -18,7 +18,7 @@
  * @param is_autosave オートセーブ中の処理ならばTRUE
  * @details
  */
-void do_cmd_save_game(player_type *player_ptr, int is_autosave)
+void do_cmd_save_game(PlayerType *player_ptr, int is_autosave)
 {
     if (is_autosave)
         msg_print(_("自動セーブ中", "Autosaving the game..."));
@@ -46,7 +46,7 @@ void do_cmd_save_game(player_type *player_ptr, int is_autosave)
  * Save the game and exit
  * @details
  */
-void do_cmd_save_and_exit(player_type *player_ptr)
+void do_cmd_save_and_exit(PlayerType *player_ptr)
 {
     player_ptr->playing = false;
     player_ptr->leaving = true;
index f65ff0b..f72b6a7 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void do_cmd_save_game(player_type *player_ptr, int is_autosave);
-void do_cmd_save_and_exit(player_type *player_ptr);
+class PlayerType;
+void do_cmd_save_game(PlayerType *player_ptr, int is_autosave);
+void do_cmd_save_and_exit(PlayerType *player_ptr);
index 851445a..37c71ec 100644 (file)
@@ -54,7 +54,7 @@ static destroy_type *initialize_destroy_type(destroy_type *destroy_ptr, object_t
     return destroy_ptr;
 }
 
-static bool check_destory_item(player_type *player_ptr, destroy_type *destroy_ptr)
+static bool check_destory_item(PlayerType *player_ptr, destroy_type *destroy_ptr)
 {
     if (destroy_ptr->force || (!confirm_destroy && (object_value(destroy_ptr->o_ptr) <= 0)))
         return true;
@@ -85,7 +85,7 @@ static bool check_destory_item(player_type *player_ptr, destroy_type *destroy_pt
     }
 }
 
-static bool select_destroying_item(player_type *player_ptr, destroy_type *destroy_ptr)
+static bool select_destroying_item(PlayerType *player_ptr, destroy_type *destroy_ptr)
 {
     concptr q = _("どのアイテムを壊しますか? ", "Destroy which item? ");
     concptr s = _("壊せるアイテムを持っていない。", "You have nothing to destroy.");
@@ -109,7 +109,7 @@ static bool select_destroying_item(player_type *player_ptr, destroy_type *destro
  * @param destory_ptr アイテム破壊構造体への参照ポインタ
  * return 魔法書の破壊によって経験値が入るならばTRUE
  */
-static bool decide_magic_book_exp(player_type *player_ptr, destroy_type *destroy_ptr)
+static bool decide_magic_book_exp(PlayerType *player_ptr, destroy_type *destroy_ptr)
 {
     if (player_ptr->prace == PlayerRaceType::ANDROID)
         return false;
@@ -132,7 +132,7 @@ static bool decide_magic_book_exp(player_type *player_ptr, destroy_type *destroy
     return gain_expr;
 }
 
-static void gain_exp_by_destroying_magic_book(player_type *player_ptr, destroy_type *destroy_ptr)
+static void gain_exp_by_destroying_magic_book(PlayerType *player_ptr, destroy_type *destroy_ptr)
 {
     bool gain_expr = decide_magic_book_exp(player_ptr, destroy_ptr);
     if (!gain_expr || (player_ptr->exp >= PY_MAX_EXP))
@@ -152,7 +152,7 @@ static void gain_exp_by_destroying_magic_book(player_type *player_ptr, destroy_t
     gain_exp(player_ptr, tester_exp * destroy_ptr->amt);
 }
 
-static void process_destroy_magic_book(player_type *player_ptr, destroy_type *destroy_ptr)
+static void process_destroy_magic_book(PlayerType *player_ptr, destroy_type *destroy_ptr)
 {
     if (!item_tester_high_level_book(destroy_ptr->q_ptr))
         return;
@@ -175,7 +175,7 @@ static void process_destroy_magic_book(player_type *player_ptr, destroy_type *de
         chg_virtue(player_ptr, V_SACRIFICE, 1);
 }
 
-static void exe_destroy_item(player_type *player_ptr, destroy_type *destroy_ptr)
+static void exe_destroy_item(PlayerType *player_ptr, destroy_type *destroy_ptr)
 {
     destroy_ptr->q_ptr->copy_from(destroy_ptr->o_ptr);
     msg_format(_("%sを壊した。", "You destroy %s."), destroy_ptr->o_name);
@@ -194,7 +194,7 @@ static void exe_destroy_item(player_type *player_ptr, destroy_type *destroy_ptr)
  * @brief アイテムを破壊するコマンドのメインルーチン / Destroy an item
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_destroy(player_type *player_ptr)
+void do_cmd_destroy(PlayerType *player_ptr)
 {
     PlayerClass(player_ptr).break_samurai_stance({ SamuraiStanceType::MUSOU });
 
index e48f318..366ad5d 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_destroy(player_type *player_ptr);
+class PlayerType;
+void do_cmd_destroy(PlayerType *player_ptr);
index 63e2148..59bb70d 100644 (file)
@@ -58,7 +58,7 @@
  * @param o_ptr 食べるオブジェクト
  * @return 鑑定されるならTRUE、されないならFALSE
  */
-bool exe_eat_food_type_object(player_type *player_ptr, object_type *o_ptr)
+bool exe_eat_food_type_object(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (o_ptr->tval != ItemKindType::FOOD)
         return false;
@@ -150,7 +150,7 @@ bool exe_eat_food_type_object(player_type *player_ptr, object_type *o_ptr)
  * @param item オブジェクトのインベントリ番号
  * @return 食べようとしたらTRUE、しなかったらFALSE
  */
-bool exe_eat_charge_of_magic_device(player_type *player_ptr, object_type *o_ptr, INVENTORY_IDX item)
+bool exe_eat_charge_of_magic_device(PlayerType *player_ptr, object_type *o_ptr, INVENTORY_IDX item)
 {
     if (o_ptr->tval != ItemKindType::STAFF && o_ptr->tval != ItemKindType::WAND)
         return false;
@@ -218,7 +218,7 @@ bool exe_eat_charge_of_magic_device(player_type *player_ptr, object_type *o_ptr,
  * @brief 食料を食べるコマンドのサブルーチン
  * @param item 食べるオブジェクトの所持品ID
  */
-void exe_eat_food(player_type *player_ptr, INVENTORY_IDX item)
+void exe_eat_food(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     if (music_singing_any(player_ptr))
         stop_singing(player_ptr);
@@ -332,7 +332,7 @@ void exe_eat_food(player_type *player_ptr, INVENTORY_IDX item)
  * @brief 食料を食べるコマンドのメインルーチン /
  * Eat some food (from the pack or floor)
  */
-void do_cmd_eat_food(player_type *player_ptr)
+void do_cmd_eat_food(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     concptr q, s;
index 6897502..7af0611 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void do_cmd_eat_food(player_type *player_ptr);
-void exe_eat_food(player_type *player_ptr, INVENTORY_IDX item);
+class PlayerType;
+void do_cmd_eat_food(PlayerType *player_ptr);
+void exe_eat_food(PlayerType *player_ptr, INVENTORY_IDX item);
index 3bb39fe..712cbcf 100644 (file)
@@ -53,7 +53,7 @@
 /*!
  * @brief 装備一覧を表示するコマンドのメインルーチン / Display equipment
  */
-void do_cmd_equip(player_type *player_ptr)
+void do_cmd_equip(PlayerType *player_ptr)
 {
     char out_val[160];
     command_wrk = true;
@@ -89,7 +89,7 @@ void do_cmd_equip(player_type *player_ptr)
  * @brief 装備するコマンドのメインルーチン / Wield or wear a single item from the pack or floor
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_wield(player_type *player_ptr)
+void do_cmd_wield(PlayerType *player_ptr)
 {
     OBJECT_IDX item, slot;
     object_type forge;
@@ -297,7 +297,7 @@ void do_cmd_wield(player_type *player_ptr)
 /*!
  * @brief 装備を外すコマンドのメインルーチン / Take off an item
  */
-void do_cmd_takeoff(player_type *player_ptr)
+void do_cmd_takeoff(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     object_type *o_ptr;
index 7938ecf..2163ff7 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void do_cmd_equip(player_type *player_ptr);
-void do_cmd_wield(player_type *player_ptr);
-void do_cmd_takeoff(player_type *player_ptr);
+class PlayerType;
+void do_cmd_equip(PlayerType *player_ptr);
+void do_cmd_wield(PlayerType *player_ptr);
+void do_cmd_takeoff(PlayerType *player_ptr);
index ee3b507..6e2d42b 100644 (file)
@@ -72,7 +72,7 @@
 /*!
  * @brief 持ち物一覧を表示するコマンドのメインルーチン / Display inventory_list
  */
-void do_cmd_inven(player_type *player_ptr)
+void do_cmd_inven(PlayerType *player_ptr)
 {
     char out_val[160];
     command_wrk = false;
@@ -107,7 +107,7 @@ void do_cmd_inven(player_type *player_ptr)
 /*!
  * @brief アイテムを落とすコマンドのメインルーチン / Drop an item
  */
-void do_cmd_drop(player_type *player_ptr)
+void do_cmd_drop(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     int amt = 1;
@@ -144,7 +144,7 @@ void do_cmd_drop(player_type *player_ptr)
 /*!
  * @brief アイテムを調査するコマンドのメインルーチン / Observe an item which has been *identify*-ed
  */
-void do_cmd_observe(player_type *player_ptr)
+void do_cmd_observe(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     object_type *o_ptr;
@@ -170,7 +170,7 @@ void do_cmd_observe(player_type *player_ptr)
  * @brief アイテムの銘を消すコマンドのメインルーチン
  * Remove the inscription from an object XXX Mention item (when done)?
  */
-void do_cmd_uninscribe(player_type *player_ptr)
+void do_cmd_uninscribe(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     object_type *o_ptr;
@@ -196,7 +196,7 @@ void do_cmd_uninscribe(player_type *player_ptr)
  * @brief アイテムの銘を刻むコマンドのメインルーチン
  * Inscribe an object with a comment
  */
-void do_cmd_inscribe(player_type *player_ptr)
+void do_cmd_inscribe(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     object_type *o_ptr;
@@ -229,7 +229,7 @@ void do_cmd_inscribe(player_type *player_ptr)
  * @details
  * XXX - Add actions for other item types
  */
-void do_cmd_use(player_type *player_ptr)
+void do_cmd_use(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     object_type *o_ptr;
@@ -285,7 +285,7 @@ void do_cmd_use(player_type *player_ptr)
  * @brief 装備を発動するコマンドのメインルーチン /
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_activate(player_type *player_ptr)
+void do_cmd_activate(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     if (player_ptr->wild_mode || cmd_limit_arena(player_ptr))
index 9270dd3..e3c0eef 100644 (file)
@@ -1,10 +1,10 @@
 #pragma once
 
-struct player_type;
-void do_cmd_inven(player_type *player_ptr);
-void do_cmd_drop(player_type *player_ptr);
-void do_cmd_observe(player_type *player_ptr);
-void do_cmd_uninscribe(player_type *player_ptr);
-void do_cmd_inscribe(player_type *player_ptr);
-void do_cmd_use(player_type *player_ptr);
-void do_cmd_activate(player_type *player_ptr);
+class PlayerType;
+void do_cmd_inven(PlayerType *player_ptr);
+void do_cmd_drop(PlayerType *player_ptr);
+void do_cmd_observe(PlayerType *player_ptr);
+void do_cmd_uninscribe(PlayerType *player_ptr);
+void do_cmd_inscribe(PlayerType *player_ptr);
+void do_cmd_use(PlayerType *player_ptr);
+void do_cmd_activate(PlayerType *player_ptr);
index 15fec08..7d996b2 100644 (file)
@@ -137,7 +137,7 @@ static std::optional<std::tuple<ItemKindType, OBJECT_SUBTYPE_VALUE>> check_magic
  * @param only_browse 閲覧するだけならばTRUE
  * @return 選択した魔力のID、キャンセルならば-1を返す
  */
-static std::optional<std::tuple<ItemKindType, OBJECT_SUBTYPE_VALUE>> select_magic_eater(player_type *player_ptr, bool only_browse)
+static std::optional<std::tuple<ItemKindType, OBJECT_SUBTYPE_VALUE>> select_magic_eater(PlayerType *player_ptr, bool only_browse)
 {
     char choice;
     bool flag, request_list;
@@ -545,7 +545,7 @@ static std::optional<std::tuple<ItemKindType, OBJECT_SUBTYPE_VALUE>> select_magi
  * @param powerful 強力発動中の処理ならばTRUE
  * @return 実際にコマンドを実行したならばTRUEを返す。
  */
-bool do_cmd_magic_eater(player_type *player_ptr, bool only_browse, bool powerful)
+bool do_cmd_magic_eater(PlayerType *player_ptr, bool only_browse, bool powerful)
 {
     bool use_charge = true;
 
index 6ce4a62..18224ed 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool do_cmd_magic_eater(player_type *player_ptr, bool only_browse, bool powerful);
+class PlayerType;
+bool do_cmd_magic_eater(PlayerType *player_ptr, bool only_browse, bool powerful);
index 9dccc4b..2b74a51 100644 (file)
@@ -24,7 +24,7 @@
  * @brief 薬を飲むコマンドのメインルーチン /
  * Quaff some potion (from the pack or floor)
  */
-void do_cmd_quaff_potion(player_type *player_ptr)
+void do_cmd_quaff_potion(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode)
         return;
index e532f85..335a526 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_quaff_potion(player_type *player_ptr);
+class PlayerType;
+void do_cmd_quaff_potion(PlayerType *player_ptr);
index 3ee10a4..ebf6ccc 100644 (file)
@@ -25,7 +25,7 @@
  * @brief 読むコマンドのメインルーチン /
  * Eat some food (from the pack or floor)
  */
-void do_cmd_read_scroll(player_type *player_ptr)
+void do_cmd_read_scroll(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode || cmd_limit_arena(player_ptr))
         return;
index a5ec587..afb5da3 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_read_scroll(player_type *player_ptr);
+class PlayerType;
+void do_cmd_read_scroll(PlayerType *player_ptr);
index 889922e..e4c7267 100644 (file)
@@ -26,7 +26,7 @@
  * @brief ランタンに燃料を加えるコマンドのメインルーチン
  * Refill the players lamp (from the pack or floor)
  */
-static void do_cmd_refill_lamp(player_type *player_ptr)
+static void do_cmd_refill_lamp(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     object_type *o_ptr;
@@ -63,7 +63,7 @@ static void do_cmd_refill_lamp(player_type *player_ptr)
  * @brief 松明を束ねるコマンドのメインルーチン
  * Refuel the players torch (from the pack or floor)
  */
-static void do_cmd_refill_torch(player_type *player_ptr)
+static void do_cmd_refill_torch(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     object_type *o_ptr;
@@ -101,7 +101,7 @@ static void do_cmd_refill_torch(player_type *player_ptr)
  * @brief 燃料を補充するコマンドのメインルーチン
  * Refill the players lamp, or restock his torches
  */
-void do_cmd_refill(player_type *player_ptr)
+void do_cmd_refill(PlayerType *player_ptr)
 {
     object_type *o_ptr;
     o_ptr = &player_ptr->inventory_list[INVEN_LITE];
index 1aef5d8..90d28fe 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_refill(player_type *player_ptr);
+class PlayerType;
+void do_cmd_refill(PlayerType *player_ptr);
index 2b0643e..f69d7a7 100644 (file)
@@ -18,7 +18,7 @@
 #include "system/object-type-definition.h"
 #include "system/player-type-definition.h"
 
-ThrowCommand::ThrowCommand(player_type *player_ptr)
+ThrowCommand::ThrowCommand(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index 8a77dbd..afeab27 100644 (file)
@@ -2,13 +2,13 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ThrowCommand {
 public:
-    ThrowCommand(player_type *player_ptr);
+    ThrowCommand(PlayerType *player_ptr);
     virtual ~ThrowCommand() = default;
     bool do_cmd_throw(int mult, bool boomerang, OBJECT_IDX shuriken);
     
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index fdf66c1..f139bc1 100644 (file)
@@ -50,7 +50,7 @@
  * @param known 判明済ならばTRUE
  * @return 発動により効果内容が確定したならばTRUEを返す
  */
-int staff_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, bool *use_charge, bool powerful, bool magic, bool known)
+int staff_effect(PlayerType *player_ptr, OBJECT_SUBTYPE_VALUE sval, bool *use_charge, bool powerful, bool magic, bool known)
 {
     int k;
     bool ident = false;
@@ -283,7 +283,7 @@ int staff_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, bool *use_c
 /*!
  * @brief 杖を使うコマンドのメインルーチン /
  */
-void do_cmd_use_staff(player_type *player_ptr)
+void do_cmd_use_staff(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     concptr q, s;
index 22909b4..8fc9b1d 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-int staff_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, bool *use_charge, bool powerful, bool magic, bool known);
-void do_cmd_use_staff(player_type *player_ptr);
+class PlayerType;
+int staff_effect(PlayerType *player_ptr, OBJECT_SUBTYPE_VALUE sval, bool *use_charge, bool powerful, bool magic, bool known);
+void do_cmd_use_staff(PlayerType *player_ptr);
index 7594b7d..6c3b9a1 100644 (file)
@@ -42,7 +42,7 @@
  * @param powerful 強力発動上の処理ならばTRUE
  * @return 発動により効果内容が確定したならばTRUEを返す
  */
-int rod_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool *use_charge, bool powerful)
+int rod_effect(PlayerType *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool *use_charge, bool powerful)
 {
     int ident = false;
     PLAYER_LEVEL lev = powerful ? player_ptr->lev * 2 : player_ptr->lev;
@@ -263,7 +263,7 @@ int rod_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir
  * @brief ロッドを使うコマンドのメインルーチン /
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_zap_rod(player_type *player_ptr)
+void do_cmd_zap_rod(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode) {
         return;
index 63be19d..847d4ba 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-int rod_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool *use_charge, bool powerful);
-void do_cmd_zap_rod(player_type *player_ptr);
+class PlayerType;
+int rod_effect(PlayerType *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool *use_charge, bool powerful);
+void do_cmd_zap_rod(PlayerType *player_ptr);
index 5e5bdb8..a55ca6a 100644 (file)
@@ -51,7 +51,7 @@
  * @param magic 魔道具術上の処理ならばTRUE
  * @return 発動により効果内容が確定したならばTRUEを返す
  */
-bool wand_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool powerful, bool magic)
+bool wand_effect(PlayerType *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool powerful, bool magic)
 {
     bool ident = false;
     PLAYER_LEVEL lev = powerful ? player_ptr->lev * 2 : player_ptr->lev;
@@ -318,7 +318,7 @@ bool wand_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION d
 /*!
  * @brief 魔法棒を使うコマンドのメインルーチン /
  */
-void do_cmd_aim_wand(player_type *player_ptr)
+void do_cmd_aim_wand(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     concptr q, s;
index a29cd8b..d52173e 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool wand_effect(player_type *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool powerful, bool magic);
-void do_cmd_aim_wand(player_type *player_ptr);
+class PlayerType;
+bool wand_effect(PlayerType *player_ptr, OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool powerful, bool magic);
+void do_cmd_aim_wand(PlayerType *player_ptr);
index 168d6aa..f7ff5cc 100644 (file)
@@ -35,7 +35,7 @@
  * the "TERM_XTRA_REACT" hook before redrawing the windows.
  * </pre>
  */
-void do_cmd_redraw(player_type *player_ptr)
+void do_cmd_redraw(PlayerType *player_ptr)
 {
     term_xtra(TERM_XTRA_REACT, 0);
 
@@ -71,7 +71,7 @@ void do_cmd_redraw(player_type *player_ptr)
 /*!
  * @brief プレイヤーのステータス表示
  */
-void do_cmd_player_status(player_type *player_ptr)
+void do_cmd_player_status(PlayerType *player_ptr)
 {
     int mode = 0;
     char tmp[160];
index 95ac13d..1363d8b 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
-struct player_type;
-void do_cmd_redraw(player_type *player_ptr);
-void do_cmd_player_status(player_type *player_ptr);
+class PlayerType;
+void do_cmd_redraw(PlayerType *player_ptr);
+void do_cmd_player_status(PlayerType *player_ptr);
 void do_cmd_message_one(void);
 void do_cmd_messages(int num_now);
index beb62e0..b92ae6a 100644 (file)
@@ -12,7 +12,7 @@
  *
  * Currently, the "player" is displayed on the map.
  */
-void do_cmd_view_map(player_type *player_ptr)
+void do_cmd_view_map(PlayerType *player_ptr)
 {
     screen_save();
     prt(_("お待ち下さい...", "Please wait..."), 0, 0);
index 5791c08..999f78b 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_view_map(player_type *player_ptr);
+class PlayerType;
+void do_cmd_view_map(PlayerType *player_ptr);
index 6bb4e5b..490a710 100644 (file)
@@ -75,7 +75,7 @@ static void print_visuals_menu(concptr choice_msg)
 /*
  * Interact with "visuals"
  */
-void do_cmd_visuals(player_type *player_ptr)
+void do_cmd_visuals(PlayerType *player_ptr)
 {
     FILE *auto_dump_stream;
     char tmp[160];
index e93c1ae..81968f7 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_visuals(player_type *player_ptr);
+class PlayerType;
+void do_cmd_visuals(PlayerType *player_ptr);
index a3da1a5..79568f0 100644 (file)
@@ -25,7 +25,7 @@
  * @return 命中と判定された場合TRUEを返す
  * @note Always miss 5%, always hit 5%, otherwise random.
  */
-bool test_hit_norm(player_type *player_ptr, int chance, ARMOUR_CLASS ac, bool visible)
+bool test_hit_norm(PlayerType *player_ptr, int chance, ARMOUR_CLASS ac, bool visible)
 {
     if (!visible)
         chance = (chance + 1) / 2;
@@ -39,7 +39,7 @@ bool test_hit_norm(player_type *player_ptr, int chance, ARMOUR_CLASS ac, bool vi
  * @param ac 敵AC
  * @return 命中確率
  */
-PERCENTAGE hit_chance(player_type *player_ptr, int reli, ARMOUR_CLASS ac)
+PERCENTAGE hit_chance(PlayerType *player_ptr, int reli, ARMOUR_CLASS ac)
 {
     PERCENTAGE chance = 5, chance_left = 90;
     if (reli <= 0)
@@ -63,7 +63,7 @@ PERCENTAGE hit_chance(player_type *player_ptr, int reli, ARMOUR_CLASS ac)
  * Always miss 5% of the time, Always hit 5% of the time.
  * Otherwise, match monster power against player armor.
  */
-bool check_hit_from_monster_to_player(player_type *player_ptr, int power, DEPTH level, int stun)
+bool check_hit_from_monster_to_player(PlayerType *player_ptr, int power, DEPTH level, int stun)
 {
     int k = randint0(100);
     if (stun && one_in_(2))
@@ -109,7 +109,7 @@ bool check_hit_from_monster_to_monster(int power, DEPTH level, ARMOUR_CLASS ac,
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  * @param chance 基本命中値
  */
-static bool decide_attack_hit(player_type *player_ptr, player_attack_type *pa_ptr, int chance)
+static bool decide_attack_hit(PlayerType *player_ptr, player_attack_type *pa_ptr, int chance)
 {
     bool success_hit = false;
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
@@ -142,7 +142,7 @@ static bool decide_attack_hit(player_type *player_ptr, player_attack_type *pa_pt
  * @param chance 基本命中値
  * @return 当たればTRUE、外れればFALSE
  */
-bool process_attack_hit(player_type *player_ptr, player_attack_type *pa_ptr, int chance)
+bool process_attack_hit(PlayerType *player_ptr, player_attack_type *pa_ptr, int chance)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
     if (decide_attack_hit(player_ptr, pa_ptr, chance))
index 5d60edb..01f2b77 100644 (file)
@@ -3,9 +3,9 @@
 #include "system/angband.h"
 
 struct player_attack_type;
-struct player_type;
-bool test_hit_norm(player_type *player_ptr, int chance, ARMOUR_CLASS ac, bool visible);
-PERCENTAGE hit_chance(player_type *player_ptr, int chance, ARMOUR_CLASS ac);
-bool check_hit_from_monster_to_player(player_type *player_ptr, int power, DEPTH level, int stun);
+class PlayerType;
+bool test_hit_norm(PlayerType *player_ptr, int chance, ARMOUR_CLASS ac, bool visible);
+PERCENTAGE hit_chance(PlayerType *player_ptr, int chance, ARMOUR_CLASS ac);
+bool check_hit_from_monster_to_player(PlayerType *player_ptr, int power, DEPTH level, int stun);
 bool check_hit_from_monster_to_monster(int power, DEPTH level, ARMOUR_CLASS ac, int stun);
-bool process_attack_hit(player_type *player_ptr, player_attack_type *pa_ptr, int chance);
+bool process_attack_hit(PlayerType *player_ptr, player_attack_type *pa_ptr, int chance);
index 095de4d..a55b91a 100644 (file)
@@ -48,7 +48,7 @@ std::tuple<HIT_POINT, concptr, sound_type> apply_critical_norm_damage(int k, HIT
  * @param mode オプションフラグ
  * @return クリティカル修正が入ったダメージ値
  */
-HIT_POINT critical_norm(player_type *player_ptr, WEIGHT weight, int plus, HIT_POINT dam, int16_t meichuu, combat_options mode, bool impact)
+HIT_POINT critical_norm(PlayerType *player_ptr, WEIGHT weight, int plus, HIT_POINT dam, int16_t meichuu, combat_options mode, bool impact)
 {
     /* Extract "blow" power */
     int i = (weight + (meichuu * 3 + plus * 5) + player_ptr->skill_thn);
@@ -82,7 +82,7 @@ HIT_POINT critical_norm(player_type *player_ptr, WEIGHT weight, int plus, HIT_PO
  * チェックを通ったら、ユニークならば2倍ダメージ、それ以外は一撃死
  * @todo 3つの処理をdetailsに書くよりは関数自体を分割すべきだが、一旦後回しにする。他の項目と一緒に処理する
  */
-static void ninja_critical(player_type *player_ptr, player_attack_type *pa_ptr)
+static void ninja_critical(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     monster_race *r_ptr = &r_info[pa_ptr->m_ptr->r_idx];
     int maxhp = pa_ptr->m_ptr->maxhp;
@@ -115,7 +115,7 @@ static void ninja_critical(player_type *player_ptr, player_attack_type *pa_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-void critical_attack(player_type *player_ptr, player_attack_type *pa_ptr)
+void critical_attack(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
     monster_race *r_ptr = &r_info[pa_ptr->m_ptr->r_idx];
index 1f9f0a8..ab0975c 100644 (file)
@@ -7,7 +7,7 @@
 #include <tuple>
 
 struct player_attack_type;
-struct player_type;
+class PlayerType;
 std::tuple<HIT_POINT, concptr, sound_type> apply_critical_norm_damage(int k, HIT_POINT base_dam);
-HIT_POINT critical_norm(player_type *player_ptr, WEIGHT weight, int plus, HIT_POINT dam, int16_t meichuu, combat_options mode, bool impact = false);
-void critical_attack(player_type *player_ptr, player_attack_type *pa_ptr);
+HIT_POINT critical_norm(PlayerType *player_ptr, WEIGHT weight, int plus, HIT_POINT dam, int16_t meichuu, combat_options mode, bool impact = false);
+void critical_attack(PlayerType *player_ptr, player_attack_type *pa_ptr);
index 3c9c9a7..700334a 100644 (file)
@@ -30,7 +30,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-static void aura_fire_by_monster_attack(player_type *player_ptr, monap_type *monap_ptr)
+static void aura_fire_by_monster_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!has_sh_fire(player_ptr) || !monap_ptr->alive || player_ptr->is_dead)
         return;
@@ -53,7 +53,7 @@ static void aura_fire_by_monster_attack(player_type *player_ptr, monap_type *mon
     }
 }
 
-static void aura_elec_by_monster_attack(player_type *player_ptr, monap_type *monap_ptr)
+static void aura_elec_by_monster_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!has_sh_elec(player_ptr) || !monap_ptr->alive || player_ptr->is_dead)
         return;
@@ -76,7 +76,7 @@ static void aura_elec_by_monster_attack(player_type *player_ptr, monap_type *mon
     }
 }
 
-static void aura_cold_by_monster_attack(player_type *player_ptr, monap_type *monap_ptr)
+static void aura_cold_by_monster_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!has_sh_cold(player_ptr) || !monap_ptr->alive || player_ptr->is_dead)
         return;
@@ -99,7 +99,7 @@ static void aura_cold_by_monster_attack(player_type *player_ptr, monap_type *mon
     }
 }
 
-static void aura_shards_by_monster_attack(player_type *player_ptr, monap_type *monap_ptr)
+static void aura_shards_by_monster_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!player_ptr->dustrobe || !monap_ptr->alive || player_ptr->is_dead)
         return;
@@ -123,7 +123,7 @@ static void aura_shards_by_monster_attack(player_type *player_ptr, monap_type *m
         teleport_player(player_ptr, 10, TELEPORT_SPONTANEOUS);
 }
 
-static void aura_holy_by_monster_attack(player_type *player_ptr, monap_type *monap_ptr)
+static void aura_holy_by_monster_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!player_ptr->tim_sh_holy || !monap_ptr->alive || player_ptr->is_dead)
         return;
@@ -152,7 +152,7 @@ static void aura_holy_by_monster_attack(player_type *player_ptr, monap_type *mon
         r_ptr->r_flags3 |= RF3_EVIL;
 }
 
-static void aura_force_by_monster_attack(player_type *player_ptr, monap_type *monap_ptr)
+static void aura_force_by_monster_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!player_ptr->tim_sh_touki || !monap_ptr->alive || player_ptr->is_dead)
         return;
@@ -175,7 +175,7 @@ static void aura_force_by_monster_attack(player_type *player_ptr, monap_type *mo
     }
 }
 
-static void aura_shadow_by_monster_attack(player_type *player_ptr, monap_type *monap_ptr)
+static void aura_shadow_by_monster_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!SpellHex(player_ptr).is_spelling_specific(HEX_SHADOW_CLOAK) || !monap_ptr->alive || player_ptr->is_dead)
         return;
@@ -220,7 +220,7 @@ static void aura_shadow_by_monster_attack(player_type *player_ptr, monap_type *m
     }
 }
 
-void process_aura_counterattack(player_type *player_ptr, monap_type *monap_ptr)
+void process_aura_counterattack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!monap_ptr->touched)
         return;
index 6da105f..4751e13 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 typedef struct monap_type monap_type;
-struct player_type;
-void process_aura_counterattack(player_type *player_ptr, monap_type *monap_ptr);
+class PlayerType;
+void process_aura_counterattack(PlayerType *player_ptr, monap_type *monap_ptr);
index 05884fa..9915864 100644 (file)
@@ -75,7 +75,7 @@
  * @param arrow_ptr 矢弾のオブジェクト構造体参照ポインタ
  * @return スナイパーの射撃属性、弓矢の属性を考慮する。デフォルトはGF_PLAYER_SHOOT。
  */
-AttributeFlags shot_attribute(player_type *player_ptr, object_type *bow_ptr, object_type *arrow_ptr, SPELL_IDX snipe_type)
+AttributeFlags shot_attribute(PlayerType *player_ptr, object_type *bow_ptr, object_type *arrow_ptr, SPELL_IDX snipe_type)
 {
     AttributeFlags attribute_flags{};
     attribute_flags.set(AttributeType::PLAYER_SHOOT);
@@ -146,7 +146,7 @@ AttributeFlags shot_attribute(player_type *player_ptr, object_type *bow_ptr, obj
  * @return スレイ倍率をかけたダメージ量
  */
 static MULTIPLY calc_shot_damage_with_slay(
-    player_type *player_ptr, object_type *bow_ptr, object_type *arrow_ptr, HIT_POINT tdam, monster_type *monster_ptr, SPELL_IDX snipe_type)
+    PlayerType *player_ptr, object_type *bow_ptr, object_type *arrow_ptr, HIT_POINT tdam, monster_type *monster_ptr, SPELL_IDX snipe_type)
 {
     MULTIPLY mult = 10;
 
@@ -447,7 +447,7 @@ static MULTIPLY calc_shot_damage_with_slay(
  * Note that Bows of "Extra Shots" give an extra shot.
  * </pre>
  */
-void exe_fire(player_type *player_ptr, INVENTORY_IDX item, object_type *j_ptr, SPELL_IDX snipe_type)
+void exe_fire(PlayerType *player_ptr, INVENTORY_IDX item, object_type *j_ptr, SPELL_IDX snipe_type)
 {
     DIRECTION dir;
     int i;
@@ -944,7 +944,7 @@ void exe_fire(player_type *player_ptr, INVENTORY_IDX item, object_type *j_ptr, S
  * @return 命中と判定された場合TRUEを返す
  * @note Always miss 5%, always hit 5%, otherwise random.
  */
-bool test_hit_fire(player_type *player_ptr, int chance, monster_type *m_ptr, int vis, char *o_name)
+bool test_hit_fire(PlayerType *player_ptr, int chance, monster_type *m_ptr, int vis, char *o_name)
 {
     int k;
     ARMOUR_CLASS ac;
@@ -1006,7 +1006,7 @@ bool test_hit_fire(player_type *player_ptr, int chance, monster_type *m_ptr, int
  * @param dam 現在算出中のダメージ値
  * @return クリティカル修正が入ったダメージ値
  */
-HIT_POINT critical_shot(player_type *player_ptr, WEIGHT weight, int plus_ammo, int plus_bow, HIT_POINT dam)
+HIT_POINT critical_shot(PlayerType *player_ptr, WEIGHT weight, int plus_ammo, int plus_bow, HIT_POINT dam)
 {
     int i, k;
     object_type *j_ptr = &player_ptr->inventory_list[INVEN_BOW];
@@ -1157,7 +1157,7 @@ int bow_tmul(OBJECT_SUBTYPE_VALUE sval)
  * @return ダメージ期待値
  * @note 基本ダメージ量と重量はこの部位では計算に加わらない。
  */
-HIT_POINT calc_crit_ratio_shot(player_type *player_ptr, HIT_POINT plus_ammo, HIT_POINT plus_bow)
+HIT_POINT calc_crit_ratio_shot(PlayerType *player_ptr, HIT_POINT plus_ammo, HIT_POINT plus_bow)
 {
     HIT_POINT i;
     object_type *j_ptr = &player_ptr->inventory_list[INVEN_BOW];
@@ -1195,7 +1195,7 @@ HIT_POINT calc_crit_ratio_shot(player_type *player_ptr, HIT_POINT plus_ammo, HIT
  * @param dam 基本ダメージ量
  * @return ダメージ期待値
  */
-HIT_POINT calc_expect_crit_shot(player_type *player_ptr, WEIGHT weight, int plus_ammo, int plus_bow, HIT_POINT dam)
+HIT_POINT calc_expect_crit_shot(PlayerType *player_ptr, WEIGHT weight, int plus_ammo, int plus_bow, HIT_POINT dam)
 {
     uint32_t num;
     int i, k, crit;
@@ -1238,7 +1238,7 @@ HIT_POINT calc_expect_crit_shot(player_type *player_ptr, WEIGHT weight, int plus
  * @param impact 強撃かどうか
  * @return ダメージ期待値
  */
-HIT_POINT calc_expect_crit(player_type *player_ptr, WEIGHT weight, int plus, HIT_POINT dam, int16_t meichuu, bool dokubari, bool impact)
+HIT_POINT calc_expect_crit(PlayerType *player_ptr, WEIGHT weight, int plus, HIT_POINT dam, int16_t meichuu, bool dokubari, bool impact)
 {
     if (dokubari)
         return dam;
index 0e455fa..3069014 100644 (file)
@@ -4,12 +4,12 @@
 
 struct monster_type;
 struct object_type;
-struct player_type;
-bool test_hit_fire(player_type *player_ptr, int chance, monster_type *m_ptr, int vis, char *o_name);
-HIT_POINT critical_shot(player_type *player_ptr, WEIGHT weight, int plus_ammo, int plus_bow, HIT_POINT dam);
+class PlayerType;
+bool test_hit_fire(PlayerType *player_ptr, int chance, monster_type *m_ptr, int vis, char *o_name);
+HIT_POINT critical_shot(PlayerType *player_ptr, WEIGHT weight, int plus_ammo, int plus_bow, HIT_POINT dam);
 ENERGY bow_energy(OBJECT_SUBTYPE_VALUE sval);
 int bow_tmul(OBJECT_SUBTYPE_VALUE sval);
-HIT_POINT calc_crit_ratio_shot(player_type *player_ptr, HIT_POINT plus_ammo, HIT_POINT plus_bow);
-HIT_POINT calc_expect_crit_shot(player_type *player_ptr, WEIGHT weight, int plus_ammo, int plus_bow, HIT_POINT dam);
-HIT_POINT calc_expect_crit(player_type *player_ptr, WEIGHT weight, int plus, HIT_POINT dam, int16_t meichuu, bool dokubari, bool impact);
-void exe_fire(player_type *player_ptr, INVENTORY_IDX item, object_type *j_ptr, SPELL_IDX snipe_type);
+HIT_POINT calc_crit_ratio_shot(PlayerType *player_ptr, HIT_POINT plus_ammo, HIT_POINT plus_bow);
+HIT_POINT calc_expect_crit_shot(PlayerType *player_ptr, WEIGHT weight, int plus_ammo, int plus_bow, HIT_POINT dam);
+HIT_POINT calc_expect_crit(PlayerType *player_ptr, WEIGHT weight, int plus, HIT_POINT dam, int16_t meichuu, bool dokubari, bool impact);
+void exe_fire(PlayerType *player_ptr, INVENTORY_IDX item, object_type *j_ptr, SPELL_IDX snipe_type);
index 597d371..34c441b 100644 (file)
@@ -29,7 +29,7 @@
  * @param m_ptr 目標モンスターの構造体参照ポインタ
  * @return スレイング加味後の倍率(/10倍)
  */
-MULTIPLY mult_slaying(player_type *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr)
+MULTIPLY mult_slaying(PlayerType *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr)
 {
     static const struct slay_table_t {
         tr_type slay_flag;
@@ -87,7 +87,7 @@ MULTIPLY mult_slaying(player_type *player_ptr, MULTIPLY mult, const TrFlags &flg
  * @param m_ptr 目標モンスターの構造体参照ポインタ
  * @return スレイング加味後の倍率(/10倍)
  */
-MULTIPLY mult_brand(player_type *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr)
+MULTIPLY mult_brand(PlayerType *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr)
 {
     static const struct brand_table_t {
         tr_type brand_flag;
@@ -149,7 +149,7 @@ MULTIPLY mult_brand(player_type *player_ptr, MULTIPLY mult, const TrFlags &flgs,
  * Note that most brands and slays are x3, except Slay Animal (x2),\n
  * Slay Evil (x2), and Kill dragon (x5).\n
  */
-HIT_POINT calc_attack_damage_with_slay(player_type *player_ptr, object_type *o_ptr, HIT_POINT tdam, monster_type *m_ptr, combat_options mode, bool thrown)
+HIT_POINT calc_attack_damage_with_slay(PlayerType *player_ptr, object_type *o_ptr, HIT_POINT tdam, monster_type *m_ptr, combat_options mode, bool thrown)
 {
     auto flgs = object_flags(o_ptr);
     torch_flags(o_ptr, flgs); /* torches has secret flags */
@@ -208,7 +208,7 @@ HIT_POINT calc_attack_damage_with_slay(player_type *player_ptr, object_type *o_p
     return (tdam * mult / 10);
 }
 
-AttributeFlags melee_attribute(player_type *player_ptr, object_type *o_ptr, combat_options mode)
+AttributeFlags melee_attribute(PlayerType *player_ptr, object_type *o_ptr, combat_options mode)
 {
     AttributeFlags attribute_flags{};
     attribute_flags.set(AttributeType::PLAYER_MELEE);
index 1708c5d..e1f532e 100644 (file)
@@ -8,8 +8,8 @@
 
 struct monster_type;
 struct object_type;
-struct player_type;
-MULTIPLY mult_slaying(player_type *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr);
-MULTIPLY mult_brand(player_type *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr);
-HIT_POINT calc_attack_damage_with_slay(player_type *player_ptr, object_type *o_ptr, HIT_POINT tdam, monster_type *m_ptr, combat_options mode, bool thrown);
-AttributeFlags melee_attribute(player_type *player_ptr, object_type *o_ptr, combat_options mode);
+class PlayerType;
+MULTIPLY mult_slaying(PlayerType *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr);
+MULTIPLY mult_brand(PlayerType *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr);
+HIT_POINT calc_attack_damage_with_slay(PlayerType *player_ptr, object_type *o_ptr, HIT_POINT tdam, monster_type *m_ptr, combat_options mode, bool thrown);
+AttributeFlags melee_attribute(PlayerType *player_ptr, object_type *o_ptr, combat_options mode);
index af30ce2..149e664 100644 (file)
@@ -242,7 +242,7 @@ bool get_check(concptr prompt) { return get_check_strict(p_ptr, prompt, 0); }
  * mode & CHECK_NO_HISTORY  : no message_add
  * mode & CHECK_DEFAULT_Y   : accept any key as y, except n and Esc.
  */
-bool get_check_strict(player_type *player_ptr, concptr prompt, BIT_FLAGS mode)
+bool get_check_strict(PlayerType *player_ptr, concptr prompt, BIT_FLAGS mode)
 {
     char buf[80];
     if (!rogue_like_commands)
index 577d809..cf347a1 100644 (file)
 #define CHECK_NO_HISTORY 0x04
 #define CHECK_DEFAULT_Y 0x08
 
-struct player_type;
+class PlayerType;
 bool askfor_aux(char *buf, int len, bool numpad_cursor);
 bool askfor(char *buf, int len);
 bool get_string(concptr prompt, char *buf, int len);
 bool get_check(concptr prompt);
-bool get_check_strict(player_type *player_ptr, concptr prompt, BIT_FLAGS mode);
+bool get_check_strict(PlayerType *player_ptr, concptr prompt, BIT_FLAGS mode);
 bool get_com(concptr prompt, char *command, bool z_escape);
 QUANTITY get_quantity(concptr prompt, QUANTITY max);
 void pause_line(int row);
index 0b69e93..3b8fc77 100644 (file)
@@ -17,7 +17,7 @@
  * The second arg is currently unused, but could induce output flush.
  * All disturbance cancels repeated commands, resting, and running.
  */
-void disturb(player_type *player_ptr, bool stop_search, bool stop_travel)
+void disturb(PlayerType *player_ptr, bool stop_search, bool stop_travel)
 {
     if (command_rep) {
         command_rep = 0;
index e856508..1421e4b 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void disturb(player_type *player_ptr, bool stop_search, bool flush_output);
+class PlayerType;
+void disturb(PlayerType *player_ptr, bool stop_search, bool flush_output);
index 3b24184..2cca64d 100644 (file)
@@ -32,7 +32,7 @@
 #include "view/display-scores.h"
 #include "world/world.h"
 
-static void clear_floor(player_type *player_ptr)
+static void clear_floor(PlayerType *player_ptr)
 {
     (void)fd_close(highscore_fd);
     highscore_fd = -1;
@@ -40,7 +40,7 @@ static void clear_floor(player_type *player_ptr)
     signals_handle_tstp();
 }
 
-static void send_world_score_on_closing(player_type *player_ptr, bool do_send)
+static void send_world_score_on_closing(PlayerType *player_ptr, bool do_send)
 {
     if (send_world_score(player_ptr, do_send, display_player))
         return;
@@ -60,7 +60,7 @@ static void send_world_score_on_closing(player_type *player_ptr, bool do_send)
  * @param player_ptr プレイヤー構造体参照ポインタ。
  * @return 死亡していればTRUE, まだ生きているならば各処理を済ませた上ででFALSE。
  */
-static bool check_death(player_type *player_ptr)
+static bool check_death(PlayerType *player_ptr)
 {
     if (player_ptr->is_dead)
         return true;
@@ -79,7 +79,7 @@ static bool check_death(player_type *player_ptr)
  * @brief 勝利者用の引退演出処理 /
  * Change the player into a King! -RAK-
  */
-static void kingly(player_type *player_ptr)
+static void kingly(PlayerType *player_ptr)
 {
     bool seppuku = streq(player_ptr->died_from, "Seppuku");
     player_ptr->current_floor_ptr->dun_level = 0;
@@ -139,7 +139,7 @@ static void kingly(player_type *player_ptr)
  * This function is called only from "main.c" and "signals.c".
  * </pre>
  */
-void close_game(player_type *player_ptr)
+void close_game(PlayerType *player_ptr)
 {
     bool do_send = true;
     handle_stuff(player_ptr);
index 0a53dbc..e6571e6 100644 (file)
@@ -7,5 +7,5 @@
  * @date 2020/03/09
  */
 
-struct player_type;
-void close_game(player_type *player_ptr);
+class PlayerType;
+void close_game(PlayerType *player_ptr);
index 88858e8..0bf2229 100644 (file)
@@ -94,7 +94,7 @@
 #include "wizard/wizard-special-process.h"
 #include "world/world.h"
 
-static void restore_windows(player_type *player_ptr)
+static void restore_windows(PlayerType *player_ptr)
 {
     player_ptr->hack_mutation = false;
     w_ptr->character_icky_depth = 1;
@@ -107,7 +107,7 @@ static void restore_windows(player_type *player_ptr)
     (void)term_set_cursor(0);
 }
 
-static void send_waiting_record(player_type *player_ptr)
+static void send_waiting_record(PlayerType *player_ptr)
 {
     if (!player_ptr->wait_report_score)
         return;
@@ -144,7 +144,7 @@ static void send_waiting_record(player_type *player_ptr)
     quit(0);
 }
 
-static void init_random_seed(player_type *player_ptr, bool new_game)
+static void init_random_seed(PlayerType *player_ptr, bool new_game)
 {
     bool init_random_seed = false;
     if (!w_ptr->character_loaded) {
@@ -162,7 +162,7 @@ static void init_random_seed(player_type *player_ptr, bool new_game)
         Rand_state_init();
 }
 
-static void init_world_floor_info(player_type *player_ptr)
+static void init_world_floor_info(PlayerType *player_ptr)
 {
     w_ptr->character_dungeon = false;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -188,7 +188,7 @@ static void init_world_floor_info(player_type *player_ptr)
  * 1.0.9 以前はセーブ前に player_ptr->riding = -1 としていたので、再設定が必要だった。
  * もう不要だが、以前のセーブファイルとの互換のために残しておく。
  */
-static void restore_world_floor_info(player_type *player_ptr)
+static void restore_world_floor_info(PlayerType *player_ptr)
 {
     write_level = false;
     exe_write_diary(player_ptr, DIARY_GAMESTART, 1, _("                            ----ゲーム再開----", "                            --- Restarted Game ---"));
@@ -205,7 +205,7 @@ static void restore_world_floor_info(player_type *player_ptr)
     }
 }
 
-static void reset_world_info(player_type *player_ptr)
+static void reset_world_info(PlayerType *player_ptr)
 {
     w_ptr->creating_savefile = false;
     player_ptr->teleport_town = false;
@@ -217,7 +217,7 @@ static void reset_world_info(player_type *player_ptr)
     record_o_name[0] = '\0';
 }
 
-static void generate_wilderness(player_type *player_ptr)
+static void generate_wilderness(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if ((floor_ptr->dun_level == 0) && floor_ptr->inside_quest)
@@ -229,7 +229,7 @@ static void generate_wilderness(player_type *player_ptr)
     select_floor_music(player_ptr);
 }
 
-static void change_floor_if_error(player_type *player_ptr)
+static void change_floor_if_error(PlayerType *player_ptr)
 {
     if (!w_ptr->character_dungeon) {
         change_floor(player_ptr);
@@ -250,7 +250,7 @@ static void change_floor_if_error(player_type *player_ptr)
     player_ptr->panic_save = 0;
 }
 
-static void generate_world(player_type *player_ptr, bool new_game)
+static void generate_world(PlayerType *player_ptr, bool new_game)
 {
     reset_world_info(player_ptr);
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -283,7 +283,7 @@ static void generate_world(player_type *player_ptr, bool new_game)
     exe_write_diary(player_ptr, DIARY_DESCRIPTION, 0, buf);
 }
 
-static void init_io(player_type *player_ptr)
+static void init_io(PlayerType *player_ptr)
 {
     term_xtra(TERM_XTRA_REACT, 0);
     player_ptr->window_flags = PW_ALL;
@@ -295,7 +295,7 @@ static void init_io(player_type *player_ptr)
         rogue_like_commands = true;
 }
 
-static void init_riding_pet(player_type *player_ptr, bool new_game)
+static void init_riding_pet(PlayerType *player_ptr, bool new_game)
 {
     if (!new_game || ((player_ptr->pclass != PlayerClassType::CAVALRY) && (player_ptr->pclass != PlayerClassType::BEASTMASTER)))
         return;
@@ -312,7 +312,7 @@ static void init_riding_pet(player_type *player_ptr, bool new_game)
     m_ptr->energy_need = ENERGY_NEED() + ENERGY_NEED();
 }
 
-static void decide_arena_death(player_type *player_ptr)
+static void decide_arena_death(PlayerType *player_ptr)
 {
     if (!player_ptr->playing || !player_ptr->is_dead)
         return;
@@ -341,7 +341,7 @@ static void decide_arena_death(player_type *player_ptr)
     leave_floor(player_ptr);
 }
 
-static void process_game_turn(player_type *player_ptr)
+static void process_game_turn(PlayerType *player_ptr)
 {
     bool load_game = true;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -382,7 +382,7 @@ static void process_game_turn(player_type *player_ptr)
  * savefile, we will commit suicide, if necessary, to allow the
  * player to start a new game.
  */
-void play_game(player_type *player_ptr, bool new_game, bool browsing_movie)
+void play_game(PlayerType *player_ptr, bool new_game, bool browsing_movie)
 {
     if (browsing_movie) {
         reset_visuals(player_ptr);
index 844dd61..738ff87 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void play_game(player_type *player_ptr, bool new_game, bool browsing_movie);
+class PlayerType;
+void play_game(PlayerType *player_ptr, bool new_game, bool browsing_movie);
index 815365c..c50931b 100644 (file)
@@ -25,7 +25,7 @@
  * @brief 10ゲームターンが進行するごとに魔法効果の残りターンを減らしていく処理
  * / Handle timeout every 10 game turns
  */
-void reduce_magic_effects_timeout(player_type *player_ptr)
+void reduce_magic_effects_timeout(PlayerType *player_ptr)
 {
     if (player_ptr->tim_mimic) {
         (void)set_mimic(player_ptr, player_ptr->tim_mimic - 1, player_ptr->mimic_form, true);
index ff1df7c..2ab31b6 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void reduce_magic_effects_timeout(player_type *player_ptr);
+class PlayerType;
+void reduce_magic_effects_timeout(PlayerType *player_ptr);
index 8313194..5b2a598 100644 (file)
@@ -51,7 +51,7 @@ static void compact_objects_aux(floor_type *floor_ptr, OBJECT_IDX i1, OBJECT_IDX
  * After "compacting" (if needed), we "reorder" the objects into a more\n
  * compact order, and we reset the allocation info, and the "live" array.\n
  */
-void compact_objects(player_type *player_ptr, int size)
+void compact_objects(PlayerType *player_ptr, int size)
 {
     object_type *o_ptr;
     if (size) {
index 1e4bb9e..cd9e6fb 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void compact_objects(player_type *player_ptr, int size);
+class PlayerType;
+void compact_objects(PlayerType *player_ptr, int size);
index 5138d25..7d2f729 100644 (file)
@@ -67,7 +67,7 @@
 bool load = true;
 bool can_save = false;
 
-static void process_fishing(player_type *player_ptr)
+static void process_fishing(PlayerType *player_ptr)
 {
     term_xtra(TERM_XTRA_DELAY, 10);
     if (one_in_(1000)) {
@@ -99,7 +99,7 @@ static void process_fishing(player_type *player_ptr)
     }
 }
 
-bool continuous_action_running(player_type *player_ptr)
+bool continuous_action_running(PlayerType *player_ptr)
 {
     return player_ptr->running || travel.run || command_rep || (player_ptr->action == ACTION_REST) || (player_ptr->action == ACTION_FISH);
 }
@@ -111,7 +111,7 @@ bool continuous_action_running(player_type *player_ptr)
  * must come first just in case somebody manages to corrupt\n
  * the savefiles by clever use of menu commands or something.\n
  */
-void process_player(player_type *player_ptr)
+void process_player(PlayerType *player_ptr)
 {
     if (player_ptr->hack_mutation) {
         msg_print(_("何か変わった気がする!", "You feel different!"));
@@ -421,7 +421,7 @@ void process_player(player_type *player_ptr)
 /*!
  * @brief プレイヤーの行動エネルギーが充填される(=プレイヤーのターンが回る)毎に行われる処理  / process the effects per 100 energy at player speed.
  */
-void process_upkeep_with_speed(player_type *player_ptr)
+void process_upkeep_with_speed(PlayerType *player_ptr)
 {
     if (!load && player_ptr->enchant_energy_need > 0 && !player_ptr->leaving) {
         player_ptr->enchant_energy_need -= SPEED_TO_ENERGY(player_ptr->pspeed);
index f5d4966..e6c209d 100644 (file)
@@ -3,7 +3,7 @@
 extern bool load; /*!<ロード処理中の分岐フラグ*/
 extern bool can_save;
 
-struct player_type;
-bool continuous_action_running(player_type *player_ptr);
-void process_player(player_type *player_ptr);
-void process_upkeep_with_speed(player_type *player_ptr);
+class PlayerType;
+bool continuous_action_running(PlayerType *player_ptr);
+void process_player(PlayerType *player_ptr);
+void process_upkeep_with_speed(PlayerType *player_ptr);
index 7176cce..e493649 100644 (file)
@@ -133,7 +133,7 @@ static int highscore_add(high_score *score)
  * @param do_send 実際に転送ア処置を行うか否か
  * @return 転送が成功したらTRUEを返す
  */
-bool send_world_score(player_type *current_player_ptr, bool do_send, display_player_pf display_player)
+bool send_world_score(PlayerType *current_player_ptr, bool do_send, display_player_pf display_player)
 {
 #ifdef WORLD_SCORE
     if (!send_score || !do_send) {
@@ -175,7 +175,7 @@ bool send_world_score(player_type *current_player_ptr, bool do_send, display_pla
  * @details
  * Assumes "signals_ignore_tstp()" has been called.
  */
-errr top_twenty(player_type *current_player_ptr)
+errr top_twenty(PlayerType *current_player_ptr)
 {
     high_score the_score = {};
     char buf[32];
@@ -276,7 +276,7 @@ errr top_twenty(player_type *current_player_ptr)
  * Predict the players location, and display it.
  * @return エラーコード
  */
-errr predict_score(player_type *current_player_ptr)
+errr predict_score(PlayerType *current_player_ptr)
 {
     high_score the_score;
     char buf[32];
@@ -343,7 +343,7 @@ errr predict_score(player_type *current_player_ptr)
  * @brief スコアランキングの簡易表示 /
  * show_highclass - selectively list highscores based on class -KMW-
  */
-void show_highclass(player_type *current_player_ptr)
+void show_highclass(PlayerType *current_player_ptr)
 {
     screen_save();
     char buf[1024], out_val[256];
@@ -412,7 +412,7 @@ void show_highclass(player_type *current_player_ptr)
  * Race Legends -KMW-
  * @param race_num 種族ID
  */
-void race_score(player_type *current_player_ptr, int race_num)
+void race_score(PlayerType *current_player_ptr, int race_num)
 {
     int i = 0, j, m = 0;
     int pr, clev, lastlev;
@@ -487,7 +487,7 @@ void race_score(player_type *current_player_ptr, int race_num)
  * @brief スコアランキングの簡易表示(種族毎)メインルーチン /
  * Race Legends -KMW-
  */
-void race_legends(player_type *current_player_ptr)
+void race_legends(PlayerType *current_player_ptr)
 {
     for (int i = 0; i < MAX_RACES; i++) {
         race_score(current_player_ptr, i);
@@ -502,7 +502,7 @@ void race_legends(player_type *current_player_ptr)
  * @brief スコアファイル出力
  * Display some character info
  */
-bool check_score(player_type *current_player_ptr)
+bool check_score(PlayerType *current_player_ptr)
 {
     term_clear();
 
index c81396c..bde11b4 100644 (file)
@@ -3,11 +3,11 @@
 #include "io/files-util.h"
 #include "system/angband.h"
 
-struct player_type;
-bool send_world_score(player_type *current_player_ptr, bool do_send, display_player_pf display_player);
-errr top_twenty(player_type *current_player_ptr);
-errr predict_score(player_type *current_player_ptr);
-void race_legends(player_type *current_player_ptr);
-void race_score(player_type *current_player_ptr, int race_num);
-void show_highclass(player_type *current_player_ptr);
-bool check_score(player_type *current_player_ptr);
+class PlayerType;
+bool send_world_score(PlayerType *current_player_ptr, bool do_send, display_player_pf display_player);
+errr top_twenty(PlayerType *current_player_ptr);
+errr predict_score(PlayerType *current_player_ptr);
+void race_legends(PlayerType *current_player_ptr);
+void race_score(PlayerType *current_player_ptr, int race_num);
+void show_highclass(PlayerType *current_player_ptr);
+bool check_score(PlayerType *current_player_ptr);
index 89ec4a2..00aa34f 100644 (file)
@@ -125,7 +125,7 @@ static void show_file_aux_line(concptr str, int cy, concptr shower)
  * </pre>
  * @todo 表示とそれ以外を分割する
  */
-bool show_file(player_type *player_ptr, bool show_version, concptr name, concptr what, int line, BIT_FLAGS mode)
+bool show_file(PlayerType *player_ptr, bool show_version, concptr name, concptr what, int line, BIT_FLAGS mode)
 {
     int wid, hgt;
     term_get_size(&wid, &hgt);
index 73319b1..682a56b 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool show_file(player_type *player_ptr, bool show_version, concptr name, concptr what, int line, BIT_FLAGS mode);
+class PlayerType;
+bool show_file(PlayerType *player_ptr, bool show_version, concptr name, concptr what, int line, BIT_FLAGS mode);
 void str_tolower(char *str);
index f1b07d6..3bb6879 100644 (file)
@@ -9,7 +9,7 @@
  * @brief 全更新処理をチェックして処理していく
  * Handle "player_ptr->update" and "player_ptr->redraw" and "player_ptr->window"
  */
-void handle_stuff(player_type* player_ptr)
+void handle_stuff(PlayerType* player_ptr)
 {
     if (player_ptr->update)
         update_creature(player_ptr);
@@ -22,7 +22,7 @@ void handle_stuff(player_type* player_ptr)
 /*
  * Track the given monster race
  */
-void monster_race_track(player_type *player_ptr, MONRACE_IDX r_idx)
+void monster_race_track(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     player_ptr->monster_race_idx = r_idx;
     player_ptr->window_flags |= (PW_MONSTER);
@@ -31,7 +31,7 @@ void monster_race_track(player_type *player_ptr, MONRACE_IDX r_idx)
 /*
  * Track the given object kind
  */
-void object_kind_track(player_type *player_ptr, KIND_OBJECT_IDX k_idx)
+void object_kind_track(PlayerType *player_ptr, KIND_OBJECT_IDX k_idx)
 {
     player_ptr->object_kind_idx = k_idx;
     player_ptr->window_flags |= (PW_OBJECT);
@@ -43,7 +43,7 @@ void object_kind_track(player_type *player_ptr, KIND_OBJECT_IDX k_idx)
  * @param m_idx トラッキング対象のモンスターID。0の時キャンセル
  * @param なし
  */
-void health_track(player_type *player_ptr, MONSTER_IDX m_idx)
+void health_track(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     if (m_idx && m_idx == player_ptr->riding)
         return;
@@ -52,14 +52,14 @@ void health_track(player_type *player_ptr, MONSTER_IDX m_idx)
     player_ptr->redraw |= (PR_HEALTH);
 }
 
-bool update_player(player_type *player_ptr)
+bool update_player(PlayerType *player_ptr)
 {
     player_ptr->update |= PU_COMBINE | PU_REORDER;
     player_ptr->window_flags |= PW_INVEN;
     return true;
 }
 
-bool redraw_player(player_type *player_ptr)
+bool redraw_player(PlayerType *player_ptr)
 {
     if (player_ptr->csp > player_ptr->msp) {
         player_ptr->csp = player_ptr->msp;
index eab42fc..6ba5109 100644 (file)
@@ -2,11 +2,11 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void handle_stuff(player_type *player_ptr);
-void monster_race_track(player_type *player_ptr, MONRACE_IDX r_idx);
-void object_kind_track(player_type *player_ptr, KIND_OBJECT_IDX k_idx);
-void health_track(player_type *player_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+void handle_stuff(PlayerType *player_ptr);
+void monster_race_track(PlayerType *player_ptr, MONRACE_IDX r_idx);
+void object_kind_track(PlayerType *player_ptr, KIND_OBJECT_IDX k_idx);
+void health_track(PlayerType *player_ptr, MONSTER_IDX m_idx);
 
-bool update_player(player_type *player_ptr);
-bool redraw_player(player_type *player_ptr);
+bool update_player(PlayerType *player_ptr);
+bool redraw_player(PlayerType *player_ptr);
index ba27e65..36624e5 100644 (file)
@@ -14,7 +14,7 @@
  * @details アンデッド種族は18:00からゲームを開始するので、この修正を予め行う。
  * @return 修正をかけた後のゲームターン
  */
-int32_t turn_real(player_type *player_ptr, int32_t hoge)
+int32_t turn_real(PlayerType *player_ptr, int32_t hoge)
 {
     switch (player_ptr->start_race) {
     case PlayerRaceType::VAMPIRE:
@@ -33,7 +33,7 @@ int32_t turn_real(player_type *player_ptr, int32_t hoge)
  * @details ターン及びターンを記録する変数をターンの限界の1日前まで巻き戻す.
  * @return 修正をかけた後のゲームターン
  */
-void prevent_turn_overflow(player_type *player_ptr)
+void prevent_turn_overflow(PlayerType *player_ptr)
 {
     if (w_ptr->game_turn < w_ptr->game_turn_limit)
         return;
index d7ed844..8e233e3 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-int32_t turn_real(player_type *player_ptr, int32_t hoge);
-void prevent_turn_overflow(player_type* player_ptr);
+class PlayerType;
+int32_t turn_real(PlayerType *player_ptr, int32_t hoge);
+void prevent_turn_overflow(PlayerType* player_ptr);
index 8606f87..63aeed9 100644 (file)
@@ -11,7 +11,7 @@
  * @brief オブジェクト、地形の表示シンボルなど初期化する / Reset the "visual" lists
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void reset_visuals(player_type *player_ptr)
+void reset_visuals(PlayerType *player_ptr)
 {
     for (auto &f_ref : f_info) {
         for (int j = 0; j < F_LIT_MAX; j++) {
index f75c103..385f2a7 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void reset_visuals(player_type *player_ptr);
+class PlayerType;
+void reset_visuals(PlayerType *player_ptr);
index a2f4b22..c2cbc63 100644 (file)
@@ -29,7 +29,7 @@
 /*!
  * @brief コンソールを再描画する /
  * Redraw a term when it is resized
- * @todo ここにplayer_type を追加するとz-termに影響が行くので保留
+ * @todo ここにPlayerType を追加するとz-termに影響が行くので保留
  */
 void redraw_window(void)
 {
@@ -46,7 +46,7 @@ void redraw_window(void)
  * @brief 現在のマップ名を描画する / Print dungeon
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void print_dungeon(player_type *player_ptr)
+static void print_dungeon(PlayerType *player_ptr)
 {
     c_put_str(TERM_WHITE, "             ", ROW_DUNGEON, COL_DUNGEON);
     concptr dungeon_name = map_name(player_ptr);
@@ -61,7 +61,7 @@ static void print_dungeon(player_type *player_ptr)
  * @brief redraw のフラグに応じた更新をまとめて行う / Handle "redraw"
  * @details 更新処理の対象はゲーム中の全描画処理
  */
-void redraw_stuff(player_type *player_ptr)
+void redraw_stuff(PlayerType *player_ptr)
 {
     if (!player_ptr->redraw)
         return;
@@ -222,7 +222,7 @@ void redraw_stuff(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details 更新処理の対象はサブウィンドウ全般
  */
-void window_stuff(player_type *player_ptr)
+void window_stuff(PlayerType *player_ptr)
 {
     if (!player_ptr->window_flags)
         return;
index f5358d2..aed06cb 100644 (file)
@@ -24,7 +24,7 @@ enum window_redraw_type {
 };
 
 // clang-format on
-struct player_type;
+class PlayerType;
 void redraw_window(void);
-void window_stuff(player_type *player_ptr);
-void redraw_stuff(player_type *player_ptr);
+void window_stuff(PlayerType *player_ptr);
+void redraw_stuff(PlayerType *player_ptr);
index f645ecb..ed315fd 100644 (file)
@@ -56,7 +56,7 @@
  * the user dies, or the game is terminated.\n
  * </p>
  */
-void process_dungeon(player_type *player_ptr, bool load_game)
+void process_dungeon(PlayerType *player_ptr, bool load_game)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     floor_ptr->base_level = floor_ptr->dun_level;
index 737c3fd..83fbdcb 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void process_dungeon(player_type *player_ptr, bool load_game);
+class PlayerType;
+void process_dungeon(PlayerType *player_ptr, bool load_game);
index 81621d0..5848de1 100644 (file)
@@ -93,7 +93,7 @@ DUNGEON_IDX choose_dungeon(concptr note, POSITION y, POSITION x)
  * @brief プレイヤーが現在ダンジョンに潜っているかどうかを返す。
  * @memo 現在はdun_levelが0でないかそうでないかに限るが可読性を高めるため。
  */
-bool is_in_dungeon(player_type *player_ptr)
+bool is_in_dungeon(PlayerType *player_ptr)
 {
     return player_ptr->current_floor_ptr->dun_level > 0;
 }
index 0b0019f..fdc108b 100644 (file)
@@ -89,6 +89,6 @@ typedef struct dungeon_type {
 extern std::vector<DEPTH> max_dlv;
 extern std::vector<dungeon_type> d_info;
 
-struct player_type;
+class PlayerType;
 DUNGEON_IDX choose_dungeon(concptr note, POSITION y, POSITION x);
-bool is_in_dungeon(player_type *player_ptr);
+bool is_in_dungeon(PlayerType *player_ptr);
index 4b744c6..f4abdd6 100644 (file)
@@ -21,7 +21,7 @@
 #include "util/bit-flags-calculator.h"
 #include "view/display-messages.h"
 
-QuestCompletionChecker::QuestCompletionChecker(player_type *player_ptr, monster_type *m_ptr)
+QuestCompletionChecker::QuestCompletionChecker(PlayerType *player_ptr, monster_type *m_ptr)
     : player_ptr(player_ptr)
     , m_ptr(m_ptr)
 {
index 40ad90a..fc35ae5 100644 (file)
@@ -6,17 +6,17 @@
 
 struct monster_type;
 struct object_type;
-struct player_type;
+class PlayerType;
 struct quest_type;
 class QuestCompletionChecker {
 public:
-    QuestCompletionChecker(player_type *player_ptr, monster_type *m_ptr);
+    QuestCompletionChecker(PlayerType *player_ptr, monster_type *m_ptr);
     virtual ~QuestCompletionChecker() = default;
 
     void complete();
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     monster_type *m_ptr;
     short quest_idx;
     quest_type *q_ptr = nullptr;
index 541cf70..f85bd39 100644 (file)
@@ -19,7 +19,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 成功したならばTRUEを返す
  */
-bool place_quest_monsters(player_type *player_ptr)
+bool place_quest_monsters(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (int i = 0; i < max_q_idx; i++) {
index c13b197..0241423 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool place_quest_monsters(player_type *player_ptr);
+class PlayerType;
+bool place_quest_monsters(PlayerType *player_ptr);
index 95b3111..7fdf857 100644 (file)
@@ -67,7 +67,7 @@ bool quest_type::is_fixed(short quest_idx)
  * @brief ランダムクエストの討伐ユニークを決める / Determine the random quest uniques
  * @param q_ptr クエスト構造体の参照ポインタ
  */
-void determine_random_questor(player_type *player_ptr, quest_type *q_ptr)
+void determine_random_questor(PlayerType *player_ptr, quest_type *q_ptr)
 {
     get_mon_num_prep(player_ptr, mon_hook_quest, nullptr);
 
@@ -111,7 +111,7 @@ void determine_random_questor(player_type *player_ptr, quest_type *q_ptr)
 
 /*!
  * @brief クエストの最終状態を記録する(成功or失敗、時間)
- * @param player_type プレイヤー情報への参照ポインタ
+ * @param PlayerType プレイヤー情報への参照ポインタ
  * @param q_ptr クエスト情報への参照ポインタ
  * @param stat ステータス(成功or失敗)
  */
@@ -128,7 +128,7 @@ void record_quest_final_status(quest_type *q_ptr, PLAYER_LEVEL lev, QuestStatusT
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param quest_num 達成状態にしたいクエストのID
  */
-void complete_quest(player_type *player_ptr, QUEST_IDX quest_num)
+void complete_quest(PlayerType *player_ptr, QUEST_IDX quest_num)
 {
     quest_type *const q_ptr = &quest[quest_num];
 
@@ -159,7 +159,7 @@ void complete_quest(player_type *player_ptr, QUEST_IDX quest_num)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param o_ptr 入手したオブジェクトの構造体参照ポインタ
  */
-void check_find_art_quest_completion(player_type *player_ptr, object_type *o_ptr)
+void check_find_art_quest_completion(PlayerType *player_ptr, object_type *o_ptr)
 {
     /* Check if completed a quest */
     for (QUEST_IDX i = 0; i < max_q_idx; i++) {
@@ -215,7 +215,7 @@ void quest_discovery(QUEST_IDX q_idx)
  * @param level 検索対象になる階
  * @return クエストIDを返す。該当がない場合0を返す。
  */
-QUEST_IDX quest_number(player_type *player_ptr, DEPTH level)
+QUEST_IDX quest_number(PlayerType *player_ptr, DEPTH level)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (floor_ptr->inside_quest)
@@ -239,7 +239,7 @@ QUEST_IDX quest_number(player_type *player_ptr, DEPTH level)
  * @param level 検索対象になる階
  * @return クエストIDを返す。該当がない場合0を返す。
  */
-QUEST_IDX random_quest_number(player_type *player_ptr, DEPTH level)
+QUEST_IDX random_quest_number(PlayerType *player_ptr, DEPTH level)
 {
     if (player_ptr->dungeon_idx != DUNGEON_ANGBAND)
         return 0;
@@ -258,7 +258,7 @@ QUEST_IDX random_quest_number(player_type *player_ptr, DEPTH level)
  * @brief クエスト階層から離脱する際の処理
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void leave_quest_check(player_type *player_ptr)
+void leave_quest_check(PlayerType *player_ptr)
 {
     leaving_quest = player_ptr->current_floor_ptr->inside_quest;
     if (!leaving_quest)
@@ -302,7 +302,7 @@ void leave_quest_check(player_type *player_ptr)
 /*!
  * @brief 「塔」クエストの各階層から離脱する際の処理
  */
-void leave_tower_check(player_type *player_ptr)
+void leave_tower_check(PlayerType *player_ptr)
 {
     leaving_quest = player_ptr->current_floor_ptr->inside_quest;
     bool is_leaving_from_tower = leaving_quest != 0;
@@ -322,7 +322,7 @@ void leave_tower_check(player_type *player_ptr)
 /*! 
  * @brief Player enters a new quest
  */
-void exe_enter_quest(player_type *player_ptr, QUEST_IDX quest_idx)
+void exe_enter_quest(PlayerType *player_ptr, QUEST_IDX quest_idx)
 {
     if (quest[quest_idx].type != QuestKindType::RANDOM)
         player_ptr->current_floor_ptr->dun_level = 1;
@@ -335,7 +335,7 @@ void exe_enter_quest(player_type *player_ptr, QUEST_IDX quest_idx)
  * @brief クエスト入り口にプレイヤーが乗った際の処理 / Do building commands
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_quest(player_type *player_ptr)
+void do_cmd_quest(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode)
         return;
index 66edc8d..01f9689 100644 (file)
@@ -84,15 +84,15 @@ extern int quest_text_line;
 extern int leaving_quest;
 
 struct object_type;
-struct player_type;
-void determine_random_questor(player_type *player_ptr, quest_type *q_ptr);
+class PlayerType;
+void determine_random_questor(PlayerType *player_ptr, quest_type *q_ptr);
 void record_quest_final_status(quest_type *q_ptr, PLAYER_LEVEL lev, QuestStatusType stat);
-void complete_quest(player_type *player_ptr, QUEST_IDX quest_num);
-void check_find_art_quest_completion(player_type *player_ptr, object_type *o_ptr);
+void complete_quest(PlayerType *player_ptr, QUEST_IDX quest_num);
+void check_find_art_quest_completion(PlayerType *player_ptr, object_type *o_ptr);
 void quest_discovery(QUEST_IDX q_idx);
-QUEST_IDX quest_number(player_type *player_ptr, DEPTH level);
-QUEST_IDX random_quest_number(player_type *player_ptr, DEPTH level);
-void leave_quest_check(player_type *player_ptr);
-void leave_tower_check(player_type *player_ptr);
-void exe_enter_quest(player_type *player_ptr, QUEST_IDX quest_idx);
-void do_cmd_quest(player_type *player_ptr);
+QUEST_IDX quest_number(PlayerType *player_ptr, DEPTH level);
+QUEST_IDX random_quest_number(PlayerType *player_ptr, DEPTH level);
+void leave_quest_check(PlayerType *player_ptr);
+void leave_tower_check(PlayerType *player_ptr);
+void exe_enter_quest(PlayerType *player_ptr, QUEST_IDX quest_idx);
+void do_cmd_quest(PlayerType *player_ptr);
index 5065811..8ee664d 100644 (file)
@@ -31,7 +31,7 @@
  * Line 2 -- forbid monsters
  * Line 3 -- forbid the player
  */
-static bool cave_naked_bold(player_type *player_ptr, POSITION y, POSITION x)
+static bool cave_naked_bold(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     return cave_clean_bold(floor_ptr, y, x) && (floor_ptr->grid_array[y][x].m_idx == 0) && !player_bold(player_ptr, y, x);
@@ -63,7 +63,7 @@ static bool cave_naked_bold(player_type *player_ptr, POSITION y, POSITION x)
  * Perhaps we should affect doors?
  * </pre>
  */
-bool affect_feature(player_type *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ)
+bool affect_feature(PlayerType *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
index 05fdb1d..9aab520 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "effect/attribute-types.h"
 
-struct player_type;
-bool affect_feature(player_type *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ);
+class PlayerType;
+bool affect_feature(PlayerType *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ);
index b1f2925..1b7d574 100644 (file)
@@ -39,7 +39,7 @@
  * @param typ 効果属性 / Type of damage to apply to monsters (and objects)
  * @return 何か一つでも効力があればTRUEを返す / TRUE if any "effects" of the projection were observed, else FALSE
  */
-bool affect_item(player_type *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ)
+bool affect_item(PlayerType *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
 
index 298a1a9..9ed643c 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "effect/attribute-types.h"
 
-struct player_type;
-bool affect_item(player_type *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ);
+class PlayerType;
+bool affect_item(PlayerType *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ);
index 121a741..e660b38 100644 (file)
@@ -29,7 +29,7 @@
 #include "util/bit-flags-calculator.h"
 #include "view/display-messages.h"
 
-static void effect_monster_charm_resist(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_charm_resist(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (common_saving_throw_charm(player_ptr, em_ptr->dam, em_ptr->m_ptr)) {
         em_ptr->note = _("には効果がなかった。", " is unaffected.");
@@ -51,7 +51,7 @@ static void effect_monster_charm_resist(player_type *player_ptr, effect_monster_
     }
 }
 
-process_result effect_monster_charm(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_charm(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     int vir = virtue_number(player_ptr, V_HARMONY);
     if (vir) {
@@ -71,7 +71,7 @@ process_result effect_monster_charm(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_control_undead(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_control_undead(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -104,7 +104,7 @@ process_result effect_monster_control_undead(player_type *player_ptr, effect_mon
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_control_demon(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_control_demon(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -137,7 +137,7 @@ process_result effect_monster_control_demon(player_type *player_ptr, effect_mons
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_control_animal(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_control_animal(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -172,7 +172,7 @@ process_result effect_monster_control_animal(player_type *player_ptr, effect_mon
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_charm_living(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_charm_living(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     int vir = virtue_number(player_ptr, V_UNLIFE);
     if (em_ptr->seen)
@@ -210,7 +210,7 @@ process_result effect_monster_charm_living(player_type *player_ptr, effect_monst
     return PROCESS_CONTINUE;
 }
 
-static void effect_monster_domination_corrupted_addition(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_domination_corrupted_addition(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     BadStatusSetter bss(player_ptr);
     switch (randint1(4)) {
@@ -232,7 +232,7 @@ static void effect_monster_domination_corrupted_addition(player_type *player_ptr
 }
 
 // Powerful demons & undead can turn a mindcrafter's attacks back on them.
-static void effect_monster_domination_corrupted(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_domination_corrupted(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     bool is_corrupted = ((em_ptr->r_ptr->flags3 & (RF3_UNDEAD | RF3_DEMON)) != 0) && (em_ptr->r_ptr->level > player_ptr->lev / 2) && (one_in_(2));
     if (!is_corrupted) {
@@ -267,7 +267,7 @@ static void effect_monster_domination_addition(effect_monster_type *em_ptr)
     }
 }
 
-process_result effect_monster_domination(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_domination(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (!is_hostile(em_ptr->m_ptr))
         return PROCESS_CONTINUE;
@@ -298,7 +298,7 @@ process_result effect_monster_domination(player_type *player_ptr, effect_monster
     return PROCESS_CONTINUE;
 }
 
-static bool effect_monster_crusade_domination(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool effect_monster_crusade_domination(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (((em_ptr->r_ptr->flags3 & RF3_GOOD) == 0) || player_ptr->current_floor_ptr->inside_arena)
         return false;
@@ -331,7 +331,7 @@ static bool effect_monster_crusade_domination(player_type *player_ptr, effect_mo
     return true;
 }
 
-process_result effect_monster_crusade(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_crusade(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -357,7 +357,7 @@ process_result effect_monster_crusade(player_type *player_ptr, effect_monster_ty
  * @param hp 計算対象のHP
  * @return 捕まえられる最大HP
  */
-static HIT_POINT calcutate_capturable_hp(player_type *player_ptr, monster_type *m_ptr, HIT_POINT hp)
+static HIT_POINT calcutate_capturable_hp(PlayerType *player_ptr, monster_type *m_ptr, HIT_POINT hp)
 {
     if (is_pet(m_ptr))
         return hp * 4L;
@@ -373,7 +373,7 @@ static HIT_POINT calcutate_capturable_hp(player_type *player_ptr, monster_type *
  * @param player_ptr プレイヤー情報への参照ポインタ
  * @param em_ptr 効果情報への参照ポインタ
  */
-static void effect_monster_captured(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_captured(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->m_ptr->mflag2.has(MonsterConstantFlagType::CHAMELEON))
         choose_new_monster(player_ptr, em_ptr->g_ptr->m_idx, false, MON_CHAMELEON);
@@ -397,7 +397,7 @@ static void effect_monster_captured(player_type *player_ptr, effect_monster_type
  * @param em_ptr 効果情報への参照ポインタ
  * @return 効果発動結果
  */
-process_result effect_monster_capture(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_capture(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if ((floor_ptr->inside_quest && (quest[floor_ptr->inside_quest].type == QuestKindType::KILL_ALL) && !is_pet(em_ptr->m_ptr))
index b87a5cb..8ab5ed2 100644 (file)
@@ -4,12 +4,12 @@
 
 enum process_result;
 struct effect_monster_type;
-struct player_type;
-process_result effect_monster_charm(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_control_undead(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_control_demon(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_control_animal(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_charm_living(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_domination(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_crusade(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_capture(player_type *player_ptr, effect_monster_type *em_ptr);
+class PlayerType;
+process_result effect_monster_charm(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_control_undead(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_control_demon(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_control_animal(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_charm_living(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_domination(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_crusade(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_capture(PlayerType *player_ptr, effect_monster_type *em_ptr);
index c66322f..67035ea 100644 (file)
@@ -10,7 +10,7 @@
 #include "system/monster-type-definition.h"
 #include "system/player-type-definition.h"
 
-static bool effect_monster_away_resist(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool effect_monster_away_resist(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flagsr & RFR_RES_TELE) == 0) return false;
 
@@ -32,7 +32,7 @@ static bool effect_monster_away_resist(player_type *player_ptr, effect_monster_t
 }
 
 
-process_result effect_monster_away_undead(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_away_undead(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flags3 & (RF3_UNDEAD)) == 0)
        {
@@ -56,7 +56,7 @@ process_result effect_monster_away_undead(player_type *player_ptr, effect_monste
 }
 
 
-process_result effect_monster_away_evil(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_away_evil(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flags3 & (RF3_EVIL)) == 0)
        {
@@ -80,7 +80,7 @@ process_result effect_monster_away_evil(player_type *player_ptr, effect_monster_
 }
 
 
-process_result effect_monster_away_all(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_away_all(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        bool resists_tele = effect_monster_away_resist(player_ptr, em_ptr);
        if (!resists_tele)
@@ -95,7 +95,7 @@ process_result effect_monster_away_all(player_type *player_ptr, effect_monster_t
 }
 
 
-process_result effect_monster_turn_undead(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_turn_undead(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flags3 & (RF3_UNDEAD)) == 0)
        {
@@ -121,7 +121,7 @@ process_result effect_monster_turn_undead(player_type *player_ptr, effect_monste
 }
 
 
-process_result effect_monster_turn_evil(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_turn_evil(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flags3 & (RF3_EVIL)) == 0)
        {
@@ -166,7 +166,7 @@ process_result effect_monster_turn_all(effect_monster_type *em_ptr)
 }
 
 
-process_result effect_monster_disp_undead(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_disp_undead(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flags3 & (RF3_UNDEAD)) == 0)
        {
@@ -186,7 +186,7 @@ process_result effect_monster_disp_undead(player_type *player_ptr, effect_monste
 }
 
 
-process_result effect_monster_disp_evil(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_disp_evil(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flags3 & (RF3_EVIL)) == 0)
        {
@@ -205,7 +205,7 @@ process_result effect_monster_disp_evil(player_type *player_ptr, effect_monster_
 }
 
 
-process_result effect_monster_disp_good(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_disp_good(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flags3 & (RF3_GOOD)) == 0)
        {
@@ -241,7 +241,7 @@ process_result effect_monster_disp_living(effect_monster_type *em_ptr)
 }
 
 
-process_result effect_monster_disp_demon(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_disp_demon(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if ((em_ptr->r_ptr->flags3 & (RF3_DEMON)) == 0)
        {
index cf43cdd..c538c27 100644 (file)
@@ -3,16 +3,16 @@
 #include "system/angband.h"
 
 struct effect_monster_type;
-struct player_type;
-process_result effect_monster_away_undead(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_away_evil(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_away_all(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_turn_undead(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_turn_evil(player_type *player_ptr, effect_monster_type *em_ptr);
+class PlayerType;
+process_result effect_monster_away_undead(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_away_evil(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_away_all(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_turn_undead(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_turn_evil(PlayerType *player_ptr, effect_monster_type *em_ptr);
 process_result effect_monster_turn_all(effect_monster_type *em_ptr);
-process_result effect_monster_disp_undead(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_disp_evil(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_disp_good(player_type *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_disp_undead(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_disp_evil(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_disp_good(PlayerType *player_ptr, effect_monster_type *em_ptr);
 process_result effect_monster_disp_living(effect_monster_type *em_ptr);
-process_result effect_monster_disp_demon(player_type *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_disp_demon(PlayerType *player_ptr, effect_monster_type *em_ptr);
 process_result effect_monster_disp_all(effect_monster_type *em_ptr);
index 7414594..31728eb 100644 (file)
@@ -7,7 +7,7 @@
 #include "system/monster-race-definition.h"
 #include "system/player-type-definition.h"
 
-process_result effect_monster_lite_weak(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_lite_weak(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if (!em_ptr->dam)
        {
@@ -32,7 +32,7 @@ process_result effect_monster_lite_weak(player_type *player_ptr, effect_monster_
 }
 
 
-process_result effect_monster_lite(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_lite(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if (em_ptr->seen) em_ptr->obvious = true;
 
@@ -57,7 +57,7 @@ process_result effect_monster_lite(player_type *player_ptr, effect_monster_type
 }
 
 
-process_result effect_monster_dark(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_dark(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
        if (em_ptr->seen) em_ptr->obvious = true;
 
index c8a435a..a505258 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct effect_monster_type;
-struct player_type;
-process_result effect_monster_lite_weak(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_lite(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_dark(player_type *player_ptr, effect_monster_type *em_ptr);
+class PlayerType;
+process_result effect_monster_lite_weak(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_lite(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_dark(PlayerType *player_ptr, effect_monster_type *em_ptr);
index 644ca85..747e473 100644 (file)
@@ -36,7 +36,7 @@ process_result effect_monster_old_poly(effect_monster_type *em_ptr)
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_old_clone(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_old_clone(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -56,7 +56,7 @@ process_result effect_monster_old_clone(player_type *player_ptr, effect_monster_
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_star_heal(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_star_heal(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -83,7 +83,7 @@ process_result effect_monster_star_heal(player_type *player_ptr, effect_monster_
 }
 
 // who == 0ならばプレイヤーなので、それの判定.
-static void effect_monster_old_heal_check_player(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_old_heal_check_player(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->who != 0)
         return;
@@ -105,7 +105,7 @@ static void effect_monster_old_heal_check_player(player_type *player_ptr, effect
         chg_virtue(player_ptr, V_NATURE, 1);
 }
 
-static void effect_monster_old_heal_recovery(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_old_heal_recovery(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (monster_stunned_remaining(em_ptr->m_ptr)) {
         if (em_ptr->seen_msg)
@@ -129,7 +129,7 @@ static void effect_monster_old_heal_recovery(player_type *player_ptr, effect_mon
     }
 }
 
-process_result effect_monster_old_heal(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_old_heal(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -159,7 +159,7 @@ process_result effect_monster_old_heal(player_type *player_ptr, effect_monster_t
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_old_speed(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_old_speed(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -179,7 +179,7 @@ process_result effect_monster_old_speed(player_type *player_ptr, effect_monster_
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_old_slow(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_old_slow(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -203,7 +203,7 @@ process_result effect_monster_old_slow(player_type *player_ptr, effect_monster_t
  * @todo 「ユニークは (魔法では)常に眠らない」はr_infoの趣旨に反すると思われる
  * 眠る確率を半分にするとかしておいた方が良さそう
  */
-process_result effect_monster_old_sleep(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_old_sleep(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -230,7 +230,7 @@ process_result effect_monster_old_sleep(player_type *player_ptr, effect_monster_
  * @todo 「ユニークは (魔法では)常に混乱しない」はr_infoの趣旨に反すると思われる
  * 眠る確率を半分にするとかしておいた方が良さそう
  */
-process_result effect_monster_old_conf(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_old_conf(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
index 744a10d..d931797 100644 (file)
@@ -3,14 +3,14 @@
 #include "system/angband.h"
 
 struct effect_monster_type;
-struct player_type;
+class PlayerType;
 process_result effect_monster_old_poly(effect_monster_type *em_ptr);
-process_result effect_monster_old_clone(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_star_heal(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_old_heal(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_old_speed(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_old_slow(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_old_sleep(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_old_conf(player_type *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_old_clone(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_star_heal(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_old_heal(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_old_speed(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_old_slow(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_old_sleep(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_old_conf(PlayerType *player_ptr, effect_monster_type *em_ptr);
 process_result effect_monster_stasis(effect_monster_type *em_ptr, bool to_evil);
 process_result effect_monster_stun(effect_monster_type *em_ptr);
index 0f8e437..8603027 100644 (file)
@@ -27,7 +27,7 @@
  * @param em_ptr モンスター効果への参照ポインタ
  * @return 完全な耐性を発動した場合TRUE、そうでなければFALSE
  */
-static bool resisted_psi_because_empty_mind(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool resisted_psi_because_empty_mind(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (none_bits(em_ptr->r_ptr->flags2, RF2_EMPTY_MIND))
         return false;
@@ -72,7 +72,7 @@ static bool resisted_psi_because_weird_mind_or_powerful(effect_monster_type *em_
  * 1) UNDEADまたはDEMONである
  * 2) レベルが詠唱者の レベル/2 より大きい
  */
-static bool reflects_psi_with_currupted_mind(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool reflects_psi_with_currupted_mind(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     bool is_corrupted = any_bits(em_ptr->r_ptr->flags3, RF3_UNDEAD | RF3_DEMON) && (em_ptr->r_ptr->level > player_ptr->lev / 2) && one_in_(2);
     if (!is_corrupted)
@@ -93,7 +93,7 @@ static bool reflects_psi_with_currupted_mind(player_type *player_ptr, effect_mon
  * 効果は、混乱、朦朧、恐怖、麻痺
  * 3/4の確率または影分身時はダメージ及び追加効果はない。
  */
-static void effect_monster_psi_reflect_extra_effect(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_psi_reflect_extra_effect(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (!one_in_(4) || check_multishadow(player_ptr)) {
         return;
@@ -131,7 +131,7 @@ static void effect_monster_psi_reflect_extra_effect(player_type *player_ptr, eff
  * @details
  * 耐性を発動した精神の堕落したモンスターは効力を跳ね返すことがある。
  */
-static void effect_monster_psi_resist(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_psi_resist(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (resisted_psi_because_empty_mind(player_ptr, em_ptr))
         return;
@@ -193,7 +193,7 @@ static void effect_monster_psi_extra_effect(effect_monster_type *em_ptr)
  * 視界による影響を発動する。
  * モンスターの耐性とそれに不随した効果を発動する。
  */
-process_result effect_monster_psi(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_psi(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -218,7 +218,7 @@ process_result effect_monster_psi(player_type *player_ptr, effect_monster_type *
  * @details
  * 耐性を発動した精神の堕落したモンスターは効力を跳ね返すことがある。
  */
-static void effect_monster_psi_drain_resist(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_psi_drain_resist(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (resisted_psi_because_empty_mind(player_ptr, em_ptr))
         return;
@@ -257,7 +257,7 @@ static void effect_monster_psi_drain_resist(player_type *player_ptr, effect_mons
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果への参照ポインタ
  */
-static void effect_monster_psi_drain_change_power(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_psi_drain_change_power(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     int b = damroll(5, em_ptr->dam) / 4;
     concptr str = (player_ptr->pclass == PlayerClassType::MINDCRAFTER) ? _("超能力パワー", "psychic energy") : _("魔力", "mana");
@@ -278,7 +278,7 @@ static void effect_monster_psi_drain_change_power(player_type *player_ptr, effec
  * @details
  * ダメージがないか3/4の確率で追加効果なし
  */
-process_result effect_monster_psi_drain(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_psi_drain(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -299,7 +299,7 @@ process_result effect_monster_psi_drain(player_type *player_ptr, effect_monster_
  * @details
  * 朦朧+ショートテレポートアウェイ
  */
-process_result effect_monster_telekinesis(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_telekinesis(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
index 854fda0..24e416a 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct effect_monster_type;
-struct player_type;
-process_result effect_monster_psi(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_psi_drain(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_telekinesis(player_type *player_ptr, effect_monster_type *em_ptr);
+class PlayerType;
+process_result effect_monster_psi(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_psi_drain(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_telekinesis(PlayerType *player_ptr, effect_monster_type *em_ptr);
index ae8874b..02f01e5 100644 (file)
@@ -29,7 +29,7 @@ process_result effect_monster_nothing(effect_monster_type *em_ptr)
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_acid(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_acid(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -45,7 +45,7 @@ process_result effect_monster_acid(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_elec(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_elec(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -61,7 +61,7 @@ process_result effect_monster_elec(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_fire(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_fire(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -86,7 +86,7 @@ process_result effect_monster_fire(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_cold(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_cold(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -111,7 +111,7 @@ process_result effect_monster_cold(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_pois(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_pois(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -127,7 +127,7 @@ process_result effect_monster_pois(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_nuke(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_nuke(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -148,7 +148,7 @@ process_result effect_monster_nuke(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_hell_fire(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_hell_fire(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -164,7 +164,7 @@ process_result effect_monster_hell_fire(player_type *player_ptr, effect_monster_
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_holy_fire(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_holy_fire(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -192,7 +192,7 @@ process_result effect_monster_holy_fire(player_type *player_ptr, effect_monster_
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_plasma(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_plasma(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -209,7 +209,7 @@ process_result effect_monster_plasma(player_type *player_ptr, effect_monster_typ
     return PROCESS_CONTINUE;
 }
 
-static bool effect_monster_nether_resist(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool effect_monster_nether_resist(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if ((em_ptr->r_ptr->flagsr & RFR_RES_NETH) == 0)
         return false;
@@ -231,7 +231,7 @@ static bool effect_monster_nether_resist(player_type *player_ptr, effect_monster
     return true;
 }
 
-process_result effect_monster_nether(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_nether(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -247,7 +247,7 @@ process_result effect_monster_nether(player_type *player_ptr, effect_monster_typ
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_water(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_water(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -270,7 +270,7 @@ process_result effect_monster_water(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_chaos(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_chaos(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -295,7 +295,7 @@ process_result effect_monster_chaos(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_shards(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_shards(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -312,7 +312,7 @@ process_result effect_monster_shards(player_type *player_ptr, effect_monster_typ
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_rocket(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_rocket(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -328,7 +328,7 @@ process_result effect_monster_rocket(player_type *player_ptr, effect_monster_typ
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_sound(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_sound(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -347,7 +347,7 @@ process_result effect_monster_sound(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_confusion(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_confusion(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -366,7 +366,7 @@ process_result effect_monster_confusion(player_type *player_ptr, effect_monster_
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_disenchant(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_disenchant(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -383,7 +383,7 @@ process_result effect_monster_disenchant(player_type *player_ptr, effect_monster
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_nexus(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_nexus(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -400,7 +400,7 @@ process_result effect_monster_nexus(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_force(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_force(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -420,7 +420,7 @@ process_result effect_monster_force(player_type *player_ptr, effect_monster_type
 }
 
 // Powerful monsters can resists and normal monsters slow down.
-process_result effect_monster_inertial(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_inertial(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -446,7 +446,7 @@ process_result effect_monster_inertial(player_type *player_ptr, effect_monster_t
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_time(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_time(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -465,7 +465,7 @@ process_result effect_monster_time(player_type *player_ptr, effect_monster_type
     return PROCESS_CONTINUE;
 }
 
-static bool effect_monster_gravity_resist_teleport(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool effect_monster_gravity_resist_teleport(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -491,7 +491,7 @@ static bool effect_monster_gravity_resist_teleport(player_type *player_ptr, effe
     return true;
 }
 
-static void effect_monster_gravity_slow(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_monster_gravity_slow(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if ((em_ptr->r_ptr->flags1 & (RF1_UNIQUE)) || (em_ptr->r_ptr->level > randint1((em_ptr->dam - 10) < 1 ? 1 : (em_ptr->dam - 10)) + 10))
         em_ptr->obvious = false;
@@ -514,7 +514,7 @@ static void effect_monster_gravity_stun(effect_monster_type *em_ptr)
  * Powerful monsters can resist and normal monsters slow down
  * Furthermore, this magic can make non-unique monsters slow/stun.
  */
-process_result effect_monster_gravity(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_gravity(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     em_ptr->do_dist = effect_monster_gravity_resist_teleport(player_ptr, em_ptr) ? 0 : 10;
     if (player_ptr->riding && (em_ptr->g_ptr->m_idx == player_ptr->riding))
@@ -536,7 +536,7 @@ process_result effect_monster_gravity(player_type *player_ptr, effect_monster_ty
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_disintegration(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_disintegration(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -553,7 +553,7 @@ process_result effect_monster_disintegration(player_type *player_ptr, effect_mon
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_icee_bolt(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_icee_bolt(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -582,7 +582,7 @@ process_result effect_monster_icee_bolt(player_type *player_ptr, effect_monster_
  * @details
  * 量子生物に倍打、壁抜けに1.5倍打、テレポート耐性が耐性
  */
-process_result effect_monster_void(player_type* player_ptr, effect_monster_type* em_ptr)
+process_result effect_monster_void(PlayerType* player_ptr, effect_monster_type* em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -627,7 +627,7 @@ process_result effect_monster_void(player_type* player_ptr, effect_monster_type*
  * 飛ばないテレポート耐性に1.25倍打、暗黒耐性が耐性
  * 1/3で追加に混乱か恐怖
  */
-process_result effect_monster_abyss(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_abyss(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
index 03c5bfa..3a9b828 100644 (file)
@@ -3,31 +3,31 @@
 #include "system/angband.h"
 
 struct effect_monster_type;
-struct player_type;
+class PlayerType;
 process_result effect_monster_nothing(effect_monster_type *em_ptr);
-process_result effect_monster_acid(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_elec(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_fire(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_cold(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_pois(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_nuke(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_hell_fire(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_holy_fire(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_plasma(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_nether(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_water(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_chaos(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_shards(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_rocket(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_sound(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_confusion(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_disenchant(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_nexus(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_force(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_inertial(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_time(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_gravity(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_disintegration(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_icee_bolt(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_void(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_abyss(player_type *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_acid(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_elec(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_fire(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_cold(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_pois(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_nuke(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_hell_fire(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_holy_fire(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_plasma(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_nether(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_water(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_chaos(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_shards(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_rocket(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_sound(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_confusion(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_disenchant(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_nexus(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_force(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_inertial(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_time(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_gravity(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_disintegration(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_icee_bolt(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_void(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_abyss(PlayerType *player_ptr, effect_monster_type *em_ptr);
index 1d68829..b581dff 100644 (file)
@@ -17,7 +17,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-process_result effect_monster_drain_mana(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_drain_mana(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -62,7 +62,7 @@ process_result effect_monster_drain_mana(player_type *player_ptr, effect_monster
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_mind_blast(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_mind_blast(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -101,7 +101,7 @@ process_result effect_monster_mind_blast(player_type *player_ptr, effect_monster
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_brain_smash(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_brain_smash(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
index ab4cd0d..6eb3d24 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct effect_monster_type;
-struct player_type;
-process_result effect_monster_drain_mana(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_mind_blast(player_type *player_ptr, effect_monster_type *em_ptr);
-process_result effect_monster_brain_smash(player_type *player_ptr, effect_monster_type *em_ptr);
+class PlayerType;
+process_result effect_monster_drain_mana(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_mind_blast(PlayerType *player_ptr, effect_monster_type *em_ptr);
+process_result effect_monster_brain_smash(PlayerType *player_ptr, effect_monster_type *em_ptr);
index 8218e65..01183c6 100644 (file)
@@ -38,7 +38,7 @@
 #include "util/bit-flags-calculator.h"
 #include "view/display-messages.h"
 
-process_result effect_monster_hypodynamia(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_hypodynamia(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -66,7 +66,7 @@ process_result effect_monster_hypodynamia(player_type *player_ptr, effect_monste
 /*!
  * @todo リファクタリング前のコード時点で、単に耐性があるだけでもダメージ0だった.
  */
-process_result effect_monster_death_ray(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_death_ray(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -97,7 +97,7 @@ process_result effect_monster_death_ray(player_type *player_ptr, effect_monster_
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_kill_wall(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_kill_wall(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if ((em_ptr->r_ptr->flags3 & (RF3_HURT_ROCK)) == 0) {
         em_ptr->dam = 0;
@@ -149,7 +149,7 @@ process_result effect_monster_hand_doom(effect_monster_type *em_ptr)
  * 寝た場合は試行終了。
  * 与える効果は減速、朦朧、混乱、睡眠。
  */
-process_result effect_monster_engetsu(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_engetsu(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -239,7 +239,7 @@ process_result effect_monster_engetsu(player_type *player_ptr, effect_monster_ty
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_genocide(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_genocide(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->seen)
         em_ptr->obvious = true;
@@ -254,7 +254,7 @@ process_result effect_monster_genocide(player_type *player_ptr, effect_monster_t
     return PROCESS_CONTINUE;
 }
 
-process_result effect_monster_photo(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_photo(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (!em_ptr->who)
         msg_format(_("%sを写真に撮った。", "You take a photograph of %s."), em_ptr->m_name);
@@ -294,7 +294,7 @@ process_result effect_monster_wounds(effect_monster_type *em_ptr)
  * @param em_ptr モンスター効果構造体への参照ポインタ
  * @return ここのスイッチングで終るならTRUEかFALSE、後続処理を実行するならCONTINUE
  */
-process_result switch_effects_monster(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result switch_effects_monster(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     switch (em_ptr->attribute) {
     case AttributeType::PSY_SPEAR:
index bf5b4b0..d54a191 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 struct effect_monster_type;
-struct player_type;
-process_result switch_effects_monster(player_type *player_ptr, effect_monster_type *em_ptr);
+class PlayerType;
+process_result switch_effects_monster(PlayerType *player_ptr, effect_monster_type *em_ptr);
index 4d287a5..8c02d66 100644 (file)
@@ -54,7 +54,7 @@ static void substitute_effect_monster(effect_monster_type *em_ptr, MONSTER_IDX w
  * @param flag 効果フラグ
  * @param see_s_msg TRUEならばメッセージを表示する
  */
-effect_monster_type *initialize_effect_monster(player_type *player_ptr, effect_monster_type *em_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType attribute, BIT_FLAGS flag, bool see_s_msg)
+effect_monster_type *initialize_effect_monster(PlayerType *player_ptr, effect_monster_type *em_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType attribute, BIT_FLAGS flag, bool see_s_msg)
 {
        substitute_effect_monster(em_ptr, who, r, y, x, dam, attribute, flag, see_s_msg);
 
index fccfc49..bec2d80 100644 (file)
@@ -44,6 +44,6 @@ typedef struct effect_monster_type {
     bool see_s_msg;
 } effect_monster_type;
 
-struct player_type;
-effect_monster_type *initialize_effect_monster(player_type *player_ptr, effect_monster_type *em_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x,
+class PlayerType;
+effect_monster_type *initialize_effect_monster(PlayerType *player_ptr, effect_monster_type *em_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x,
     HIT_POINT dam, AttributeType attribute, BIT_FLAGS flag, bool see_s_msg);
index 5955724..224c369 100644 (file)
@@ -59,7 +59,7 @@
  * @param em_ptr モンスター効果構造体への参照ポインタ
  * @return 効果が何もないならFALSE、何かあるならTRUE
  */
-static process_result is_affective(player_type *player_ptr, effect_monster_type *em_ptr)
+static process_result is_affective(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (!em_ptr->g_ptr->m_idx)
         return PROCESS_FALSE;
@@ -97,7 +97,7 @@ static process_result is_affective(player_type *player_ptr, effect_monster_type
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void make_description_of_affecred_monster(player_type *player_ptr, effect_monster_type *em_ptr)
+static void make_description_of_affecred_monster(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     em_ptr->dam = (em_ptr->dam + em_ptr->r) / (em_ptr->r + 1);
     monster_desc(player_ptr, em_ptr->m_name, em_ptr->m_ptr, 0);
@@ -113,7 +113,7 @@ static void make_description_of_affecred_monster(player_type *player_ptr, effect
  * 完全な耐性を持っていたら、一部属性を除いて影響は及ぼさない
  * 射撃属性 (デバッグ用)であれば貫通する
  */
-static process_result exe_affect_monster_by_effect(player_type *player_ptr, effect_monster_type *em_ptr)
+static process_result exe_affect_monster_by_effect(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     process_result result = is_affective(player_ptr, em_ptr);
     if (result != PROCESS_TRUE) {
@@ -148,7 +148,7 @@ static process_result exe_affect_monster_by_effect(player_type *player_ptr, effe
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void effect_damage_killed_pet(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_damage_killed_pet(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     bool sad = is_pet(em_ptr->m_ptr) && !(em_ptr->m_ptr->ml);
     if (em_ptr->known && em_ptr->note) {
@@ -173,7 +173,7 @@ static void effect_damage_killed_pet(player_type *player_ptr, effect_monster_typ
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void effect_damage_makes_sleep(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_damage_makes_sleep(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->note && em_ptr->seen_msg)
         msg_format("%^s%s", em_ptr->m_name, em_ptr->note);
@@ -194,7 +194,7 @@ static void effect_damage_makes_sleep(player_type *player_ptr, effect_monster_ty
  * @details
  * モンスターIDがプレイヤー(0)の場合は処理しない。
  */
-static bool deal_effect_damage_from_monster(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool deal_effect_damage_from_monster(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->who <= 0)
         return false;
@@ -220,7 +220,7 @@ static bool deal_effect_damage_from_monster(player_type *player_ptr, effect_mons
  * @param em_ptr モンスター効果構造体への参照ポインタ
  * @return 大賞モンスターが不潔な病人だった場合はTRUE、それ以外はFALSE
  */
-static bool heal_leaper(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool heal_leaper(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (!em_ptr->heal_leper)
         return false;
@@ -246,7 +246,7 @@ static bool heal_leaper(player_type *player_ptr, effect_monster_type *em_ptr)
  * @details
  * em_ptr->do_fearによる恐怖メッセージもここで表示。
  */
-static bool deal_effect_damage_from_player(player_type *player_ptr, effect_monster_type *em_ptr)
+static bool deal_effect_damage_from_player(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     bool fear = false;
     MonsterDamageProcessor mdp(player_ptr, em_ptr->g_ptr->m_idx, em_ptr->dam, &fear, em_ptr->attribute);
@@ -283,7 +283,7 @@ static bool deal_effect_damage_from_player(player_type *player_ptr, effect_monst
  * 3.プレイヤーによる効果ダメージの処理
  * 4.睡眠する処理
  */
-static void deal_effect_damage_to_monster(player_type *player_ptr, effect_monster_type *em_ptr)
+static void deal_effect_damage_to_monster(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->attribute == AttributeType::DRAIN_MANA)
         return;
@@ -307,7 +307,7 @@ static void deal_effect_damage_to_monster(player_type *player_ptr, effect_monste
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void effect_makes_change_virtues(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_makes_change_virtues(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if ((em_ptr->who > 0) || !em_ptr->slept)
         return;
@@ -323,7 +323,7 @@ static void effect_makes_change_virtues(player_type *player_ptr, effect_monster_
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void affected_monster_prevents_bad_status(player_type *player_ptr, effect_monster_type *em_ptr)
+static void affected_monster_prevents_bad_status(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if ((em_ptr->r_ptr->flags1 & RF1_UNIQUE) || (em_ptr->r_ptr->flags1 & RF1_QUESTOR) || (player_ptr->riding && (em_ptr->g_ptr->m_idx == player_ptr->riding)))
         em_ptr->do_polymorph = false;
@@ -338,7 +338,7 @@ static void affected_monster_prevents_bad_status(player_type *player_ptr, effect
  * @param em_ptr モンスター効果構造体への参照ポインタ
  * @param stun_damage 朦朧値
  */
-static void effect_damage_piles_stun(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_damage_piles_stun(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if ((em_ptr->do_stun == 0) || (em_ptr->r_ptr->flagsr & (RFR_RES_SOUN | RFR_RES_WALL)) || (em_ptr->r_ptr->flags3 & RF3_NO_STUN))
         return;
@@ -365,7 +365,7 @@ static void effect_damage_piles_stun(player_type *player_ptr, effect_monster_typ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  * @param stun_damage 混乱値
  */
-static void effect_damage_piles_confusion(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_damage_piles_confusion(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if ((em_ptr->do_conf == 0) || (em_ptr->r_ptr->flags3 & RF3_NO_CONF) || (em_ptr->r_ptr->flagsr & RFR_EFF_RES_CHAO_MASK))
         return;
@@ -394,7 +394,7 @@ static void effect_damage_piles_confusion(player_type *player_ptr, effect_monste
  * @details
  * 打撃ダメージによる恐怖もあるため、メッセージは後で表示。
  */
-static void effect_damage_piles_fear(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_damage_piles_fear(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->do_fear == 0 || any_bits(em_ptr->r_ptr->flags3, RF3_NO_FEAR))
         return;
@@ -433,7 +433,7 @@ static void effect_damage_makes_weak(effect_monster_type *em_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void effect_damage_makes_polymorph(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_damage_makes_polymorph(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (!em_ptr->do_polymorph || (randint1(90) <= em_ptr->r_ptr->level))
         return;
@@ -455,7 +455,7 @@ static void effect_damage_makes_polymorph(player_type *player_ptr, effect_monste
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void effect_damage_makes_teleport(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_damage_makes_teleport(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->do_dist == 0)
         return;
@@ -486,7 +486,7 @@ static void effect_damage_makes_teleport(player_type *player_ptr, effect_monster
  * 2.ダメージ量が現HPを上回る場合
  * 3.通常時(デバフをかける)
  */
-static void effect_damage_gives_bad_status(player_type *player_ptr, effect_monster_type *em_ptr)
+static void effect_damage_gives_bad_status(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     int tmp_damage = em_ptr->dam;
     em_ptr->dam = mon_damage_mod(player_ptr, em_ptr->m_ptr, em_ptr->dam, (bool)(em_ptr->attribute == AttributeType::PSY_SPEAR));
@@ -517,7 +517,7 @@ static void effect_damage_gives_bad_status(player_type *player_ptr, effect_monst
  * 4.ダメージ処理及び恐怖メッセージ
  * 5.悪魔領域血の呪いによる事後処理
  */
-static void exe_affect_monster_by_damage(player_type *player_ptr, effect_monster_type *em_ptr)
+static void exe_affect_monster_by_damage(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     effect_makes_change_virtues(player_ptr, em_ptr);
     affected_monster_prevents_bad_status(player_ptr, em_ptr);
@@ -532,7 +532,7 @@ static void exe_affect_monster_by_damage(player_type *player_ptr, effect_monster
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void update_phase_out_stat(player_type *player_ptr, effect_monster_type *em_ptr)
+static void update_phase_out_stat(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (!player_ptr->phase_out)
         return;
@@ -547,7 +547,7 @@ static void update_phase_out_stat(player_type *player_ptr, effect_monster_type *
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void postprocess_by_effected_pet(player_type *player_ptr, effect_monster_type *em_ptr)
+static void postprocess_by_effected_pet(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if ((em_ptr->dam <= 0) || is_pet(em_ptr->m_ptr) || is_friendly(em_ptr->m_ptr))
         return;
@@ -568,7 +568,7 @@ static void postprocess_by_effected_pet(player_type *player_ptr, effect_monster_
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void postprocess_by_riding_pet_effected(player_type *player_ptr, effect_monster_type *em_ptr)
+static void postprocess_by_riding_pet_effected(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (!player_ptr->riding || (player_ptr->riding != em_ptr->g_ptr->m_idx) || (em_ptr->dam <= 0))
         return;
@@ -585,7 +585,7 @@ static void postprocess_by_riding_pet_effected(player_type *player_ptr, effect_m
  * @param em_ptr モンスター効果構造体への参照ポインタ
  * @details 写真のフラッシュは弱閃光属性
  */
-static void postprocess_by_taking_photo(player_type *player_ptr, effect_monster_type *em_ptr)
+static void postprocess_by_taking_photo(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     if (em_ptr->photo == 0)
         return;
@@ -604,7 +604,7 @@ static void postprocess_by_taking_photo(player_type *player_ptr, effect_monster_
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr モンスター効果構造体への参照ポインタ
  */
-static void exe_affect_monster_postprocess(player_type *player_ptr, effect_monster_type *em_ptr)
+static void exe_affect_monster_postprocess(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     postprocess_by_effected_pet(player_ptr, em_ptr);
     postprocess_by_riding_pet_effected(player_ptr, em_ptr);
@@ -633,7 +633,7 @@ static void exe_affect_monster_postprocess(player_type *player_ptr, effect_monst
  * 3.ペット及び撮影による事後効果
  */
 bool affect_monster(
-    player_type *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType attribute, BIT_FLAGS flag, bool see_s_msg)
+    PlayerType *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType attribute, BIT_FLAGS flag, bool see_s_msg)
 {
     effect_monster_type tmp_effect;
     effect_monster_type *em_ptr = initialize_effect_monster(player_ptr, &tmp_effect, who, r, y, x, dam, attribute, flag, see_s_msg);
index 7ff36db..fe97f2a 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "effect/attribute-types.h"
 
-struct player_type;
-bool affect_monster(player_type *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ, BIT_FLAGS flag, bool see_s_msg);
+class PlayerType;
+bool affect_monster(PlayerType *player_ptr, MONSTER_IDX who, POSITION r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ, BIT_FLAGS flag, bool see_s_msg);
index 80fabad..8c0a112 100644 (file)
@@ -11,7 +11,7 @@
 #include "view/display-messages.h"
 #include "world/world.h"
 
-void effect_player_curse_1(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_curse_1(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if ((randint0(100 + ep_ptr->rlev / 2) < player_ptr->skill_sav) && !check_multishadow(player_ptr)) {
         msg_print(_("しかし効力を跳ね返した!", "You resist the effects!"));
@@ -22,7 +22,7 @@ void effect_player_curse_1(player_type *player_ptr, effect_player_type *ep_ptr)
     }
 }
 
-void effect_player_curse_2(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_curse_2(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if ((randint0(100 + ep_ptr->rlev / 2) < player_ptr->skill_sav) && !check_multishadow(player_ptr)) {
         msg_print(_("しかし効力を跳ね返した!", "You resist the effects!"));
@@ -33,7 +33,7 @@ void effect_player_curse_2(player_type *player_ptr, effect_player_type *ep_ptr)
     }
 }
 
-void effect_player_curse_3(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_curse_3(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if ((randint0(100 + ep_ptr->rlev / 2) < player_ptr->skill_sav) && !check_multishadow(player_ptr)) {
         msg_print(_("しかし効力を跳ね返した!", "You resist the effects!"));
@@ -44,7 +44,7 @@ void effect_player_curse_3(player_type *player_ptr, effect_player_type *ep_ptr)
     }
 }
 
-void effect_player_curse_4(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_curse_4(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if ((randint0(100 + ep_ptr->rlev / 2) < player_ptr->skill_sav) && (ep_ptr->m_ptr->r_idx != MON_KENSHIROU) && !check_multishadow(player_ptr)) {
         msg_print(_("しかし秘孔を跳ね返した!", "You resist the effects!"));
index 129af72..b797adf 100644 (file)
@@ -1,8 +1,8 @@
 #pragma once
 
 struct effect_player_type;
-struct player_type;
-void effect_player_curse_1(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_curse_2(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_curse_3(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_curse_4(player_type *player_ptr, effect_player_type *ep_ptr);
+class PlayerType;
+void effect_player_curse_1(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_curse_2(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_curse_3(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_curse_4(PlayerType *player_ptr, effect_player_type *ep_ptr);
index 5713f14..ca0ff6c 100644 (file)
@@ -9,7 +9,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-void effect_player_old_heal(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_old_heal(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何らかの攻撃によって気分がよくなった。", "You are hit by something invigorating!"));
@@ -18,7 +18,7 @@ void effect_player_old_heal(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->dam = 0;
 }
 
-void effect_player_old_speed(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_old_speed(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かで攻撃された!", "You are hit by something!"));
@@ -27,7 +27,7 @@ void effect_player_old_speed(player_type *player_ptr, effect_player_type *ep_ptr
     ep_ptr->dam = 0;
 }
 
-void effect_player_old_slow(player_type *player_ptr)
+void effect_player_old_slow(PlayerType *player_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("何か遅いもので攻撃された!", "You are hit by something slow!"));
@@ -36,7 +36,7 @@ void effect_player_old_slow(player_type *player_ptr)
     (void)BadStatusSetter(player_ptr).mod_slowness(randint0(4) + 4, false);
 }
 
-void effect_player_old_sleep(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_old_sleep(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->free_act)
         return;
index 09b1d81..9095dbc 100644 (file)
@@ -1,8 +1,8 @@
 #pragma once
 
 struct effect_player_type;
-struct player_type;
-void effect_player_old_heal(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_old_speed(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_old_slow(player_type *player_ptr);
-void effect_player_old_sleep(player_type *player_ptr, effect_player_type *ep_ptr);
+class PlayerType;
+void effect_player_old_heal(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_old_speed(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_old_slow(PlayerType *player_ptr);
+void effect_player_old_sleep(PlayerType *player_ptr, effect_player_type *ep_ptr);
index c783c9b..6435b23 100644 (file)
@@ -35,7 +35,7 @@
 
 // 毒を除く4元素.
 void effect_player_elements(
-    player_type *player_ptr, effect_player_type *ep_ptr, concptr attack_message, HIT_POINT (*damage_func)(player_type *, HIT_POINT, concptr, bool))
+    PlayerType *player_ptr, effect_player_type *ep_ptr, concptr attack_message, HIT_POINT (*damage_func)(PlayerType *, HIT_POINT, concptr, bool))
 {
     if (player_ptr->blind)
         msg_print(attack_message);
@@ -43,7 +43,7 @@ void effect_player_elements(
     ep_ptr->get_damage = (*damage_func)(player_ptr, ep_ptr->dam, ep_ptr->killer, false);
 }
 
-void effect_player_poison(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_poison(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     bool double_resist = is_oppose_pois(player_ptr);
     if (player_ptr->blind)
@@ -62,7 +62,7 @@ void effect_player_poison(player_type *player_ptr, effect_player_type *ep_ptr)
     }
 }
 
-void effect_player_nuke(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_nuke(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     bool double_resist = is_oppose_pois(player_ptr);
     if (player_ptr->blind)
@@ -88,7 +88,7 @@ void effect_player_nuke(player_type *player_ptr, effect_player_type *ep_ptr)
         inventory_damage(player_ptr, BreakerAcid(), 2);
 }
 
-void effect_player_missile(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_missile(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かで攻撃された!", "You are hit by something!"));
@@ -96,7 +96,7 @@ void effect_player_missile(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_holy_fire(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_holy_fire(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かで攻撃された!", "You are hit by something!"));
@@ -106,7 +106,7 @@ void effect_player_holy_fire(player_type *player_ptr, effect_player_type *ep_ptr
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_hell_fire(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_hell_fire(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かで攻撃された!", "You are hit by something!"));
@@ -116,7 +116,7 @@ void effect_player_hell_fire(player_type *player_ptr, effect_player_type *ep_ptr
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_arrow(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_arrow(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind) {
         sound(SOUND_SHOOT_HIT);
@@ -134,7 +134,7 @@ void effect_player_arrow(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_plasma(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_plasma(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かとても熱いもので攻撃された!", "You are hit by something *HOT*!"));
@@ -158,7 +158,7 @@ void effect_player_plasma(player_type *player_ptr, effect_player_type *ep_ptr)
  * 幽霊は回復する。追加効果で経験値吸収。
  */
 
-void effect_player_nether(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_nether(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("地獄の力で攻撃された!", "You are hit by nether forces!"));
@@ -189,7 +189,7 @@ void effect_player_nether(player_type *player_ptr, effect_player_type *ep_ptr)
  * @details
  * 追加効果で朦朧と混乱、冷気同様のインベントリ破壊。
  */
-void effect_player_water(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_water(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("何か湿ったもので攻撃された!", "You are hit by something wet!"));
@@ -221,7 +221,7 @@ void effect_player_water(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_chaos(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_chaos(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("無秩序の波動で攻撃された!", "You are hit by a wave of anarchy!"));
@@ -257,7 +257,7 @@ void effect_player_chaos(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_shards(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_shards(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何か鋭いもので攻撃された!", "You are hit by something sharp!"));
@@ -274,7 +274,7 @@ void effect_player_shards(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_sound(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_sound(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("轟音で攻撃された!", "You are hit by a loud noise!"));
@@ -292,7 +292,7 @@ void effect_player_sound(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_confusion(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_confusion(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("何か混乱するもので攻撃された!", "You are hit by something puzzling!"));
@@ -307,7 +307,7 @@ void effect_player_confusion(player_type *player_ptr, effect_player_type *ep_ptr
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_disenchant(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_disenchant(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かさえないもので攻撃された!", "You are hit by something static!"));
@@ -321,7 +321,7 @@ void effect_player_disenchant(player_type *player_ptr, effect_player_type *ep_pt
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_nexus(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_nexus(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何か奇妙なもので攻撃された!", "You are hit by something strange!"));
@@ -335,7 +335,7 @@ void effect_player_nexus(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_force(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_force(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("運動エネルギーで攻撃された!", "You are hit by kinetic force!"));
@@ -346,7 +346,7 @@ void effect_player_force(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_rocket(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_rocket(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("爆発があった!", "There is an explosion!"));
@@ -369,7 +369,7 @@ void effect_player_rocket(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_inertial(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_inertial(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("何か遅いもので攻撃された!", "You are hit by something slow!"));
@@ -382,7 +382,7 @@ void effect_player_inertial(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_lite(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_lite(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かで攻撃された!", "You are hit by something!"));
@@ -411,7 +411,7 @@ void effect_player_lite(player_type *player_ptr, effect_player_type *ep_ptr)
     player_ptr->window_flags |= (PW_OVERHEAD | PW_DUNGEON);
 }
 
-void effect_player_dark(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_dark(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かで攻撃された!", "You are hit by something!"));
@@ -425,7 +425,7 @@ void effect_player_dark(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-static void effect_player_time_one_disability(player_type *player_ptr)
+static void effect_player_time_one_disability(PlayerType *player_ptr)
 {
     int k = 0;
     concptr act = nullptr;
@@ -464,7 +464,7 @@ static void effect_player_time_one_disability(player_type *player_ptr)
     player_ptr->update |= (PU_BONUS);
 }
 
-static void effect_player_time_all_disabilities(player_type *player_ptr)
+static void effect_player_time_all_disabilities(PlayerType *player_ptr)
 {
     msg_print(_("あなたは以前ほど力強くなくなってしまった...。", "You're not as powerful as you used to be..."));
     for (int k = 0; k < A_MAX; k++) {
@@ -476,7 +476,7 @@ static void effect_player_time_all_disabilities(player_type *player_ptr)
     player_ptr->update |= (PU_BONUS);
 }
 
-static void effect_player_time_addition(player_type *player_ptr)
+static void effect_player_time_addition(PlayerType *player_ptr)
 {
     switch (randint1(10)) {
     case 1:
@@ -508,7 +508,7 @@ static void effect_player_time_addition(player_type *player_ptr)
  * @param player_ptr プレイヤー情報への参照ポインタ
  * @param em_ptr プレイヤー効果情報への参照ポインタ
  */
-void effect_player_time(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_time(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("過去からの衝撃に攻撃された!", "You are hit by a blast from the past!"));
@@ -526,7 +526,7 @@ void effect_player_time(player_type *player_ptr, effect_player_type *ep_ptr)
         effect_player_time_addition(player_ptr);
 }
 
-void effect_player_gravity(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_gravity(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("何か重いもので攻撃された!", "You are hit by something heavy!"));
@@ -555,7 +555,7 @@ void effect_player_gravity(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_disintegration(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_disintegration(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("純粋なエネルギーで攻撃された!", "You are hit by pure energy!"));
@@ -563,7 +563,7 @@ void effect_player_disintegration(player_type *player_ptr, effect_player_type *e
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_death_ray(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_death_ray(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何か非常に冷たいもので攻撃された!", "You are hit by something extremely cold!"));
@@ -572,7 +572,7 @@ void effect_player_death_ray(player_type *player_ptr, effect_player_type *ep_ptr
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_mana(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_mana(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("魔法のオーラで攻撃された!", "You are hit by an aura of magic!"));
@@ -580,7 +580,7 @@ void effect_player_mana(player_type *player_ptr, effect_player_type *ep_ptr)
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_psy_spear(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_psy_spear(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("エネルギーの塊で攻撃された!", "You are hit by an energy!"));
@@ -588,7 +588,7 @@ void effect_player_psy_spear(player_type *player_ptr, effect_player_type *ep_ptr
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_FORCE, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_meteor(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_meteor(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind)
         msg_print(_("何かが空からあなたの頭上に落ちてきた!", "Something falls from the sky on you!"));
@@ -601,7 +601,7 @@ void effect_player_meteor(player_type *player_ptr, effect_player_type *ep_ptr)
     }
 }
 
-void effect_player_icee(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_icee(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (player_ptr->blind) {
         msg_print(_("何か鋭く冷たいもので攻撃された!", "You are hit by something sharp and cold!"));
@@ -628,7 +628,7 @@ void effect_player_icee(player_type *player_ptr, effect_player_type *ep_ptr)
     }
 }
 
-void effect_player_hand_doom(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_hand_doom(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if ((randint0(100 + ep_ptr->rlev / 2) < player_ptr->skill_sav) && !check_multishadow(player_ptr)) {
         msg_print(_("しかし効力を跳ね返した!", "You resist the effects!"));
@@ -645,7 +645,7 @@ void effect_player_hand_doom(player_type *player_ptr, effect_player_type *ep_ptr
     }
 }
 
-void effect_player_void(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_void(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     auto effect_mes = player_ptr->blind ? _("何かに身体が引っ張りこまれる!", "Something absorbs you!")
                                         : _("周辺の空間が歪んだ。", "Sight warps around you.");
@@ -660,7 +660,7 @@ void effect_player_void(player_type *player_ptr, effect_player_type *ep_ptr)
     }
 }
 
-void effect_player_abyss(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_abyss(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     auto effect_mes = player_ptr->blind ? _("身体が沈み込む気がする!", "You feel you are sinking into something!")
                                         : _("深淵があなたを誘い込んでいる!", "You are falling in abyss!");
index 1a4b15d..e27e94a 100644 (file)
@@ -3,35 +3,35 @@
 #include "system/angband.h"
 
 struct effect_player_type;
-struct player_type;
+class PlayerType;
 void effect_player_elements(
-    player_type *player_ptr, effect_player_type *ep_ptr, concptr attack_message, HIT_POINT (*damage_func)(player_type *, HIT_POINT, concptr, bool));
-void effect_player_poison(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_nuke(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_missile(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_holy_fire(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_hell_fire(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_arrow(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_plasma(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_nether(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_water(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_chaos(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_shards(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_sound(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_confusion(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_disenchant(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_nexus(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_force(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_rocket(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_inertial(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_lite(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_dark(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_time(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_gravity(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_disintegration(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_death_ray(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_mana(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_psy_spear(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_meteor(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_icee(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_hand_doom(player_type *player_ptr, effect_player_type *ep_ptr);
+    PlayerType *player_ptr, effect_player_type *ep_ptr, concptr attack_message, HIT_POINT (*damage_func)(PlayerType *, HIT_POINT, concptr, bool));
+void effect_player_poison(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_nuke(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_missile(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_holy_fire(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_hell_fire(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_arrow(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_plasma(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_nether(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_water(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_chaos(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_shards(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_sound(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_confusion(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_disenchant(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_nexus(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_force(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_rocket(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_inertial(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_lite(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_dark(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_time(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_gravity(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_disintegration(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_death_ray(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_mana(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_psy_spear(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_meteor(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_icee(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_hand_doom(PlayerType *player_ptr, effect_player_type *ep_ptr);
index 463de74..0f67366 100644 (file)
@@ -13,7 +13,7 @@
 #include "view/display-messages.h"
 #include "world/world.h"
 
-void effect_player_drain_mana(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_drain_mana(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if (check_multishadow(player_ptr)) {
         msg_print(_("攻撃は幻影に命中し、あなたには届かなかった。", "The attack hits Shadow, but you are unharmed!"));
@@ -63,7 +63,7 @@ void effect_player_drain_mana(player_type *player_ptr, effect_player_type *ep_pt
     ep_ptr->dam = 0;
 }
 
-void effect_player_mind_blast(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_mind_blast(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if ((randint0(100 + ep_ptr->rlev / 2) < std::max<short>(5, player_ptr->skill_sav)) && !check_multishadow(player_ptr)) {
         msg_print(_("しかし効力を跳ね返した!", "You resist the effects!"));
@@ -95,7 +95,7 @@ void effect_player_mind_blast(player_type *player_ptr, effect_player_type *ep_pt
     ep_ptr->get_damage = take_hit(player_ptr, DAMAGE_ATTACK, ep_ptr->dam, ep_ptr->killer);
 }
 
-void effect_player_brain_smash(player_type *player_ptr, effect_player_type *ep_ptr)
+void effect_player_brain_smash(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     if ((randint0(100 + ep_ptr->rlev / 2) < std::max<short>(5, player_ptr->skill_sav)) && !check_multishadow(player_ptr)) {
         msg_print(_("しかし効力を跳ね返した!", "You resist the effects!"));
index 32fabb9..eedcb1a 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct effect_player_type;
-struct player_type;
-void effect_player_drain_mana(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_mind_blast(player_type *player_ptr, effect_player_type *ep_ptr);
-void effect_player_brain_smash(player_type *player_ptr, effect_player_type *ep_ptr);
+class PlayerType;
+void effect_player_drain_mana(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_mind_blast(PlayerType *player_ptr, effect_player_type *ep_ptr);
+void effect_player_brain_smash(PlayerType *player_ptr, effect_player_type *ep_ptr);
index 388d93b..8088da2 100644 (file)
@@ -14,7 +14,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param em_ptr プレイヤー効果構造体への参照ポインタ
  */
-void switch_effects_player(player_type *player_ptr, effect_player_type *ep_ptr)
+void switch_effects_player(PlayerType *player_ptr, effect_player_type *ep_ptr)
 {
     switch (ep_ptr->attribute) {
     case AttributeType::ACID:
index 1034f5f..2ff0247 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct effect_player_type;
-struct player_type;
-void switch_effects_player(player_type *player_ptr, effect_player_type *ep_ptr);
+class PlayerType;
+void switch_effects_player(PlayerType *player_ptr, effect_player_type *ep_ptr);
index d251f47..516c701 100644 (file)
@@ -64,7 +64,7 @@ static effect_player_type *initialize_effect_player(effect_player_type *ep_ptr,
  * @param ep_ptr プレイヤー効果構造体への参照ポインタ
  * @return 当たったらFALSE、反射したらTRUE
  */
-static bool process_bolt_reflection(player_type *player_ptr, effect_player_type *ep_ptr, project_func project)
+static bool process_bolt_reflection(PlayerType *player_ptr, effect_player_type *ep_ptr, project_func project)
 {
     auto can_reflect = (has_reflect(player_ptr) != 0);
     can_reflect &= any_bits(ep_ptr->flag, PROJECT_REFLECTABLE);
@@ -119,7 +119,7 @@ static bool process_bolt_reflection(player_type *player_ptr, effect_player_type
  * @param x 目標X座標
  * @return 当たらなかったらFALSE、反射したらTRUE、当たったらCONTINUE
  */
-static process_result check_continue_player_effect(player_type *player_ptr, effect_player_type *ep_ptr, POSITION y, POSITION x, project_func project)
+static process_result check_continue_player_effect(PlayerType *player_ptr, effect_player_type *ep_ptr, POSITION y, POSITION x, project_func project)
 {
     if (!player_bold(player_ptr, y, x)) {
         return PROCESS_FALSE;
@@ -150,7 +150,7 @@ static process_result check_continue_player_effect(player_type *player_ptr, effe
  * @param ep_ptr プレイヤー効果構造体への参照ポインタ
  * @param who_name モンスター名
  */
-static void describe_effect_source(player_type *player_ptr, effect_player_type *ep_ptr, concptr who_name)
+static void describe_effect_source(PlayerType *player_ptr, effect_player_type *ep_ptr, concptr who_name)
 {
     if (ep_ptr->who > 0) {
         ep_ptr->m_ptr = &player_ptr->current_floor_ptr->m_list[ep_ptr->who];
@@ -188,7 +188,7 @@ static void describe_effect_source(player_type *player_ptr, effect_player_type *
  * @param monspell 効果元のモンスター魔法ID
  * @return 何か一つでも効力があればTRUEを返す / TRUE if any "effects" of the projection were observed, else FALSE
  */
-bool affect_player(MONSTER_IDX who, player_type *player_ptr, concptr who_name, int r, POSITION y, POSITION x, HIT_POINT dam, AttributeType attribute,
+bool affect_player(MONSTER_IDX who, PlayerType *player_ptr, concptr who_name, int r, POSITION y, POSITION x, HIT_POINT dam, AttributeType attribute,
     BIT_FLAGS flag, project_func project)
 {
     effect_player_type tmp_effect;
index 866ce63..3c63a4c 100644 (file)
@@ -5,9 +5,9 @@
 
 struct ProjectResult;
 
-struct player_type;
+class PlayerType;
 using project_func = ProjectResult (*)(
-    player_type *player_ptr, MONSTER_IDX who, POSITION rad, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ, BIT_FLAGS flag);
+    PlayerType *player_ptr, MONSTER_IDX who, POSITION rad, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ, BIT_FLAGS flag);
 
-bool affect_player(MONSTER_IDX who, player_type *player_ptr, concptr who_name, int r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ, BIT_FLAGS flag,
+bool affect_player(MONSTER_IDX who, PlayerType *player_ptr, concptr who_name, int r, POSITION y, POSITION x, HIT_POINT dam, AttributeType typ, BIT_FLAGS flag,
     project_func project);
index 99cd453..d48393e 100644 (file)
@@ -45,7 +45,7 @@
  * @param cury 現在の鏡のy座標
  * @param curx 現在の鏡のx座標
  */
-static void next_mirror(player_type *player_ptr, POSITION *next_y, POSITION *next_x, POSITION cury, POSITION curx)
+static void next_mirror(PlayerType *player_ptr, POSITION *next_y, POSITION *next_x, POSITION cury, POSITION curx)
 {
     POSITION mirror_x[10], mirror_y[10]; /* 鏡はもっと少ない */
     int mirror_num = 0; /* 鏡の数 */
@@ -87,7 +87,7 @@ static void next_mirror(player_type *player_ptr, POSITION *next_y, POSITION *nex
  * @todo 似たような処理が山ほど並んでいる、何とかならないものか
  * @todo 引数にそのまま再代入していてカオスすぎる。直すのは簡単ではない
  */
-ProjectResult project(player_type *player_ptr, const MONSTER_IDX who, POSITION rad, POSITION y, POSITION x, const HIT_POINT dam,
+ProjectResult project(PlayerType *player_ptr, const MONSTER_IDX who, POSITION rad, POSITION y, POSITION x, const HIT_POINT dam,
     const AttributeType typ, BIT_FLAGS flag)
 {
     int dist;
index 8418d3a..c383f47 100644 (file)
@@ -12,7 +12,7 @@ struct ProjectResult {
 };
 
 struct effect_player_type;
-struct player_type;
+class PlayerType;
 ProjectResult project(
-    player_type *player_ptr, const MONSTER_IDX who, POSITION rad, POSITION y, POSITION x, const HIT_POINT dam, const AttributeType typ,
+    PlayerType *player_ptr, const MONSTER_IDX who, POSITION rad, POSITION y, POSITION x, const HIT_POINT dam, const AttributeType typ,
     BIT_FLAGS flag);
index cf7fddd..c2cb439 100644 (file)
@@ -127,7 +127,7 @@ static void decide_tval_show(flavor_type *flavor_ptr)
         flavor_ptr->show_armour = true;
 }
 
-static void describe_weapon_dice(player_type *player_ptr, flavor_type *flavor_ptr)
+static void describe_weapon_dice(PlayerType *player_ptr, flavor_type *flavor_ptr)
 {
     if (!flavor_ptr->known && object_is_quest_target(player_ptr->current_floor_ptr->inside_quest, flavor_ptr->o_ptr))
         return;
@@ -142,7 +142,7 @@ static void describe_weapon_dice(player_type *player_ptr, flavor_type *flavor_pt
     flavor_ptr->t = object_desc_chr(flavor_ptr->t, flavor_ptr->p2);
 }
 
-static void describe_bow(player_type *player_ptr, flavor_type *flavor_ptr)
+static void describe_bow(PlayerType *player_ptr, flavor_type *flavor_ptr)
 {
     flavor_ptr->power = bow_tmul(flavor_ptr->o_ptr->sval);
     if (flavor_ptr->tr_flags.has(TR_XTRA_MIGHT))
@@ -175,7 +175,7 @@ static void describe_bow(player_type *player_ptr, flavor_type *flavor_ptr)
     flavor_ptr->t = object_desc_chr(flavor_ptr->t, flavor_ptr->p2);
 }
 
-static void describe_tval(player_type *player_ptr, flavor_type *flavor_ptr)
+static void describe_tval(PlayerType *player_ptr, flavor_type *flavor_ptr)
 {
     switch (flavor_ptr->o_ptr->tval) {
     case ItemKindType::SHOT:
@@ -227,7 +227,7 @@ static void describe_named_item_tval(flavor_type *flavor_ptr)
     }
 }
 
-static void describe_fire_energy(player_type *player_ptr, flavor_type *flavor_ptr)
+static void describe_fire_energy(PlayerType *player_ptr, flavor_type *flavor_ptr)
 {
     ENERGY energy_fire = bow_energy(flavor_ptr->bow_ptr->sval);
     if (player_ptr->num_fire == 0) {
@@ -253,7 +253,7 @@ static void describe_fire_energy(player_type *player_ptr, flavor_type *flavor_pt
     flavor_ptr->t = object_desc_str(flavor_ptr->t, show_ammo_detail ? "% crit" : "%");
 }
 
-static void describe_bow_power(player_type *player_ptr, flavor_type *flavor_ptr)
+static void describe_bow_power(PlayerType *player_ptr, flavor_type *flavor_ptr)
 {
     flavor_ptr->avgdam = flavor_ptr->o_ptr->dd * (flavor_ptr->o_ptr->ds + 1) * 10 / 2;
     int tmul = bow_tmul(flavor_ptr->bow_ptr->sval);
@@ -289,7 +289,7 @@ static void describe_bow_power(player_type *player_ptr, flavor_type *flavor_ptr)
     flavor_ptr->t = object_desc_chr(flavor_ptr->t, flavor_ptr->p2);
 }
 
-static void describe_spike_power(player_type *player_ptr, flavor_type *flavor_ptr)
+static void describe_spike_power(PlayerType *player_ptr, flavor_type *flavor_ptr)
 {
     int avgdam = player_ptr->mighty_throw ? (1 + 3) : 1;
     int16_t energy_fire = 100 - player_ptr->lev;
@@ -502,7 +502,7 @@ static void decide_item_feeling(flavor_type *flavor_ptr)
  * @param mode 表記に関するオプション指定
  * @return 現在クエスト達成目的のアイテムならばTRUEを返す
  */
-void describe_flavor(player_type *player_ptr, char *buf, object_type *o_ptr, BIT_FLAGS mode)
+void describe_flavor(PlayerType *player_ptr, char *buf, object_type *o_ptr, BIT_FLAGS mode)
 {
     flavor_type tmp_flavor;
     flavor_type *flavor_ptr = initialize_flavor_type(&tmp_flavor, buf, o_ptr, mode);
index eae02f8..fbad406 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-void describe_flavor(player_type *player_ptr, char *buf, object_type *o_ptr, BIT_FLAGS mode);
+class PlayerType;
+void describe_flavor(PlayerType *player_ptr, char *buf, object_type *o_ptr, BIT_FLAGS mode);
index ee5b202..e3c31d1 100644 (file)
@@ -40,7 +40,7 @@ typedef struct flavor_type {
     int avgdam;
 } flavor_type;
 
-struct player_type;
+class PlayerType;
 flavor_type *initialize_flavor_type(flavor_type *flavor_ptr, char *buf, object_type *o_ptr, BIT_FLAGS mode);
 char *object_desc_chr(char *t, char c);
 char *object_desc_str(char *t, concptr s);
index e71654f..39cfa71 100644 (file)
@@ -350,7 +350,7 @@ static void describe_inscription(flavor_type *flavor_ptr)
     }
 }
 
-void describe_named_item(player_type *player_ptr, flavor_type *flavor_ptr)
+void describe_named_item(PlayerType *player_ptr, flavor_type *flavor_ptr)
 {
     check_object_known_aware(flavor_ptr);
     switch_tval_description(flavor_ptr);
index 4935e42..642a98a 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct flavor_type;
-struct player_type;
-void describe_named_item(player_type *player_ptr, flavor_type *flavor_ptr);
+class PlayerType;
+void describe_named_item(PlayerType *player_ptr, flavor_type *flavor_ptr);
index 6004a26..0821bcb 100644 (file)
@@ -48,7 +48,7 @@ static dun_data_type *initialize_dun_data_type(dun_data_type *dd_ptr, concptr *w
     return dd_ptr;
 }
 
-static void check_arena_floor(player_type *player_ptr, dun_data_type *dd_ptr)
+static void check_arena_floor(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!dd_ptr->empty_level) {
@@ -74,7 +74,7 @@ static void check_arena_floor(player_type *player_ptr, dun_data_type *dd_ptr)
     }
 }
 
-static void place_cave_contents(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
+static void place_cave_contents(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (floor_ptr->dun_level == 1)
@@ -99,7 +99,7 @@ static void place_cave_contents(player_type *player_ptr, dun_data_type *dd_ptr,
     }
 }
 
-static bool decide_tunnel_planned_site(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr, dt_type *dt_ptr, int i)
+static bool decide_tunnel_planned_site(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr, dt_type *dt_ptr, int i)
 {
     dd_ptr->tunn_n = 0;
     dd_ptr->wall_n = 0;
@@ -116,7 +116,7 @@ static bool decide_tunnel_planned_site(player_type *player_ptr, dun_data_type *d
     return true;
 }
 
-static void make_tunnels(player_type *player_ptr, dun_data_type *dd_ptr)
+static void make_tunnels(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     for (int j = 0; j < dd_ptr->tunn_n; j++) {
         grid_type *g_ptr;
@@ -132,7 +132,7 @@ static void make_tunnels(player_type *player_ptr, dun_data_type *dd_ptr)
     }
 }
 
-static void make_walls(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr, dt_type *dt_ptr)
+static void make_walls(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr, dt_type *dt_ptr)
 {
     for (int j = 0; j < dd_ptr->wall_n; j++) {
         grid_type *g_ptr;
@@ -146,7 +146,7 @@ static void make_walls(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_t
     }
 }
 
-static bool make_centers(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr, dt_type *dt_ptr)
+static bool make_centers(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr, dt_type *dt_ptr)
 {
     dd_ptr->tunnel_fail_count = 0;
     dd_ptr->door_n = 0;
@@ -165,7 +165,7 @@ static bool make_centers(player_type *player_ptr, dun_data_type *dd_ptr, dungeon
     return true;
 }
 
-static void make_doors(player_type *player_ptr, dun_data_type *dd_ptr, dt_type *dt_ptr)
+static void make_doors(PlayerType *player_ptr, dun_data_type *dd_ptr, dt_type *dt_ptr)
 {
     for (int i = 0; i < dd_ptr->door_n; i++) {
         dd_ptr->tunnel_y = dd_ptr->door[i].y;
@@ -187,7 +187,7 @@ static void make_only_tunnel_points(floor_type *floor_ptr, dun_data_type *dd_ptr
     }
 }
 
-static bool make_one_floor(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
+static bool make_one_floor(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
 
@@ -220,7 +220,7 @@ static bool make_one_floor(player_type *player_ptr, dun_data_type *dd_ptr, dunge
     return true;
 }
 
-static bool switch_making_floor(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
+static bool switch_making_floor(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
 {
     if (d_ptr->flags.has(DungeonFeatureType::MAZE)) {
         floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -244,7 +244,7 @@ static bool switch_making_floor(player_type *player_ptr, dun_data_type *dd_ptr,
     return true;
 }
 
-static void make_aqua_streams(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
+static void make_aqua_streams(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
 {
     if (dd_ptr->laketype != 0)
         return;
@@ -262,7 +262,7 @@ static void make_aqua_streams(player_type *player_ptr, dun_data_type *dd_ptr, du
  * @brief マスにフロア端用の永久壁を配置する / Set boundary mimic and add "solid" perma-wall
  * @param g_ptr 永久壁を配置したいマス構造体の参照ポインタ
  */
-static void place_bound_perm_wall(player_type *player_ptr, grid_type *g_ptr)
+static void place_bound_perm_wall(PlayerType *player_ptr, grid_type *g_ptr)
 {
     if (bound_walls_perm) {
         g_ptr->mimic = 0;
@@ -279,7 +279,7 @@ static void place_bound_perm_wall(player_type *player_ptr, grid_type *g_ptr)
     place_grid(player_ptr, g_ptr, GB_SOLID_PERM);
 }
 
-static void make_perm_walls(player_type *player_ptr)
+static void make_perm_walls(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (POSITION x = 0; x < floor_ptr->width; x++) {
@@ -293,7 +293,7 @@ static void make_perm_walls(player_type *player_ptr)
     }
 }
 
-static bool check_place_necessary_objects(player_type *player_ptr, dun_data_type *dd_ptr)
+static bool check_place_necessary_objects(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     if (!new_player_spot(player_ptr)) {
         *dd_ptr->why = _("プレイヤー配置に失敗", "Failed to place a player");
@@ -308,7 +308,7 @@ static bool check_place_necessary_objects(player_type *player_ptr, dun_data_type
     return true;
 }
 
-static void decide_dungeon_data_allocation(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
+static void decide_dungeon_data_allocation(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     dd_ptr->alloc_object_num = floor_ptr->dun_level / 3;
@@ -333,7 +333,7 @@ static void decide_dungeon_data_allocation(player_type *player_ptr, dun_data_typ
             dd_ptr->alloc_monster_num);
 }
 
-static bool allocate_dungeon_data(player_type *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
+static bool allocate_dungeon_data(PlayerType *player_ptr, dun_data_type *dd_ptr, dungeon_type *d_ptr)
 {
     dd_ptr->alloc_monster_num += randint1(8);
     for (dd_ptr->alloc_monster_num = dd_ptr->alloc_monster_num + dd_ptr->alloc_object_num; dd_ptr->alloc_monster_num > 0; dd_ptr->alloc_monster_num--)
@@ -378,7 +378,7 @@ static void decide_grid_glowing(floor_type *floor_ptr, dun_data_type *dd_ptr, du
  * @param why エラー原因メッセージを返す
  * @return ダンジョン生成が全て無事に成功したらTRUEを返す。
  */
-bool cave_gen(player_type *player_ptr, concptr *why)
+bool cave_gen(PlayerType *player_ptr, concptr *why)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     reset_lite_area(floor_ptr);
index efffc0f..e54bd77 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool cave_gen(player_type *player_ptr, concptr *why);
+class PlayerType;
+bool cave_gen(PlayerType *player_ptr, concptr *why);
index fa75391..f6839a8 100644 (file)
@@ -39,7 +39,7 @@ bool in_bounds2u(floor_type *floor_ptr, POSITION y, POSITION x) { return (y < fl
  * Line 2 -- forbid normal monsters
  * Line 3 -- forbid the player
  */
-bool is_cave_empty_bold(player_type *player_ptr, POSITION y, POSITION x)
+bool is_cave_empty_bold(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     bool is_empty_grid = cave_has_flag_bold(floor_ptr, y, x, FloorFeatureType::PLACE);
@@ -55,7 +55,7 @@ bool is_cave_empty_bold(player_type *player_ptr, POSITION y, POSITION x)
  * Line 1 -- forbid non-empty grids
  * Line 2 -- forbid trees while dungeon generation
  */
-bool is_cave_empty_bold2(player_type *player_ptr, POSITION y, POSITION x)
+bool is_cave_empty_bold2(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     bool is_empty_grid = is_cave_empty_bold(player_ptr, y, x);
     is_empty_grid &= w_ptr->character_dungeon || !cave_has_flag_bold(player_ptr->current_floor_ptr, y, x, FloorFeatureType::TREE);
@@ -70,7 +70,7 @@ bool cave_has_flag_bold(floor_type *floor_ptr, POSITION y, POSITION x, FloorFeat
 /*
  * Determine if a "legal" grid is within "los" of the player
  */
-bool player_has_los_bold(player_type *player_ptr, POSITION y, POSITION x)
+bool player_has_los_bold(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     return ((player_ptr->current_floor_ptr->grid_array[y][x].info & CAVE_VIEW) != 0) || player_ptr->phase_out;
 }
@@ -78,7 +78,7 @@ bool player_has_los_bold(player_type *player_ptr, POSITION y, POSITION x)
 /*
  * Determine if player is on this grid
  */
-bool player_bold(player_type *player_ptr, POSITION y, POSITION x) { return (y == player_ptr->y) && (x == player_ptr->x); }
+bool player_bold(PlayerType *player_ptr, POSITION y, POSITION x) { return (y == player_ptr->y) && (x == player_ptr->x); }
 
 /*
  * Does the grid stop disintegration?
index 97ede15..649c748 100644 (file)
@@ -4,16 +4,16 @@
 
 struct floor_type;
 struct grid_type;
-struct player_type;
+class PlayerType;
 enum class FloorFeatureType;
 bool in_bounds(floor_type *floor_ptr, POSITION y, POSITION x);
 bool in_bounds2(floor_type *floor_ptr, POSITION y, POSITION x);
 bool in_bounds2u(floor_type *floor_ptr, POSITION y, POSITION x);
-bool is_cave_empty_bold(player_type *player_ptr, POSITION x, POSITION y);
-bool is_cave_empty_bold2(player_type *player_ptr, POSITION x, POSITION y);
+bool is_cave_empty_bold(PlayerType *player_ptr, POSITION x, POSITION y);
+bool is_cave_empty_bold2(PlayerType *player_ptr, POSITION x, POSITION y);
 bool cave_has_flag_bold(floor_type *floor_ptr, POSITION y, POSITION x, FloorFeatureType f_idx);
-bool player_has_los_bold(player_type *player_ptr, POSITION y, POSITION x);
-bool player_bold(player_type *player_ptr, POSITION y, POSITION x);
+bool player_has_los_bold(PlayerType *player_ptr, POSITION y, POSITION x);
+bool player_bold(PlayerType *player_ptr, POSITION y, POSITION x);
 bool cave_stop_disintegration(floor_type *floor_ptr, POSITION y, POSITION x);
 bool cave_los_bold(floor_type *floor_ptr, POSITION y, POSITION x);
 bool feat_supports_los(FEAT_IDX f_idx);
index 9c90460..17e5d12 100644 (file)
@@ -74,7 +74,7 @@ static void drop_here(floor_type *floor_ptr, object_type *j_ptr, POSITION y, POS
     g_ptr->o_idx_list.add(floor_ptr, o_idx);
 }
 
-static void generate_artifact(player_type *player_ptr, qtwg_type *qtwg_ptr, const ARTIFACT_IDX artifact_index)
+static void generate_artifact(PlayerType *player_ptr, qtwg_type *qtwg_ptr, const ARTIFACT_IDX artifact_index)
 {
     if (artifact_index == 0)
         return;
@@ -91,7 +91,7 @@ static void generate_artifact(player_type *player_ptr, qtwg_type *qtwg_ptr, cons
     drop_here(player_ptr->current_floor_ptr, q_ptr, *qtwg_ptr->y, *qtwg_ptr->x);
 }
 
-static void parse_qtw_D(player_type *player_ptr, qtwg_type *qtwg_ptr, char *s)
+static void parse_qtw_D(PlayerType *player_ptr, qtwg_type *qtwg_ptr, char *s)
 {
     *qtwg_ptr->x = qtwg_ptr->xmin;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -311,7 +311,7 @@ static int parse_qtw_Q(qtwg_type *qtwg_ptr, char **zz)
     return PARSE_ERROR_GENERIC;
 }
 
-static bool parse_qtw_P(player_type *player_ptr, qtwg_type *qtwg_ptr, char **zz)
+static bool parse_qtw_P(PlayerType *player_ptr, qtwg_type *qtwg_ptr, char **zz)
 {
     if (qtwg_ptr->buf[0] != 'P')
         return false;
@@ -393,7 +393,7 @@ static bool parse_qtw_M(qtwg_type *qtwg_ptr, char **zz)
  * @return エラーコード
  * @todo クエスト情報のみを読み込む手段と実際にフロアデータまで読み込む処理は分離したい
  */
-parse_error_type generate_fixed_map_floor(player_type *player_ptr, qtwg_type *qtwg_ptr, process_dungeon_file_pf parse_fixed_map)
+parse_error_type generate_fixed_map_floor(PlayerType *player_ptr, qtwg_type *qtwg_ptr, process_dungeon_file_pf parse_fixed_map)
 {
     char *zz[33];
     if (!qtwg_ptr->buf[0])
index 2bbb888..b6cc3c5 100644 (file)
@@ -14,8 +14,8 @@ typedef struct qtwg_type {
     int *x;
 } qtwg_type;
 
-struct player_type;
-typedef parse_error_type (*process_dungeon_file_pf)(player_type *, concptr, int, int, int, int);
+class PlayerType;
+typedef parse_error_type (*process_dungeon_file_pf)(PlayerType *, concptr, int, int, int, int);
 
 qtwg_type *initialize_quest_generator_type(qtwg_type *qg_ptr, char *buf, int ymin, int xmin, int ymax, int xmax, int *y, int *x);
-parse_error_type generate_fixed_map_floor(player_type *player_ptr, qtwg_type *qg_ptr, process_dungeon_file_pf parse_fixed_map);
+parse_error_type generate_fixed_map_floor(PlayerType *player_ptr, qtwg_type *qg_ptr, process_dungeon_file_pf parse_fixed_map);
index d498837..958f358 100644 (file)
@@ -49,7 +49,7 @@
 /*!
  * @brief 階段移動先のフロアが生成できない時に簡単な行き止まりマップを作成する / Builds the dead end
  */
-static void build_dead_end(player_type *player_ptr)
+static void build_dead_end(PlayerType *player_ptr)
 {
     clear_cave(player_ptr);
     player_ptr->x = player_ptr->y = 0;
@@ -66,7 +66,7 @@ static void build_dead_end(player_type *player_ptr)
     wipe_generate_random_floor_flags(player_ptr->current_floor_ptr);
 }
 
-static MONSTER_IDX decide_pet_index(player_type *player_ptr, const int current_monster, POSITION *cy, POSITION *cx)
+static MONSTER_IDX decide_pet_index(PlayerType *player_ptr, const int current_monster, POSITION *cy, POSITION *cx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (current_monster == 0) {
@@ -96,7 +96,7 @@ static MONSTER_IDX decide_pet_index(player_type *player_ptr, const int current_m
     return (d == 6) ? 0 : m_pop(floor_ptr);
 }
 
-static void set_pet_params(player_type *player_ptr, monster_race **r_ptr, const int current_monster, MONSTER_IDX m_idx, const POSITION cy, const POSITION cx)
+static void set_pet_params(PlayerType *player_ptr, monster_race **r_ptr, const int current_monster, MONSTER_IDX m_idx, const POSITION cy, const POSITION cx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     player_ptr->current_floor_ptr->grid_array[cy][cx].m_idx = m_idx;
@@ -119,7 +119,7 @@ static void set_pet_params(player_type *player_ptr, monster_race **r_ptr, const
  * @brief 移動先のフロアに伴ったペットを配置する / Place preserved pet monsters on new floor
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void place_pet(player_type *player_ptr)
+static void place_pet(PlayerType *player_ptr)
 {
     int max_num = player_ptr->wild_mode ? 1 : MAX_PARTY_MON;
     for (int current_monster = 0; current_monster < max_num; current_monster++) {
@@ -186,7 +186,7 @@ static void update_unique_artifact(floor_type *floor_ptr, int16_t cur_floor_id)
     }
 }
 
-static void check_visited_floor(player_type *player_ptr, saved_floor_type *sf_ptr, bool *loaded)
+static void check_visited_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr, bool *loaded)
 {
     if ((sf_ptr->last_visit == 0) || !load_floor(player_ptr, sf_ptr, 0))
         return;
@@ -205,7 +205,7 @@ static void check_visited_floor(player_type *player_ptr, saved_floor_type *sf_pt
     g_ptr->special = 0;
 }
 
-static void update_floor_id(player_type *player_ptr, saved_floor_type *sf_ptr)
+static void update_floor_id(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     if (player_ptr->floor_id == 0) {
         if (player_ptr->change_floor_mode & CFM_UP)
@@ -228,7 +228,7 @@ static void update_floor_id(player_type *player_ptr, saved_floor_type *sf_ptr)
         sf_ptr->upper_floor_id = player_ptr->floor_id;
 }
 
-static void reset_unique_by_floor_change(player_type *player_ptr)
+static void reset_unique_by_floor_change(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (MONSTER_IDX i = 1; i < floor_ptr->m_max; i++) {
@@ -256,7 +256,7 @@ static void reset_unique_by_floor_change(player_type *player_ptr)
     }
 }
 
-static void new_floor_allocation(player_type *player_ptr, saved_floor_type *sf_ptr)
+static void new_floor_allocation(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     GAME_TURN tmp_last_visit = sf_ptr->last_visit;
     int alloc_chance = d_info[player_ptr->dungeon_idx].max_m_alloc_chance;
@@ -285,7 +285,7 @@ static void new_floor_allocation(player_type *player_ptr, saved_floor_type *sf_p
         (void)alloc_monster(player_ptr, 0, 0, summon_specific);
 }
 
-static void check_dead_end(player_type *player_ptr, saved_floor_type *sf_ptr)
+static void check_dead_end(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     if (sf_ptr->last_visit == 0) {
         generate_floor(player_ptr);
@@ -300,7 +300,7 @@ static void check_dead_end(player_type *player_ptr, saved_floor_type *sf_ptr)
         sf_ptr->lower_floor_id = 0;
 }
 
-static void update_new_floor_feature(player_type *player_ptr, saved_floor_type *sf_ptr, const bool loaded)
+static void update_new_floor_feature(PlayerType *player_ptr, saved_floor_type *sf_ptr, const bool loaded)
 {
     if (loaded) {
         new_floor_allocation(player_ptr, sf_ptr);
@@ -323,7 +323,7 @@ static void update_new_floor_feature(player_type *player_ptr, saved_floor_type *
     g_ptr->special = player_ptr->floor_id;
 }
 
-static void cut_off_the_upstair(player_type *player_ptr)
+static void cut_off_the_upstair(PlayerType *player_ptr)
 {
     if (player_ptr->change_floor_mode & CFM_RAND_PLACE) {
         (void)new_player_spot(player_ptr);
@@ -339,7 +339,7 @@ static void cut_off_the_upstair(player_type *player_ptr)
         msg_print(_("ゴトゴトと何か音がした。", "You hear some noises."));
 }
 
-static void update_floor(player_type *player_ptr)
+static void update_floor(PlayerType *player_ptr)
 {
     if (!(player_ptr->change_floor_mode & CFM_SAVE_FLOORS) && !(player_ptr->change_floor_mode & CFM_FIRST_FLOOR)) {
         generate_floor(player_ptr);
@@ -368,7 +368,7 @@ static void update_floor(player_type *player_ptr)
  * restored from the temporary file.  If the floor is new one, new floor\n
  * will be generated.\n
  */
-void change_floor(player_type *player_ptr)
+void change_floor(PlayerType *player_ptr)
 {
     w_ptr->character_dungeon = false;
     player_ptr->dtrap = false;
index 206285e..21ea1a6 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void change_floor(player_type *player_ptr);
+class PlayerType;
+void change_floor(PlayerType *player_ptr);
index 583e743..68fcb4f 100644 (file)
@@ -43,7 +43,7 @@
 #include "view/display-messages.h"
 #include "world/world.h"
 
-void day_break(player_type *player_ptr)
+void day_break(PlayerType *player_ptr)
 {
     msg_print(_("夜が明けた。", "The sun has risen."));
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -67,7 +67,7 @@ void day_break(player_type *player_ptr)
         set_superstealth(player_ptr, false);
 }
 
-void night_falls(player_type *player_ptr)
+void night_falls(PlayerType *player_ptr)
 {
     msg_print(_("日が沈んだ。", "The sun has fallen."));
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -108,7 +108,7 @@ static int rating_boost(int delta) { return delta * delta + 50 * delta; }
  * / Examine all monsters and unidentified objects, and get the feeling of current dungeon floor
  * @return 算出されたダンジョンの雰囲気ランク
  */
-static byte get_dungeon_feeling(player_type *player_ptr)
+static byte get_dungeon_feeling(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!floor_ptr->dun_level)
@@ -228,7 +228,7 @@ static byte get_dungeon_feeling(player_type *player_ptr)
  * @brief ダンジョンの雰囲気を更新し、変化があった場合メッセージを表示する
  * / Update dungeon feeling, and announce it if changed
  */
-void update_dungeon_feeling(player_type *player_ptr)
+void update_dungeon_feeling(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!floor_ptr->dun_level)
@@ -262,7 +262,7 @@ void update_dungeon_feeling(player_type *player_ptr)
 /*
  * Glow deep lava and building entrances in the floor
  */
-void glow_deep_lava_and_bldg(player_type *player_ptr)
+void glow_deep_lava_and_bldg(PlayerType *player_ptr)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         return;
index 141902a..d056843 100644 (file)
@@ -1,10 +1,10 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct floor_type;
-void day_break(player_type *player_ptr);
-void night_falls(player_type *player_ptr);
-void update_dungeon_feeling(player_type *player_ptr);
-void glow_deep_lava_and_bldg(player_type *player_ptr);
+void day_break(PlayerType *player_ptr);
+void night_falls(PlayerType *player_ptr);
+void update_dungeon_feeling(PlayerType *player_ptr);
+void glow_deep_lava_and_bldg(PlayerType *player_ptr);
 void forget_lite(floor_type *floor_ptr);
 void forget_view(floor_type *floor_ptr);
index 04fcce7..dd519b9 100644 (file)
@@ -59,7 +59,7 @@
  * @brief 闘技場用のアリーナ地形を作成する / Builds the on_defeat_arena_monster after it is entered -KMW-
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void build_arena(player_type *player_ptr, POSITION *start_y, POSITION *start_x)
+static void build_arena(PlayerType *player_ptr, POSITION *start_y, POSITION *start_x)
 {
     POSITION yval = SCREEN_HGT / 2;
     POSITION xval = SCREEN_WID / 2;
@@ -110,7 +110,7 @@ static void build_arena(player_type *player_ptr, POSITION *start_y, POSITION *st
 /*!
  * @brief 挑戦時闘技場への入場処理 / Town logic flow for generation of on_defeat_arena_monster -KMW-
  */
-static void generate_challenge_arena(player_type *player_ptr)
+static void generate_challenge_arena(PlayerType *player_ptr)
 {
     POSITION qy = 0;
     POSITION qx = 0;
@@ -143,7 +143,7 @@ static void generate_challenge_arena(player_type *player_ptr)
  * @brief モンスター闘技場のフロア生成 / Builds the on_defeat_arena_monster after it is entered -KMW-
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void build_battle(player_type *player_ptr, POSITION *y, POSITION *x)
+static void build_battle(PlayerType *player_ptr, POSITION *y, POSITION *x)
 {
     POSITION yval = SCREEN_HGT / 2;
     POSITION xval = SCREEN_WID / 2;
@@ -202,7 +202,7 @@ static void build_battle(player_type *player_ptr, POSITION *y, POSITION *x)
 /*!
  * @brief モンスター闘技場への導入処理 / Town logic flow for generation of on_defeat_arena_monster -KMW-
  */
-static void generate_gambling_arena(player_type *player_ptr)
+static void generate_gambling_arena(PlayerType *player_ptr)
 {
     POSITION y, x;
     POSITION qy = 0;
@@ -239,7 +239,7 @@ static void generate_gambling_arena(player_type *player_ptr)
  * @brief 固定マップクエストのフロア生成 / Generate a quest level
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void generate_fixed_floor(player_type *player_ptr)
+static void generate_fixed_floor(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (POSITION y = 0; y < floor_ptr->height; y++)
@@ -264,7 +264,7 @@ static void generate_fixed_floor(player_type *player_ptr)
  * @param concptr
  * @return フロアの生成に成功したらTRUE
  */
-static bool level_gen(player_type *player_ptr, concptr *why)
+static bool level_gen(PlayerType *player_ptr, concptr *why)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     DUNGEON_IDX d_idx = floor_ptr->dungeon_idx;
@@ -328,7 +328,7 @@ void wipe_generate_random_floor_flags(floor_type *floor_ptr)
  * @brief フロアの全情報を初期化する / Clear and empty floor.
  * @parama player_ptr プレイヤーへの参照ポインタ
  */
-void clear_cave(player_type *player_ptr)
+void clear_cave(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     std::fill_n(floor_ptr->o_list.begin(), floor_ptr->o_max, object_type{});
@@ -453,7 +453,7 @@ static bool floor_is_connected(const floor_type *const floor_ptr, const IsWallFu
  * @parama player_ptr プレイヤーへの参照ポインタ
  * @note Hack -- regenerate any "overflow" levels
  */
-void generate_floor(player_type *player_ptr)
+void generate_floor(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     floor_ptr->dungeon_idx = player_ptr->dungeon_idx;
index 2e1e9de..b7e722e 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 void wipe_generate_random_floor_flags(floor_type *floor_ptr);
-void clear_cave(player_type *player_ptr);
-void generate_floor(player_type *player_ptr);
+void clear_cave(PlayerType *player_ptr);
+void generate_floor(PlayerType *player_ptr);
index 972b1ef..3d9517f 100644 (file)
@@ -42,7 +42,7 @@
 #include "view/display-messages.h"
 #include "world/world.h"
 
-static void check_riding_preservation(player_type *player_ptr)
+static void check_riding_preservation(PlayerType *player_ptr)
 {
     if (!player_ptr->riding)
         return;
@@ -58,7 +58,7 @@ static void check_riding_preservation(player_type *player_ptr)
     }
 }
 
-static bool check_pet_preservation_conditions(player_type *player_ptr, monster_type *m_ptr)
+static bool check_pet_preservation_conditions(PlayerType *player_ptr, monster_type *m_ptr)
 {
     if (reinit_wilderness)
         return false;
@@ -79,7 +79,7 @@ static bool check_pet_preservation_conditions(player_type *player_ptr, monster_t
     return false;
 }
 
-static void sweep_preserving_pet(player_type *player_ptr)
+static void sweep_preserving_pet(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode || player_ptr->current_floor_ptr->inside_arena || player_ptr->phase_out)
         return;
@@ -95,7 +95,7 @@ static void sweep_preserving_pet(player_type *player_ptr)
     }
 }
 
-static void record_pet_diary(player_type *player_ptr)
+static void record_pet_diary(PlayerType *player_ptr)
 {
     if (!record_named_pet)
         return;
@@ -115,7 +115,7 @@ static void record_pet_diary(player_type *player_ptr)
  * @brief フロア移動時のペット保存処理 / Preserve_pets
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void preserve_pet(player_type *player_ptr)
+static void preserve_pet(PlayerType *player_ptr)
 {
     for (MONSTER_IDX party_monster_num = 0; party_monster_num < MAX_PARTY_MON; party_monster_num++)
         party_mon[party_monster_num].r_idx = 0;
@@ -142,7 +142,7 @@ static void preserve_pet(player_type *player_ptr)
  * @brief 新フロアに移動元フロアに繋がる階段を配置する / Virtually teleport onto the stairs that is connecting between two floors.
  * @param sf_ptr 移動元の保存フロア構造体参照ポインタ
  */
-static void locate_connected_stairs(player_type *player_ptr, floor_type *floor_ptr, saved_floor_type *sf_ptr, BIT_FLAGS floor_mode)
+static void locate_connected_stairs(PlayerType *player_ptr, floor_type *floor_ptr, saved_floor_type *sf_ptr, BIT_FLAGS floor_mode)
 {
     POSITION sx = 0;
     POSITION sy = 0;
@@ -206,7 +206,7 @@ static void locate_connected_stairs(player_type *player_ptr, floor_type *floor_p
 /*!
  * @brief フロア移動時、プレイヤーの移動先モンスターが既にいた場合ランダムな近隣に移動させる / When a monster is at a place where player will return,
  */
-static void get_out_monster(player_type *player_ptr)
+static void get_out_monster(PlayerType *player_ptr)
 {
     int tries = 0;
     POSITION dis = 1;
@@ -245,7 +245,7 @@ static void get_out_monster(player_type *player_ptr)
  * @brief クエスト・フロア内のモンスター・インベントリ情報を保存する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void preserve_info(player_type *player_ptr)
+static void preserve_info(PlayerType *player_ptr)
 {
     MONRACE_IDX quest_r_idx = 0;
     for (DUNGEON_IDX i = 0; i < max_q_idx; i++) {
@@ -279,7 +279,7 @@ static void preserve_info(player_type *player_ptr)
     }
 }
 
-static void set_grid_by_leaving_floor(player_type *player_ptr, grid_type **g_ptr)
+static void set_grid_by_leaving_floor(PlayerType *player_ptr, grid_type **g_ptr)
 {
     if ((player_ptr->change_floor_mode & CFM_SAVE_FLOORS) == 0)
         return;
@@ -293,7 +293,7 @@ static void set_grid_by_leaving_floor(player_type *player_ptr, grid_type **g_ptr
         prepare_change_floor_mode(player_ptr, CFM_SHAFT);
 }
 
-static void jump_floors(player_type *player_ptr)
+static void jump_floors(PlayerType *player_ptr)
 {
     if (none_bits(player_ptr->change_floor_mode, CFM_DOWN | CFM_UP)) {
         return;
@@ -323,7 +323,7 @@ static void jump_floors(player_type *player_ptr)
     player_ptr->current_floor_ptr->dun_level += move_num;
 }
 
-static void exit_to_wilderness(player_type *player_ptr)
+static void exit_to_wilderness(PlayerType *player_ptr)
 {
     if (is_in_dungeon(player_ptr) || (player_ptr->dungeon_idx == 0))
         return;
@@ -340,7 +340,7 @@ static void exit_to_wilderness(player_type *player_ptr)
     player_ptr->change_floor_mode &= ~CFM_SAVE_FLOORS; // TODO
 }
 
-static void kill_saved_floors(player_type *player_ptr, saved_floor_type *sf_ptr)
+static void kill_saved_floors(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     if (!(player_ptr->change_floor_mode & CFM_SAVE_FLOORS)) {
         for (DUNGEON_IDX i = 0; i < MAX_SAVED_FLOORS; i++)
@@ -354,7 +354,7 @@ static void kill_saved_floors(player_type *player_ptr, saved_floor_type *sf_ptr)
         kill_saved_floor(player_ptr, sf_ptr);
 }
 
-static void refresh_new_floor_id(player_type *player_ptr, grid_type *g_ptr)
+static void refresh_new_floor_id(PlayerType *player_ptr, grid_type *g_ptr)
 {
     if (new_floor_id != 0)
         return;
@@ -364,7 +364,7 @@ static void refresh_new_floor_id(player_type *player_ptr, grid_type *g_ptr)
         g_ptr->special = new_floor_id;
 }
 
-static void update_upper_lower_or_floor_id(player_type *player_ptr, saved_floor_type *sf_ptr)
+static void update_upper_lower_or_floor_id(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     if ((player_ptr->change_floor_mode & CFM_RAND_CONNECT) == 0)
         return;
@@ -375,7 +375,7 @@ static void update_upper_lower_or_floor_id(player_type *player_ptr, saved_floor_
         sf_ptr->lower_floor_id = new_floor_id;
 }
 
-static void exe_leave_floor(player_type *player_ptr, saved_floor_type *sf_ptr)
+static void exe_leave_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     grid_type *g_ptr = nullptr;
     set_grid_by_leaving_floor(player_ptr, &g_ptr);
@@ -407,7 +407,7 @@ static void exe_leave_floor(player_type *player_ptr, saved_floor_type *sf_ptr)
  * / Maintain quest monsters, mark next floor_id at stairs, save current floor, and prepare to enter next floor.
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void leave_floor(player_type *player_ptr)
+void leave_floor(PlayerType *player_ptr)
 {
     preserve_pet(player_ptr);
     remove_all_mirrors(player_ptr, false);
@@ -427,7 +427,7 @@ void leave_floor(player_type *player_ptr)
  * @brief 任意のダンジョン及び階層に飛ぶ
  * Go to any level
  */
-void jump_floor(player_type *player_ptr, DUNGEON_IDX dun_idx, DEPTH depth)
+void jump_floor(PlayerType *player_ptr, DUNGEON_IDX dun_idx, DEPTH depth)
 {
     player_ptr->dungeon_idx = dun_idx;
     player_ptr->current_floor_ptr->dun_level = depth;
index d90b491..16a112c 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 #include "system/angband.h"
 
-struct player_type;
-void leave_floor(player_type *player_ptr);
-void jump_floor(player_type *player_ptr, DUNGEON_IDX dun_idx, DEPTH depth);
+class PlayerType;
+void leave_floor(PlayerType *player_ptr);
+void jump_floor(PlayerType *player_ptr, DUNGEON_IDX dun_idx, DEPTH depth);
index 672f621..7157a61 100644 (file)
@@ -6,4 +6,4 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param mode 追加したい所持フラグ
  */
-void prepare_change_floor_mode(player_type *player_ptr, BIT_FLAGS mode) { player_ptr->change_floor_mode |= mode; }
+void prepare_change_floor_mode(PlayerType *player_ptr, BIT_FLAGS mode) { player_ptr->change_floor_mode |= mode; }
index b3a9388..ff27769 100644 (file)
@@ -18,5 +18,5 @@ enum cfm_type {
        CFM_FIRST_FLOOR = 0x0200, /*!< ダンジョンに入った最初のフロアである / Create exit from the dungeon */
 };
 
-struct player_type;
-void prepare_change_floor_mode(player_type *player_ptr, BIT_FLAGS mode);
+class PlayerType;
+void prepare_change_floor_mode(PlayerType *player_ptr, BIT_FLAGS mode);
index c1df82b..cce6eb1 100644 (file)
@@ -70,7 +70,7 @@ static errr get_obj_num_prep(void)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param o_ptr デバッグ出力するオブジェクトの構造体参照ポインタ
  */
-static void object_mention(player_type *player_ptr, object_type *o_ptr)
+static void object_mention(PlayerType *player_ptr, object_type *o_ptr)
 {
     object_aware(player_ptr, o_ptr);
     object_known(o_ptr);
@@ -118,7 +118,7 @@ static void set_ammo_quantity(object_type *j_ptr)
  * @param rq_mon_level ランダムクエスト討伐対象のレベル。ランダムクエスト以外の生成であれば無効値
  * @return アイテムの生成成功可否
  */
-bool make_object(player_type *player_ptr, object_type *j_ptr, BIT_FLAGS mode, std::optional<int> rq_mon_level)
+bool make_object(PlayerType *player_ptr, object_type *j_ptr, BIT_FLAGS mode, std::optional<int> rq_mon_level)
 {
     auto *floor_ptr = player_ptr->current_floor_ptr;
     auto prob = any_bits(mode, AM_GOOD) ? 10 : 1000;
@@ -163,7 +163,7 @@ bool make_object(player_type *player_ptr, object_type *j_ptr, BIT_FLAGS mode, st
  * @details
  * The location must be a legal, clean, floor grid.
  */
-bool make_gold(player_type *player_ptr, object_type *j_ptr)
+bool make_gold(PlayerType *player_ptr, object_type *j_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     int i = ((randint1(floor_ptr->object_level + 2) + 2) / 2) - 1;
@@ -190,7 +190,7 @@ bool make_gold(player_type *player_ptr, object_type *j_ptr)
  * @param y 削除したフロアマスのY座標
  * @param x 削除したフロアマスのX座標
  */
-void delete_all_items_from_floor(player_type *player_ptr, POSITION y, POSITION x)
+void delete_all_items_from_floor(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -216,7 +216,7 @@ void delete_all_items_from_floor(player_type *player_ptr, POSITION y, POSITION x
  * @param item 増やしたいアイテムの所持スロット
  * @param num 増やしたいアイテムの数
  */
-void floor_item_increase(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num)
+void floor_item_increase(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
 
@@ -239,7 +239,7 @@ void floor_item_increase(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBE
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param item 消去したいアイテムの所持スロット
  */
-void floor_item_optimize(player_type *player_ptr, INVENTORY_IDX item)
+void floor_item_optimize(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     object_type *o_ptr = &player_ptr->current_floor_ptr->o_list[item];
     if (!o_ptr->k_idx)
@@ -260,7 +260,7 @@ void floor_item_optimize(player_type *player_ptr, INVENTORY_IDX item)
  * @details
  * Handle "stacks" of objects correctly.
  */
-void delete_object_idx(player_type *player_ptr, OBJECT_IDX o_idx)
+void delete_object_idx(PlayerType *player_ptr, OBJECT_IDX o_idx)
 {
     object_type *j_ptr;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -330,7 +330,7 @@ ObjectIndexList &get_o_idx_list_contains(floor_type *floor_ptr, OBJECT_IDX o_idx
  * the object can combine, stack, or be placed.  Artifacts will try very\n
  * hard to be placed, including "teleporting" to a useful grid if needed.\n
  */
-OBJECT_IDX drop_near(player_type *player_ptr, object_type *j_ptr, PERCENTAGE chance, POSITION y, POSITION x)
+OBJECT_IDX drop_near(PlayerType *player_ptr, object_type *j_ptr, PERCENTAGE chance, POSITION y, POSITION x)
 {
     int i, k, d, s;
     POSITION dy, dx;
@@ -569,7 +569,7 @@ void floor_item_charges(floor_type *floor_ptr, INVENTORY_IDX item)
  * @param floo_ptr 現在フロアへの参照ポインタ
  * @param item メッセージの対象にしたいアイテム所持スロット
  */
-void floor_item_describe(player_type *player_ptr, INVENTORY_IDX item)
+void floor_item_describe(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     object_type *o_ptr = &player_ptr->current_floor_ptr->o_list[item];
     GAME_TEXT o_name[MAX_NLEN];
@@ -588,7 +588,7 @@ void floor_item_describe(player_type *player_ptr, INVENTORY_IDX item)
 /*
  * Choose an item and get auto-picker entry from it.
  */
-object_type *choose_object(player_type *player_ptr, OBJECT_IDX *idx, concptr q, concptr s, BIT_FLAGS option, const ItemTester& item_tester)
+object_type *choose_object(PlayerType *player_ptr, OBJECT_IDX *idx, concptr q, concptr s, BIT_FLAGS option, const ItemTester& item_tester)
 {
     OBJECT_IDX item;
 
index 5aca507..70d02f0 100644 (file)
@@ -8,17 +8,17 @@ class ObjectIndexList;
 
 struct floor_type;
 struct object_type;
-struct player_type;
+class PlayerType;
 class ItemTester;
-bool make_object(player_type *player_ptr, object_type *j_ptr, BIT_FLAGS mode, std::optional<int> rq_mon_level = std::nullopt);
-bool make_gold(player_type *player_ptr, object_type *j_ptr);
-void delete_all_items_from_floor(player_type *player_ptr, POSITION y, POSITION x);
-void floor_item_increase(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num);
-void floor_item_optimize(player_type *player_ptr, INVENTORY_IDX item);
-void delete_object_idx(player_type *player_ptr, OBJECT_IDX o_idx);
+bool make_object(PlayerType *player_ptr, object_type *j_ptr, BIT_FLAGS mode, std::optional<int> rq_mon_level = std::nullopt);
+bool make_gold(PlayerType *player_ptr, object_type *j_ptr);
+void delete_all_items_from_floor(PlayerType *player_ptr, POSITION y, POSITION x);
+void floor_item_increase(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num);
+void floor_item_optimize(PlayerType *player_ptr, INVENTORY_IDX item);
+void delete_object_idx(PlayerType *player_ptr, OBJECT_IDX o_idx);
 void excise_object_idx(floor_type *floor_ptr, OBJECT_IDX o_idx);
 ObjectIndexList &get_o_idx_list_contains(floor_type *floor_ptr, OBJECT_IDX o_idx);
-OBJECT_IDX drop_near(player_type *player_ptr, object_type *o_ptr, PERCENTAGE chance, POSITION y, POSITION x);
+OBJECT_IDX drop_near(PlayerType *player_ptr, object_type *o_ptr, PERCENTAGE chance, POSITION y, POSITION x);
 void floor_item_charges(floor_type *player_ptr, INVENTORY_IDX item);
-void floor_item_describe(player_type *player_ptr, INVENTORY_IDX item);
-object_type *choose_object(player_type *player_ptr, OBJECT_IDX *idx, concptr q, concptr s, BIT_FLAGS option, const ItemTester& item_tester = AllMatchItemTester());
+void floor_item_describe(PlayerType *player_ptr, INVENTORY_IDX item);
+object_type *choose_object(PlayerType *player_ptr, OBJECT_IDX *idx, concptr q, concptr s, BIT_FLAGS option, const ItemTester& item_tester = AllMatchItemTester());
index 084b45b..bc0a1c2 100644 (file)
@@ -50,7 +50,7 @@ static void check_saved_tmp_files(const int fd, bool *force)
  * @param force テンポラリファイルが残っていた場合も警告なしで強制的に削除するフラグ
  * @details Make sure that old temporary files are not remaining as gurbages.
  */
-void init_saved_floors(player_type *player_ptr, bool force)
+void init_saved_floors(PlayerType *player_ptr, bool force)
 {
     char floor_savefile[sizeof(savefile) + 32];
     int fd = -1;
@@ -80,7 +80,7 @@ void init_saved_floors(player_type *player_ptr, bool force)
  * @details Should be called just before the game quit.
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void clear_saved_floor_files(player_type *player_ptr)
+void clear_saved_floor_files(PlayerType *player_ptr)
 {
     char floor_savefile[sizeof(savefile) + 32];
     for (int i = 0; i < MAX_SAVED_FLOORS; i++) {
@@ -119,7 +119,7 @@ saved_floor_type *get_sf_ptr(FLOOR_IDX floor_id)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param sf_ptr 保存フロアの参照ポインタ
  */
-void kill_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr)
+void kill_saved_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     char floor_savefile[sizeof(savefile) + 32];
     if (!sf_ptr || (sf_ptr->floor_id == 0))
@@ -138,7 +138,7 @@ void kill_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr)
     sf_ptr->floor_id = 0;
 }
 
-static FLOOR_IDX find_oldest_floor_idx(player_type *player_ptr)
+static FLOOR_IDX find_oldest_floor_idx(PlayerType *player_ptr)
 {
     FLOOR_IDX oldest_floor_idx = 0;
     uint32_t oldest_visit = 0xffffffffL;
@@ -162,7 +162,7 @@ static FLOOR_IDX find_oldest_floor_idx(player_type *player_ptr)
  * @details
  * If number of saved floors are already MAX_SAVED_FLOORS, kill the oldest one.
  */
-FLOOR_IDX get_new_floor_id(player_type *player_ptr)
+FLOOR_IDX get_new_floor_id(PlayerType *player_ptr)
 {
     saved_floor_type *sf_ptr = nullptr;
     FLOOR_IDX fl_idx;
@@ -199,7 +199,7 @@ FLOOR_IDX get_new_floor_id(player_type *player_ptr)
  * @details
  * To prevent multiple generation of unique monster who is the minion of player
  */
-void precalc_cur_num_of_pet(player_type *player_ptr)
+void precalc_cur_num_of_pet(PlayerType *player_ptr)
 {
     monster_type *m_ptr;
     int max_num = player_ptr->wild_mode ? 1 : MAX_PARTY_MON;
index 65e1a06..3df5223 100644 (file)
@@ -2,12 +2,12 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 struct saved_floor_type;
-void init_saved_floors(player_type *player_ptr, bool force);
-void clear_saved_floor_files(player_type *player_ptr);
+void init_saved_floors(PlayerType *player_ptr, bool force);
+void clear_saved_floor_files(PlayerType *player_ptr);
 saved_floor_type *get_sf_ptr(FLOOR_IDX floor_id);
-void kill_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr);
-FLOOR_IDX get_new_floor_id(player_type *player_ptr);
-void precalc_cur_num_of_pet(player_type *player_ptr);
+void kill_saved_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr);
+FLOOR_IDX get_new_floor_id(PlayerType *player_ptr);
+void precalc_cur_num_of_pet(PlayerType *player_ptr);
 extern FLOOR_IDX max_floor_id;
index c765f7a..c3336f3 100644 (file)
@@ -273,7 +273,7 @@ void add_river(floor_type *floor_ptr, dun_data_type *dd_ptr)
  * hidden gold types are currently unused.
  * </pre>
  */
-void build_streamer(player_type *player_ptr, FEAT_IDX feat, int chance)
+void build_streamer(PlayerType *player_ptr, FEAT_IDX feat, int chance)
 {
     int i;
     POSITION y, x, tx, ty;
@@ -413,7 +413,7 @@ void build_streamer(player_type *player_ptr, FEAT_IDX feat, int chance)
  * This happens in real world lava tubes.
  * </pre>
  */
-void place_trees(player_type *player_ptr, POSITION x, POSITION y)
+void place_trees(PlayerType *player_ptr, POSITION x, POSITION y)
 {
     int i, j;
     grid_type *g_ptr;
@@ -465,7 +465,7 @@ void place_trees(player_type *player_ptr, POSITION x, POSITION y)
  * @brief ダンジョンに*破壊*済み地形ランダムに施す /
  * Build a destroyed level
  */
-void destroy_level(player_type *player_ptr)
+void destroy_level(PlayerType *player_ptr)
 {
     msg_print_wizard(player_ptr, CHEAT_DUNGEON, _("階に*破壊*の痕跡を生成しました。", "Destroyed Level."));
 
index 42572fa..34f6769 100644 (file)
@@ -4,8 +4,8 @@
 
 struct dun_data_type;
 struct floor_type;
-struct player_type;
+class PlayerType;
 void add_river(floor_type *floor_ptr, dun_data_type *dd_ptr);
-void build_streamer(player_type *player_ptr, FEAT_IDX feat, int chance);
-void place_trees(player_type *player_ptr, POSITION x, POSITION y);
-void destroy_level(player_type *player_ptr);
+void build_streamer(PlayerType *player_ptr, FEAT_IDX feat, int chance);
+void place_trees(PlayerType *player_ptr, POSITION x, POSITION y);
+void destroy_level(PlayerType *player_ptr);
index ad1f24a..e4c0128 100644 (file)
@@ -48,7 +48,7 @@ static int scent_when = 0;
  * Whenever the age count loops, most of the scent trail is erased and
  * the age of the remainder is recalculated.
  */
-void update_smell(floor_type *floor_ptr, player_type *player_ptr)
+void update_smell(floor_type *floor_ptr, PlayerType *player_ptr)
 {
     /* Create a table that controls the spread of scent */
     const int scent_adjust[5][5] = {
@@ -149,7 +149,7 @@ void wipe_o_list(floor_type *floor_ptr)
  *
  * Currently the "m" parameter is unused.
  */
-void scatter(player_type *player_ptr, POSITION *yp, POSITION *xp, POSITION y, POSITION x, POSITION d, BIT_FLAGS mode)
+void scatter(PlayerType *player_ptr, POSITION *yp, POSITION *xp, POSITION y, POSITION x, POSITION d, BIT_FLAGS mode)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     POSITION nx, ny;
@@ -180,7 +180,7 @@ void scatter(player_type *player_ptr, POSITION *yp, POSITION *xp, POSITION y, PO
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return マップ名の文字列参照ポインタ
  */
-concptr map_name(player_type *player_ptr)
+concptr map_name(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (floor_ptr->inside_quest && quest_type::is_fixed(floor_ptr->inside_quest) && (quest[floor_ptr->inside_quest].flags & QUEST_FLAG_PRESET))
index 3b46925..a67c64f 100644 (file)
@@ -5,9 +5,9 @@
 struct floor_type;
 extern floor_type floor_info;
 
-struct player_type;
-void update_smell(floor_type *floor_ptr, player_type *player_ptr);
+class PlayerType;
+void update_smell(floor_type *floor_ptr, PlayerType *player_ptr);
 void forget_flow(floor_type *floor_ptr);
 void wipe_o_list(floor_type *floor_ptr);
-void scatter(player_type *player_ptr, POSITION *yp, POSITION *xp, POSITION y, POSITION x, POSITION d, BIT_FLAGS mode);
-concptr map_name(player_type *player_ptr);
+void scatter(PlayerType *player_ptr, POSITION *yp, POSITION *xp, POSITION y, POSITION x, POSITION d, BIT_FLAGS mode);
+concptr map_name(PlayerType *player_ptr);
index 13bbeac..0596427 100644 (file)
@@ -97,7 +97,7 @@ POSITION distance(POSITION y1, POSITION x1, POSITION y2, POSITION x2)
  * @param x 方角を確認したX座標
  * @return 方向ID
  */
-DIRECTION coords_to_dir(player_type *player_ptr, POSITION y, POSITION x)
+DIRECTION coords_to_dir(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     DIRECTION d[3][3] = { { 7, 4, 1 }, { 8, 5, 2 }, { 9, 6, 3 } };
     POSITION dy, dx;
@@ -145,7 +145,7 @@ DIRECTION coords_to_dir(player_type *player_ptr, POSITION y, POSITION x)
  * "glowing" grid.  This prevents the player from being able to "see" the\n
  * walls of illuminated rooms from a corridor outside the room.\n
  */
-bool player_can_see_bold(player_type *player_ptr, POSITION y, POSITION x)
+bool player_can_see_bold(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr;
 
@@ -238,7 +238,7 @@ void mmove2(POSITION *y, POSITION *x, POSITION y1, POSITION x1, POSITION y2, POS
  * @return 個々のモンスターがプレイヤーが見えたらTRUE
  * @todo is_seen() の関数マクロをバラそうとしたがインクルード関係のコンパイルエラーで失敗
  */
-bool is_seen(player_type *player_ptr, monster_type *m_ptr)
+bool is_seen(PlayerType *player_ptr, monster_type *m_ptr)
 {
     bool is_inside_view = !ignore_unview;
     is_inside_view |= player_ptr->phase_out;
index 40ec128..5551d71 100644 (file)
@@ -28,11 +28,11 @@ extern const POSITION cdd[8];
 extern const POSITION ddx_cdd[8];
 extern const POSITION ddy_cdd[8];
 
-struct player_type;
-DIRECTION coords_to_dir(player_type *player_ptr, POSITION y, POSITION x);
+class PlayerType;
+DIRECTION coords_to_dir(PlayerType *player_ptr, POSITION y, POSITION x);
 POSITION distance(POSITION y1, POSITION x1, POSITION y2, POSITION x2);
 void mmove2(POSITION *y, POSITION *x, POSITION y1, POSITION x1, POSITION y2, POSITION x2);
-bool player_can_see_bold(player_type *player_ptr, POSITION y, POSITION x);
+bool player_can_see_bold(PlayerType *player_ptr, POSITION y, POSITION x);
 
 struct monster_type;
-bool is_seen(player_type *player_ptr, monster_type *m_ptr);
+bool is_seen(PlayerType *player_ptr, monster_type *m_ptr);
index 72a2b0f..cf5a643 100644 (file)
@@ -46,7 +46,7 @@
  *\n
  * Use the "update_view()" function to determine player line-of-sight.\n
  */
-bool los(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2)
+bool los(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2)
 {
     POSITION dy = y2 - y1;
     POSITION dx = x2 - x1;
index 1757ded..cd5b537 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool los(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2);
+class PlayerType;
+bool los(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2);
index dfd3956..df6e9b0 100644 (file)
@@ -54,7 +54,7 @@ static int next_to_walls(floor_type *floor_ptr, POSITION y, POSITION x)
  * @param walls 最低減隣接させたい外壁の数
  * @return 階段を生成して問題がないならばTRUEを返す。
  */
-static bool alloc_stairs_aux(player_type *player_ptr, POSITION y, POSITION x, int walls)
+static bool alloc_stairs_aux(PlayerType *player_ptr, POSITION y, POSITION x, int walls)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
@@ -72,7 +72,7 @@ static bool alloc_stairs_aux(player_type *player_ptr, POSITION y, POSITION x, in
  * @param walls 最低減隣接させたい外壁の数
  * @return 規定数通りに生成に成功したらTRUEを返す。
  */
-bool alloc_stairs(player_type *player_ptr, FEAT_IDX feat, int num, int walls)
+bool alloc_stairs(PlayerType *player_ptr, FEAT_IDX feat, int num, int walls)
 {
     int shaft_num = 0;
     feature_type *f_ptr = &f_info[feat];
@@ -161,7 +161,7 @@ static void place_rubble(floor_type *floor_ptr, POSITION y, POSITION x)
  * @param num 配置したい数
  * @return 規定数通りに生成に成功したらTRUEを返す。
  */
-void alloc_object(player_type *player_ptr, dap_type set, EFFECT_ID typ, int num)
+void alloc_object(PlayerType *player_ptr, dap_type set, EFFECT_ID typ, int num)
 {
     POSITION y = 0;
     POSITION x = 0;
index 0e6b544..6a96c05 100644 (file)
@@ -4,6 +4,6 @@
 #include "effect/attribute-types.h"
 
 enum dap_type : int;
-struct player_type;
-bool alloc_stairs(player_type *player_ptr, FEAT_IDX feat, int num, int walls);
-void alloc_object(player_type *player_ptr, dap_type set, EFFECT_ID typ, int num);
+class PlayerType;
+bool alloc_stairs(PlayerType *player_ptr, FEAT_IDX feat, int num, int walls);
+void alloc_object(PlayerType *player_ptr, dap_type set, EFFECT_ID typ, int num);
index 09f4067..d8949ea 100644 (file)
@@ -29,7 +29,7 @@
  *             mode & 0x02 -- Marked items only
  *             mode & 0x04 -- Stop after first
  */
-ITEM_NUMBER scan_floor_items(player_type *player_ptr, OBJECT_IDX *items, POSITION y, POSITION x, BIT_FLAGS mode, const ItemTester &item_tester)
+ITEM_NUMBER scan_floor_items(PlayerType *player_ptr, OBJECT_IDX *items, POSITION y, POSITION x, BIT_FLAGS mode, const ItemTester &item_tester)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!in_bounds(floor_ptr, y, x))
@@ -91,7 +91,7 @@ static void prepare_label_string_floor(floor_type *floor_ptr, char *label, FLOOR
  * @return 選択したアイテムの添え字
  * @details
  */
-COMMAND_CODE show_floor_items(player_type *player_ptr, int target_item, POSITION y, POSITION x, TERM_LEN *min_width, const ItemTester &item_tester)
+COMMAND_CODE show_floor_items(PlayerType *player_ptr, int target_item, POSITION y, POSITION x, TERM_LEN *min_width, const ItemTester &item_tester)
 {
     COMMAND_CODE i, m;
     int j, k, l;
index f72bd7c..15d6091 100644 (file)
@@ -12,7 +12,7 @@ enum scan_floor_mode {
     SCAN_FLOOR_AT_MOST_ONE = 1U << 2, /*!< 高々1つのアイテムしか取得しない */
 };
 
-struct player_type;
+class PlayerType;
 class ItemTester;
-ITEM_NUMBER scan_floor_items(player_type *player_ptr, OBJECT_IDX *items, POSITION y, POSITION x, BIT_FLAGS mode, const ItemTester& item_tester);
-COMMAND_CODE show_floor_items(player_type *player_ptr, int target_item, POSITION y, POSITION x, TERM_LEN *min_width, const ItemTester& item_tester);
+ITEM_NUMBER scan_floor_items(PlayerType *player_ptr, OBJECT_IDX *items, POSITION y, POSITION x, BIT_FLAGS mode, const ItemTester& item_tester);
+COMMAND_CODE show_floor_items(PlayerType *player_ptr, int target_item, POSITION y, POSITION x, TERM_LEN *min_width, const ItemTester& item_tester);
index 0f7e6fa..e261993 100644 (file)
@@ -34,7 +34,7 @@
  * @brief パターン終点到達時のテレポート処理を行う
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void pattern_teleport(player_type *player_ptr)
+void pattern_teleport(PlayerType *player_ptr)
 {
     DEPTH min_level = 0;
     DEPTH max_level = 99;
@@ -101,7 +101,7 @@ void pattern_teleport(player_type *player_ptr)
  * @brief 各種パターン地形上の特別な処理 / Returns TRUE if we are on the Pattern...
  * @return 実際にパターン地形上にプレイヤーが居た場合はTRUEを返す。
  */
-bool pattern_effect(player_type *player_ptr)
+bool pattern_effect(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!pattern_tile(floor_ptr, player_ptr->y, player_ptr->x))
@@ -164,7 +164,7 @@ bool pattern_effect(player_type *player_ptr)
  * @param n_x プレイヤーの移動先X座標
  * @return 移動処理が可能である場合(可能な場合に選択した場合)TRUEを返す。
  */
-bool pattern_seq(player_type *player_ptr, POSITION c_y, POSITION c_x, POSITION n_y, POSITION n_x)
+bool pattern_seq(PlayerType *player_ptr, POSITION c_y, POSITION c_x, POSITION n_y, POSITION n_x)
 {
     feature_type *cur_f_ptr = &f_info[player_ptr->current_floor_ptr->grid_array[c_y][c_x].feat];
     feature_type *new_f_ptr = &f_info[player_ptr->current_floor_ptr->grid_array[n_y][n_x].feat];
index f53dfbf..1c798eb 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool pattern_effect(player_type *player_ptr);
-bool pattern_seq(player_type *player_ptr, POSITION c_y, POSITION c_x, POSITION n_y, POSITION n_x);
-void pattern_teleport(player_type *player_ptr);
+class PlayerType;
+bool pattern_effect(PlayerType *player_ptr);
+bool pattern_seq(PlayerType *player_ptr, POSITION c_y, POSITION c_x, POSITION n_y, POSITION n_x);
+void pattern_teleport(PlayerType *player_ptr);
index e2d81d4..8b3a749 100644 (file)
@@ -50,7 +50,7 @@ static void correct_dir(POSITION *rdir, POSITION *cdir, POSITION y1, POSITION x1
  * @param col2 終点X座標
  * @return 生成に成功したらTRUEを返す
  */
-bool build_tunnel(player_type *player_ptr, dun_data_type *dd_ptr, dt_type *dt_ptr, POSITION row1, POSITION col1, POSITION row2, POSITION col2)
+bool build_tunnel(PlayerType *player_ptr, dun_data_type *dd_ptr, dt_type *dt_ptr, POSITION row1, POSITION col1, POSITION row2, POSITION col2)
 {
     POSITION tmp_row, tmp_col;
     POSITION row_dir, col_dir;
@@ -158,7 +158,7 @@ bool build_tunnel(player_type *player_ptr, dun_data_type *dd_ptr, dt_type *dt_pt
  * @param affectwall (調査中)
  * @todo 特に詳細な処理の意味を調査すべし
  */
-static bool set_tunnel(player_type *player_ptr, dun_data_type *dd_ptr, POSITION *x, POSITION *y, bool affectwall)
+static bool set_tunnel(PlayerType *player_ptr, dun_data_type *dd_ptr, POSITION *x, POSITION *y, bool affectwall)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[*y][*x];
@@ -230,7 +230,7 @@ static bool set_tunnel(player_type *player_ptr, dun_data_type *dd_ptr, POSITION
  * @param x 基準点のX座標
  * @param y 基準点のY座標
  */
-static void create_cata_tunnel(player_type *player_ptr, dun_data_type *dd_ptr, POSITION x, POSITION y)
+static void create_cata_tunnel(PlayerType *player_ptr, dun_data_type *dd_ptr, POSITION x, POSITION y)
 {
     POSITION x1 = x - 1;
     POSITION y1 = y;
@@ -255,7 +255,7 @@ static void create_cata_tunnel(player_type *player_ptr, dun_data_type *dd_ptr, P
  * @todo 詳細用調査
  */
 static void short_seg_hack(
-    player_type *player_ptr, dun_data_type *dd_ptr, const POSITION x1, const POSITION y1, const POSITION x2, const POSITION y2, int type, int count, bool *fail)
+    PlayerType *player_ptr, dun_data_type *dd_ptr, const POSITION x1, const POSITION y1, const POSITION x2, const POSITION y2, int type, int count, bool *fail)
 {
     if (!(*fail))
         return;
@@ -341,7 +341,7 @@ static void short_seg_hack(
  * @brief 特定の壁(永久壁など)を避けながら部屋間の通路を作成する / This routine maps a path from (x1, y1) to (x2, y2) avoiding SOLID walls.
  * @todo 詳細要調査
  */
-bool build_tunnel2(player_type *player_ptr, dun_data_type *dd_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2, int type, int cutoff)
+bool build_tunnel2(PlayerType *player_ptr, dun_data_type *dd_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2, int type, int cutoff)
 {
     POSITION x3, y3, dx, dy;
     POSITION changex, changey;
index c56a035..65ed31f 100644 (file)
@@ -4,6 +4,6 @@
 
 struct dun_data_type;
 struct dt_type;
-struct player_type;
-bool build_tunnel(player_type *player_ptr, dun_data_type *dd_ptr, dt_type *dt_ptr, POSITION row1, POSITION col1, POSITION row2, POSITION col2);
-bool build_tunnel2(player_type *player_ptr, dun_data_type *dd_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2, int type, int cutoff);
+class PlayerType;
+bool build_tunnel(PlayerType *player_ptr, dun_data_type *dd_ptr, dt_type *dt_ptr, POSITION row1, POSITION col1, POSITION row2, POSITION col2);
+bool build_tunnel2(PlayerType *player_ptr, dun_data_type *dd_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2, int type, int cutoff);
index da9a8b8..d5c3bdf 100644 (file)
@@ -285,7 +285,7 @@ static void generate_wilderness_area(floor_type *floor_ptr, int terrain, uint32_
  * If corner is set then only the corners of the area are needed.
  * </pre>
  */
-static void generate_area(player_type *player_ptr, POSITION y, POSITION x, bool border, bool corner)
+static void generate_area(PlayerType *player_ptr, POSITION y, POSITION x, bool border, bool corner)
 {
     player_ptr->town_num = wilderness[y][x].town;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -370,10 +370,10 @@ static border_type border;
 /*!
  * @brief 広域マップの生成 /
  * Build the wilderness area outside of the town.
- * @todo 広域マップは恒常生成にする予定、player_typeによる処理分岐は最終的に排除する。
+ * @todo 広域マップは恒常生成にする予定、PlayerTypeによる処理分岐は最終的に排除する。
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void wilderness_gen(player_type *player_ptr)
+void wilderness_gen(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     floor_ptr->height = MAX_HGT;
@@ -550,7 +550,7 @@ static int16_t conv_terrain2feat[MAX_WILDERNESS];
  * @brief 広域マップの生成(簡易処理版) /
  * Build the wilderness area. -DG-
  */
-void wilderness_gen_small(player_type *player_ptr)
+void wilderness_gen_small(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (int i = 0; i < MAX_WID; i++)
@@ -621,7 +621,7 @@ static wilderness_grid w_letter[255];
  * @param y 広域マップの高さを返す参照ポインタ
  * @param x 広域マップの幅を返す参照ポインタ
  */
-parse_error_type parse_line_wilderness(player_type *player_ptr, char *buf, int xmin, int xmax, int *y, int *x)
+parse_error_type parse_line_wilderness(PlayerType *player_ptr, char *buf, int xmin, int xmax, int *y, int *x)
 {
     if (!(buf[0] == 'W'))
         return (PARSE_ERROR_GENERIC);
@@ -833,7 +833,7 @@ void init_wilderness_terrains(void)
  * @param encount 襲撃時TRUE
  * @return 切り替えが行われた場合はTRUEを返す。
  */
-bool change_wild_mode(player_type *player_ptr, bool encount)
+bool change_wild_mode(PlayerType *player_ptr, bool encount)
 {
     generate_encounter = encount;
     if (player_ptr->leaving)
index 1638580..48eaa0e 100644 (file)
@@ -40,12 +40,12 @@ typedef struct wilderness_type {
 
 extern std::vector<std::vector<wilderness_type>> wilderness;
 
-struct player_type;
+class PlayerType;
 void set_floor_and_wall(DUNGEON_IDX type);
-void wilderness_gen(player_type *player_ptr);
-void wilderness_gen_small(player_type *player_ptr);
+void wilderness_gen(PlayerType *player_ptr);
+void wilderness_gen_small(PlayerType *player_ptr);
 errr init_wilderness(void);
 void init_wilderness_terrains(void);
 void seed_wilderness(void);
-parse_error_type parse_line_wilderness(player_type *player_ptr, char *buf, int xmin, int xmax, int *y, int *x);
-bool change_wild_mode(player_type *player_ptr, bool encount);
+parse_error_type parse_line_wilderness(PlayerType *player_ptr, char *buf, int xmin, int xmax, int *y, int *x);
+bool change_wild_mode(PlayerType *player_ptr, bool encount);
index e6f675d..0359a22 100644 (file)
@@ -16,7 +16,7 @@
  *
  * The doors must be INSIDE the allocated region.
  */
-void add_door(player_type *player_ptr, POSITION x, POSITION y)
+void add_door(PlayerType *player_ptr, POSITION x, POSITION y)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!floor_ptr->grid_array[y][x].is_outer())
@@ -61,7 +61,7 @@ void add_door(player_type *player_ptr, POSITION x, POSITION y)
  * @param x 配置したいフロアのX座標
  * @param type DOOR_DEFAULT / DOOR_DOOR / DOOR_GLASS_DOOR / DOOR_CURTAIN のいずれか
  */
-void place_secret_door(player_type *player_ptr, POSITION y, POSITION x, int type)
+void place_secret_door(PlayerType *player_ptr, POSITION y, POSITION x, int type)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (d_info[floor_ptr->dungeon_idx].flags.has(DungeonFeatureType::NO_DOORS)) {
@@ -98,7 +98,7 @@ void place_secret_door(player_type *player_ptr, POSITION y, POSITION x, int type
  * @param y 配置したいフロアのY座標
  * @param x 配置したいフロアのX座標
  */
-void place_locked_door(player_type *player_ptr, POSITION y, POSITION x)
+void place_locked_door(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (d_info[floor_ptr->dungeon_idx].flags.has(DungeonFeatureType::NO_DOORS)) {
@@ -118,7 +118,7 @@ void place_locked_door(player_type *player_ptr, POSITION y, POSITION x)
  * @param x ドアの配置を試みたいマスのX座標
  * @param room 部屋に接している場合向けのドア生成か否か
  */
-void place_random_door(player_type *player_ptr, POSITION y, POSITION x, bool room)
+void place_random_door(PlayerType *player_ptr, POSITION y, POSITION x, bool room)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
@@ -176,7 +176,7 @@ void place_random_door(player_type *player_ptr, POSITION y, POSITION x, bool roo
  * @param x ドアの配置を試みたいマスのX座標
  * @param type ドアの地形ID
  */
-void place_closed_door(player_type *player_ptr, POSITION y, POSITION x, int type)
+void place_closed_door(PlayerType *player_ptr, POSITION y, POSITION x, int type)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (d_info[floor_ptr->dungeon_idx].flags.has(DungeonFeatureType::NO_DOORS)) {
index 47f7260..5d7061b 100644 (file)
@@ -2,9 +2,9 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void add_door(player_type *player_ptr, POSITION x, POSITION y);
-void place_secret_door(player_type *player_ptr, POSITION y, POSITION x, int type);
-void place_locked_door(player_type *player_ptr, POSITION y, POSITION x);
-void place_random_door(player_type *player_ptr, POSITION y, POSITION x, bool room);
-void place_closed_door(player_type *player_ptr, POSITION y, POSITION x, int type);
+class PlayerType;
+void add_door(PlayerType *player_ptr, POSITION x, POSITION y);
+void place_secret_door(PlayerType *player_ptr, POSITION y, POSITION x, int type);
+void place_locked_door(PlayerType *player_ptr, POSITION y, POSITION x);
+void place_random_door(PlayerType *player_ptr, POSITION y, POSITION x, bool room);
+void place_closed_door(PlayerType *player_ptr, POSITION y, POSITION x, int type);
index adda9f4..1916433 100644 (file)
@@ -22,7 +22,7 @@
  * @brief フロアに洞窟や湖を配置する / Generate various caverns and lakes
  * @details There were moved from cave_gen().
  */
-void gen_caverns_and_lakes(player_type *player_ptr, dungeon_type *dungeon_ptr, dun_data_type *dd_ptr)
+void gen_caverns_and_lakes(PlayerType *player_ptr, dungeon_type *dungeon_ptr, dun_data_type *dd_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if ((floor_ptr->dun_level > 30) && one_in_(DUN_DEST * 2) && small_levels && dungeon_ptr->flags.has(DungeonFeatureType::DESTROY)) {
@@ -157,7 +157,7 @@ static bool possible_doorway(floor_type *floor_ptr, POSITION y, POSITION x)
  * @param y 設置を行いたいマスのY座標
  * @param x 設置を行いたいマスのX座標
  */
-void try_door(player_type *player_ptr, dt_type *dt_ptr, POSITION y, POSITION x)
+void try_door(PlayerType *player_ptr, dt_type *dt_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!in_bounds(floor_ptr, y, x) || cave_has_flag_bold(floor_ptr, y, x, FloorFeatureType::WALL) || floor_ptr->grid_array[y][x].is_room())
index 3c8f191..1a810bf 100644 (file)
@@ -5,7 +5,7 @@
 struct dungeon_type;
 struct dun_data_type;
 struct dt_type;
-struct player_type;
-void gen_caverns_and_lakes(player_type *player_ptr, dungeon_type *dungeon_ptr, dun_data_type *dd_ptr);
+class PlayerType;
+void gen_caverns_and_lakes(PlayerType *player_ptr, dungeon_type *dungeon_ptr, dun_data_type *dd_ptr);
 bool has_river_flag(dungeon_type *dungeon_ptr);
-void try_door(player_type *player_ptr, dt_type *dt_ptr, POSITION y, POSITION x);
+void try_door(PlayerType *player_ptr, dt_type *dt_ptr, POSITION y, POSITION x);
index d870968..cf36bbc 100644 (file)
@@ -120,7 +120,7 @@ FEAT_IDX feat_ground_type[100], feat_wall_type[100];
  * @param feat 地形情報のID
  * @return 罠持ちの地形ならばTRUEを返す。
  */
-bool is_trap(player_type *player_ptr, FEAT_IDX feat)
+bool is_trap(PlayerType *player_ptr, FEAT_IDX feat)
 {
        /* 関数ポインタの都合 */
        (void)player_ptr;
@@ -132,7 +132,7 @@ bool is_trap(player_type *player_ptr, FEAT_IDX feat)
  * @param feat 地形情報のID
  * @return 閉じたドアのある地形ならばTRUEを返す。
  */
-bool is_closed_door(player_type *player_ptr, FEAT_IDX feat)
+bool is_closed_door(PlayerType *player_ptr, FEAT_IDX feat)
 {
        /* 関数ポインタの都合 */
        (void)player_ptr;
@@ -189,7 +189,7 @@ FEAT_IDX feat_jammed_door_random(int door_type)
 /*
  * Change the "feat" flag for a grid, and notice/redraw the grid
  */
-void cave_set_feat(player_type *player_ptr, POSITION y, POSITION x, FEAT_IDX feat)
+void cave_set_feat(PlayerType *player_ptr, POSITION y, POSITION x, FEAT_IDX feat)
 {
     auto *floor_ptr = player_ptr->current_floor_ptr;
     auto *g_ptr = &floor_ptr->grid_array[y][x];
index 3c8355c..d6cd990 100644 (file)
@@ -114,13 +114,13 @@ extern FEAT_IDX feat_ground_type[100];
 extern FEAT_IDX feat_wall_type[100];
 
 struct floor_type;
-struct player_type;
-bool is_closed_door(player_type *player_ptr, FEAT_IDX feat);
-bool is_trap(player_type *player_ptr, FEAT_IDX feat);
+class PlayerType;
+bool is_closed_door(PlayerType *player_ptr, FEAT_IDX feat);
+bool is_trap(PlayerType *player_ptr, FEAT_IDX feat);
 void apply_default_feat_lighting(TERM_COLOR *f_attr, SYMBOL_CODE *f_char);
 bool is_ascii_graphics(char x);
 bool permanent_wall(feature_type *f_ptr);
 FEAT_IDX feat_locked_door_random(int door_type);
 FEAT_IDX feat_jammed_door_random(int door_type);
-void cave_set_feat(player_type *player_ptr, POSITION y, POSITION x, FEAT_IDX feat);
+void cave_set_feat(PlayerType *player_ptr, POSITION y, POSITION x, FEAT_IDX feat);
 FEAT_IDX conv_dungeon_feat(floor_type *floor_ptr, FEAT_IDX newfeat);
index f50b6ca..dbb05e3 100644 (file)
@@ -70,7 +70,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 配置に成功したらTRUEを返す
  */
-bool new_player_spot(player_type *player_ptr)
+bool new_player_spot(PlayerType *player_ptr)
 {
     POSITION y = 0, x = 0;
     int max_attempts = 10000;
@@ -135,7 +135,7 @@ bool new_player_spot(player_type *player_ptr)
  * @param g_ptr マス構造体の参照ポインタ
  * @return 隠されたドアがあるならTRUEを返す。
  */
-bool is_hidden_door(player_type *player_ptr, grid_type *g_ptr)
+bool is_hidden_door(PlayerType *player_ptr, grid_type *g_ptr)
 {
     if ((g_ptr->mimic || g_ptr->cave_has_flag(FloorFeatureType::SECRET)) && is_closed_door(player_ptr, g_ptr->feat))
         return true;
@@ -149,7 +149,7 @@ bool is_hidden_door(player_type *player_ptr, grid_type *g_ptr)
  * @param x x座標
  * @return 指定された座標に照明がかかっているならTRUEを返す。。
  */
-bool check_local_illumination(player_type *player_ptr, POSITION y, POSITION x)
+bool check_local_illumination(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     /* Hack -- move towards player */
     POSITION yy = (y < player_ptr->y) ? (y + 1) : (y > player_ptr->y) ? (y - 1) : y;
@@ -187,7 +187,7 @@ bool check_local_illumination(player_type *player_ptr, POSITION y, POSITION x)
  * @param y 視界先y座標
  * @param x 視界先x座標
  */
-void update_local_illumination(player_type *player_ptr, POSITION y, POSITION x)
+void update_local_illumination(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     int i;
     POSITION yy, xx;
@@ -238,7 +238,7 @@ void update_local_illumination(player_type *player_ptr, POSITION y, POSITION x)
  * @return 視覚に収められていないならTRUEを返す
  * @details player_can_see_bold()関数の返り値の否定を返している。
  */
-bool no_lite(player_type *player_ptr)
+bool no_lite(PlayerType *player_ptr)
 {
     return (!player_can_see_bold(player_ptr, player_ptr->y, player_ptr->x));
 }
@@ -246,7 +246,7 @@ bool no_lite(player_type *player_ptr)
 /*
  * Place an attr/char pair at the given map coordinate, if legal.
  */
-void print_rel(player_type *player_ptr, SYMBOL_CODE c, TERM_COLOR a, POSITION y, POSITION x)
+void print_rel(PlayerType *player_ptr, SYMBOL_CODE c, TERM_COLOR a, POSITION y, POSITION x)
 {
     /* Only do "legal" locations */
     if (panel_contains(y, x)) {
@@ -266,7 +266,7 @@ void print_rel(player_type *player_ptr, SYMBOL_CODE c, TERM_COLOR a, POSITION y,
 }
 
 /*!
- * @todo ここにplayer_type を追加した時のコンパイルエラーに対処できなかったので保留
+ * @todo ここにPlayerType を追加した時のコンパイルエラーに対処できなかったので保留
  * Memorize interesting viewable object/features in the given grid
  *
  * This function should only be called on "legal" grids.
@@ -305,7 +305,7 @@ void print_rel(player_type *player_ptr, SYMBOL_CODE c, TERM_COLOR a, POSITION y,
  * optimized primarily for the most common cases, that is, for the
  * non-marked floor grids.
  */
-void note_spot(player_type *player_ptr, POSITION y, POSITION x)
+void note_spot(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
 
@@ -383,7 +383,7 @@ void note_spot(player_type *player_ptr, POSITION y, POSITION x)
  *
  * This function should only be called on "legal" grids
  */
-void lite_spot(player_type *player_ptr, POSITION y, POSITION x)
+void lite_spot(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     /* Redraw if on screen */
     if (panel_contains(y, x) && in_bounds2(player_ptr->current_floor_ptr, y, x)) {
@@ -639,7 +639,7 @@ static POSITION flow_y = 0;
  * We do not need a priority queue because the cost from grid
  * to grid is always "one" and we process them in order.
  */
-void update_flow(player_type *player_ptr)
+void update_flow(PlayerType *player_ptr)
 {
     POSITION x, y;
     DIRECTION d;
@@ -753,7 +753,7 @@ FEAT_IDX feat_state(floor_type *floor_ptr, FEAT_IDX feat, FloorFeatureType actio
  * Takes a location and action and changes the feature at that
  * location through applying the given action.
  */
-void cave_alter_feat(player_type *player_ptr, POSITION y, POSITION x, FloorFeatureType action)
+void cave_alter_feat(PlayerType *player_ptr, POSITION y, POSITION x, FloorFeatureType action)
 {
     /* Set old feature */
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -804,7 +804,7 @@ void cave_alter_feat(player_type *player_ptr, POSITION y, POSITION x, FloorFeatu
 }
 
 /* Remove a mirror */
-void remove_mirror(player_type *player_ptr, POSITION y, POSITION x)
+void remove_mirror(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
 
@@ -836,7 +836,7 @@ void remove_mirror(player_type *player_ptr, POSITION y, POSITION x)
  * @param mode オプション
  * @return テレポート先として妥当ならばtrue
  */
-bool cave_monster_teleportable_bold(player_type *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, teleport_flags mode)
+bool cave_monster_teleportable_bold(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, teleport_flags mode)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
@@ -873,7 +873,7 @@ bool cave_monster_teleportable_bold(player_type *player_ptr, MONSTER_IDX m_idx,
  * @param mode オプション
  * @return テレポート先として妥当ならばtrue
  */
-bool cave_player_teleportable_bold(player_type *player_ptr, POSITION y, POSITION x, teleport_flags mode)
+bool cave_player_teleportable_bold(PlayerType *player_ptr, POSITION y, POSITION x, teleport_flags mode)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     feature_type *f_ptr = &f_info[g_ptr->feat];
@@ -922,7 +922,7 @@ bool cave_player_teleportable_bold(player_type *player_ptr, POSITION y, POSITION
  * @param feat 地形ID
  * @return 開いた地形である場合TRUEを返す /  Return TRUE if the given feature is an open door
  */
-bool is_open(player_type *player_ptr, FEAT_IDX feat)
+bool is_open(PlayerType *player_ptr, FEAT_IDX feat)
 {
     return f_info[feat].flags.has(FloorFeatureType::CLOSE) && (feat != feat_state(player_ptr->current_floor_ptr, feat, FloorFeatureType::CLOSE));
 }
@@ -933,7 +933,7 @@ bool is_open(player_type *player_ptr, FEAT_IDX feat)
  * @param mode 移動に関するオプションフラグ
  * @return 移動可能ならばTRUEを返す
  */
-bool player_can_enter(player_type *player_ptr, FEAT_IDX feature, BIT_FLAGS16 mode)
+bool player_can_enter(PlayerType *player_ptr, FEAT_IDX feature, BIT_FLAGS16 mode)
 {
     feature_type *f_ptr = &f_info[feature];
 
@@ -959,7 +959,7 @@ bool player_can_enter(player_type *player_ptr, FEAT_IDX feature, BIT_FLAGS16 mod
     return true;
 }
 
-void place_grid(player_type *player_ptr, grid_type *g_ptr, grid_bold_type gb_type)
+void place_grid(PlayerType *player_ptr, grid_type *g_ptr, grid_bold_type gb_type)
 {
     switch (gb_type) {
     case GB_FLOOR: {
@@ -1047,12 +1047,12 @@ void place_grid(player_type *player_ptr, grid_type *g_ptr, grid_bold_type gb_typ
  * @param g_ptr グリッドへの参照ポインタ
  * @return 照明が消されている地形ならばTRUE
  */
-bool darkened_grid(player_type *player_ptr, grid_type *g_ptr)
+bool darkened_grid(PlayerType *player_ptr, grid_type *g_ptr)
 {
     return ((g_ptr->info & (CAVE_VIEW | CAVE_LITE | CAVE_MNLT | CAVE_MNDK)) == (CAVE_VIEW | CAVE_MNDK)) && !player_ptr->see_nocto;
 }
 
-void place_bold(player_type *player_ptr, POSITION y, POSITION x, grid_bold_type gb_type)
+void place_bold(PlayerType *player_ptr, POSITION y, POSITION x, grid_bold_type gb_type)
 {
     grid_type *const g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     place_grid(player_ptr, g_ptr, gb_type);
@@ -1074,7 +1074,7 @@ void set_cave_feat(floor_type *floor_ptr, POSITION y, POSITION x, FEAT_IDX featu
  * @details Return the number of features around (or under) the character.
  * Usually look for doors and floor traps.
  */
-int count_dt(player_type *player_ptr, POSITION *y, POSITION *x, bool (*test)(player_type *, FEAT_IDX), bool under)
+int count_dt(PlayerType *player_ptr, POSITION *y, POSITION *x, bool (*test)(PlayerType *, FEAT_IDX), bool under)
 {
     int count = 0;
     for (DIRECTION d = 0; d < 9; d++) {
index 73a367e..7a819eb 100644 (file)
@@ -42,32 +42,32 @@ enum grid_bold_type {
 
 struct floor_type;
 struct grid_type;
-struct player_type;
+class PlayerType;
 struct monster_race;
 enum class FloorFeatureType;
-bool new_player_spot(player_type *player_ptr);
-bool is_hidden_door(player_type *player_ptr, grid_type *g_ptr);
-bool player_can_enter(player_type *player_ptr, FEAT_IDX feature, BIT_FLAGS16 mode);
+bool new_player_spot(PlayerType *player_ptr);
+bool is_hidden_door(PlayerType *player_ptr, grid_type *g_ptr);
+bool player_can_enter(PlayerType *player_ptr, FEAT_IDX feature, BIT_FLAGS16 mode);
 bool feat_uses_special(FEAT_IDX f_idx);
-void update_local_illumination(player_type *player_ptr, POSITION y, POSITION x);
-bool no_lite(player_type *player_ptr);
-void print_rel(player_type *player_ptr, SYMBOL_CODE c, TERM_COLOR a, POSITION y, POSITION x);
-void note_spot(player_type *player_ptr, POSITION y, POSITION x);
-void lite_spot(player_type *player_ptr, POSITION y, POSITION x);
-void update_flow(player_type *player_ptr);
+void update_local_illumination(PlayerType *player_ptr, POSITION y, POSITION x);
+bool no_lite(PlayerType *player_ptr);
+void print_rel(PlayerType *player_ptr, SYMBOL_CODE c, TERM_COLOR a, POSITION y, POSITION x);
+void note_spot(PlayerType *player_ptr, POSITION y, POSITION x);
+void lite_spot(PlayerType *player_ptr, POSITION y, POSITION x);
+void update_flow(PlayerType *player_ptr);
 FEAT_IDX feat_state(floor_type *floor_ptr, FEAT_IDX feat, FloorFeatureType action);
-void cave_alter_feat(player_type *player_ptr, POSITION y, POSITION x, FloorFeatureType action);
-void remove_mirror(player_type *player_ptr, POSITION y, POSITION x);
-bool is_open(player_type *player_ptr, FEAT_IDX feat);
-bool check_local_illumination(player_type *player_ptr, POSITION y, POSITION x);
-bool cave_monster_teleportable_bold(player_type *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, teleport_flags mode);
-bool cave_player_teleportable_bold(player_type *player_ptr, POSITION y, POSITION x, teleport_flags mode);
-void place_grid(player_type *player_ptr, grid_type *g_ptr, grid_bold_type pg_type);
-bool darkened_grid(player_type *player_ptr, grid_type *g_ptr);
-void delete_monster(player_type *player_ptr, POSITION y, POSITION x);
-void place_bold(player_type *player_ptr, POSITION y, POSITION x, grid_bold_type gh_type);
+void cave_alter_feat(PlayerType *player_ptr, POSITION y, POSITION x, FloorFeatureType action);
+void remove_mirror(PlayerType *player_ptr, POSITION y, POSITION x);
+bool is_open(PlayerType *player_ptr, FEAT_IDX feat);
+bool check_local_illumination(PlayerType *player_ptr, POSITION y, POSITION x);
+bool cave_monster_teleportable_bold(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, teleport_flags mode);
+bool cave_player_teleportable_bold(PlayerType *player_ptr, POSITION y, POSITION x, teleport_flags mode);
+void place_grid(PlayerType *player_ptr, grid_type *g_ptr, grid_bold_type pg_type);
+bool darkened_grid(PlayerType *player_ptr, grid_type *g_ptr);
+void delete_monster(PlayerType *player_ptr, POSITION y, POSITION x);
+void place_bold(PlayerType *player_ptr, POSITION y, POSITION x, grid_bold_type gh_type);
 void set_cave_feat(floor_type *floor_ptr, POSITION y, POSITION x, FEAT_IDX feature_idx);
-int count_dt(player_type *player_ptr, POSITION *y, POSITION *x, bool (*test)(player_type *, FEAT_IDX), bool under);
+int count_dt(PlayerType *player_ptr, POSITION *y, POSITION *x, bool (*test)(PlayerType *, FEAT_IDX), bool under);
 void cave_lite_hack(floor_type *floor_ptr, POSITION y, POSITION x);
 void cave_redraw_later(floor_type *floor_ptr, POSITION y, POSITION x);
 void cave_note_and_redraw_later(floor_type *floor_ptr, POSITION y, POSITION x);
index 3a6a2f0..3496935 100644 (file)
@@ -19,7 +19,7 @@
  * @details
  * The location must be a legal, clean, floor grid.
  */
-void place_gold(player_type *player_ptr, POSITION y, POSITION x)
+void place_gold(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
@@ -66,7 +66,7 @@ void place_gold(player_type *player_ptr, POSITION y, POSITION x)
  * This routine uses "object_level" for the "generation level".\n
  * This routine requires a clean floor grid destination.\n
  */
-void place_object(player_type *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode)
+void place_object(PlayerType *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
index ea55cf1..203675f 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void place_gold(player_type *player_ptr, POSITION y, POSITION x);
-void place_object(player_type *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode);
+class PlayerType;
+void place_gold(PlayerType *player_ptr, POSITION y, POSITION x);
+void place_object(PlayerType *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode);
index 12bae42..c5432e7 100644 (file)
@@ -16,7 +16,7 @@
  * @param y 配置を試みたいマスのY座標
  * @param x 配置を試みたいマスのX座標
  */
-void place_random_stairs(player_type *player_ptr, POSITION y, POSITION x)
+void place_random_stairs(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     bool up_stairs = true;
     bool down_stairs = true;
index 6aad7e4..5b42d40 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 
 struct floor_type;
-struct player_type;
-void place_random_stairs(player_type *player_ptr, POSITION y, POSITION x);
+class PlayerType;
+void place_random_stairs(PlayerType *player_ptr, POSITION y, POSITION x);
 bool cave_valid_bold(floor_type *floor_ptr, POSITION y, POSITION x);
index 40b4a3e..4a8182a 100644 (file)
@@ -163,7 +163,7 @@ void init_normal_traps(void)
  * Actually, it is not this routine, but the "trap instantiation"\n
  * code, which should also check for "trap doors" on quest levels.\n
  */
-FEAT_IDX choose_random_trap(player_type *player_ptr)
+FEAT_IDX choose_random_trap(PlayerType *player_ptr)
 {
     FEAT_IDX feat;
 
@@ -198,7 +198,7 @@ FEAT_IDX choose_random_trap(player_type *player_ptr)
  * @param y 秘匿したいマスのY座標
  * @param x 秘匿したいマスのX座標
  */
-void disclose_grid(player_type *player_ptr, POSITION y, POSITION x)
+void disclose_grid(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
 
@@ -224,7 +224,7 @@ void disclose_grid(player_type *player_ptr, POSITION y, POSITION x)
  * when they are "discovered" (by detecting them or setting them off),\n
  * the trap is "instantiated" as a visible, "typed", trap.\n
  */
-void place_trap(player_type *player_ptr, POSITION y, POSITION x)
+void place_trap(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
@@ -251,7 +251,7 @@ void place_trap(player_type *player_ptr, POSITION y, POSITION x)
  * Always miss 5% of the time, Always hit 5% of the time.
  * Otherwise, match trap power against player armor.
  */
-static int check_hit_from_monster_to_player(player_type *player_ptr, int power)
+static int check_hit_from_monster_to_player(PlayerType *player_ptr, int power)
 {
     int k;
     ARMOUR_CLASS ac;
@@ -286,7 +286,7 @@ static int check_hit_from_monster_to_player(player_type *player_ptr, int power)
  * @brief 落とし穴系トラップの判定とプレイヤーの被害処理
  * @param trap_feat_type トラップの種別ID
  */
-static void hit_trap_pit(player_type *player_ptr, enum trap_type trap_feat_type)
+static void hit_trap_pit(PlayerType *player_ptr, enum trap_type trap_feat_type)
 {
     HIT_POINT dam;
     concptr trap_name = "";
@@ -344,7 +344,7 @@ static void hit_trap_pit(player_type *player_ptr, enum trap_type trap_feat_type)
  * @brief ダーツ系トラップ(通常ダメージ)の判定とプレイヤーの被害処理
  * @return ダーツが命中した場合TRUEを返す
  */
-static bool hit_trap_dart(player_type *player_ptr)
+static bool hit_trap_dart(PlayerType *player_ptr)
 {
     bool hit = false;
 
@@ -364,7 +364,7 @@ static bool hit_trap_dart(player_type *player_ptr)
  * @brief ダーツ系トラップ(通常ダメージ+能力値減少)の判定とプレイヤーの被害処理
  * @param stat 低下する能力値ID
  */
-static void hit_trap_lose_stat(player_type *player_ptr, int stat)
+static void hit_trap_lose_stat(PlayerType *player_ptr, int stat)
 {
     if (hit_trap_dart(player_ptr)) {
         do_dec_stat(player_ptr, stat);
@@ -374,7 +374,7 @@ static void hit_trap_lose_stat(player_type *player_ptr, int stat)
 /*!
  * @brief ダーツ系トラップ(通常ダメージ+減速)の判定とプレイヤーの被害処理
  */
-static void hit_trap_slow(player_type *player_ptr)
+static void hit_trap_slow(PlayerType *player_ptr)
 {
     if (hit_trap_dart(player_ptr)) {
         (void)BadStatusSetter(player_ptr).mod_slowness(randint0(20) + 20, false);
@@ -387,7 +387,7 @@ static void hit_trap_slow(player_type *player_ptr)
  * @param break_trap 作動後のトラップ破壊が確定しているならばTRUE
  * @todo cmd-save.h への依存あり。コールバックで何とかしたい
  */
-void hit_trap(player_type *player_ptr, bool break_trap)
+void hit_trap(PlayerType *player_ptr, bool break_trap)
 {
     int i, num, dam;
     POSITION x = player_ptr->x, y = player_ptr->y;
index ef741e5..139c349 100644 (file)
@@ -57,9 +57,9 @@ const int MAX_NORMAL_TRAPS = TRAP_ALARM + 1;
 
 extern const std::vector<EnumClassFlagGroup<ChestTrapType>> chest_traps;
 
-struct player_type;
+class PlayerType;
 void init_normal_traps(void);
-FEAT_IDX choose_random_trap(player_type *player_ptr);
-void disclose_grid(player_type *player_ptr, POSITION y, POSITION x);
-void place_trap(player_type *player_ptr, POSITION y, POSITION x);
-void hit_trap(player_type *player_ptr, bool break_trap);
+FEAT_IDX choose_random_trap(PlayerType *player_ptr);
+void disclose_grid(PlayerType *player_ptr, POSITION y, POSITION x);
+void place_trap(PlayerType *player_ptr, POSITION y, POSITION x);
+void hit_trap(PlayerType *player_ptr, bool break_trap);
index 25aa3eb..f571366 100644 (file)
@@ -61,8 +61,8 @@
  * @details
  * ダメージを受けた場合、自然回復できない。
  */
-static bool deal_damege_by_feat(player_type *player_ptr, grid_type *g_ptr, concptr msg_levitation, concptr msg_normal,
-    std::function<PERCENTAGE(player_type *)> damage_rate, std::function<void(player_type *, int)> additional_effect)
+static bool deal_damege_by_feat(PlayerType *player_ptr, grid_type *g_ptr, concptr msg_levitation, concptr msg_normal,
+    std::function<PERCENTAGE(PlayerType *)> damage_rate, std::function<void(PlayerType *, int)> additional_effect)
 {
     feature_type *f_ptr = &f_info[g_ptr->feat];
     int damage = 0;
@@ -106,7 +106,7 @@ static bool deal_damege_by_feat(player_type *player_ptr, grid_type *g_ptr, concp
  * @brief 10ゲームターンが進行するごとにプレイヤーのHPとMPの増減処理を行う。
  *  / Handle timed damage and regeneration every 10 game turns
  */
-void process_player_hp_mp(player_type *player_ptr)
+void process_player_hp_mp(PlayerType *player_ptr)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[player_ptr->y][player_ptr->x];
     feature_type *f_ptr = &f_info[g_ptr->feat];
@@ -190,7 +190,7 @@ void process_player_hp_mp(player_type *player_ptr)
 
     if (f_ptr->flags.has(FloorFeatureType::POISON_PUDDLE) && !is_invuln(player_ptr)) {
         if (deal_damege_by_feat(player_ptr, g_ptr, _("毒気を吸い込んだ!", "The gas poisons you!"), _("に毒された!", "poisons you!"), calc_acid_damage_rate,
-                [](player_type *player_ptr, int damage) {
+                [](PlayerType *player_ptr, int damage) {
                     if (!has_resist_pois(player_ptr))
                         (void)BadStatusSetter(player_ptr).mod_poison(static_cast<TIME_EFFECT>(damage));
                 })) {
@@ -390,7 +390,7 @@ void process_player_hp_mp(player_type *player_ptr)
 /*
  * Increase players hit points, notice effects
  */
-bool hp_player(player_type *player_ptr, int num)
+bool hp_player(PlayerType *player_ptr, int num)
 {
     int vir;
     vir = virtue_number(player_ptr, V_VITALITY);
index 420e58e..47d849b 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void process_player_hp_mp(player_type *player_ptr);
-bool hp_player(player_type *player_ptr, int num);
+class PlayerType;
+void process_player_hp_mp(PlayerType *player_ptr);
+bool hp_player(PlayerType *player_ptr, int num);
index 583ed88..1f4cacf 100644 (file)
@@ -26,7 +26,7 @@ int wild_regen = 20;
  * @brief プレイヤーのHP自然回復処理 / Regenerate hit points -RAK-
  * @param percent 回復比率
  */
-void regenhp(player_type *player_ptr, int percent)
+void regenhp(PlayerType *player_ptr, int percent)
 {
     if (PlayerClass(player_ptr).samurai_stance_is(SamuraiStanceType::KOUKIJIN))
         return;
@@ -61,7 +61,7 @@ void regenhp(player_type *player_ptr, int percent)
  * @param upkeep_factor ペット維持によるMPコスト量
  * @param regen_amount 回復量
  */
-void regenmana(player_type *player_ptr, MANA_POINT upkeep_factor, MANA_POINT regen_amount)
+void regenmana(PlayerType *player_ptr, MANA_POINT upkeep_factor, MANA_POINT regen_amount)
 {
     MANA_POINT old_csp = player_ptr->csp;
     int32_t regen_rate = regen_amount * 100 - upkeep_factor * PY_REGEN_NORMAL;
@@ -117,7 +117,7 @@ void regenmana(player_type *player_ptr, MANA_POINT upkeep_factor, MANA_POINT reg
  * @brief 取り込んだ魔道具の自然回復処理 / Regenerate magic regen_amount: PY_REGEN_NORMAL * 2 (if resting) * 2 (if having regenarate)
  * @param regen_amount 回復量
  */
-void regenmagic(player_type *player_ptr, int regen_amount)
+void regenmagic(PlayerType *player_ptr, int regen_amount)
 {
     auto magic_eater_data = PlayerClass(player_ptr).get_specific_data<magic_eater_data_type>();
     if (!magic_eater_data) {
@@ -164,7 +164,7 @@ void regenmagic(player_type *player_ptr, int regen_amount)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @note Should probably be done during monster turns.
  */
-void regenerate_monsters(player_type *player_ptr)
+void regenerate_monsters(PlayerType *player_ptr)
 {
     for (int i = 1; i < player_ptr->current_floor_ptr->m_max; i++) {
         monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[i];
@@ -199,7 +199,7 @@ void regenerate_monsters(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @note Should probably be done during monster turns.
  */
-void regenerate_captured_monsters(player_type *player_ptr)
+void regenerate_captured_monsters(PlayerType *player_ptr)
 {
     bool heal = false;
     for (int i = 0; i < INVEN_TOTAL; i++) {
index 25a7566..299ca40 100644 (file)
@@ -13,9 +13,9 @@
 
 extern int wild_regen;
 
-struct player_type;
-void regenhp(player_type *player_ptr, int percent);
-void regenmana(player_type *player_ptr, MANA_POINT upkeep_factor, MANA_POINT regen_amount);
-void regenmagic(player_type *player_ptr, int regen_amount);
-void regenerate_monsters(player_type *player_ptr);
-void regenerate_captured_monsters(player_type *player_ptr);
+class PlayerType;
+void regenhp(PlayerType *player_ptr, int percent);
+void regenmana(PlayerType *player_ptr, MANA_POINT upkeep_factor, MANA_POINT regen_amount);
+void regenmagic(PlayerType *player_ptr, int regen_amount);
+void regenerate_monsters(PlayerType *player_ptr);
+void regenerate_captured_monsters(PlayerType *player_ptr);
index a829750..b739c92 100644 (file)
@@ -34,7 +34,7 @@ static concptr variant = "ZANGBAND";
  * @param fp
  * @return エラーコード
  */
-static concptr parse_fixed_map_expression(player_type *player_ptr, char **sp, char *fp)
+static concptr parse_fixed_map_expression(PlayerType *player_ptr, char **sp, char *fp)
 {
     char b1 = '[';
     char b2 = ']';
@@ -232,7 +232,7 @@ static concptr parse_fixed_map_expression(player_type *player_ptr, char **sp, ch
  * @param xmax 詳細不明
  * @return エラーコード
  */
-parse_error_type parse_fixed_map(player_type *player_ptr, concptr name, int ymin, int xmin, int ymax, int xmax)
+parse_error_type parse_fixed_map(PlayerType *player_ptr, concptr name, int ymin, int xmin, int ymax, int xmax)
 {
     char buf[1024];
     path_build(buf, sizeof(buf), ANGBAND_DIR_EDIT, name);
index 9ee0f7b..e92702c 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "info-reader/parse-error-types.h"
 
-struct player_type;
-parse_error_type parse_fixed_map(player_type *player_ptr, concptr name, int ymin, int xmin, int ymax, int xmax);
+class PlayerType;
+parse_error_type parse_fixed_map(PlayerType *player_ptr, concptr name, int ymin, int xmin, int ymax, int xmax);
index 0d69be8..8931085 100644 (file)
@@ -42,7 +42,7 @@
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す
  * @todo 適切な関数名をどうしても付けられなかったので暫定でauxとした
  */
-static bool check_floor_item_tag_aux(player_type *player_ptr, fis_type *fis_ptr, char *prev_tag, const ItemTester& item_tester)
+static bool check_floor_item_tag_aux(PlayerType *player_ptr, fis_type *fis_ptr, char *prev_tag, const ItemTester& item_tester)
 {
     if (!fis_ptr->floor || (*fis_ptr->cp >= 0))
         return false;
@@ -74,7 +74,7 @@ static bool check_floor_item_tag_aux(player_type *player_ptr, fis_type *fis_ptr,
  * @param prev_tag 前回選択したアイテムのタグ (のはず)
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す
  */
-static bool get_floor_item_tag_inventory(player_type *player_ptr, fis_type *fis_ptr, char *prev_tag, const ItemTester& item_tester)
+static bool get_floor_item_tag_inventory(PlayerType *player_ptr, fis_type *fis_ptr, char *prev_tag, const ItemTester& item_tester)
 {
     bool flag = false;
     item_use_flag use_flag = (*fis_ptr->cp >= INVEN_MAIN_HAND) ? USE_EQUIP : USE_INVEN;
@@ -104,7 +104,7 @@ static bool get_floor_item_tag_inventory(player_type *player_ptr, fis_type *fis_
  * @param prev_tag 前回選択したアイテムのタグ (のはず)
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す
  */
-static bool check_floor_item_tag_inventory(player_type *player_ptr, fis_type *fis_ptr, char *prev_tag, const ItemTester& item_tester)
+static bool check_floor_item_tag_inventory(PlayerType *player_ptr, fis_type *fis_ptr, char *prev_tag, const ItemTester& item_tester)
 {
     if ((!fis_ptr->inven || (*fis_ptr->cp < 0) || (*fis_ptr->cp >= INVEN_PACK))
         && (!fis_ptr->equip || (*fis_ptr->cp < INVEN_MAIN_HAND) || (*fis_ptr->cp >= INVEN_TOTAL)))
@@ -128,7 +128,7 @@ static bool check_floor_item_tag_inventory(player_type *player_ptr, fis_type *fi
  * @param prev_tag 前回選択したアイテムのタグ (のはず)
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す
  */
-static bool check_floor_item_tag(player_type *player_ptr, fis_type *fis_ptr, char *prev_tag, const ItemTester& item_tester)
+static bool check_floor_item_tag(PlayerType *player_ptr, fis_type *fis_ptr, char *prev_tag, const ItemTester& item_tester)
 {
     if (!repeat_pull(fis_ptr->cp))
         return false;
@@ -149,7 +149,7 @@ static bool check_floor_item_tag(player_type *player_ptr, fis_type *fis_ptr, cha
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fis_ptr 床上アイテムへの参照ポインタ
  */
-static void test_inventory_floor(player_type *player_ptr, fis_type *fis_ptr, const ItemTester& item_tester)
+static void test_inventory_floor(PlayerType *player_ptr, fis_type *fis_ptr, const ItemTester& item_tester)
 {
     if (!fis_ptr->inven) {
         fis_ptr->i2 = -1;
@@ -169,7 +169,7 @@ static void test_inventory_floor(player_type *player_ptr, fis_type *fis_ptr, con
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fis_ptr 床上アイテムへの参照ポインタ
  */
-static void test_equipment_floor(player_type *player_ptr, fis_type *fis_ptr, const ItemTester& item_tester)
+static void test_equipment_floor(PlayerType *player_ptr, fis_type *fis_ptr, const ItemTester& item_tester)
 {
     if (!fis_ptr->equip) {
         fis_ptr->e2 = -1;
@@ -194,7 +194,7 @@ static void test_equipment_floor(player_type *player_ptr, fis_type *fis_ptr, con
  * @param mode オプションフラグ
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す。/
  */
-bool get_item_floor(player_type *player_ptr, COMMAND_CODE *cp, concptr pmt, concptr str, BIT_FLAGS mode, const ItemTester& item_tester)
+bool get_item_floor(PlayerType *player_ptr, COMMAND_CODE *cp, concptr pmt, concptr str, BIT_FLAGS mode, const ItemTester& item_tester)
 {
     fis_type tmp_fis;
     fis_type *fis_ptr = initialize_fis_type(&tmp_fis, cp, mode);
index ed64925..006ce0d 100644 (file)
@@ -3,6 +3,6 @@
 #include "object/tval-types.h"
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ItemTester;
-bool get_item_floor(player_type *player_ptr, COMMAND_CODE *cp, concptr pmt, concptr str, BIT_FLAGS mode, const ItemTester& item_tester);
+bool get_item_floor(PlayerType *player_ptr, COMMAND_CODE *cp, concptr pmt, concptr str, BIT_FLAGS mode, const ItemTester& item_tester);
index 5dd5814..190d6bb 100644 (file)
@@ -134,7 +134,7 @@ static void choise_cursed_item(CurseTraitType flag, object_type *o_ptr, int *cho
  * @return 該当の呪いが一つでもあった場合にランダムに選ばれた装備品のオブジェクト構造体参照ポインタを返す。\n
  * 呪いがない場合nullptrを返す。
  */
-object_type *choose_cursed_obj_name(player_type *player_ptr, CurseTraitType flag)
+object_type *choose_cursed_obj_name(PlayerType *player_ptr, CurseTraitType flag)
 {
     int choices[INVEN_TOTAL - INVEN_MAIN_HAND];
     int number = 0;
@@ -159,7 +159,7 @@ object_type *choose_cursed_obj_name(player_type *player_ptr, CurseTraitType flag
  * @brief 呪われている、トランプエゴ等による装備品由来のテレポートを実行する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void curse_teleport(player_type *player_ptr)
+static void curse_teleport(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed_special.has_not(CurseSpecialTraitType::TELEPORT_SELF)) || !one_in_(200))
         return;
@@ -200,7 +200,7 @@ static void curse_teleport(player_type *player_ptr)
 /*!
  * @details 元々呪い効果の発揮ルーチン中にいたので、整合性保持のためここに置いておく
  */
-static void occur_chainsword_effect(player_type *player_ptr)
+static void occur_chainsword_effect(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed_special.has_not(CurseSpecialTraitType::CHAINSWORD)) || !one_in_(CHAINSWORD_NOISE))
         return;
@@ -211,7 +211,7 @@ static void occur_chainsword_effect(player_type *player_ptr)
     disturb(player_ptr, false, false);
 }
 
-static void curse_drain_exp(player_type *player_ptr)
+static void curse_drain_exp(PlayerType *player_ptr)
 {
     if ((player_ptr->prace == PlayerRaceType::ANDROID) || (player_ptr->cursed.has_not(CurseTraitType::DRAIN_EXP)) || !one_in_(4))
         return;
@@ -227,7 +227,7 @@ static void curse_drain_exp(player_type *player_ptr)
     check_experience(player_ptr);
 }
 
-static void multiply_low_curse(player_type *player_ptr)
+static void multiply_low_curse(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed.has_not(CurseTraitType::ADD_L_CURSE)) || !one_in_(2000))
         return;
@@ -246,7 +246,7 @@ static void multiply_low_curse(player_type *player_ptr)
     player_ptr->update |= (PU_BONUS);
 }
 
-static void multiply_high_curse(player_type *player_ptr)
+static void multiply_high_curse(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed.has_not(CurseTraitType::ADD_H_CURSE)) || !one_in_(2000))
         return;
@@ -265,7 +265,7 @@ static void multiply_high_curse(player_type *player_ptr)
     player_ptr->update |= (PU_BONUS);
 }
 
-static void curse_call_monster(player_type *player_ptr)
+static void curse_call_monster(PlayerType *player_ptr)
 {
     const int call_type = PM_ALLOW_GROUP | PM_ALLOW_UNIQUE | PM_NO_PET;
     const int obj_desc_type = OD_OMIT_PREFIX | OD_NAME_ONLY;
@@ -307,7 +307,7 @@ static void curse_call_monster(player_type *player_ptr)
     }
 }
 
-static void curse_cowardice(player_type *player_ptr)
+static void curse_cowardice(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed.has_not(CurseTraitType::COWARDICE)) || !one_in_(1500))
         return;
@@ -324,7 +324,7 @@ static void curse_cowardice(player_type *player_ptr)
  * @brief 装備による狂戦士化の発作を引き起こす
  * @param player_ptr プレイヤー情報への参照ポインタ
  */
-static void curse_berserk_rage(player_type *player_ptr)
+static void curse_berserk_rage(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed.has_not(CurseTraitType::BERS_RAGE)) || !one_in_(1500))
         return;
@@ -336,7 +336,7 @@ static void curse_berserk_rage(player_type *player_ptr)
     (void)BadStatusSetter(player_ptr).afraidness(0);
 }
 
-static void curse_drain_hp(player_type *player_ptr)
+static void curse_drain_hp(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed.has_not(CurseTraitType::DRAIN_HP)) || !one_in_(666))
         return;
@@ -347,7 +347,7 @@ static void curse_drain_hp(player_type *player_ptr)
     take_hit(player_ptr, DAMAGE_LOSELIFE, std::min(player_ptr->lev * 2, 100), o_name);
 }
 
-static void curse_drain_mp(player_type *player_ptr)
+static void curse_drain_mp(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed.has_not(CurseTraitType::DRAIN_MANA)) || (player_ptr->csp == 0) || !one_in_(666))
         return;
@@ -364,7 +364,7 @@ static void curse_drain_mp(player_type *player_ptr)
     player_ptr->redraw |= PR_MANA;
 }
 
-static void occur_curse_effects(player_type *player_ptr)
+static void occur_curse_effects(PlayerType *player_ptr)
 {
     if ((player_ptr->cursed.has_none_of(TRC_P_FLAG_MASK) && player_ptr->cursed_special.has_none_of(TRCS_P_FLAG_MASK)) || player_ptr->phase_out
         || player_ptr->wild_mode)
@@ -397,7 +397,7 @@ static void occur_curse_effects(player_type *player_ptr)
  * / Handle curse effects once every 10 game turns
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void execute_cursed_items_effect(player_type *player_ptr)
+void execute_cursed_items_effect(PlayerType *player_ptr)
 {
     occur_curse_effects(player_ptr);
     if (!one_in_(999) || player_ptr->anti_magic || (one_in_(2) && has_resist_curse(player_ptr)))
index 6bc2437..52def97 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-object_type *choose_cursed_obj_name(player_type *player_ptr, BIT_FLAGS flag);
-void execute_cursed_items_effect(player_type *player_ptr);
+class PlayerType;
+object_type *choose_cursed_obj_name(PlayerType *player_ptr, BIT_FLAGS flag);
+void execute_cursed_items_effect(PlayerType *player_ptr);
index 435ab36..b2bf98f 100644 (file)
@@ -25,7 +25,7 @@
  * Destruction taken from "melee.c" code for "stealing".
  * New-style wands and rods handled correctly. -LM-
  */
-void inventory_damage(player_type *player_ptr, const ObjectBreaker& breaker, int perc)
+void inventory_damage(PlayerType *player_ptr, const ObjectBreaker& breaker, int perc)
 {
     INVENTORY_IDX i;
     int j, amt;
index 663d969..d016102 100644 (file)
@@ -6,6 +6,6 @@
  * This seems like a pretty standard "typedef"
  */
 struct object_type;
-struct player_type;
+class PlayerType;
 
-void inventory_damage(player_type *player_ptr, const ObjectBreaker& breaker, int perc);
+void inventory_damage(PlayerType *player_ptr, const ObjectBreaker& breaker, int perc);
index e6119f9..5b07da3 100644 (file)
@@ -13,7 +13,7 @@
  * @param i 部位表現を求めるプレイヤーの所持/装備オブジェクトID
  * @return 部位表現の文字列ポインタ
  */
-concptr mention_use(player_type *player_ptr, int i)
+concptr mention_use(PlayerType *player_ptr, int i)
 {
     concptr p;
 
@@ -89,7 +89,7 @@ concptr mention_use(player_type *player_ptr, int i)
  * @details
  * Currently, only used for items in the equipment, inventory.
  */
-concptr describe_use(player_type *player_ptr, int i)
+concptr describe_use(PlayerType *player_ptr, int i)
 {
     concptr p;
     switch (i) {
index 9b80b2e..7118017 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 #include "system/player-type-definition.h"
-concptr mention_use(player_type *player_ptr, int i);
-concptr describe_use(player_type *player_ptr, int i);
+concptr mention_use(PlayerType *player_ptr, int i);
+concptr describe_use(PlayerType *player_ptr, int i);
index 4db1f8b..399df2d 100644 (file)
@@ -17,7 +17,7 @@
 #include "view/display-messages.h"
 #include "view/object-describer.h"
 
-void vary_item(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num)
+void vary_item(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num)
 {
     if (item >= 0) {
         inven_item_increase(player_ptr, item, num);
@@ -38,7 +38,7 @@ void vary_item(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num)
  * @param item 所持数を増やしたいプレイヤーのアイテム所持スロット
  * @param num 増やしたい量
  */
-void inven_item_increase(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num)
+void inven_item_increase(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num)
 {
     object_type *o_ptr = &player_ptr->inventory_list[item];
     num += o_ptr->number;
@@ -73,7 +73,7 @@ void inven_item_increase(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBE
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param item 消去したいプレイヤーのアイテム所持スロット
  */
-void inven_item_optimize(player_type *player_ptr, INVENTORY_IDX item)
+void inven_item_optimize(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     object_type *o_ptr = &player_ptr->inventory_list[item];
     if (!o_ptr->k_idx)
@@ -113,7 +113,7 @@ void inven_item_optimize(player_type *player_ptr, INVENTORY_IDX item)
  * @details
  * The object will be dropped "near" the current location
  */
-void drop_from_inventory(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER amt)
+void drop_from_inventory(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER amt)
 {
     object_type forge;
     object_type *q_ptr;
@@ -148,7 +148,7 @@ void drop_from_inventory(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBE
  * @details
  * Note special handling of the "overflow" slot
  */
-void combine_pack(player_type *player_ptr)
+void combine_pack(PlayerType *player_ptr)
 {
     bool flag = false;
     bool is_first_combination = true;
@@ -221,7 +221,7 @@ void combine_pack(player_type *player_ptr)
  * @details
  * Note special handling of the "overflow" slot
  */
-void reorder_pack(player_type *player_ptr)
+void reorder_pack(PlayerType *player_ptr)
 {
     int i, j, k;
     int32_t o_value;
@@ -282,7 +282,7 @@ void reorder_pack(player_type *player_ptr)
  * Note that this code must remove any location/stack information\n
  * from the object once it is placed into the inventory.\n
  */
-int16_t store_item_to_inventory(player_type *player_ptr, object_type *o_ptr)
+int16_t store_item_to_inventory(PlayerType *player_ptr, object_type *o_ptr)
 {
     INVENTORY_IDX i, j, k;
     INVENTORY_IDX n = -1;
@@ -348,7 +348,7 @@ int16_t store_item_to_inventory(player_type *player_ptr, object_type *o_ptr)
  * @param o_ptr 拾いたいオブジェクトの構造体参照ポインタ
  * @return 溢れずに済むならTRUEを返す
  */
-bool check_store_item_to_inventory(player_type *player_ptr, const object_type *o_ptr)
+bool check_store_item_to_inventory(PlayerType *player_ptr, const object_type *o_ptr)
 {
     if (player_ptr->inven_cnt < INVEN_PACK)
         return true;
@@ -378,7 +378,7 @@ bool check_store_item_to_inventory(player_type *player_ptr, const object_type *o
  * to fall to the ground.\n
  * Return the inventory slot into which the item is placed.\n
  */
-INVENTORY_IDX inven_takeoff(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER amt)
+INVENTORY_IDX inven_takeoff(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER amt)
 {
     INVENTORY_IDX slot;
     object_type forge;
index 256019f..c775f42 100644 (file)
@@ -3,13 +3,13 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-void vary_item(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num);
-void inven_item_increase(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num);
-void inven_item_optimize(player_type *player_ptr, INVENTORY_IDX item);
-void drop_from_inventory(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER amt);
-void combine_pack(player_type *player_ptr);
-void reorder_pack(player_type *player_ptr);
-int16_t store_item_to_inventory(player_type *player_ptr, object_type *o_ptr);
-bool check_store_item_to_inventory(player_type *player_ptr, const object_type *o_ptr);
-INVENTORY_IDX inven_takeoff(player_type *player_ptr, INVENTORY_IDX item, ITEM_NUMBER amt);
+class PlayerType;
+void vary_item(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num);
+void inven_item_increase(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER num);
+void inven_item_optimize(PlayerType *player_ptr, INVENTORY_IDX item);
+void drop_from_inventory(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER amt);
+void combine_pack(PlayerType *player_ptr);
+void reorder_pack(PlayerType *player_ptr);
+int16_t store_item_to_inventory(PlayerType *player_ptr, object_type *o_ptr);
+bool check_store_item_to_inventory(PlayerType *player_ptr, const object_type *o_ptr);
+INVENTORY_IDX inven_takeoff(PlayerType *player_ptr, INVENTORY_IDX item, ITEM_NUMBER amt);
index be01fb6..082744d 100644 (file)
@@ -99,7 +99,7 @@ bool get_tag_floor(floor_type *floor_ptr, COMMAND_CODE *cp, char tag, FLOOR_IDX
  * Also, the tag "@xn" will work as well, where "n" is a any tag-char,\n
  * and "x" is the "current" command_cmd code.\n
  */
-bool get_tag(player_type *player_ptr, COMMAND_CODE *cp, char tag, BIT_FLAGS mode, const ItemTester& item_tester)
+bool get_tag(PlayerType *player_ptr, COMMAND_CODE *cp, char tag, BIT_FLAGS mode, const ItemTester& item_tester)
 {
     COMMAND_CODE start, end;
     switch (mode) {
@@ -167,7 +167,7 @@ bool get_tag(player_type *player_ptr, COMMAND_CODE *cp, char tag, BIT_FLAGS mode
  * @param i 選択アイテムID
  * @return 正規のIDならばTRUEを返す。
  */
-bool get_item_okay(player_type *player_ptr, OBJECT_IDX i, const ItemTester& item_tester)
+bool get_item_okay(PlayerType *player_ptr, OBJECT_IDX i, const ItemTester& item_tester)
 {
     if ((i < 0) || (i >= INVEN_TOTAL))
         return false;
@@ -186,7 +186,7 @@ bool get_item_okay(player_type *player_ptr, OBJECT_IDX i, const ItemTester& item
  * @details The item can be negative to mean "item on floor".
  * Hack -- allow user to "prevent" certain choices
  */
-bool get_item_allow(player_type *player_ptr, INVENTORY_IDX item)
+bool get_item_allow(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     if (!command_cmd)
         return true;
@@ -218,7 +218,7 @@ bool get_item_allow(player_type *player_ptr, INVENTORY_IDX item)
  * Convert a label into the index of a item in the "equip"
  * @return 対応するID。該当スロットにオブジェクトが存在しなかった場合-1を返す / Return "-1" if the label does not indicate a real item
  */
-INVENTORY_IDX label_to_equipment(player_type *player_ptr, int c)
+INVENTORY_IDX label_to_equipment(PlayerType *player_ptr, int c)
 {
     INVENTORY_IDX i = (INVENTORY_IDX)(islower(c) ? A2I(c) : -1) + INVEN_MAIN_HAND;
 
@@ -242,7 +242,7 @@ INVENTORY_IDX label_to_equipment(player_type *player_ptr, int c)
  * @return 対応するID。該当スロットにオブジェクトが存在しなかった場合-1を返す / Return "-1" if the label does not indicate a real item
  * @details Note that the label does NOT distinguish inven/equip.
  */
-INVENTORY_IDX label_to_inventory(player_type *player_ptr, int c)
+INVENTORY_IDX label_to_inventory(PlayerType *player_ptr, int c)
 {
     INVENTORY_IDX i = (INVENTORY_IDX)(islower(c) ? A2I(c) : -1);
 
@@ -261,7 +261,7 @@ INVENTORY_IDX label_to_inventory(player_type *player_ptr, int c)
  * @return 確認がYesならTRUEを返す。
  * @details The item can be negative to mean "item on floor".
  */
-bool verify(player_type *player_ptr, concptr prompt, INVENTORY_IDX item)
+bool verify(PlayerType *player_ptr, concptr prompt, INVENTORY_IDX item)
 {
     GAME_TEXT o_name[MAX_NLEN];
     char out_val[MAX_NLEN + 20];
@@ -283,7 +283,7 @@ bool verify(player_type *player_ptr, concptr prompt, INVENTORY_IDX item)
  * @param label ラベルリストを取得する文字列参照ポインタ
  * @param mode 所持品リストか装備品リストかの切り替え
  */
-void prepare_label_string(player_type *player_ptr, char *label, BIT_FLAGS mode, const ItemTester& item_tester)
+void prepare_label_string(PlayerType *player_ptr, char *label, BIT_FLAGS mode, const ItemTester& item_tester)
 {
     concptr alphabet_chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
     int offset = (mode == USE_EQUIP) ? INVEN_MAIN_HAND : 0;
index ce3f82e..fa10705 100644 (file)
@@ -4,14 +4,14 @@
 #include "system/angband.h"
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 class ItemTester;
 bool is_ring_slot(int i);
 bool get_tag_floor(floor_type *floor_ptr, COMMAND_CODE *cp, char tag, FLOOR_IDX floor_list[], ITEM_NUMBER floor_num);
-bool get_tag(player_type *player_ptr, COMMAND_CODE *cp, char tag, BIT_FLAGS mode, const ItemTester& item_tester);
-bool get_item_okay(player_type *player_ptr, OBJECT_IDX i, const ItemTester& item_tester);
-bool get_item_allow(player_type *player_ptr, INVENTORY_IDX item);
-INVENTORY_IDX label_to_equipment(player_type *player_ptr, int c);
-INVENTORY_IDX label_to_inventory(player_type *player_ptr, int c);
-bool verify(player_type *player_ptr, concptr prompt, INVENTORY_IDX item);
-void prepare_label_string(player_type *player_ptr, char *label, BIT_FLAGS mode, const ItemTester& item_tester);
+bool get_tag(PlayerType *player_ptr, COMMAND_CODE *cp, char tag, BIT_FLAGS mode, const ItemTester& item_tester);
+bool get_item_okay(PlayerType *player_ptr, OBJECT_IDX i, const ItemTester& item_tester);
+bool get_item_allow(PlayerType *player_ptr, INVENTORY_IDX item);
+INVENTORY_IDX label_to_equipment(PlayerType *player_ptr, int c);
+INVENTORY_IDX label_to_inventory(PlayerType *player_ptr, int c);
+bool verify(PlayerType *player_ptr, concptr prompt, INVENTORY_IDX item);
+void prepare_label_string(PlayerType *player_ptr, char *label, BIT_FLAGS mode, const ItemTester& item_tester);
index fc3b669..370ccc1 100644 (file)
@@ -51,7 +51,7 @@ static void check_item_selection_mode(item_selection_type *item_selection_ptr)
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す
  * @todo 適切な関数名をどうしても付けられなかったので暫定でauxとした
  */
-static bool check_item_tag_aux(player_type *player_ptr, item_selection_type *item_selection_ptr, const ItemTester& item_tester)
+static bool check_item_tag_aux(PlayerType *player_ptr, item_selection_type *item_selection_ptr, const ItemTester& item_tester)
 {
     if (!item_selection_ptr->floor || (*item_selection_ptr->cp >= 0))
         return false;
@@ -73,7 +73,7 @@ static bool check_item_tag_aux(player_type *player_ptr, item_selection_type *ite
  * @param prev_tag 前回選択したアイテムのタグ (のはず)
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す
  */
-static bool check_item_tag_inventory(player_type *player_ptr, item_selection_type *item_selection_ptr, char *prev_tag, const ItemTester& item_tester)
+static bool check_item_tag_inventory(PlayerType *player_ptr, item_selection_type *item_selection_ptr, char *prev_tag, const ItemTester& item_tester)
 {
     if ((!item_selection_ptr->inven || (*item_selection_ptr->cp < 0) || (*item_selection_ptr->cp >= INVEN_PACK))
         && (!item_selection_ptr->equip || (*item_selection_ptr->cp < INVEN_MAIN_HAND) || (*item_selection_ptr->cp >= INVEN_TOTAL)))
@@ -116,7 +116,7 @@ static bool check_item_tag_inventory(player_type *player_ptr, item_selection_typ
  * @param prev_tag 前回選択したアイテムのタグ (のはず)
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す
  */
-static bool check_item_tag(player_type *player_ptr, item_selection_type *item_selection_ptr, char *prev_tag, const ItemTester& item_tester)
+static bool check_item_tag(PlayerType *player_ptr, item_selection_type *item_selection_ptr, char *prev_tag, const ItemTester& item_tester)
 {
     if (!repeat_pull(item_selection_ptr->cp))
         return false;
@@ -137,7 +137,7 @@ static bool check_item_tag(player_type *player_ptr, item_selection_type *item_se
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fis_ptr アイテム選択への参照ポインタ
  */
-static void test_inventory(player_type *player_ptr, item_selection_type *item_selection_ptr, const ItemTester& item_tester)
+static void test_inventory(PlayerType *player_ptr, item_selection_type *item_selection_ptr, const ItemTester& item_tester)
 {
     if (!item_selection_ptr->inven) {
         item_selection_ptr->i2 = -1;
@@ -157,7 +157,7 @@ static void test_inventory(player_type *player_ptr, item_selection_type *item_se
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fis_ptr アイテム選択への参照ポインタ
  */
-static void test_equipment(player_type *player_ptr, item_selection_type *item_selection_ptr, const ItemTester& item_tester)
+static void test_equipment(PlayerType *player_ptr, item_selection_type *item_selection_ptr, const ItemTester& item_tester)
 {
     if (!item_selection_ptr->equip) {
         item_selection_ptr->e2 = -1;
@@ -187,7 +187,7 @@ static void test_equipment(player_type *player_ptr, item_selection_type *item_se
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す
  * Return TRUE only if an acceptable item was chosen by the user
  */
-bool get_item(player_type *player_ptr, OBJECT_IDX *cp, concptr pmt, concptr str, BIT_FLAGS mode, const ItemTester& item_tester)
+bool get_item(PlayerType *player_ptr, OBJECT_IDX *cp, concptr pmt, concptr str, BIT_FLAGS mode, const ItemTester& item_tester)
 {
     static char prev_tag = '\0';
     if (easy_floor || use_menu)
index c087f28..60f165a 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ItemTester;
-bool get_item(player_type *player_ptr, OBJECT_IDX *cp, concptr pmt, concptr str, BIT_FLAGS mode, const ItemTester& item_tester);
+bool get_item(PlayerType *player_ptr, OBJECT_IDX *cp, concptr pmt, concptr str, BIT_FLAGS mode, const ItemTester& item_tester);
index 4d9c6da..3cdb1e4 100644 (file)
@@ -14,7 +14,7 @@
 /*!
  * @brief アイテムの所持種類数が超えた場合にアイテムを床に落とす処理
  */
-void pack_overflow(player_type *player_ptr)
+void pack_overflow(PlayerType *player_ptr)
 {
     if (player_ptr->inventory_list[INVEN_PACK].k_idx == 0)
         return;
index 0709bca..8870728 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void pack_overflow(player_type *player_ptr);
+class PlayerType;
+void pack_overflow(PlayerType *player_ptr);
index 89fbe50..ebdf844 100644 (file)
@@ -44,7 +44,7 @@
  * @return アイテムを拾えるならばTRUEを返す。
  * @details assuming mode = (USE_EQUIP | USE_INVEN | USE_FLOOR).
  */
-bool can_get_item(player_type *player_ptr, const ItemTester& item_tester)
+bool can_get_item(PlayerType *player_ptr, const ItemTester& item_tester)
 {
     for (int j = 0; j < INVEN_TOTAL; j++)
         if (item_tester.okay(&player_ptr->inventory_list[j]))
@@ -59,7 +59,7 @@ bool can_get_item(player_type *player_ptr, const ItemTester& item_tester)
  * @brief 床上のアイテムを拾う選択用サブルーチン
  * @return プレイヤーによりアイテムが選択されたならTRUEを返す。
  */
-static bool py_pickup_floor_aux(player_type *player_ptr)
+static bool py_pickup_floor_aux(PlayerType *player_ptr)
 {
     OBJECT_IDX this_o_idx;
     OBJECT_IDX item;
@@ -80,7 +80,7 @@ static bool py_pickup_floor_aux(player_type *player_ptr)
  * @details
  * This is called by py_pickup() when easy_floor is TRUE.
  */
-void py_pickup_floor(player_type *player_ptr, bool pickup)
+void py_pickup_floor(PlayerType *player_ptr, bool pickup)
 {
     GAME_TEXT o_name[MAX_NLEN];
     object_type *o_ptr;
@@ -172,7 +172,7 @@ void py_pickup_floor(player_type *player_ptr, bool pickup)
  * Add the given dungeon object to the character's inventory.\n
  * Delete the object afterwards.\n
  */
-void describe_pickup_item(player_type *player_ptr, OBJECT_IDX o_idx)
+void describe_pickup_item(PlayerType *player_ptr, OBJECT_IDX o_idx)
 {
 #ifdef JP
     GAME_TEXT o_name[MAX_NLEN];
@@ -235,7 +235,7 @@ void describe_pickup_item(player_type *player_ptr, OBJECT_IDX o_idx)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pickup 自動拾い処理を行うならばTRUEとする
  */
-void carry(player_type *player_ptr, bool pickup)
+void carry(PlayerType *player_ptr, bool pickup)
 {
     verify_panel(player_ptr);
     player_ptr->update |= PU_MONSTERS;
index 596391f..d6e79ae 100644 (file)
@@ -3,9 +3,9 @@
 #include "object/tval-types.h"
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ItemTester;
-bool can_get_item(player_type *player_ptr, const ItemTester& item_tester);
-void py_pickup_floor(player_type *player_ptr, bool pickup);
-void describe_pickup_item(player_type *player_ptr, OBJECT_IDX o_idx);
-void carry(player_type *player_ptr, bool pickup);
+bool can_get_item(PlayerType *player_ptr, const ItemTester& item_tester);
+void py_pickup_floor(PlayerType *player_ptr, bool pickup);
+void describe_pickup_item(PlayerType *player_ptr, OBJECT_IDX o_idx);
+void carry(PlayerType *player_ptr, bool pickup);
index 25accef..b62f152 100644 (file)
@@ -19,7 +19,7 @@
  * If player has inscribed the object with "!!", let him know when it's recharged. -LM-
  * @param o_ptr 対象オブジェクトの構造体参照ポインタ
  */
-static void recharged_notice(player_type *player_ptr, object_type *o_ptr)
+static void recharged_notice(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (!o_ptr->inscription)
         return;
@@ -49,7 +49,7 @@ static void recharged_notice(player_type *player_ptr, object_type *o_ptr)
  * @brief 10ゲームターンが進行するごとに魔道具の自然充填を行う処理
  * / Handle recharging objects once every 10 game turns
  */
-void recharge_magic_items(player_type *player_ptr)
+void recharge_magic_items(PlayerType *player_ptr)
 {
     int i;
     bool changed;
index 6b53604..dbd54c8 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void recharge_magic_items(player_type *player_ptr);
+class PlayerType;
+void recharge_magic_items(PlayerType *player_ptr);
index 19037ab..a6007f4 100644 (file)
@@ -54,7 +54,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_pet(player_type *player_ptr, FILE *fff)
+static void dump_aux_pet(PlayerType *player_ptr, FILE *fff)
 {
     bool pet = false;
     bool pet_settings = false;
@@ -109,7 +109,7 @@ static void dump_aux_pet(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_quest(player_type *player_ptr, FILE *fff)
+static void dump_aux_quest(PlayerType *player_ptr, FILE *fff)
 {
     fprintf(fff, _("\n\n  [クエスト情報]\n", "\n\n  [Quest Information]\n"));
     std::vector<QUEST_IDX> quest_num(max_q_idx);
@@ -130,7 +130,7 @@ static void dump_aux_quest(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_last_message(player_type *player_ptr, FILE *fff)
+static void dump_aux_last_message(PlayerType *player_ptr, FILE *fff)
 {
     if (!player_ptr->is_dead)
         return;
@@ -234,7 +234,7 @@ static void dump_aux_options(FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_arena(player_type *player_ptr, FILE *fff)
+static void dump_aux_arena(PlayerType *player_ptr, FILE *fff)
 {
     if (lite_town || vanilla_town)
         return;
@@ -281,7 +281,7 @@ static void dump_aux_arena(player_type *player_ptr, FILE *fff)
  * @brief 撃破モンスターの情報をファイルにダンプする
  * @param fff ファイルポインタ
  */
-static void dump_aux_monsters(player_type *player_ptr, FILE *fff)
+static void dump_aux_monsters(PlayerType *player_ptr, FILE *fff)
 {
     fprintf(fff, _("\n  [倒したモンスター]\n\n", "\n  [Defeated Monsters]\n\n"));
 
@@ -360,7 +360,7 @@ static void dump_aux_monsters(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_race_history(player_type *player_ptr, FILE *fff)
+static void dump_aux_race_history(PlayerType *player_ptr, FILE *fff)
 {
     if (!player_ptr->old_race1 && !player_ptr->old_race2)
         return;
@@ -388,7 +388,7 @@ static void dump_aux_race_history(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_realm_history(player_type *player_ptr, FILE *fff)
+static void dump_aux_realm_history(PlayerType *player_ptr, FILE *fff)
 {
     if (player_ptr->old_realm == 0)
         return;
@@ -408,7 +408,7 @@ static void dump_aux_realm_history(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_virtues(player_type *player_ptr, FILE *fff)
+static void dump_aux_virtues(PlayerType *player_ptr, FILE *fff)
 {
     fprintf(fff, _("\n\n  [自分に関する情報]\n\n", "\n\n  [HP-rate & Max stat & Virtues]\n\n"));
 
@@ -445,7 +445,7 @@ static void dump_aux_virtues(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_mutations(player_type *player_ptr, FILE *fff)
+static void dump_aux_mutations(PlayerType *player_ptr, FILE *fff)
 {
     if (player_ptr->muta.any()) {
         fprintf(fff, _("\n\n  [突然変異]\n\n", "\n\n  [Mutations]\n\n"));
@@ -458,7 +458,7 @@ static void dump_aux_mutations(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_aux_equipment_inventory(player_type *player_ptr, FILE *fff)
+static void dump_aux_equipment_inventory(PlayerType *player_ptr, FILE *fff)
 {
     GAME_TEXT o_name[MAX_NLEN];
     if (player_ptr->equip_cnt) {
@@ -490,7 +490,7 @@ static void dump_aux_equipment_inventory(player_type *player_ptr, FILE *fff)
  * @brief 我が家と博物館のオブジェクト情報をファイルにダンプする
  * @param fff ファイルポインタ
  */
-static void dump_aux_home_museum(player_type *player_ptr, FILE *fff)
+static void dump_aux_home_museum(PlayerType *player_ptr, FILE *fff)
 {
     store_type *store_ptr;
     store_ptr = &town_info[1].store[enum2i(StoreSaleType::HOME)];
@@ -552,7 +552,7 @@ static concptr get_check_sum(void)
  * @param fff ファイルポインタ
  * @return エラーコード
  */
-void make_character_dump(player_type *player_ptr, FILE *fff, display_player_pf display_player)
+void make_character_dump(PlayerType *player_ptr, FILE *fff, display_player_pf display_player)
 {
     char title[127];
     put_version(title);
index 7c1331d..373eb35 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "io/files-util.h"
 
-struct player_type;
-void make_character_dump(player_type *player_ptr, FILE *fff, display_player_pf display_player);
+class PlayerType;
+void make_character_dump(PlayerType *player_ptr, FILE *fff, display_player_pf display_player);
index 301573a..fffbbe3 100644 (file)
@@ -11,7 +11,7 @@
  * @param change_color バッファへ詰める文字の変更有無
  */
 static void dump_player_status_with_screen_num(
-       player_type *player_ptr, FILE *fff, display_player_pf display_player,
+       PlayerType *player_ptr, FILE *fff, display_player_pf display_player,
        int screen_num, TERM_LEN start_y, TERM_LEN end_y, bool change_color)
 {
        TERM_COLOR a;
@@ -51,7 +51,7 @@ static void dump_player_status_with_screen_num(
  * @param fff ファイルポインタ
  * @param display_player 画面表示へのコールバック
  */
-void dump_aux_player_status(player_type *player_ptr, FILE *fff, display_player_pf display_player)
+void dump_aux_player_status(PlayerType *player_ptr, FILE *fff, display_player_pf display_player)
 {
        dump_player_status_with_screen_num(player_ptr, fff, display_player, 0, 1, 22, false);
        dump_player_status_with_screen_num(player_ptr, fff, display_player, 1, 10, 19, false);
index b5c4346..9cffe65 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "io/files-util.h"
 
-struct player_type;
-void dump_aux_player_status(player_type *player_ptr, FILE *fff, display_player_pf display_player);
+class PlayerType;
+void dump_aux_player_status(PlayerType *player_ptr, FILE *fff, display_player_pf display_player);
index 58765a5..1edf873 100644 (file)
@@ -52,7 +52,7 @@ static void spoiler_print_randart(object_type *o_ptr, obj_desc_list *art_ptr)
  * @param o_ptr ランダムアーティファクトのオブジェクト構造体参照ポインタ
  * @param tval 出力したいランダムアーティファクトの種類
  */
-static void spoil_random_artifact_aux(player_type *player_ptr, object_type *o_ptr, ItemKindType tval)
+static void spoil_random_artifact_aux(PlayerType *player_ptr, object_type *o_ptr, ItemKindType tval)
 {
     obj_desc_list artifact;
     if (!o_ptr->is_known() || !o_ptr->art_name || o_ptr->tval != tval)
@@ -67,7 +67,7 @@ static void spoil_random_artifact_aux(player_type *player_ptr, object_type *o_pt
  * Create a list file for random artifacts
  * @param fname 出力ファイル名
  */
-void spoil_random_artifact(player_type *player_ptr, concptr fname)
+void spoil_random_artifact(PlayerType *player_ptr, concptr fname)
 {
     store_type *store_ptr;
     object_type *q_ptr;
index cd79127..7d49fe4 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void spoil_random_artifact(player_type *player_ptr, concptr fname);
+class PlayerType;
+void spoil_random_artifact(PlayerType *player_ptr, concptr fname);
index 8321c62..ca4f7c7 100644 (file)
@@ -34,7 +34,7 @@ typedef struct {
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_magic_eater(player_type *player_ptr, FILE *fff)
+static void dump_magic_eater(PlayerType *player_ptr, FILE *fff)
 {
     auto magic_eater_data = PlayerClass(player_ptr).get_specific_data<magic_eater_data_type>();
     if (!magic_eater_data) {
@@ -98,7 +98,7 @@ static void dump_magic_eater(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_smith(player_type *player_ptr, FILE *fff)
+static void dump_smith(PlayerType *player_ptr, FILE *fff)
 {
     fprintf(fff, _("\n\n  [手に入れたエッセンス]\n\n", "\n\n  [Get Essence]\n\n"));
     fprintf(fff, _("エッセンス   個数     エッセンス   個数     エッセンス   個数", "Essence      Num      Essence      Num      Essence      Num "));
@@ -161,7 +161,7 @@ static void add_monster_spell_type(char p[][80], int col, BlueMagicType SpellPro
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_blue_mage(player_type *player_ptr, FILE *fff)
+static void dump_blue_mage(PlayerType *player_ptr, FILE *fff)
 {
     const auto bluemage_data = PlayerClass(player_ptr).get_specific_data<bluemage_data_type>();
     if (!bluemage_data) {
@@ -228,7 +228,7 @@ static void dump_blue_mage(player_type *player_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-void dump_aux_class_special(player_type *player_ptr, FILE *fff)
+void dump_aux_class_special(PlayerType *player_ptr, FILE *fff)
 {
     switch (player_ptr->pclass) {
     case PlayerClassType::MAGIC_EATER: {
index 27a8147..76bb44e 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void dump_aux_class_special(player_type *player_ptr, FILE *fff);
+class PlayerType;
+void dump_aux_class_special(PlayerType *player_ptr, FILE *fff);
index b782e06..ca8b9a7 100644 (file)
@@ -35,7 +35,7 @@ void move_cursor_relative(int row, int col)
  * @param y 目標地点のY座標
  * @param x 目標地点のX座標
  */
-void print_path(player_type *player_ptr, POSITION y, POSITION x)
+void print_path(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     uint16_t path_g[512];
     byte default_color = TERM_SLATE;
@@ -101,7 +101,7 @@ void print_path(player_type *player_ptr, POSITION y, POSITION x)
  * Also used in do_cmd_locate
  * @return 実際に再描画が必要だった場合TRUEを返す
  */
-bool change_panel(player_type *player_ptr, POSITION dy, POSITION dx)
+bool change_panel(PlayerType *player_ptr, POSITION dy, POSITION dx)
 {
     TERM_LEN wid, hgt;
     get_screen_size(&wid, &hgt);
index 63808f2..dda9406 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 void move_cursor_relative(int row, int col);
-void print_path(player_type *player_ptr, POSITION y, POSITION x);
-bool change_panel(player_type *player_ptr, POSITION dy, POSITION dx);
+void print_path(PlayerType *player_ptr, POSITION y, POSITION x);
+bool change_panel(PlayerType *player_ptr, POSITION dy, POSITION dx);
 void panel_bounds_center(void);
index 44cf096..d743ecd 100644 (file)
@@ -24,7 +24,7 @@
  * This routine is called only in very rare situations, and only
  * by certain visual systems, when they experience fatal errors.
  */
-void exit_game_panic(player_type *player_ptr)
+void exit_game_panic(PlayerType *player_ptr)
 {
        if (!w_ptr->character_generated || w_ptr->character_saved)
                quit(_("緊急事態", "panic"));
index 8c41b01..7d7f0b4 100644 (file)
@@ -5,5 +5,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void exit_game_panic(player_type *player_ptr);
+class PlayerType;
+void exit_game_panic(PlayerType *player_ptr);
index 4d6f893..025ca16 100644 (file)
@@ -57,7 +57,7 @@ char debug_savefile[1024];
  * Allow the "full" flag to dump additional info,
  * and trigger its usage from various places in the code.
  */
-errr file_character(player_type *player_ptr, concptr name, display_player_pf display_player)
+errr file_character(PlayerType *player_ptr, concptr name, display_player_pf display_player)
 {
     char buf[1024];
     path_build(buf, sizeof(buf), ANGBAND_DIR_USER, name);
@@ -201,7 +201,7 @@ errr get_rnd_line_jonly(concptr file_name, int entry, char *output, int count)
  * @return エラーコード
  * @details
  */
-static errr counts_seek(player_type *player_ptr, int fd, uint32_t where, bool flag)
+static errr counts_seek(PlayerType *player_ptr, int fd, uint32_t where, bool flag)
 {
     char temp1[128], temp2[128];
     auto short_pclass = enum2i(player_ptr->pclass);
@@ -244,7 +244,7 @@ static errr counts_seek(player_type *player_ptr, int fd, uint32_t where, bool fl
  * @return エラーコード
  * @details
  */
-uint32_t counts_read(player_type *player_ptr, int where)
+uint32_t counts_read(PlayerType *player_ptr, int where)
 {
     char buf[1024];
     path_build(buf, sizeof(buf), ANGBAND_DIR_DATA, _("z_info_j.raw", "z_info.raw"));
@@ -267,7 +267,7 @@ uint32_t counts_read(player_type *player_ptr, int where)
  * @return エラーコード
  * @details
  */
-errr counts_write(player_type *player_ptr, int where, uint32_t count)
+errr counts_write(PlayerType *player_ptr, int where, uint32_t count)
 {
     char buf[1024];
     path_build(buf, sizeof(buf), ANGBAND_DIR_DATA, _("z_info_j.raw", "z_info.raw"));
index 8c7e5c4..0720888 100644 (file)
@@ -21,16 +21,16 @@ extern concptr ANGBAND_DIR_DEBUG_SAVE;
 extern concptr ANGBAND_DIR_USER;
 extern concptr ANGBAND_DIR_XTRA;
 
-struct player_type;
-typedef void (*display_player_pf)(player_type *, int);
+class PlayerType;
+typedef void (*display_player_pf)(PlayerType *, int);
 typedef void(*update_playtime_pf)(void);
 
-extern errr file_character(player_type *player_ptr, concptr name, display_player_pf display_player);
+extern errr file_character(PlayerType *player_ptr, concptr name, display_player_pf display_player);
 extern errr get_rnd_line(concptr file_name, int entry, char *output);
 void read_dead_file(char* buf, size_t buf_size);
 
 #ifdef JP
 extern errr get_rnd_line_jonly(concptr file_name, int entry, char *output, int count);
 #endif
-extern errr counts_write(player_type *player_ptr, int where, uint32_t count);
-extern uint32_t counts_read(player_type *player_ptr, int where);
+extern errr counts_write(PlayerType *player_ptr, int where, uint32_t count);
+extern uint32_t counts_read(PlayerType *player_ptr, int where);
index 45fdb2d..a1675a9 100644 (file)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 実際にデバッグコマンドへ移行したらTRUEを返す。
  */
-static bool enter_debug_mode(player_type *player_ptr)
+static bool enter_debug_mode(PlayerType *player_ptr)
 {
     if (!w_ptr->noscore) {
         if (!allow_debug_options) {
@@ -130,7 +130,7 @@ static bool enter_debug_mode(player_type *player_ptr)
  * / Parse and execute the current command Give "Warning" on illegal commands.
  * @todo Make some "blocks"
  */
-void process_command(player_type *player_ptr)
+void process_command(PlayerType *player_ptr)
 {
     COMMAND_CODE old_now_message = now_message;
     repeat_check();
index 3d296d7..bf318f5 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void process_command(player_type* player_ptr);
+class PlayerType;
+void process_command(PlayerType* player_ptr);
index 0aa3b26..6362cfc 100644 (file)
@@ -46,7 +46,7 @@ int16_t command_new; /* Command chaining from inven/equip view */
  */
 static char request_command_buffer[256];
 
-static char inkey_from_menu(player_type *player_ptr)
+static char inkey_from_menu(PlayerType *player_ptr)
 {
     char cmd;
     int basey, basex;
@@ -189,7 +189,7 @@ static char inkey_from_menu(player_type *player_ptr)
  *
  * Note that "player_ptr->command_new" may not work any more.
  */
-void request_command(player_type *player_ptr, int shopping)
+void request_command(PlayerType *player_ptr, int shopping)
 {
     int16_t cmd;
     int mode;
index 6959600..dc4dd0e 100644 (file)
@@ -16,5 +16,5 @@ extern TERM_LEN command_gap;
 extern int16_t command_wrk;
 extern int16_t command_new;
 
-struct player_type;
-void request_command(player_type *player_ptr, int shopping);
+class PlayerType;
+void request_command(PlayerType *player_ptr, int shopping);
index 90bd894..20c494d 100644 (file)
@@ -291,7 +291,7 @@ static errr interpret_v_token(char *buf)
  * Process "X:<str>" -- turn option off
  * Process "Y:<str>" -- turn option on
  */
-static errr interpret_xy_token(player_type *player_ptr, char *buf)
+static errr interpret_xy_token(PlayerType *player_ptr, char *buf)
 {
     for (int i = 0; option_info[i].o_desc; i++) {
         bool is_option = option_info[i].o_var != nullptr;
@@ -470,7 +470,7 @@ static errr interpret_t_token(char *buf)
  * used for the "nothing" attr/char.
  * </pre>
  */
-errr interpret_pref_file(player_type *player_ptr, char *buf)
+errr interpret_pref_file(PlayerType *player_ptr, char *buf)
 {
     if (buf[1] != ':')
         return 1;
index df79a02..0fc5f65 100644 (file)
@@ -6,6 +6,6 @@
 
 extern char *histpref_buf;
 
-struct player_type;
-errr interpret_pref_file(player_type *player_ptr, char *buf);
+class PlayerType;
+errr interpret_pref_file(PlayerType *player_ptr, char *buf);
 void add_history_from_pref_line(concptr t);
index 39c7810..eb8c201 100644 (file)
@@ -13,7 +13,7 @@
  * @brief ファイルポインタを通じて突然変異の一覧を出力する
  * @param out_file 出力先ファイルポインタ
  */
-void dump_mutations(player_type *player_ptr, FILE *out_file)
+void dump_mutations(PlayerType *player_ptr, FILE *out_file)
 {
     if (!out_file)
         return;
index f6861b4..887e166 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void dump_mutations(player_type *player_ptr, FILE *out_file);
+class PlayerType;
+void dump_mutations(PlayerType *player_ptr, FILE *out_file);
index 7f2a2fb..2b12a37 100644 (file)
@@ -24,7 +24,7 @@
  *   result
  * </pre>
  */
-concptr process_pref_file_expr(player_type *player_ptr, char **sp, char *fp)
+concptr process_pref_file_expr(PlayerType *player_ptr, char **sp, char *fp)
 {
     char *s;
     s = (*sp);
index ba7b135..82311bf 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-concptr process_pref_file_expr(player_type *player_ptr, char **sp, char *fp);
+class PlayerType;
+concptr process_pref_file_expr(PlayerType *player_ptr, char **sp, char *fp);
 
index cf18bba..1148f88 100644 (file)
@@ -54,7 +54,7 @@ static int auto_dump_line_num;
  * @return エラーコード
  * @todo 関数名を変更する
  */
-static errr process_pref_file_aux(player_type *player_ptr, concptr name, int preftype)
+static errr process_pref_file_aux(PlayerType *player_ptr, concptr name, int preftype)
 {
     FILE *fp;
     fp = angband_fopen(name, "r");
@@ -153,7 +153,7 @@ static errr process_pref_file_aux(player_type *player_ptr, concptr name, int pre
  * allow conditional evaluation and filename inclusion.
  * </pre>
  */
-errr process_pref_file(player_type *player_ptr, concptr name, bool only_user_dir)
+errr process_pref_file(PlayerType *player_ptr, concptr name, bool only_user_dir)
 {
     char buf[1024];
     errr err1 = 0;
@@ -179,7 +179,7 @@ errr process_pref_file(player_type *player_ptr, concptr name, bool only_user_dir
  * @param name ファイル名
  * @details
  */
-errr process_autopick_file(player_type *player_ptr, concptr name)
+errr process_autopick_file(PlayerType *player_ptr, concptr name)
 {
     char buf[1024];
     path_build(buf, sizeof(buf), ANGBAND_DIR_USER, name);
@@ -195,7 +195,7 @@ errr process_autopick_file(player_type *player_ptr, concptr name)
  * @return エラーコード
  * @details
  */
-errr process_histpref_file(player_type *player_ptr, concptr name)
+errr process_histpref_file(PlayerType *player_ptr, concptr name)
 {
     bool old_character_xtra = w_ptr->character_xtra;
     char buf[1024];
@@ -278,7 +278,7 @@ void close_auto_dump(FILE **fpp, concptr auto_dump_mark)
  * Modified by Arcum Dagsson to support
  * separate macro files for different realms.
  */
-void load_all_pref_files(player_type *player_ptr)
+void load_all_pref_files(PlayerType *player_ptr)
 {
     char buf[1024];
     sprintf(buf, "user.prf");
@@ -307,7 +307,7 @@ void load_all_pref_files(player_type *player_ptr)
 /*!
  * @brief 生い立ちメッセージをファイルからロードする。
  */
-bool read_histpref(player_type *player_ptr)
+bool read_histpref(PlayerType *player_ptr)
 {
     char buf[80];
     errr err;
index b12bceb..00ae6a6 100644 (file)
@@ -5,14 +5,14 @@
 extern char auto_dump_header[];
 extern char auto_dump_footer[];
 
-struct player_type;
-errr process_pref_file(player_type *player_ptr, concptr name, bool only_user_dir = false);
-errr process_autopick_file(player_type *player_ptr, concptr name);
-errr process_histpref_file(player_type *player_ptr, concptr name);
-bool read_histpref(player_type *player_ptr);
+class PlayerType;
+errr process_pref_file(PlayerType *player_ptr, concptr name, bool only_user_dir = false);
+errr process_autopick_file(PlayerType *player_ptr, concptr name);
+errr process_histpref_file(PlayerType *player_ptr, concptr name);
+bool read_histpref(PlayerType *player_ptr);
 
 void auto_dump_printf(FILE *auto_dump_stream, concptr fmt, ...);
 bool open_auto_dump(FILE **fpp, concptr buf, concptr mark);
 void close_auto_dump(FILE **fpp, concptr auto_dump_mark);
 
-void load_all_pref_files(player_type* player_ptr);
+void load_all_pref_files(PlayerType* player_ptr);
index fdcef1e..517de47 100644 (file)
@@ -268,7 +268,7 @@ void prepare_chuukei_hooks(void)
 /*
  * Prepare z-term hooks to call send_*_to_chuukei_server()'s
  */
-void prepare_movie_hooks(player_type *player_ptr)
+void prepare_movie_hooks(PlayerType *player_ptr)
 {
     char buf[1024];
     char tmp[80];
index 1fccbaa..c079162 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void prepare_movie_hooks(player_type *player_ptr);
+class PlayerType;
+void prepare_movie_hooks(PlayerType *player_ptr);
 void prepare_browse_movie_without_path_build(concptr filename);
 void browse_movie(void);
 #ifndef WINDOWS
index 476d4dc..6895ddb 100644 (file)
@@ -235,7 +235,7 @@ static bool http_post(concptr url, BUF *buf)
  * @param dumpbuf 伝送内容バッファ
  * @return エラーコード
  */
-static errr make_dump(player_type *player_ptr, BUF *dumpbuf, display_player_pf display_player)
+static errr make_dump(PlayerType *player_ptr, BUF *dumpbuf, display_player_pf display_player)
 {
     char buf[1024];
     FILE *fff;
@@ -274,7 +274,7 @@ static errr make_dump(player_type *player_ptr, BUF *dumpbuf, display_player_pf d
  * @brief スクリーンダンプを作成する/ Make screen dump to buffer
  * @return 作成したスクリーンダンプの参照ポインタ
  */
-concptr make_screen_dump(player_type *player_ptr)
+concptr make_screen_dump(PlayerType *player_ptr)
 {
     static concptr html_head[] = {
         "<html>\n<body text=\"#ffffff\" bgcolor=\"#000000\">\n",
@@ -403,7 +403,7 @@ concptr make_screen_dump(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 正常にスコアを送信できたらtrue、失敗時に送信を中止したらfalse
  */
-bool report_score(player_type *player_ptr, display_player_pf display_player)
+bool report_score(PlayerType *player_ptr, display_player_pf display_player)
 {
     auto *score = buf_new();
     char personality_desc[128];
index bdc8c71..9563d88 100644 (file)
@@ -7,7 +7,7 @@ extern concptr screen_dump;
 #ifdef WORLD_SCORE
 #include "io/files-util.h"
 
-struct player_type;
-bool report_score(player_type *player_ptr, display_player_pf display_player);
-concptr make_screen_dump(player_type *player_ptr);
+class PlayerType;
+bool report_score(PlayerType *player_ptr, display_player_pf display_player);
+concptr make_screen_dump(PlayerType *player_ptr);
 #endif
index 3ac8f96..d80cec4 100644 (file)
@@ -41,7 +41,7 @@
 /*!
  * @brief コンソールのリサイズに合わせてマップを再描画する /
  * Map resizing whenever the main term changes size
- * @todo ここにplayer_type を追加するとz-termに影響が行くので保留
+ * @todo ここにPlayerType を追加するとz-termに影響が行くので保留
  */
 void resize_map()
 {
index de7b365..0ec3d68 100644 (file)
@@ -58,7 +58,7 @@ static void handle_signal_suspend(int sig)
  * To prevent messy accidents, we should reset this global variable
  * whenever the user enters a keypress, or something like that.
  * </pre>
- * @todo ここにplayer_typeを追加すると関数ポインタ周りの収拾がつかなくなるので保留
+ * @todo ここにPlayerTypeを追加すると関数ポインタ周りの収拾がつかなくなるので保留
  */
 static void handle_signal_simple(int sig)
 {
index 0b342e0..aae37fa 100644 (file)
@@ -38,7 +38,7 @@ void safe_setuid_drop(void)
 /*!
  * @brief ファイルのグラブパーミッションチェック / Hack -- grab permissions
  */
-void safe_setuid_grab(player_type *player_ptr)
+void safe_setuid_grab(PlayerType *player_ptr)
 {
 #ifdef SET_UID
 #ifdef SAFE_SETUID
index 33d0920..daab892 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 void safe_setuid_drop(void);
-void safe_setuid_grab(player_type *player_ptr);
+void safe_setuid_grab(PlayerType *player_ptr);
index 50eb558..beb9969 100644 (file)
@@ -72,7 +72,7 @@ static bool open_diary_file(FILE **fff, bool *disable_diary)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return クエストID
  */
-static QUEST_IDX write_floor(player_type *player_ptr, concptr *note_level, char *note_level_buf)
+static QUEST_IDX write_floor(PlayerType *player_ptr, concptr *note_level, char *note_level_buf)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     QUEST_IDX q_idx = quest_number(player_ptr, floor_ptr->dun_level);
@@ -165,7 +165,7 @@ static void write_diary_pet(FILE *fff, int num, concptr note)
  * @param note 日記内容のIDに応じた文字列参照ポインタ
  * @return エラーコード
  */
-errr exe_write_diary(player_type *player_ptr, int type, int num, concptr note)
+errr exe_write_diary(PlayerType *player_ptr, int type, int num, concptr note)
 {
     static bool disable_diary = false;
 
index f29e787..0f2f59b 100644 (file)
@@ -46,9 +46,9 @@
 
 extern bool write_level;
 
-struct player_type;
+class PlayerType;
 #ifdef JP
 #else
 concptr get_ordinal_number_suffix(int num);
 #endif
-errr exe_write_diary(player_type *player_ptr, int type, int num, concptr note);
+errr exe_write_diary(PlayerType *player_ptr, int type, int num, concptr note);
index 430569d..4670d34 100644 (file)
@@ -19,7 +19,7 @@
  * @brief 自動拾い設定ファイルをロードするコマンドのメインルーチン /
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_reload_autopick(player_type *player_ptr)
+void do_cmd_reload_autopick(PlayerType *player_ptr)
 {
     if (!get_check(_("自動拾い設定ファイルをロードしますか? ", "Reload auto-pick preference file? ")))
         return;
@@ -30,7 +30,7 @@ void do_cmd_reload_autopick(player_type *player_ptr)
 /*
  * Check the status of "autopick"
  */
-void do_cmd_knowledge_autopick(player_type *player_ptr)
+void do_cmd_knowledge_autopick(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
index bcace0d..58a0af1 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void do_cmd_reload_autopick(player_type *player_ptr);
-void do_cmd_knowledge_autopick(player_type *player_ptr);
+class PlayerType;
+void do_cmd_reload_autopick(PlayerType *player_ptr);
+void do_cmd_knowledge_autopick(PlayerType *player_ptr);
index da86d11..0cd8a64 100644 (file)
@@ -24,7 +24,7 @@
 /*
  * Display weapon-exp
  */
-void do_cmd_knowledge_weapon_exp(player_type *player_ptr)
+void do_cmd_knowledge_weapon_exp(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
@@ -69,7 +69,7 @@ void do_cmd_knowledge_weapon_exp(player_type *player_ptr)
  * @brief 魔法の経験値を表示するコマンドのメインルーチン
  * Display spell-exp
  */
-void do_cmd_knowledge_spell_exp(player_type *player_ptr)
+void do_cmd_knowledge_spell_exp(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
@@ -149,7 +149,7 @@ void do_cmd_knowledge_spell_exp(player_type *player_ptr)
  * @brief スキル情報を表示するコマンドのメインルーチン /
  * Display skill-exp
  */
-void do_cmd_knowledge_skill_exp(player_type *player_ptr)
+void do_cmd_knowledge_skill_exp(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     char file_name[FILE_NAME_SIZE];
index 3259a55..a97e8f4 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void do_cmd_knowledge_weapon_exp(player_type *player_ptr);
-void do_cmd_knowledge_spell_exp(player_type *player_ptr);
-void do_cmd_knowledge_skill_exp(player_type *player_ptr);
+class PlayerType;
+void do_cmd_knowledge_weapon_exp(PlayerType *player_ptr);
+void do_cmd_knowledge_spell_exp(PlayerType *player_ptr);
+void do_cmd_knowledge_skill_exp(PlayerType *player_ptr);
index f43a1aa..c4ce053 100644 (file)
@@ -337,7 +337,7 @@ void do_cmd_knowledge_features(bool *need_redraw, bool visual_only, IDX direct_f
 /*
  * Dungeon
  */
-void do_cmd_knowledge_dungeon(player_type *player_ptr)
+void do_cmd_knowledge_dungeon(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
index 8d1b97f..7bcad5d 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 void do_cmd_knowledge_features(bool *need_redraw, bool visual_only, IDX direct_f_idx, IDX *lighting_level);
-void do_cmd_knowledge_dungeon(player_type *player_ptr);
+void do_cmd_knowledge_dungeon(PlayerType *player_ptr);
index a80670e..ff6ff0c 100644 (file)
@@ -140,7 +140,7 @@ static void display_identified_resistances_flag(object_type *o_ptr, FILE *fff)
  * @param o_ptr アイテムへの参照ポインタ
  * @param where アイテムの場所 (手持ち、家等) を示す文字列への参照ポインタ
  */
-static void do_cmd_knowledge_inventory_aux(player_type *player_ptr, FILE *fff, object_type *o_ptr, char *where)
+static void do_cmd_knowledge_inventory_aux(PlayerType *player_ptr, FILE *fff, object_type *o_ptr, char *where)
 {
     int i = 0;
     GAME_TEXT o_name[MAX_NLEN];
@@ -211,7 +211,7 @@ static void reset_label_number(int *label_number, FILE *fff)
  * @param label_number 現在の行数
  * @param fff ファイルへの参照ポインタ
  */
-static void show_wearing_equipment_resistances(player_type *player_ptr, ItemKindType tval, int *label_number, FILE *fff)
+static void show_wearing_equipment_resistances(PlayerType *player_ptr, ItemKindType tval, int *label_number, FILE *fff)
 {
     char where[32];
     strcpy(where, _("装", "E "));
@@ -232,7 +232,7 @@ static void show_wearing_equipment_resistances(player_type *player_ptr, ItemKind
  * @param label_number 現在の行数
  * @param fff ファイルへの参照ポインタ
  */
-static void show_holding_equipment_resistances(player_type *player_ptr, ItemKindType tval, int *label_number, FILE *fff)
+static void show_holding_equipment_resistances(PlayerType *player_ptr, ItemKindType tval, int *label_number, FILE *fff)
 {
     char where[32];
     strcpy(where, _("持", "I "));
@@ -253,7 +253,7 @@ static void show_holding_equipment_resistances(player_type *player_ptr, ItemKind
  * @param label_number 現在の行数
  * @param fff ファイルへの参照ポインタ
  */
-static void show_home_equipment_resistances(player_type *player_ptr, ItemKindType tval, int *label_number, FILE *fff)
+static void show_home_equipment_resistances(PlayerType *player_ptr, ItemKindType tval, int *label_number, FILE *fff)
 {
     store_type *store_ptr;
     store_ptr = &town_info[1].store[enum2i(StoreSaleType::HOME)];
@@ -273,7 +273,7 @@ static void show_home_equipment_resistances(player_type *player_ptr, ItemKindTyp
  * @brief Display *ID* ed weapons/armors's resistances
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_knowledge_inventory(player_type *player_ptr)
+void do_cmd_knowledge_inventory(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
index 72ddcb0..791a8e0 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_knowledge_inventory(player_type *player_ptr);
+class PlayerType;
+void do_cmd_knowledge_inventory(PlayerType *player_ptr);
index 588d554..e220993 100644 (file)
@@ -39,7 +39,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @todo okay = 既知のアーティファクト? と思われるが確証がない分かりやすい変数名へ変更求む&万が一未知である旨の配列なら負論理なのでゴソッと差し替えるべき
  */
-void do_cmd_knowledge_artifacts(player_type *player_ptr)
+void do_cmd_knowledge_artifacts(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
@@ -215,7 +215,7 @@ static void display_object_list(int col, int row, int per_page, IDX object_idx[]
 /*
  * Describe fake object
  */
-static void desc_obj_fake(player_type *player_ptr, KIND_OBJECT_IDX k_idx)
+static void desc_obj_fake(PlayerType *player_ptr, KIND_OBJECT_IDX k_idx)
 {
     object_type *o_ptr;
     object_type object_type_body;
@@ -236,7 +236,7 @@ static void desc_obj_fake(player_type *player_ptr, KIND_OBJECT_IDX k_idx)
 /**
  * @brief Display known objects
  */
-void do_cmd_knowledge_objects(player_type *player_ptr, bool *need_redraw, bool visual_only, KIND_OBJECT_IDX direct_k_idx)
+void do_cmd_knowledge_objects(PlayerType *player_ptr, bool *need_redraw, bool visual_only, KIND_OBJECT_IDX direct_k_idx)
 {
     KIND_OBJECT_IDX object_old, object_top;
     KIND_OBJECT_IDX grp_idx[100];
index 9bf936f..59b5e43 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void do_cmd_knowledge_artifacts(player_type *player_ptr);
-void do_cmd_knowledge_objects(player_type *player_ptr, bool *need_redraw, bool visual_only, KIND_OBJECT_IDX direct_k_idx);
+class PlayerType;
+void do_cmd_knowledge_artifacts(PlayerType *player_ptr);
+void do_cmd_knowledge_objects(PlayerType *player_ptr, bool *need_redraw, bool visual_only, KIND_OBJECT_IDX direct_k_idx);
index 4c8f015..15bf301 100644 (file)
@@ -50,7 +50,7 @@
  * @param mode 思い出の扱いに関するモード
  * @return 得られたモンスターIDの数 / The number of monsters in the group
  */
-static IDX collect_monsters(player_type *player_ptr, IDX grp_cur, IDX mon_idx[], monster_lore_mode mode)
+static IDX collect_monsters(PlayerType *player_ptr, IDX grp_cur, IDX mon_idx[], monster_lore_mode mode)
 {
     concptr group_char = monster_group_char[grp_cur];
     bool grp_unique = (monster_group_char[grp_cur] == (char *)-1L);
@@ -109,7 +109,7 @@ static IDX collect_monsters(player_type *player_ptr, IDX grp_cur, IDX mon_idx[],
  * Display current pets
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_knowledge_pets(player_type *player_ptr)
+void do_cmd_knowledge_pets(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
@@ -150,7 +150,7 @@ void do_cmd_knowledge_pets(player_type *player_ptr)
  * Total kill count
  * @note the player ghosts are ignored.
  */
-void do_cmd_knowledge_kill_count(player_type *player_ptr)
+void do_cmd_knowledge_kill_count(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
@@ -286,7 +286,7 @@ static void display_monster_list(int col, int row, int per_page, int16_t mon_idx
  * @param direct_r_idx モンスターID
  * @todo 引数の詳細について加筆求む
  */
-void do_cmd_knowledge_monsters(player_type *player_ptr, bool *need_redraw, bool visual_only, IDX direct_r_idx)
+void do_cmd_knowledge_monsters(PlayerType *player_ptr, bool *need_redraw, bool visual_only, IDX direct_r_idx)
 {
     TERM_LEN wid, hgt;
     term_get_size(&wid, &hgt);
@@ -463,7 +463,7 @@ void do_cmd_knowledge_monsters(player_type *player_ptr, bool *need_redraw, bool
  * List wanted monsters
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_knowledge_bounty(player_type *player_ptr)
+void do_cmd_knowledge_bounty(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
index 63937db..a76bd1a 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void do_cmd_knowledge_monsters(player_type *player_ptr, bool *need_redraw, bool visual_only, IDX direct_r_idx);
-void do_cmd_knowledge_pets(player_type *player_ptr);
-void do_cmd_knowledge_kill_count(player_type *player_ptr);
-void do_cmd_knowledge_bounty(player_type *player_ptr);
+class PlayerType;
+void do_cmd_knowledge_monsters(PlayerType *player_ptr, bool *need_redraw, bool visual_only, IDX direct_r_idx);
+void do_cmd_knowledge_pets(PlayerType *player_ptr);
+void do_cmd_knowledge_kill_count(PlayerType *player_ptr);
+void do_cmd_knowledge_bounty(PlayerType *player_ptr);
index f509b5a..f7f7254 100644 (file)
@@ -13,7 +13,7 @@
 /*!
  * @brief 突然変異表示コマンドの実装 / List mutations we have...
  */
-void do_cmd_knowledge_mutations(player_type *player_ptr)
+void do_cmd_knowledge_mutations(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
index b09e167..d1fba21 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_knowledge_mutations(player_type *player_ptr);
+class PlayerType;
+void do_cmd_knowledge_mutations(PlayerType *player_ptr);
index 695f324..0c1c5fb 100644 (file)
@@ -30,7 +30,7 @@
  * @brief Check on the status of an active quest
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_checkquest(player_type *player_ptr)
+void do_cmd_checkquest(PlayerType *player_ptr)
 {
     screen_save();
     do_cmd_knowledge_quests(player_ptr);
@@ -40,9 +40,9 @@ void do_cmd_checkquest(player_type *player_ptr)
 /*!
  * @brief Print all active quests
  * @param player_ptr プレイヤーへの参照ポインタ
- * @todo player_typeではなくQUEST_IDXを引数にすべきかもしれない
+ * @todo PlayerTypeではなくQUEST_IDXを引数にすべきかもしれない
  */
-static void do_cmd_knowledge_quests_current(player_type *player_ptr, FILE *fff)
+static void do_cmd_knowledge_quests_current(PlayerType *player_ptr, FILE *fff)
 {
     char tmp_str[1024];
     char rand_tmp_str[512] = "\0";
@@ -176,7 +176,7 @@ static void do_cmd_knowledge_quests_current(player_type *player_ptr, FILE *fff)
         fprintf(fff, _("  なし\n", "  Nothing.\n"));
 }
 
-static bool do_cmd_knowledge_quests_aux(player_type *player_ptr, FILE *fff, IDX q_idx)
+static bool do_cmd_knowledge_quests_aux(PlayerType *player_ptr, FILE *fff, IDX q_idx)
 {
     char tmp_str[120];
     char playtime_str[16];
@@ -222,7 +222,7 @@ static bool do_cmd_knowledge_quests_aux(player_type *player_ptr, FILE *fff, IDX
  * @param fff セーブファイル (展開済?)
  * @param quest_num[] 受注したことのあるクエスト群
  */
-void do_cmd_knowledge_quests_completed(player_type *player_ptr, FILE *fff, QUEST_IDX quest_num[])
+void do_cmd_knowledge_quests_completed(PlayerType *player_ptr, FILE *fff, QUEST_IDX quest_num[])
 {
     fprintf(fff, _("《達成したクエスト》\n", "< Completed Quest >\n"));
     QUEST_IDX total = 0;
@@ -245,7 +245,7 @@ void do_cmd_knowledge_quests_completed(player_type *player_ptr, FILE *fff, QUEST
  * @param fff セーブファイル (展開済?)
  * @param quest_num[] 受注したことのあるクエスト群
  */
-void do_cmd_knowledge_quests_failed(player_type *player_ptr, FILE *fff, QUEST_IDX quest_num[])
+void do_cmd_knowledge_quests_failed(PlayerType *player_ptr, FILE *fff, QUEST_IDX quest_num[])
 {
     fprintf(fff, _("《失敗したクエスト》\n", "< Failed Quest >\n"));
     QUEST_IDX total = 0;
@@ -289,7 +289,7 @@ static void do_cmd_knowledge_quests_wiz_random(FILE *fff)
  * Print quest status of all active quests
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_knowledge_quests(player_type *player_ptr)
+void do_cmd_knowledge_quests(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
index 594080d..5a92013 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void do_cmd_checkquest(player_type *player_ptr);
-void do_cmd_knowledge_quests_completed(player_type *player_ptr, FILE *fff, QUEST_IDX quest_num[]);
-void do_cmd_knowledge_quests_failed(player_type *player_ptr, FILE *fff, QUEST_IDX quest_num[]);
-void do_cmd_knowledge_quests(player_type *player_ptr);
+class PlayerType;
+void do_cmd_checkquest(PlayerType *player_ptr);
+void do_cmd_knowledge_quests_completed(PlayerType *player_ptr, FILE *fff, QUEST_IDX quest_num[]);
+void do_cmd_knowledge_quests_failed(PlayerType *player_ptr, FILE *fff, QUEST_IDX quest_num[]);
+void do_cmd_knowledge_quests(PlayerType *player_ptr);
index 789b472..9135870 100644 (file)
@@ -32,7 +32,7 @@
 /*
  * List virtues & status
  */
-void do_cmd_knowledge_virtues(player_type *player_ptr)
+void do_cmd_knowledge_virtues(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
@@ -52,7 +52,7 @@ void do_cmd_knowledge_virtues(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param fff ファイルポインタ
  */
-static void dump_yourself(player_type *player_ptr, FILE *fff)
+static void dump_yourself(PlayerType *player_ptr, FILE *fff)
 {
     if (!fff)
         return;
@@ -168,7 +168,7 @@ static void dump_winner_classes(FILE *fff)
  * List virtues & status
  *
  */
-void do_cmd_knowledge_stat(player_type *player_ptr)
+void do_cmd_knowledge_stat(PlayerType *player_ptr)
 {
     FILE *fff = nullptr;
     GAME_TEXT file_name[FILE_NAME_SIZE];
@@ -210,7 +210,7 @@ void do_cmd_knowledge_stat(player_type *player_ptr)
  * List my home
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void do_cmd_knowledge_home(player_type *player_ptr)
+void do_cmd_knowledge_home(PlayerType *player_ptr)
 {
     parse_fixed_map(player_ptr, "w_info.txt", 0, 0, w_ptr->max_wild_y, w_ptr->max_wild_x);
 
index c7f2a16..c30fdb6 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void do_cmd_knowledge_virtues(player_type *player_ptr);
-void do_cmd_knowledge_stat(player_type *player_ptr);
-void do_cmd_knowledge_home(player_type *player_ptr);
+class PlayerType;
+void do_cmd_knowledge_virtues(PlayerType *player_ptr);
+void do_cmd_knowledge_stat(PlayerType *player_ptr);
+void do_cmd_knowledge_home(PlayerType *player_ptr);
index 7d7708d..80c0e09 100644 (file)
@@ -127,7 +127,7 @@ static void display_uniques(unique_list_type *unique_list_ptr, FILE *fff)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param is_alive 生きているユニークのリストならばTRUE、撃破したユニークのリストならばFALSE
  */
-void do_cmd_knowledge_uniques(player_type *player_ptr, bool is_alive)
+void do_cmd_knowledge_uniques(PlayerType *player_ptr, bool is_alive)
 {
     unique_list_type tmp_list;
     unique_list_type *unique_list_ptr = initialize_unique_lsit_type(&tmp_list, is_alive);
index ca271be..535d511 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_knowledge_uniques(player_type *player_ptr, bool is_alive);
+class PlayerType;
+void do_cmd_knowledge_uniques(PlayerType *player_ptr, bool is_alive);
index 2be275e..122a082 100644 (file)
@@ -34,7 +34,7 @@ void rd_dummy2(void)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details もはや何に使われていたのか不明
  */
-void rd_dummy_monsters(player_type *player_ptr)
+void rd_dummy_monsters(PlayerType *player_ptr)
 {
     if (h_older_than(1, 5, 0, 2))
         return;
index 9f05047..fbde072 100644 (file)
@@ -1,8 +1,8 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 void rd_dummy1(void);
 void rd_dummy2(void);
-void rd_dummy_monsters(player_type *player_ptr);
+void rd_dummy_monsters(PlayerType *player_ptr);
 void rd_ghost(void);
 void rd_dummy3(void);
index 76b767e..0022bd7 100644 (file)
@@ -23,7 +23,7 @@
  * The monsters/objects must be loaded in the same order
  * that they were stored, since the actual indexes matter.
  */
-static errr rd_dungeon(player_type *player_ptr)
+static errr rd_dungeon(PlayerType *player_ptr)
 {
     init_saved_floors(player_ptr, false);
     errr err = 0;
@@ -123,7 +123,7 @@ static errr rd_dungeon(player_type *player_ptr)
     return err;
 }
 
-errr restore_dungeon(player_type *player_ptr)
+errr restore_dungeon(PlayerType *player_ptr)
 {
     if (player_ptr->is_dead) {
         for (int i = MIN_RANDOM_QUEST; i < MAX_RANDOM_QUEST + 1; i++)
index c4f786c..822c82b 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-errr restore_dungeon(player_type *player_ptr);
+class PlayerType;
+errr restore_dungeon(PlayerType *player_ptr);
index 570123e..1836d8a 100644 (file)
@@ -17,7 +17,7 @@
  * @brief その他の情報を読み込む / Read the "extra" information
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void rd_extra(player_type *player_ptr)
+void rd_extra(PlayerType *player_ptr)
 {
     if (h_older_than(0, 0, 7))
         player_ptr->riding = 0;
index 6622211..feb3186 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void rd_extra(player_type *player_ptr);
+class PlayerType;
+void rd_extra(PlayerType *player_ptr);
index 01535d5..0fceb44 100644 (file)
@@ -44,7 +44,7 @@
  * The monsters/objects must be loaded in the same order
  * that they were stored, since the actual indexes matter.
  */
-errr rd_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr)
+errr rd_saved_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     clear_cave(player_ptr);
@@ -197,7 +197,7 @@ errr rd_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr)
  * @param sf_ptr 保存フロア読み込み先
  * @return 成功したらtrue
  */
-static bool load_floor_aux(player_type *player_ptr, saved_floor_type *sf_ptr)
+static bool load_floor_aux(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     load_xor_byte = 0;
     strip_bytes(1);
@@ -234,7 +234,7 @@ static bool load_floor_aux(player_type *player_ptr, saved_floor_type *sf_ptr)
  * @param mode オプション
  * @return 成功したらtrue
  */
-bool load_floor(player_type *player_ptr, saved_floor_type *sf_ptr, BIT_FLAGS mode)
+bool load_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr, BIT_FLAGS mode)
 {
     /*
      * Temporary files are always written in system depended kanji
index 49b9c53..c8cc21b 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 struct saved_floor_type;
-errr rd_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr);
-bool load_floor(player_type *player_ptr, saved_floor_type *sf_ptr, BIT_FLAGS mode);
+errr rd_saved_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr);
+bool load_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr, BIT_FLAGS mode);
index 0c737fc..99af52f 100644 (file)
@@ -19,7 +19,7 @@
  *
  * Note that the inventory is "re-sorted" later by "dungeon()".
  */
-static errr rd_inventory(player_type *player_ptr)
+static errr rd_inventory(PlayerType *player_ptr)
 {
     player_ptr->inven_cnt = 0;
     player_ptr->equip_cnt = 0;
@@ -62,7 +62,7 @@ static errr rd_inventory(player_type *player_ptr)
     return 0;
 }
 
-errr load_inventory(player_type *player_ptr)
+errr load_inventory(PlayerType *player_ptr)
 {
     for (int i = 0; i < 64; i++) {
         player_ptr->spell_order[i] = rd_byte();
index 64a664f..a22475b 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-errr load_inventory(player_type *player_ptr);
+class PlayerType;
+errr load_inventory(PlayerType *player_ptr);
index 53e2b55..a8c5ff9 100644 (file)
@@ -72,7 +72,7 @@ void load_zangband_options(void)
         option_flag[5] |= (0x00000001U << 3);
 }
 
-void set_zangband_realm(player_type *player_ptr)
+void set_zangband_realm(PlayerType *player_ptr)
 {
     if (player_ptr->realm1 == 9)
         player_ptr->realm1 = REALM_MUSIC;
@@ -87,7 +87,7 @@ void set_zangband_realm(player_type *player_ptr)
         player_ptr->realm2 = REALM_HISSATSU;
 }
 
-void set_zangband_skill(player_type *player_ptr)
+void set_zangband_skill(PlayerType *player_ptr)
 {
     if (player_ptr->pclass != PlayerClassType::BEASTMASTER)
         player_ptr->skill_exp[PlayerSkillKindType::RIDING] /= 2;
@@ -95,7 +95,7 @@ void set_zangband_skill(player_type *player_ptr)
     player_ptr->skill_exp[PlayerSkillKindType::RIDING] = std::min(player_ptr->skill_exp[PlayerSkillKindType::RIDING], s_info[enum2i(player_ptr->pclass)].s_max[PlayerSkillKindType::RIDING]);
 }
 
-void set_zangband_race(player_type *player_ptr)
+void set_zangband_race(PlayerType *player_ptr)
 {
     player_ptr->start_race = player_ptr->prace;
     player_ptr->old_race1 = 0L;
@@ -103,7 +103,7 @@ void set_zangband_race(player_type *player_ptr)
     player_ptr->old_realm = 0;
 }
 
-void set_zangband_bounty_uniques(player_type *player_ptr)
+void set_zangband_bounty_uniques(PlayerType *player_ptr)
 {
     determine_bounty_uniques(player_ptr);
     for (int i = 0; i < MAX_BOUNTY; i++) {
@@ -113,7 +113,7 @@ void set_zangband_bounty_uniques(player_type *player_ptr)
     }
 }
 
-void set_zangband_mimic(player_type *player_ptr)
+void set_zangband_mimic(PlayerType *player_ptr)
 {
     player_ptr->tim_res_time = 0;
     player_ptr->mimic_form = 0;
@@ -121,13 +121,13 @@ void set_zangband_mimic(player_type *player_ptr)
     player_ptr->tim_sh_fire = 0;
 }
 
-void set_zangband_holy_aura(player_type *player_ptr)
+void set_zangband_holy_aura(PlayerType *player_ptr)
 {
     player_ptr->tim_sh_holy = 0;
     player_ptr->tim_eyeeye = 0;
 }
 
-void set_zangband_reflection(player_type *player_ptr)
+void set_zangband_reflection(PlayerType *player_ptr)
 {
     player_ptr->tim_reflect = 0;
     player_ptr->multishadow = 0;
@@ -139,7 +139,7 @@ void rd_zangband_dungeon()
     max_dlv[DUNGEON_ANGBAND] = rd_s16b();
 }
 
-void set_zangband_game_turns(player_type *player_ptr)
+void set_zangband_game_turns(PlayerType *player_ptr)
 {
     player_ptr->current_floor_ptr->generated_turn /= 2;
     player_ptr->feeling_turn /= 2;
@@ -152,7 +152,7 @@ void set_zangband_gambling_monsters(int i)
     mon_odds[i] = rd_s16b();
 }
 
-void set_zangband_special_attack(player_type *player_ptr)
+void set_zangband_special_attack(PlayerType *player_ptr)
 {
     if (rd_byte() != 0)
         player_ptr->special_attack = ATTACK_CONFUSE;
@@ -160,25 +160,25 @@ void set_zangband_special_attack(player_type *player_ptr)
     player_ptr->ele_attack = 0;
 }
 
-void set_zangband_special_defense(player_type *player_ptr)
+void set_zangband_special_defense(PlayerType *player_ptr)
 {
     player_ptr->ele_immune = 0;
     player_ptr->special_defense = 0;
 }
 
-void set_zangband_action(player_type *player_ptr)
+void set_zangband_action(PlayerType *player_ptr)
 {
     if (rd_byte() != 0)
         player_ptr->action = ACTION_LEARN;
 }
 
-void set_zangband_visited_towns(player_type *player_ptr)
+void set_zangband_visited_towns(PlayerType *player_ptr)
 {
     strip_bytes(4);
     player_ptr->visit = 1L;
 }
 
-void set_zangband_quest(player_type *player_ptr, quest_type *const q_ptr, int loading_quest_index, const QUEST_IDX old_inside_quest)
+void set_zangband_quest(PlayerType *player_ptr, quest_type *const q_ptr, int loading_quest_index, const QUEST_IDX old_inside_quest)
 {
     if (q_ptr->flags & QUEST_FLAG_PRESET) {
         q_ptr->dungeon = 0;
@@ -191,7 +191,7 @@ void set_zangband_quest(player_type *player_ptr, quest_type *const q_ptr, int lo
     player_ptr->current_floor_ptr->inside_quest = old_inside_quest;
 }
 
-void set_zangband_class(player_type *player_ptr)
+void set_zangband_class(PlayerType *player_ptr)
 {
     if (h_older_than(0, 2, 2) && (player_ptr->pclass == PlayerClassType::BEASTMASTER) && !player_ptr->is_dead) {
         player_ptr->hitdie = rp_ptr->r_mhp + cp_ptr->c_mhp + ap_ptr->a_mhp;
@@ -214,7 +214,7 @@ void set_zangband_class(player_type *player_ptr)
     }
 }
 
-void set_zangband_learnt_spells(player_type *player_ptr)
+void set_zangband_learnt_spells(PlayerType *player_ptr)
 {
     player_ptr->learned_spells = 0;
     for (int i = 0; i < 64; i++)
@@ -222,7 +222,7 @@ void set_zangband_learnt_spells(player_type *player_ptr)
             player_ptr->learned_spells++;
 }
 
-void set_zangband_pet(player_type *player_ptr)
+void set_zangband_pet(PlayerType *player_ptr)
 {
     player_ptr->pet_extra_flags = 0;
     if (rd_byte() != 0)
index 555f4c5..39e7ee9 100644 (file)
@@ -2,24 +2,24 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 typedef struct quest_type quest_type;
 void load_zangband_options(void);
-void set_zangband_realm(player_type *player_ptr);
-void set_zangband_skill(player_type *player_ptr);
-void set_zangband_race(player_type *player_ptr);
-void set_zangband_bounty_uniques(player_type *player_ptr);
-void set_zangband_mimic(player_type *player_ptr);
-void set_zangband_holy_aura(player_type *player_ptr);
-void set_zangband_reflection(player_type *player_ptr);
+void set_zangband_realm(PlayerType *player_ptr);
+void set_zangband_skill(PlayerType *player_ptr);
+void set_zangband_race(PlayerType *player_ptr);
+void set_zangband_bounty_uniques(PlayerType *player_ptr);
+void set_zangband_mimic(PlayerType *player_ptr);
+void set_zangband_holy_aura(PlayerType *player_ptr);
+void set_zangband_reflection(PlayerType *player_ptr);
 void rd_zangband_dungeon(void);
-void set_zangband_game_turns(player_type *player_ptr);
+void set_zangband_game_turns(PlayerType *player_ptr);
 void set_zangband_gambling_monsters(int i);
-void set_zangband_special_attack(player_type *player_ptr);
-void set_zangband_special_defense(player_type *player_ptr);
-void set_zangband_action(player_type *player_ptr);
-void set_zangband_visited_towns(player_type *player_ptr);
-void set_zangband_quest(player_type *player_ptr, quest_type *const q_ptr, int loading_quest_index, const QUEST_IDX old_inside_quest);
-void set_zangband_class(player_type *player_ptr);
-void set_zangband_learnt_spells(player_type *player_ptr);
-void set_zangband_pet(player_type *player_ptr);
+void set_zangband_special_attack(PlayerType *player_ptr);
+void set_zangband_special_defense(PlayerType *player_ptr);
+void set_zangband_action(PlayerType *player_ptr);
+void set_zangband_visited_towns(PlayerType *player_ptr);
+void set_zangband_quest(PlayerType *player_ptr, quest_type *const q_ptr, int loading_quest_index, const QUEST_IDX old_inside_quest);
+void set_zangband_class(PlayerType *player_ptr);
+void set_zangband_learnt_spells(PlayerType *player_ptr);
+void set_zangband_pet(PlayerType *player_ptr);
index cc2bdb6..1e60067 100644 (file)
@@ -52,7 +52,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return エラーコード
  */
-static errr load_town_quest(player_type *player_ptr)
+static errr load_town_quest(PlayerType *player_ptr)
 {
     if (h_older_than(2, 1, 3))
         return 0;
@@ -102,7 +102,7 @@ static void rd_winner_class()
     rd_FlagGroup(w_ptr->sf_retired, rd_byte);
 }
 
-static void load_player_world(player_type *player_ptr)
+static void load_player_world(PlayerType *player_ptr)
 {
     rd_total_play_time();
     rd_winner_class();
@@ -120,7 +120,7 @@ static void load_player_world(player_type *player_ptr)
     load_note(_("特別情報をロードしました", "Loaded extra information"));
 }
 
-static errr load_hp(player_type *player_ptr)
+static errr load_hp(PlayerType *player_ptr)
 {
     auto tmp16u = rd_u16b();
     if (tmp16u > PY_MAX_LEVEL) {
@@ -135,7 +135,7 @@ static errr load_hp(player_type *player_ptr)
     return 0;
 }
 
-static void load_spells(player_type *player_ptr)
+static void load_spells(PlayerType *player_ptr)
 {
     player_ptr->spell_learned1 = rd_u32b();
     player_ptr->spell_learned2 = rd_u32b();
@@ -179,7 +179,7 @@ static errr verify_encoded_checksum()
  * @brief セーブファイル読み込み処理の実体 / Actually read the savefile
  * @return エラーコード
  */
-static errr exe_reading_savefile(player_type *player_ptr)
+static errr exe_reading_savefile(PlayerType *player_ptr)
 {
     rd_version_info();
     rd_dummy3();
@@ -248,7 +248,7 @@ static errr exe_reading_savefile(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return エラーコード
  */
-static errr rd_savefile(player_type *player_ptr)
+static errr rd_savefile(PlayerType *player_ptr)
 {
     safe_setuid_grab(player_ptr);
     loading_savefile = angband_fopen(savefile, "rb");
@@ -270,7 +270,7 @@ static errr rd_savefile(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 引き継ぎ可能ならtrue、そうでなければfalseを返す
  */
-static bool can_takeover_savefile(const player_type *player_ptr)
+static bool can_takeover_savefile(const PlayerType *player_ptr)
 {
     if (loading_savefile_version_is_older_than(8) && player_ptr->pclass == PlayerClassType::SMITH) {
         return false;
@@ -286,7 +286,7 @@ static bool can_takeover_savefile(const player_type *player_ptr)
  * @param new_game セーブデータの新規作成が必要か否か
  * @return セーブデータが読み込めればtrue
  */
-bool load_savedata(player_type *player_ptr, bool *new_game)
+bool load_savedata(PlayerType *player_ptr, bool *new_game)
 {
     concptr what = "generic";
     w_ptr->game_turn = 0;
index 0e71eab..f11e675 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool load_savedata(player_type *player_ptr, bool *new_game);
+class PlayerType;
+bool load_savedata(PlayerType *player_ptr, bool *new_game);
index bfb1133..5e21330 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct monster_type;
-struct player_type;
+class PlayerType;
 class MonsterLoaderBase {
 public:
     virtual ~MonsterLoaderBase() = default;
index 9568715..8c11264 100644 (file)
@@ -16,7 +16,7 @@
  * @details MonsterLoaderBaseは純粋仮想関数を含むので参照を返す必要がある.
  * (値を返す設計はコンパイルエラー)
  */
-std::shared_ptr<MonsterLoaderBase> MonsterLoaderFactory::create_loader(player_type *player_ptr)
+std::shared_ptr<MonsterLoaderBase> MonsterLoaderFactory::create_loader(PlayerType *player_ptr)
 {
     auto version = get_version();
     switch (version) {
index 3f93365..20c1a20 100644 (file)
@@ -3,12 +3,12 @@
 #include <memory>
 
 enum class MonsterLoaderVersionType;
-struct player_type;
+class PlayerType;
 struct monster_type;
 class MonsterLoaderBase;
 class MonsterLoaderFactory {
 public:
-    static std::shared_ptr<MonsterLoaderBase> create_loader(player_type *player_ptr);
+    static std::shared_ptr<MonsterLoaderBase> create_loader(PlayerType *player_ptr);
 
 private:
     MonsterLoaderFactory() = delete;
index 523d4fb..7f31e6b 100644 (file)
@@ -323,7 +323,7 @@ void rd_item_old(object_type *o_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param m_ptr モンスター保存先ポインタ
  */
-void rd_monster_old(player_type *player_ptr, monster_type *m_ptr)
+void rd_monster_old(PlayerType *player_ptr, monster_type *m_ptr)
 {
     m_ptr->r_idx = rd_s16b();
 
@@ -504,7 +504,7 @@ void set_old_lore(monster_race *r_ptr, BIT_FLAGS f4, const MONRACE_IDX r_idx)
  * The monsters/objects must be loaded in the same order
  * that they were stored, since the actual indexes matter.
  */
-errr rd_dungeon_old(player_type *player_ptr)
+errr rd_dungeon_old(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     floor_ptr->dun_level = rd_s16b();
index e7c9c9d..fc155ef 100644 (file)
@@ -37,8 +37,8 @@ extern const int QUEST_OLD_CASTLE;
 extern const int QUEST_ROYAL_CRYPT;
 
 struct object_type;
-struct player_type;
+class PlayerType;
 void rd_item_old(object_type *o_ptr);
-void rd_monster_old(player_type *player_ptr, monster_type *m_ptr);
+void rd_monster_old(PlayerType *player_ptr, monster_type *m_ptr);
 void set_old_lore(monster_race *r_ptr, BIT_FLAGS f4, const MONRACE_IDX r_idx);
-errr rd_dungeon_old(player_type *player_ptr);
+errr rd_dungeon_old(PlayerType *player_ptr);
index c04ae44..28b47e2 100644 (file)
@@ -6,7 +6,7 @@
 #include "system/floor-type-definition.h"
 #include "system/player-type-definition.h"
 
-void set_hp_old(player_type *player_ptr)
+void set_hp_old(PlayerType *player_ptr)
 {
     player_ptr->mhp = rd_s16b();
 
@@ -14,7 +14,7 @@ void set_hp_old(player_type *player_ptr)
     player_ptr->chp_frac = rd_u16b();
 }
 
-void set_mana_old(player_type *player_ptr)
+void set_mana_old(PlayerType *player_ptr)
 {
     player_ptr->msp = rd_s16b();
 
@@ -22,12 +22,12 @@ void set_mana_old(player_type *player_ptr)
     player_ptr->csp_frac = rd_u16b();
 }
 
-void set_exp_frac_old(player_type *player_ptr)
+void set_exp_frac_old(PlayerType *player_ptr)
 {
     player_ptr->exp_frac = rd_u16b();
 }
 
-void remove_water_cave(player_type *player_ptr)
+void remove_water_cave(PlayerType *player_ptr)
 {
     if (player_ptr->current_floor_ptr->inside_quest != OLD_QUEST_WATER_CAVE)
         return;
index 04b9ed9..5811557 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
-struct player_type;
-void set_hp_old(player_type *player_ptr);
-void set_mana_old(player_type *player_ptr);
-void set_exp_frac_old(player_type *player_ptr);
-void remove_water_cave(player_type *player_ptr);
+class PlayerType;
+void set_hp_old(PlayerType *player_ptr);
+void set_mana_old(PlayerType *player_ptr);
+void set_exp_frac_old(PlayerType *player_ptr);
+void remove_water_cave(PlayerType *player_ptr);
index 1259647..df86891 100644 (file)
@@ -9,7 +9,7 @@
 #include "util/enum-converter.h"
 #include "util/quarks.h"
 
-MonsterLoader10::MonsterLoader10(player_type *player_ptr)
+MonsterLoader10::MonsterLoader10(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index 1fae762..bda3e33 100644 (file)
@@ -3,13 +3,13 @@
 #include "load/monster/monster-loader-base.h"
 
 struct monster_type;
-struct player_type;
+class PlayerType;
 class MonsterLoader10 : public MonsterLoaderBase {
 public:
-    MonsterLoader10(player_type *player_ptr);
+    MonsterLoader10(PlayerType *player_ptr);
     void rd_monster(monster_type *m_ptr) override;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     monster_type *m_ptr = nullptr;
 };
index 6838f4f..df057b9 100644 (file)
@@ -9,7 +9,7 @@
 #include "player/special-defense-types.h"
 #include "system/player-type-definition.h"
 
-void rd_special_attack(player_type *player_ptr)
+void rd_special_attack(PlayerType *player_ptr)
 {
     if (h_older_than(0, 0, 9)) {
         set_zangband_special_attack(player_ptr);
@@ -20,7 +20,7 @@ void rd_special_attack(player_type *player_ptr)
     player_ptr->special_attack = rd_u32b();
 }
 
-void rd_special_action(player_type *player_ptr)
+void rd_special_action(PlayerType *player_ptr)
 {
     if (!PlayerClass(player_ptr).monk_stance_is(MonkStanceType::NONE)) {
         player_ptr->action = ACTION_MONK_STANCE;
@@ -32,7 +32,7 @@ void rd_special_action(player_type *player_ptr)
     }
 }
 
-void rd_special_defense(player_type *player_ptr)
+void rd_special_defense(PlayerType *player_ptr)
 {
     if (h_older_than(0, 0, 12)) {
         set_zangband_special_defense(player_ptr);
@@ -43,7 +43,7 @@ void rd_special_defense(player_type *player_ptr)
     player_ptr->special_defense = rd_u32b();
 }
 
-void rd_action(player_type *player_ptr)
+void rd_action(PlayerType *player_ptr)
 {
     strip_bytes(1);
     player_ptr->action = rd_byte();
index 1f0b2c4..67736d6 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
-struct player_type;
-void rd_special_attack(player_type *player_ptr);
-void rd_special_action(player_type *player_ptr);
-void rd_special_defense(player_type *player_ptr);
-void rd_action(player_type *player_ptr);
+class PlayerType;
+void rd_special_attack(PlayerType *player_ptr);
+void rd_special_action(PlayerType *player_ptr);
+void rd_special_defense(PlayerType *player_ptr);
+void rd_action(PlayerType *player_ptr);
index 864ed04..b539e70 100644 (file)
@@ -30,7 +30,7 @@
  * @brief セーブデータから領域情報を読み込む / Read player realms
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void rd_realms(player_type *player_ptr)
+static void rd_realms(PlayerType *player_ptr)
 {
     if (player_ptr->pclass == PlayerClassType::ELEMENTALIST)
         player_ptr->element = rd_byte();
@@ -46,7 +46,7 @@ static void rd_realms(player_type *player_ptr)
  * @brief セーブデータからプレイヤー基本情報を読み込む / Read player's basic info
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void rd_base_info(player_type *player_ptr)
+void rd_base_info(PlayerType *player_ptr)
 {
     rd_string(player_ptr->name, sizeof(player_ptr->name));
     rd_string(player_ptr->died_from, sizeof(player_ptr->died_from));
@@ -81,7 +81,7 @@ void rd_base_info(player_type *player_ptr)
     player_ptr->wt = rd_s16b();
 }
 
-void rd_experience(player_type *player_ptr)
+void rd_experience(PlayerType *player_ptr)
 {
     player_ptr->max_exp = rd_s32b();
     if (h_older_than(1, 5, 4, 1))
@@ -115,7 +115,7 @@ void rd_experience(player_type *player_ptr)
     strip_bytes(sizeof(int16_t) * (MAX_SKILLS - PLAYER_SKILL_KIND_TYPE_RANGE.size()));
 }
 
-void rd_skills(player_type *player_ptr)
+void rd_skills(PlayerType *player_ptr)
 {
     if (h_older_than(0, 4, 1))
         set_zangband_skill(player_ptr);
@@ -127,7 +127,7 @@ void rd_skills(player_type *player_ptr)
         player_ptr->action = ACTION_SING;
 }
 
-static void set_race(player_type *player_ptr)
+static void set_race(PlayerType *player_ptr)
 {
     player_ptr->start_race = i2enum<PlayerRaceType>(rd_byte());
     player_ptr->old_race1 = rd_u32b();
@@ -135,7 +135,7 @@ static void set_race(player_type *player_ptr)
     player_ptr->old_realm = rd_s16b();
 }
 
-void rd_race(player_type *player_ptr)
+void rd_race(PlayerType *player_ptr)
 {
     if (h_older_than(1, 0, 7)) {
         set_zangband_race(player_ptr);
@@ -145,7 +145,7 @@ void rd_race(player_type *player_ptr)
     set_race(player_ptr);
 }
 
-void rd_bounty_uniques(player_type *player_ptr)
+void rd_bounty_uniques(PlayerType *player_ptr)
 {
     if (h_older_than(0, 0, 3)) {
         set_zangband_bounty_uniques(player_ptr);
@@ -160,7 +160,7 @@ void rd_bounty_uniques(player_type *player_ptr)
  * @brief 腕力などの基本ステータス情報を読み込む
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void rd_base_status(player_type *player_ptr)
+static void rd_base_status(PlayerType *player_ptr)
 {
     for (int i = 0; i < A_MAX; i++)
         player_ptr->stat_max[i] = rd_s16b();
@@ -172,7 +172,7 @@ static void rd_base_status(player_type *player_ptr)
         player_ptr->stat_cur[i] = rd_s16b();
 }
 
-static void set_imitation(player_type *player_ptr)
+static void set_imitation(PlayerType *player_ptr)
 {
     if (h_older_than(0, 0, 1)) {
         return;
@@ -206,7 +206,7 @@ static void set_imitation(player_type *player_ptr)
     }
 }
 
-static void rd_phase_out(player_type *player_ptr)
+static void rd_phase_out(PlayerType *player_ptr)
 {
     player_ptr->current_floor_ptr->inside_arena = rd_s16b() != 0;
     player_ptr->current_floor_ptr->inside_quest = rd_s16b();
@@ -217,7 +217,7 @@ static void rd_phase_out(player_type *player_ptr)
     }
 }
 
-static void rd_arena(player_type *player_ptr)
+static void rd_arena(PlayerType *player_ptr)
 {
     if (h_older_than(0, 0, 3))
         update_gambling_monsters(player_ptr);
@@ -246,7 +246,7 @@ static void rd_arena(player_type *player_ptr)
  * @brief プレイヤーの最大HP/現在HPを読み込む
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void rd_hp(player_type *player_ptr)
+static void rd_hp(PlayerType *player_ptr)
 {
     if (h_older_than(1, 7, 0, 3)) {
         set_hp_old(player_ptr);
@@ -262,7 +262,7 @@ static void rd_hp(player_type *player_ptr)
  * @brief プレイヤーの最大MP/現在MPを読み込む
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void rd_mana(player_type *player_ptr)
+static void rd_mana(PlayerType *player_ptr)
 {
     if (h_older_than(1, 7, 0, 3)) {
         set_mana_old(player_ptr);
@@ -278,7 +278,7 @@ static void rd_mana(player_type *player_ptr)
  * @brief プレイヤーのバッドステータス (と空腹)を読み込む
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void rd_bad_status(player_type *player_ptr)
+static void rd_bad_status(PlayerType *player_ptr)
 {
     strip_bytes(2); /* Old "rest" */
     player_ptr->blind = rd_s16b();
@@ -288,7 +288,7 @@ static void rd_bad_status(player_type *player_ptr)
     strip_bytes(4); /* Old "food_digested" / "protection" */
 }
 
-static void rd_energy(player_type *player_ptr)
+static void rd_energy(PlayerType *player_ptr)
 {
     player_ptr->energy_need = rd_s16b();
     if (h_older_than(1, 0, 13))
@@ -305,7 +305,7 @@ static void rd_energy(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @todo 明らかに関数名がビッグワードだが他に思いつかなかった
  */
-static void rd_status(player_type *player_ptr)
+static void rd_status(PlayerType *player_ptr)
 {
     player_ptr->fast = rd_s16b();
     player_ptr->slow = rd_s16b();
@@ -322,7 +322,7 @@ static void rd_status(player_type *player_ptr)
         player_ptr->ult_res = rd_s16b();
 }
 
-static void rd_tsuyoshi(player_type *player_ptr)
+static void rd_tsuyoshi(PlayerType *player_ptr)
 {
     if (h_older_than(0, 0, 2))
         player_ptr->tsuyoshi = 0;
@@ -330,7 +330,7 @@ static void rd_tsuyoshi(player_type *player_ptr)
         player_ptr->tsuyoshi = rd_s16b();
 }
 
-static void set_timed_effects(player_type *player_ptr)
+static void set_timed_effects(PlayerType *player_ptr)
 {
     player_ptr->tim_esp = rd_s16b();
     player_ptr->wraith_form = rd_s16b();
@@ -374,7 +374,7 @@ static void set_timed_effects(player_type *player_ptr)
     }
 }
 
-static void set_mutations(player_type *player_ptr)
+static void set_mutations(PlayerType *player_ptr)
 {
     if (loading_savefile_version_is_older_than(2)) {
         for (int i = 0; i < 3; i++) {
@@ -386,7 +386,7 @@ static void set_mutations(player_type *player_ptr)
     }
 }
 
-static void set_virtues(player_type *player_ptr)
+static void set_virtues(PlayerType *player_ptr)
 {
     for (int i = 0; i < 8; i++)
         player_ptr->virtues[i] = rd_s16b();
@@ -399,7 +399,7 @@ static void set_virtues(player_type *player_ptr)
  * @brief 各種時限効果を読み込む
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void rd_timed_effects(player_type *player_ptr)
+static void rd_timed_effects(PlayerType *player_ptr)
 {
     set_timed_effects(player_ptr);
     player_ptr->chaos_patron = rd_s16b();
@@ -407,7 +407,7 @@ static void rd_timed_effects(player_type *player_ptr)
     set_virtues(player_ptr);
 }
 
-static void rd_player_status(player_type *player_ptr)
+static void rd_player_status(PlayerType *player_ptr)
 {
     rd_base_status(player_ptr);
     strip_bytes(24);
@@ -456,7 +456,7 @@ static void rd_player_status(player_type *player_ptr)
     player_ptr->mutant_regenerate_mod = calc_mutant_regenerate_mod(player_ptr);
 }
 
-void rd_player_info(player_type *player_ptr)
+void rd_player_info(PlayerType *player_ptr)
 {
     rd_player_status(player_ptr);
     rd_special_attack(player_ptr);
index 1672ed8..9a5d4ef 100644 (file)
@@ -1,9 +1,9 @@
 #pragma once
 
-struct player_type;
-void rd_base_info(player_type *player_ptr);
-void rd_experience(player_type *player_ptr);
-void rd_skills(player_type *player_ptr);
-void rd_race(player_type *player_ptr);
-void rd_bounty_uniques(player_type *player_ptr);
-void rd_player_info(player_type *player_ptr);
+class PlayerType;
+void rd_base_info(PlayerType *player_ptr);
+void rd_experience(PlayerType *player_ptr);
+void rd_skills(PlayerType *player_ptr);
+void rd_race(PlayerType *player_ptr);
+void rd_bounty_uniques(PlayerType *player_ptr);
+void rd_player_info(PlayerType *player_ptr);
index 89b2efe..bbb2dcd 100644 (file)
@@ -66,7 +66,7 @@ static void load_quest_completion(quest_type *q_ptr)
         q_ptr->comptime = rd_u32b();
 }
 
-static void load_quest_details(player_type *player_ptr, quest_type *q_ptr, int loading_quest_index)
+static void load_quest_details(PlayerType *player_ptr, quest_type *q_ptr, int loading_quest_index)
 {
     q_ptr->cur_num = rd_s16b();
     q_ptr->max_num = rd_s16b();
@@ -83,7 +83,7 @@ static void load_quest_details(player_type *player_ptr, quest_type *q_ptr, int l
     q_ptr->flags = rd_byte();
 }
 
-void analyze_quests(player_type *player_ptr, const uint16_t max_quests_load, const byte max_rquests_load)
+void analyze_quests(PlayerType *player_ptr, const uint16_t max_quests_load, const byte max_rquests_load)
 {
     QUEST_IDX old_inside_quest = player_ptr->current_floor_ptr->inside_quest;
     for (int i = 0; i < max_quests_load; i++) {
index 72bc3c8..1dbb978 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 errr load_town(void);
 errr load_quest_info(uint16_t *max_quests_load, byte *max_rquests_load);
-void analyze_quests(player_type *player_ptr, const uint16_t max_quests_load, const byte max_rquests_load);
+void analyze_quests(PlayerType *player_ptr, const uint16_t max_quests_load, const byte max_rquests_load);
index 902e3e2..57f7144 100644 (file)
@@ -26,7 +26,7 @@
  * Also note that it may not correctly "adapt" to "knowledge" bacoming
  * known, the player may have to pick stuff up and drop it again.
  */
-static void home_carry_load(player_type *player_ptr, store_type *store_ptr, object_type *o_ptr)
+static void home_carry_load(PlayerType *player_ptr, store_type *store_ptr, object_type *o_ptr)
 {
     for (auto i = 0; i < store_ptr->stock_num; i++) {
         auto *j_ptr = &store_ptr->stock[i];
@@ -65,7 +65,7 @@ static void home_carry_load(player_type *player_ptr, store_type *store_ptr, obje
  * @param store_number 店舗ID
  * @return エラーID
  */
-static void rd_store(player_type *player_ptr, int town_number, int store_number)
+static void rd_store(PlayerType *player_ptr, int town_number, int store_number)
 {
     store_type *store_ptr;
     auto sort = false;
@@ -116,7 +116,7 @@ static void rd_store(player_type *player_ptr, int town_number, int store_number)
  * @param player_ptr プレイヤー情報への参照ポインタ(未使用)
  * @return 読み込み終わったら0、失敗したら22
  */
-void load_store(player_type *player_ptr)
+void load_store(PlayerType *player_ptr)
 {
     int16_t town_count = rd_u16b();
     int16_t store_count = rd_u16b();
index fc65285..7c162b0 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void load_store(player_type *player_ptr);
+class PlayerType;
+void load_store(PlayerType *player_ptr);
index a7e7f07..98d2c93 100644 (file)
@@ -26,7 +26,7 @@ static void rd_hengband_dungeons(void)
     }
 }
 
-void rd_dungeons(player_type *player_ptr)
+void rd_dungeons(PlayerType *player_ptr)
 {
     if (h_older_than(0, 3, 8))
         rd_zangband_dungeon();
@@ -41,7 +41,7 @@ void rd_dungeons(player_type *player_ptr)
  * @brief 現実変容処理の有無及びその残りターン数を読み込む
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void rd_alter_reality(player_type *player_ptr)
+void rd_alter_reality(PlayerType *player_ptr)
 {
     if (h_older_than(0, 3, 8))
         player_ptr->recall_dungeon = DUNGEON_ANGBAND;
@@ -70,12 +70,12 @@ void set_gambling_monsters(void)
 /*!
  * @details 自動拾い関係はこれしかないのでworldに突っ込むことにする。必要があれば再分割する
  */
-void rd_autopick(player_type *player_ptr)
+void rd_autopick(PlayerType *player_ptr)
 {
     player_ptr->autopick_autoregister = rd_byte() != 0;
 }
 
-static void set_undead_turn_limit(player_type *player_ptr)
+static void set_undead_turn_limit(PlayerType *player_ptr)
 {
     switch (player_ptr->start_race) {
     case PlayerRaceType::VAMPIRE:
@@ -90,7 +90,7 @@ static void set_undead_turn_limit(player_type *player_ptr)
     }
 }
 
-static void rd_world_info(player_type *player_ptr)
+static void rd_world_info(PlayerType *player_ptr)
 {
     set_undead_turn_limit(player_ptr);
     w_ptr->dungeon_turn_limit = TURNS_PER_TICK * TOWN_DAWN * (MAX_DAYS - 1) + TURNS_PER_TICK * TOWN_DAWN * 3 / 4;
@@ -122,7 +122,7 @@ static void rd_world_info(player_type *player_ptr)
     }
 }
 
-void rd_visited_towns(player_type *player_ptr)
+void rd_visited_towns(PlayerType *player_ptr)
 {
     if (h_older_than(0, 3, 9)) {
         player_ptr->visit = 1L;
@@ -137,7 +137,7 @@ void rd_visited_towns(player_type *player_ptr)
     player_ptr->visit = rd_u32b();
 }
 
-void rd_global_configurations(player_type *player_ptr)
+void rd_global_configurations(PlayerType *player_ptr)
 {
     w_ptr->seed_flavor = rd_u32b();
     w_ptr->seed_town = rd_u32b();
@@ -152,7 +152,7 @@ void rd_global_configurations(player_type *player_ptr)
     rd_world_info(player_ptr);
 }
 
-void load_wilderness_info(player_type *player_ptr)
+void load_wilderness_info(PlayerType *player_ptr)
 {
     player_ptr->wilderness_x = rd_s32b();
     player_ptr->wilderness_y = rd_s32b();
index afca595..1a4c535 100644 (file)
@@ -2,12 +2,12 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void rd_dungeons(player_type *player_ptr);
-void rd_alter_reality(player_type *player_ptr);
+class PlayerType;
+void rd_dungeons(PlayerType *player_ptr);
+void rd_alter_reality(PlayerType *player_ptr);
 void set_gambling_monsters(void);
-void rd_autopick(player_type *player_ptr);
-void rd_visited_towns(player_type *player_ptr);
-void rd_global_configurations(player_type *player_ptr);
-void load_wilderness_info(player_type *player_ptr);
+void rd_autopick(PlayerType *player_ptr);
+void rd_visited_towns(PlayerType *player_ptr);
+void rd_global_configurations(PlayerType *player_ptr);
+void load_wilderness_info(PlayerType *player_ptr);
 errr analyze_wilderness(void);
index 2137107..5ab0aaa 100644 (file)
@@ -111,7 +111,7 @@ bool know_damage(MONRACE_IDX r_idx, int i)
  * @param SPELL_NUM 呪文番号
  * @param msg 表示する文字列
  */
-void set_damage(player_type *player_ptr, lore_type *lore_ptr, MonsterAbilityType ms_type, concptr msg)
+void set_damage(PlayerType *player_ptr, lore_type *lore_ptr, MonsterAbilityType ms_type, concptr msg)
 {
     MONRACE_IDX r_idx = lore_ptr->r_idx;
     int base_damage = monspell_race_damage(player_ptr, ms_type, r_idx, BASE_DAM);
index 06687a5..593e528 100644 (file)
@@ -5,9 +5,9 @@
 enum class MonsterAbilityType;
 
 struct lore_type;
-struct player_type;
+class PlayerType;
 void dice_to_string(int base_damage, int dice_num, int dice_side, int dice_mult, int dice_div, char *msg);
 bool know_armour(MONRACE_IDX r_idx, const bool know_everything);
 bool know_damage(MONRACE_IDX r_idx, int i);
-void set_damage(player_type *player_ptr, lore_type *lore_ptr, MonsterAbilityType ms_type, concptr msg);
+void set_damage(PlayerType *player_ptr, lore_type *lore_ptr, MonsterAbilityType ms_type, concptr msg);
 void set_drop_flags(lore_type *lore_ptr);
index f973617..9bc5415 100644 (file)
@@ -22,7 +22,7 @@
  * @details
  * Return the number of new flags learnt.  -Mogami-
  */
-int lore_do_probe(player_type *player_ptr, MONRACE_IDX r_idx)
+int lore_do_probe(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     int n = 0;
     monster_race *r_ptr = &r_info[r_idx];
@@ -96,7 +96,7 @@ int lore_do_probe(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param num_item 手に入れたアイテム数
  * @param num_gold 手に入れた財宝の単位数
  */
-void lore_treasure(player_type *player_ptr, MONSTER_IDX m_idx, ITEM_NUMBER num_item, ITEM_NUMBER num_gold)
+void lore_treasure(PlayerType *player_ptr, MONSTER_IDX m_idx, ITEM_NUMBER num_item, ITEM_NUMBER num_gold)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
index ce1cb17..e2bf313 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-int lore_do_probe(player_type *player_ptr, MONRACE_IDX r_idx);
-void lore_treasure(player_type *player_ptr, MONSTER_IDX m_idx, ITEM_NUMBER num_item, ITEM_NUMBER num_gold);
+class PlayerType;
+int lore_do_probe(PlayerType *player_ptr, MONRACE_IDX r_idx);
+void lore_treasure(PlayerType *player_ptr, MONSTER_IDX m_idx, ITEM_NUMBER num_item, ITEM_NUMBER num_gold);
index 658b916..f11f0ed 100644 (file)
@@ -7,7 +7,7 @@
 #include "system/player-type-definition.h"
 #include "term/term-color-types.h"
 
-void set_breath_types(player_type *player_ptr, lore_type *lore_ptr)
+void set_breath_types(PlayerType *player_ptr, lore_type *lore_ptr)
 {
     lore_ptr->vn = 0;
     if (lore_ptr->ability_flags.has(MonsterAbilityType::BR_ACID)) {
@@ -143,7 +143,7 @@ void set_breath_types(player_type *player_ptr, lore_type *lore_ptr)
     }
 }
 
-void set_ball_types(player_type *player_ptr, lore_type *lore_ptr)
+void set_ball_types(PlayerType *player_ptr, lore_type *lore_ptr)
 {
     if (lore_ptr->ability_flags.has(MonsterAbilityType::BA_ACID)) {
         set_damage(player_ptr, lore_ptr, MonsterAbilityType::BA_ACID, _("アシッド・ボール%s", "produce acid balls%s"));
@@ -218,7 +218,7 @@ void set_ball_types(player_type *player_ptr, lore_type *lore_ptr)
     }
 }
 
-void set_particular_types(player_type *player_ptr, lore_type *lore_ptr)
+void set_particular_types(PlayerType *player_ptr, lore_type *lore_ptr)
 {
     if (lore_ptr->ability_flags.has(MonsterAbilityType::HAND_DOOM)) {
         lore_ptr->vp[lore_ptr->vn] = _("破滅の手(40%-60%)", "invoke the Hand of Doom(40%-60%)");
@@ -274,7 +274,7 @@ void set_particular_types(player_type *player_ptr, lore_type *lore_ptr)
     }
 }
 
-void set_bolt_types(player_type *player_ptr, lore_type *lore_ptr)
+void set_bolt_types(PlayerType *player_ptr, lore_type *lore_ptr)
 {
     if (lore_ptr->ability_flags.has(MonsterAbilityType::BO_ACID)) {
         set_damage(player_ptr, lore_ptr, MonsterAbilityType::BO_ACID, _("アシッド・ボルト%s", "produce acid bolts%s"));
@@ -421,7 +421,7 @@ void set_teleport_types(lore_type *lore_ptr)
     }
 }
 
-void set_floor_types(player_type *player_ptr, lore_type *lore_ptr)
+void set_floor_types(PlayerType *player_ptr, lore_type *lore_ptr)
 {
     if (lore_ptr->ability_flags.has(MonsterAbilityType::DARKNESS)) {
         if ((player_ptr->pclass != PlayerClassType::NINJA) || (lore_ptr->r_ptr->flags3 & (RF3_UNDEAD | RF3_HURT_LITE)) || (lore_ptr->r_ptr->flags7 & RF7_DARK_MASK)) {
index 8a23c5d..0eb6632 100644 (file)
@@ -1,12 +1,12 @@
 #pragma once
 
 struct lore_type;
-struct player_type;
-void set_breath_types(player_type *player_ptr, lore_type *lore_ptr);
-void set_ball_types(player_type *player_ptr, lore_type *lore_ptr);
-void set_particular_types(player_type *player_ptr, lore_type *lore_ptr);
-void set_bolt_types(player_type *player_ptr, lore_type *lore_ptr);
+class PlayerType;
+void set_breath_types(PlayerType *player_ptr, lore_type *lore_ptr);
+void set_ball_types(PlayerType *player_ptr, lore_type *lore_ptr);
+void set_particular_types(PlayerType *player_ptr, lore_type *lore_ptr);
+void set_bolt_types(PlayerType *player_ptr, lore_type *lore_ptr);
 void set_status_types(lore_type *lore_ptr);
 void set_teleport_types(lore_type *lore_ptr);
-void set_floor_types(player_type *player_ptr, lore_type *lore_ptr);
+void set_floor_types(PlayerType *player_ptr, lore_type *lore_ptr);
 void set_summon_types(lore_type *lore_ptr);
index b1c4329..55add50 100644 (file)
@@ -118,7 +118,7 @@ static void set_race_flags(lore_type *lore_ptr)
  * left edge of the screen, on a cleared line, in which the recall is
  * to take place.  One extra blank line is left after the recall.
  */
-void process_monster_lore(player_type *player_ptr, MONRACE_IDX r_idx, monster_lore_mode mode)
+void process_monster_lore(PlayerType *player_ptr, MONRACE_IDX r_idx, monster_lore_mode mode)
 {
     lore_type tmp_lore;
     lore_type *lore_ptr = initialize_lore_type(&tmp_lore, r_idx, mode);
index 51d0ff3..4167dd1 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "lore/lore-util.h"
 
-struct player_type;
-void process_monster_lore(player_type *player_ptr, MONRACE_IDX r_idx, monster_lore_mode mode);
+class PlayerType;
+void process_monster_lore(PlayerType *player_ptr, MONRACE_IDX r_idx, monster_lore_mode mode);
index cad5e3e..e6ffd65 100644 (file)
@@ -792,7 +792,7 @@ static void rebuild_term(term_data *td, bool resize_window = true)
 /*!
  * @brief React to global changes
  */
-static errr term_xtra_win_react(player_type *player_ptr)
+static errr term_xtra_win_react(PlayerType *player_ptr)
 {
     refresh_color_table();
 
@@ -929,7 +929,7 @@ static int term_xtra_win_delay(int v)
 
 /*!
  * @brief Do a "special thing"
- * @todo z-termに影響があるのでplayer_typeの追加は保留
+ * @todo z-termに影響があるのでPlayerTypeの追加は保留
  */
 static errr term_xtra_win(int n, int v)
 {
@@ -1528,7 +1528,7 @@ static void check_for_save_file(const std::string &savefile_option)
 /*!
  * @brief Process a menu command
  */
-static void process_menus(player_type *player_ptr, WORD wCmd)
+static void process_menus(PlayerType *player_ptr, WORD wCmd)
 {
     if (!initialized) {
         plog(_("まだ初期化中です...", "You cannot do that yet..."));
index 42572fd..76072d8 100644 (file)
@@ -208,7 +208,7 @@ static void put_title(void)
  * @param no_term TRUEならゲーム画面無しの状態で初期化を行う。
  *                コマンドラインからスポイラーの出力のみを行う時の使用を想定する。
  */
-void init_angband(player_type *player_ptr, bool no_term)
+void init_angband(PlayerType *player_ptr, bool no_term)
 {
     char buf[1024];
     path_build(buf, sizeof(buf), ANGBAND_DIR_FILE, _("news_j.txt", "news.txt"));
index 0d5d2c0..eab8433 100644 (file)
@@ -11,6 +11,6 @@
  * are included in all such copies.
  */
 
-struct player_type;
-void init_angband(player_type *player_ptr, bool no_term);
+class PlayerType;
+void init_angband(PlayerType *player_ptr, bool no_term);
 void init_file_paths(char *path, char *varpath);
index 281b108..d65b0ac 100644 (file)
@@ -51,7 +51,7 @@ void init_quests(void)
  * Initialize some other arrays
  * @return エラーコード
  */
-void init_other(player_type *player_ptr)
+void init_other(PlayerType *player_ptr)
 {
     player_ptr->current_floor_ptr = &floor_info; // TODO:本当はこんなところで初期化したくない
     auto *floor_ptr = player_ptr->current_floor_ptr;
index ea0a8ca..478f91b 100644 (file)
@@ -6,7 +6,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 void init_quests(void);
-void init_other(player_type *player_ptr);
+void init_other(PlayerType *player_ptr);
 void init_alloc(void);
index 1e85be0..47710d9 100644 (file)
@@ -47,7 +47,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return エラーコード
  */
-errr init_misc(player_type *player_ptr)
+errr init_misc(PlayerType *player_ptr)
 {
     return parse_fixed_map(player_ptr, "misc.txt", 0, 0, 0, 0);
 }
index b0bea95..69581a9 100644 (file)
@@ -6,8 +6,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-errr init_misc(player_type *player_ptr);
+class PlayerType;
+errr init_misc(PlayerType *player_ptr);
 errr init_f_info();
 errr init_k_info();
 errr init_a_info();
index dc0fb6e..e162069 100644 (file)
@@ -10,9 +10,9 @@
 #include "system/floor-type-definition.h"
 #include "system/player-type-definition.h"
 
-using scene_feel_func = bool (*)(player_type *player_ptr, scene_type *value);
+using scene_feel_func = bool (*)(PlayerType *player_ptr, scene_type *value);
 
-static bool scene_basic(player_type *player_ptr, scene_type *value)
+static bool scene_basic(PlayerType *player_ptr, scene_type *value)
 {
     if (player_ptr->ambush_flag) {
         value->type = TERM_XTRA_MUSIC_BASIC;
@@ -41,7 +41,7 @@ static bool scene_basic(player_type *player_ptr, scene_type *value)
     return false;
 }
 
-static bool scene_quest(player_type *player_ptr, scene_type *value)
+static bool scene_quest(PlayerType *player_ptr, scene_type *value)
 {
     const QUEST_IDX quest_id = quest_number(player_ptr, player_ptr->current_floor_ptr->dun_level);
     const bool enable = (quest_id > 0);
@@ -53,7 +53,7 @@ static bool scene_quest(player_type *player_ptr, scene_type *value)
     return enable;
 }
 
-static bool scene_quest_basic(player_type *player_ptr, scene_type *value)
+static bool scene_quest_basic(PlayerType *player_ptr, scene_type *value)
 {
     const QUEST_IDX quest_id = quest_number(player_ptr, player_ptr->current_floor_ptr->dun_level);
     const bool enable = (quest_id > 0);
@@ -65,7 +65,7 @@ static bool scene_quest_basic(player_type *player_ptr, scene_type *value)
     return enable;
 }
 
-static bool scene_town(player_type *player_ptr, scene_type *value)
+static bool scene_town(PlayerType *player_ptr, scene_type *value)
 {
     const bool enable = !is_in_dungeon(player_ptr) && (player_ptr->town_num > 0);
     if (enable) {
@@ -75,7 +75,7 @@ static bool scene_town(player_type *player_ptr, scene_type *value)
     return enable;
 }
 
-static bool scene_town_basic(player_type *player_ptr, scene_type *value)
+static bool scene_town_basic(PlayerType *player_ptr, scene_type *value)
 {
     const bool enable = !is_in_dungeon(player_ptr) && (player_ptr->town_num > 0);
     if (enable) {
@@ -85,7 +85,7 @@ static bool scene_town_basic(player_type *player_ptr, scene_type *value)
     return enable;
 }
 
-static bool scene_field(player_type *player_ptr, scene_type *value)
+static bool scene_field(PlayerType *player_ptr, scene_type *value)
 {
     const bool enable = !is_in_dungeon(player_ptr);
     if (enable) {
@@ -101,7 +101,7 @@ static bool scene_field(player_type *player_ptr, scene_type *value)
     return enable;
 }
 
-static bool scene_dungeon_feeling(player_type *player_ptr, scene_type *value)
+static bool scene_dungeon_feeling(PlayerType *player_ptr, scene_type *value)
 {
     const bool enable = (player_ptr->feeling >= 2) && (player_ptr->feeling <= 5);
     if (enable) {
@@ -115,7 +115,7 @@ static bool scene_dungeon_feeling(player_type *player_ptr, scene_type *value)
     return enable;
 }
 
-static bool scene_dungeon(player_type *player_ptr, scene_type *value)
+static bool scene_dungeon(PlayerType *player_ptr, scene_type *value)
 {
     const bool enable = (player_ptr->dungeon_idx > 0);
     if (enable) {
@@ -125,7 +125,7 @@ static bool scene_dungeon(player_type *player_ptr, scene_type *value)
     return enable;
 }
 
-static bool scene_dungeon_basic(player_type *player_ptr, scene_type *value)
+static bool scene_dungeon_basic(PlayerType *player_ptr, scene_type *value)
 {
     const bool enable = is_in_dungeon(player_ptr);
     if (enable) {
@@ -142,7 +142,7 @@ static bool scene_dungeon_basic(player_type *player_ptr, scene_type *value)
     return enable;
 }
 
-static bool scene_mute(player_type *player_ptr, scene_type *value)
+static bool scene_mute(PlayerType *player_ptr, scene_type *value)
 {
     (void)player_ptr;
     value->type = TERM_XTRA_MUSIC_MUTE;
@@ -188,7 +188,7 @@ int get_scene_floor_count()
  * @param list BGM選曲リスト
  * @param from_index リストの更新開始位置
  */
-void refresh_scene_floor(player_type *player_ptr, scene_type_list &list, int from_index)
+void refresh_scene_floor(PlayerType *player_ptr, scene_type_list &list, int from_index)
 {
     for (auto func : scene_floor_def_list) {
         scene_type &item = list[from_index];
index a24c491..9c6a902 100644 (file)
@@ -8,4 +8,4 @@
 #include "system/angband.h"
 
 int get_scene_floor_count();
-void refresh_scene_floor(player_type *player_ptr, scene_type_list &list, int start_index);
+void refresh_scene_floor(PlayerType *player_ptr, scene_type_list &list, int start_index);
index 6273f4c..b0add89 100644 (file)
@@ -82,7 +82,7 @@ inline static bool can_mute_scene_monster()
  * @retval true モンスターAが優先
  * @retval false モンスターBが優先
  */
-static bool is_high_rate(player_type *player_ptr, MONSTER_IDX m_idx1, MONSTER_IDX m_idx2)
+static bool is_high_rate(PlayerType *player_ptr, MONSTER_IDX m_idx1, MONSTER_IDX m_idx2)
 {
     // FIXME 視界内モンスターリストの比較関数と同じ処理
     auto floor_ptr = player_ptr->current_floor_ptr;
@@ -119,7 +119,7 @@ static bool is_high_rate(player_type *player_ptr, MONSTER_IDX m_idx1, MONSTER_ID
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param m_idx BGM対象候補のモンスター
  */
-static void update_target_monster(player_type *player_ptr, MONSTER_IDX m_idx)
+static void update_target_monster(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     if (scene_target_monster.ap_r_ptr && (scene_target_monster.m_idx == m_idx)) {
         // 同一モンスター。最後に見たゲームターンを更新。
@@ -144,9 +144,9 @@ static void update_target_monster(player_type *player_ptr, MONSTER_IDX m_idx)
     }
 }
 
-using scene_monster_func = bool (*)(player_type *player_ptr, scene_type *value);
+using scene_monster_func = bool (*)(PlayerType *player_ptr, scene_type *value);
 
-static bool scene_monster(player_type *player_ptr, scene_type *value)
+static bool scene_monster(PlayerType *player_ptr, scene_type *value)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[scene_target_monster.m_idx];
 
@@ -161,7 +161,7 @@ static bool scene_monster(player_type *player_ptr, scene_type *value)
     }
 }
 
-static bool scene_unique(player_type *player_ptr, scene_type *value)
+static bool scene_unique(PlayerType *player_ptr, scene_type *value)
 {
     (void)player_ptr;
 
@@ -174,7 +174,7 @@ static bool scene_unique(player_type *player_ptr, scene_type *value)
     return false;
 }
 
-static bool scene_unknown(player_type *player_ptr, scene_type *value)
+static bool scene_unknown(PlayerType *player_ptr, scene_type *value)
 {
     (void)player_ptr;
     if (is_unknown_monster(scene_target_monster.ap_r_ptr)) {
@@ -186,7 +186,7 @@ static bool scene_unknown(player_type *player_ptr, scene_type *value)
     return false;
 }
 
-static bool scene_high_level(player_type *player_ptr, scene_type *value)
+static bool scene_high_level(PlayerType *player_ptr, scene_type *value)
 {
     if (!is_unknown_monster(scene_target_monster.ap_r_ptr) && (scene_target_monster.ap_r_ptr->level >= player_ptr->lev)) {
         value->type = TERM_XTRA_MUSIC_BASIC;
@@ -226,7 +226,7 @@ int get_scene_monster_count()
  * @param list BGM選曲リスト
  * @param from_index リストの更新開始位置
  */
-void refresh_scene_monster(player_type *player_ptr, const std::vector<MONSTER_IDX> &monster_list, scene_type_list &list, int from_index)
+void refresh_scene_monster(PlayerType *player_ptr, const std::vector<MONSTER_IDX> &monster_list, scene_type_list &list, int from_index)
 {
     const bool mute = can_mute_scene_monster();
 
index 4fb7868..46f431b 100644 (file)
@@ -7,8 +7,8 @@
 #include "main/scene-table.h"
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 void clear_scene_target_monster();
 void set_temp_mute_scene_monster(int sec);
 int get_scene_monster_count();
-void refresh_scene_monster(player_type *player_ptr, const std::vector<MONSTER_IDX> &monster_list, scene_type_list &list, int from_index);
+void refresh_scene_monster(PlayerType *player_ptr, const std::vector<MONSTER_IDX> &monster_list, scene_type_list &list, int from_index);
index fde86cf..be6fa9e 100644 (file)
@@ -50,7 +50,7 @@ void interrupt_scene(int type, int val) {
  * @brief 現在のフロアに合ったBGM選曲
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void refresh_scene_table(player_type *player_ptr)
+void refresh_scene_table(PlayerType *player_ptr)
 {
     // clear interrupt_scene
     interrupt_scene(0, 0);
@@ -64,7 +64,7 @@ void refresh_scene_table(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monster_list 視界内モンスターリスト
  */
-void refresh_scene_table(player_type *player_ptr, const std::vector<MONSTER_IDX> &monster_list)
+void refresh_scene_table(PlayerType *player_ptr, const std::vector<MONSTER_IDX> &monster_list)
 {
     resize_scene_list();
     int index = 0;
index ebf1cf2..56577ff 100644 (file)
@@ -15,8 +15,8 @@ struct scene_type {
 
 using scene_type_list = std::vector<scene_type>;
 
-struct player_type;
+class PlayerType;
 void interrupt_scene(int type, int val);
-void refresh_scene_table(player_type *player_ptr);
-void refresh_scene_table(player_type *player_ptr, const std::vector<MONSTER_IDX> &monster_list);
+void refresh_scene_table(PlayerType *player_ptr);
+void refresh_scene_table(PlayerType *player_ptr, const std::vector<MONSTER_IDX> &monster_list);
 scene_type_list &get_scene_type_list(int val);
index 47fa809..d608cde 100644 (file)
@@ -54,7 +54,7 @@ errr play_music(int type, int val)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details 設定がない場合はミュートする。
  */
-void select_floor_music(player_type *player_ptr)
+void select_floor_music(PlayerType *player_ptr)
 {
     if (!use_music)
         return;
@@ -68,7 +68,7 @@ void select_floor_music(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monster_list モンスターリスト
  */
-void select_monster_music(player_type *player_ptr, const std::vector<MONSTER_IDX> &monster_list)
+void select_monster_music(PlayerType *player_ptr, const std::vector<MONSTER_IDX> &monster_list)
 {
     if (!use_music)
         return;
index 914dbf0..7f20954 100644 (file)
@@ -10,9 +10,9 @@
 
 extern bool has_monster_music;
 
-struct player_type;
+class PlayerType;
 void bell(void);
 void sound(int num);
 errr play_music(int type, int num);
-void select_floor_music(player_type *player_ptr);
-void select_monster_music(player_type *player_ptr, const std::vector<MONSTER_IDX> &monster_list);
+void select_floor_music(PlayerType *player_ptr);
+void select_monster_music(PlayerType *player_ptr, const std::vector<MONSTER_IDX> &monster_list);
index 7a16fba..4e6be1b 100644 (file)
@@ -33,7 +33,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return まだ優勝していないか、挑戦者モンスターとの戦いではFALSE
  */
-static bool process_ostensible_arena_victory(player_type *player_ptr)
+static bool process_ostensible_arena_victory(PlayerType *player_ptr)
 {
     if (player_ptr->arena_number != MAX_ARENA_MONS)
         return false;
@@ -57,7 +57,7 @@ static bool process_ostensible_arena_victory(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return まだパワー・ワイアーム以下を倒していないならFALSE、倒していたらTRUE
  */
-static bool battle_metal_babble(player_type *player_ptr)
+static bool battle_metal_babble(PlayerType *player_ptr)
 {
     if (player_ptr->arena_number <= MAX_ARENA_MONS)
         return false;
@@ -90,7 +90,7 @@ static bool battle_metal_babble(player_type *player_ptr)
     return true;
 }
 
-static void go_to_arena(player_type *player_ptr)
+static void go_to_arena(PlayerType *player_ptr)
 {
     if (process_ostensible_arena_victory(player_ptr))
         return;
@@ -113,7 +113,7 @@ static void go_to_arena(player_type *player_ptr)
     player_ptr->leave_bldg = true;
 }
 
-static void see_arena_poster(player_type *player_ptr)
+static void see_arena_poster(PlayerType *player_ptr)
 {
     if (player_ptr->arena_number == MAX_ARENA_MONS) {
         msg_print(_("あなたは勝利者だ。 アリーナでのセレモニーに参加しなさい。", "You are victorious. Enter the arena for the ceremony."));
@@ -140,7 +140,7 @@ static void see_arena_poster(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param cmd 闘技場処理のID
  */
-void arena_comm(player_type *player_ptr, int cmd)
+void arena_comm(PlayerType *player_ptr, int cmd)
 {
     switch (cmd) {
     case BACT_ARENA:
@@ -163,7 +163,7 @@ void arena_comm(player_type *player_ptr, int cmd)
  * @brief モンスター闘技場に参加するモンスターを更新する。
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void update_gambling_monsters(player_type *player_ptr)
+void update_gambling_monsters(PlayerType *player_ptr)
 {
     int total, i;
     int max_dl = 0;
@@ -272,7 +272,7 @@ void update_gambling_monsters(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 賭けを開始したか否か
  */
-bool monster_arena_comm(player_type *player_ptr)
+bool monster_arena_comm(PlayerType *player_ptr)
 {
     PRICE maxbet;
     PRICE wager;
index 2006922..da09489 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void arena_comm(player_type *player_ptr, int cmd);
-void update_gambling_monsters(player_type *player_ptr);
-bool monster_arena_comm(player_type *player_ptr);
+class PlayerType;
+void arena_comm(PlayerType *player_ptr, int cmd);
+void update_gambling_monsters(PlayerType *player_ptr);
+bool monster_arena_comm(PlayerType *player_ptr);
index c866caa..6d9345e 100644 (file)
@@ -42,7 +42,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 各種賞金首のいずれかでも換金が行われたか否か。
  */
-bool exchange_cash(player_type *player_ptr)
+bool exchange_cash(PlayerType *player_ptr)
 {
     bool change = false;
     GAME_TEXT o_name[MAX_NLEN];
@@ -197,7 +197,7 @@ bool exchange_cash(player_type *player_ptr)
  * @brief 本日の賞金首情報を表示する。
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void today_target(player_type *player_ptr)
+void today_target(PlayerType *player_ptr)
 {
     char buf[160];
     monster_race *r_ptr = &r_info[w_ptr->today_mon];
@@ -265,10 +265,10 @@ void show_bounty(void)
 
 /*!
  * @brief 今日の賞金首を確定する / Determine today's bounty monster
- * @param player_type プレイヤーへの参照ポインタ
+ * @param PlayerType プレイヤーへの参照ポインタ
  * @note conv_old is used if loaded 0.0.3 or older save file
  */
-void determine_daily_bounty(player_type *player_ptr, bool conv_old)
+void determine_daily_bounty(PlayerType *player_ptr, bool conv_old)
 {
     int max_dl = 3;
     if (!conv_old) {
@@ -314,7 +314,7 @@ void determine_daily_bounty(player_type *player_ptr, bool conv_old)
  * @brief 賞金首となるユニークを確定する / Determine bounty uniques
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void determine_bounty_uniques(player_type *player_ptr)
+void determine_bounty_uniques(PlayerType *player_ptr)
 {
     get_mon_num_prep_bounty(player_ptr);
 
index 6484782..5a3ceb5 100644 (file)
@@ -1,9 +1,9 @@
 #pragma once
 
-struct player_type;
-bool exchange_cash(player_type *player_ptr);
-void today_target(player_type *player_ptr);
+class PlayerType;
+bool exchange_cash(PlayerType *player_ptr);
+void today_target(PlayerType *player_ptr);
 void tsuchinoko(void);
 void show_bounty(void);
-void determine_daily_bounty(player_type *player_ptr, bool conv_old);
-void determine_bounty_uniques(player_type *player_ptr);
+void determine_daily_bounty(PlayerType *player_ptr, bool conv_old);
+void determine_bounty_uniques(PlayerType *player_ptr);
index b19ae1e..c2acf49 100644 (file)
@@ -88,7 +88,7 @@ static void give_one_ability_of_object(object_type *to_ptr, object_type *from_pt
  * @param bcost 基本修復費用
  * @return 実際にかかった費用
  */
-static PRICE repair_broken_weapon_aux(player_type *player_ptr, PRICE bcost)
+static PRICE repair_broken_weapon_aux(PlayerType *player_ptr, PRICE bcost)
 {
     clear_bldg(0, 22);
     int row = 7;
@@ -276,7 +276,7 @@ static PRICE repair_broken_weapon_aux(player_type *player_ptr, PRICE bcost)
  * @param bcost 基本鑑定費用
  * @return 実際にかかった費用
  */
-int repair_broken_weapon(player_type *player_ptr, PRICE bcost)
+int repair_broken_weapon(PlayerType *player_ptr, PRICE bcost)
 {
     PRICE cost;
     screen_save();
index 22a24a4..2b22b2f 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-int repair_broken_weapon(player_type *player_ptr, PRICE bcost);
+class PlayerType;
+int repair_broken_weapon(PlayerType *player_ptr, PRICE bcost);
index 28b70b8..364c0d0 100644 (file)
@@ -70,7 +70,7 @@ static HIT_POINT calc_slaydam(HIT_POINT dam, int mult, int div, bool force)
  * @return ダメージ期待値
  */
 static uint32_t calc_expect_dice(
-    player_type *player_ptr, uint32_t dam, int mult, int div, bool force, WEIGHT weight, int plus, int16_t meichuu, bool dokubari, bool impact, int vorpal_mult, int vorpal_div)
+    PlayerType *player_ptr, uint32_t dam, int mult, int div, bool force, WEIGHT weight, int plus, int16_t meichuu, bool dokubari, bool impact, int vorpal_mult, int vorpal_div)
 {
     dam = calc_slaydam(dam, mult, div, force);
     dam = calc_expect_crit(player_ptr, weight, plus, dam, meichuu, dokubari, impact);
@@ -116,7 +116,7 @@ static void show_weapon_dmg(int r, int c, int mindice, int maxdice, int blows, i
  * Only accurate for the current weapon, because it includes\n
  * the current number of blows for the player.\n
  */
-static void compare_weapon_aux(player_type *player_ptr, object_type *o_ptr, int col, int r)
+static void compare_weapon_aux(PlayerType *player_ptr, object_type *o_ptr, int col, int r)
 {
     int blow = player_ptr->num_blow[0];
     bool force = false;
@@ -296,7 +296,7 @@ static void compare_weapon_aux(player_type *player_ptr, object_type *o_ptr, int
 
 /*!
  * @brief 武器匠における武器一つ毎の完全情報を表示する。
- * @param player_type プレイヤーへの参照ポインタ
+ * @param PlayerType プレイヤーへの参照ポインタ
  * @param o_ptr オブジェクトの構造体の参照ポインタ。
  * @param row 表示する列の左端
  * @param col 表示する行の上端
@@ -306,7 +306,7 @@ static void compare_weapon_aux(player_type *player_ptr, object_type *o_ptr, int
  * Only accurate for the current weapon, because it includes
  * various info about the player's +to_dam and number of blows.
  */
-static void list_weapon(player_type *player_ptr, object_type *o_ptr, TERM_LEN row, TERM_LEN col)
+static void list_weapon(PlayerType *player_ptr, object_type *o_ptr, TERM_LEN row, TERM_LEN col)
 {
     GAME_TEXT o_name[MAX_NLEN];
     GAME_TEXT tmp_str[80];
@@ -345,7 +345,7 @@ static void list_weapon(player_type *player_ptr, object_type *o_ptr, TERM_LEN ro
  * @param bcost 基本鑑定費用
  * @return 最終的にかかった費用
  */
-PRICE compare_weapons(player_type *player_ptr, PRICE bcost)
+PRICE compare_weapons(PlayerType *player_ptr, PRICE bcost)
 {
     object_type *o_ptr[2];
     object_type orig_weapon;
index d7c44cd..5452dac 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-PRICE compare_weapons(player_type *player_ptr, PRICE bcost);
+class PlayerType;
+PRICE compare_weapons(PlayerType *player_ptr, PRICE bcost);
index cdc19d7..a158cb7 100644 (file)
@@ -22,7 +22,7 @@
  * @param to_ac ACをアップさせる量
  * @return 実際に行ったらTRUE
  */
-bool enchant_item(player_type *player_ptr, PRICE cost, HIT_PROB to_hit, HIT_POINT to_dam, ARMOUR_CLASS to_ac, const ItemTester& item_tester)
+bool enchant_item(PlayerType *player_ptr, PRICE cost, HIT_PROB to_hit, HIT_POINT to_dam, ARMOUR_CLASS to_ac, const ItemTester& item_tester)
 {
     clear_bldg(4, 18);
     int maxenchant = (player_ptr->lev / 5);
index c5dc311..c03deb8 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ItemTester;
-bool enchant_item(player_type *player_ptr, PRICE cost, HIT_PROB to_hit, HIT_POINT to_dam, ARMOUR_CLASS to_ac, const ItemTester &item_tester);
+bool enchant_item(PlayerType *player_ptr, PRICE cost, HIT_PROB to_hit, HIT_POINT to_dam, ARMOUR_CLASS to_ac, const ItemTester &item_tester);
index 219010a..bfd6463 100644 (file)
@@ -22,7 +22,7 @@
  * @return 常にTRUEを返す。
  * @todo 返り値が意味不明なので直した方が良いかもしれない。
  */
-bool research_mon(player_type *player_ptr)
+bool research_mon(PlayerType *player_ptr)
 {
     char buf[256];
     bool notpicked;
index 62544e4..55aac38 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool research_mon(player_type *player_ptr);
+class PlayerType;
+bool research_mon(PlayerType *player_ptr);
index 3740528..d158694 100644 (file)
@@ -21,7 +21,7 @@
  * @param questnum クエストのID
  * @param do_init クエストの開始処理か(true)、結果処理か(FALSE)
  */
-static void get_questinfo(player_type *player_ptr, IDX questnum, bool do_init)
+static void get_questinfo(PlayerType *player_ptr, IDX questnum, bool do_init)
 {
     for (int i = 0; i < 10; i++) {
         quest_text[i][0] = '\0';
@@ -47,7 +47,7 @@ static void get_questinfo(player_type *player_ptr, IDX questnum, bool do_init)
  * @param questnum クエストのID
  * @param do_init クエストの開始処理か(true)、結果処理か(FALSE)
  */
-void print_questinfo(player_type *player_ptr, IDX questnum, bool do_init)
+void print_questinfo(PlayerType *player_ptr, IDX questnum, bool do_init)
 {
     get_questinfo(player_ptr, questnum, do_init);
 
@@ -65,7 +65,7 @@ void print_questinfo(player_type *player_ptr, IDX questnum, bool do_init)
  * @brief クエスト処理のメインルーチン / Request a quest from the Lord.
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void castle_quest(player_type *player_ptr)
+void castle_quest(PlayerType *player_ptr)
 {
     clear_bldg(4, 18);
     QUEST_IDX q_index = player_ptr->current_floor_ptr->grid_array[player_ptr->y][player_ptr->x].special;
index 3c4f6da..6c090a6 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void castle_quest(player_type *player_ptr);
+class PlayerType;
+void castle_quest(PlayerType *player_ptr);
index 6c5616f..6ba006a 100644 (file)
@@ -31,7 +31,7 @@
  * the base-item.\n
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void building_recharge(player_type *player_ptr)
+void building_recharge(PlayerType *player_ptr)
 {
     msg_flag = false;
     clear_bldg(4, 18);
@@ -173,7 +173,7 @@ void building_recharge(player_type *player_ptr)
  * the base-item.\n
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void building_recharge_all(player_type *player_ptr)
+void building_recharge_all(PlayerType *player_ptr)
 {
     msg_flag = false;
     clear_bldg(4, 18);
index 27e588a..9197c06 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void building_recharge(player_type *player_ptr);
-void building_recharge_all(player_type *player_ptr);
+class PlayerType;
+void building_recharge(PlayerType *player_ptr);
+void building_recharge_all(PlayerType *player_ptr);
index 02afa96..22315ad 100644 (file)
@@ -15,7 +15,7 @@
  * @param bldg 施設構造体の参照ポインタ
  * @return 種族、職業、魔法領域のいずれかが一致しているかの是非。
  */
-bool is_owner(player_type *player_ptr, building_type *bldg)
+bool is_owner(PlayerType *player_ptr, building_type *bldg)
 {
     if (bldg->member_class[enum2i(player_ptr->pclass)] == BUILDING_OWNER) {
         return true;
@@ -44,7 +44,7 @@ bool is_owner(player_type *player_ptr, building_type *bldg)
  * @return 種族、職業、魔法領域のいずれかが一致しているかの是非。
  * @todo is_owner()との実質的な多重実装なので、リファクタリングを行うべきである。
  */
-bool is_member(player_type *player_ptr, building_type *bldg)
+bool is_member(PlayerType *player_ptr, building_type *bldg)
 {
     if (static_cast<bool>(bldg->member_class[enum2i(player_ptr->pclass)])) {
         return true;
@@ -76,7 +76,7 @@ bool is_member(player_type *player_ptr, building_type *bldg)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param bldg 施設構造体の参照ポインタ
  */
-void display_buikding_service(player_type *player_ptr, building_type *bldg)
+void display_buikding_service(PlayerType *player_ptr, building_type *bldg)
 {
     char buff[20];
     byte action_color;
index 4c076ab..5f6fc96 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 typedef struct building_type building_type;
-struct player_type;
-bool is_owner(player_type *player_ptr, building_type *bldg);
-bool is_member(player_type *player_ptr, building_type *bldg);
-void display_buikding_service(player_type *player_ptr, building_type *bldg);
+class PlayerType;
+bool is_owner(PlayerType *player_ptr, building_type *bldg);
+bool is_member(PlayerType *player_ptr, building_type *bldg);
+void display_buikding_service(PlayerType *player_ptr, building_type *bldg);
index b3fb269..df63bde 100644 (file)
@@ -20,7 +20,7 @@ void clear_bldg(int min_row, int max_row)
  * @brief 所持金を表示する。
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void building_prt_gold(player_type *player_ptr)
+void building_prt_gold(PlayerType *player_ptr)
 {
     char tmp_str[80];
     prt(_("手持ちのお金: ", "Gold Remaining: "), 23, 53);
index df9d484..34e5756 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 void clear_bldg(int min_row, int max_row);
-void building_prt_gold(player_type *player_ptr);
+void building_prt_gold(PlayerType *player_ptr);
index 9e28bbd..6241841 100644 (file)
@@ -18,7 +18,7 @@
  * @param cmd プレイするゲームID
  * @return プレイ成立やルール説明のみ等ならTRUE、賭け金不足で不成立ならFALSE
  */
-bool gamble_comm(player_type *player_ptr, int cmd)
+bool gamble_comm(PlayerType *player_ptr, int cmd)
 {
     int i;
     int roll1, roll2, roll3, choice, odds, win;
index c9ba88e..0090cc6 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool gamble_comm(player_type *player_ptr, int cmd);
+class PlayerType;
+bool gamble_comm(PlayerType *player_ptr, int cmd);
index 7fa54b7..d0e843f 100644 (file)
@@ -59,7 +59,7 @@ typedef struct mam_pp_type {
 } mam_pp_type;
 
 mam_pp_type *initialize_mam_pp_type(
-    player_type *player_ptr, mam_pp_type *mam_pp_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *dead, bool *fear, concptr note, MONSTER_IDX who)
+    PlayerType *player_ptr, mam_pp_type *mam_pp_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *dead, bool *fear, concptr note, MONSTER_IDX who)
 {
     mam_pp_ptr->m_idx = m_idx;
     mam_pp_ptr->m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
@@ -73,7 +73,7 @@ mam_pp_type *initialize_mam_pp_type(
     return mam_pp_ptr;
 }
 
-static void prepare_redraw(player_type *player_ptr, mam_pp_type *mam_pp_ptr)
+static void prepare_redraw(PlayerType *player_ptr, mam_pp_type *mam_pp_ptr)
 {
     if (!mam_pp_ptr->m_ptr->ml)
         return;
@@ -135,7 +135,7 @@ static bool process_all_resistances(mam_pp_type *mam_pp_ptr)
  * 見えない位置で死んだら何も表示しない
  * 爆発して粉々になった等ならその旨を、残りは生命か無生命かで分岐
  */
-static void print_monster_dead_by_monster(player_type *player_ptr, mam_pp_type *mam_pp_ptr)
+static void print_monster_dead_by_monster(PlayerType *player_ptr, mam_pp_type *mam_pp_ptr)
 {
     if (!mam_pp_ptr->known)
         return;
@@ -169,7 +169,7 @@ static void print_monster_dead_by_monster(player_type *player_ptr, mam_pp_type *
  * @param mam_pp_ptr 標的モンスター構造体への参照ポインタ
  * @return 生きていたらTRUE、それ以外 (ユニークは@以外の攻撃では死なない)はFALSE
  */
-static bool check_monster_hp(player_type *player_ptr, mam_pp_type *mam_pp_ptr)
+static bool check_monster_hp(PlayerType *player_ptr, mam_pp_type *mam_pp_ptr)
 {
     monster_race *r_ptr = &r_info[mam_pp_ptr->m_ptr->r_idx];
     if (mam_pp_ptr->m_ptr->hp < 0)
@@ -194,7 +194,7 @@ static bool check_monster_hp(player_type *player_ptr, mam_pp_type *mam_pp_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param mam_pp_ptr 標的モンスター構造体への参照ポインタ
  */
-static void cancel_fear_by_pain(player_type *player_ptr, mam_pp_type *mam_pp_ptr)
+static void cancel_fear_by_pain(PlayerType *player_ptr, mam_pp_type *mam_pp_ptr)
 {
     if (!monster_fear_remaining(mam_pp_ptr->m_ptr) || (mam_pp_ptr->dam <= 0)
         || !set_monster_monfear(player_ptr, mam_pp_ptr->m_idx, monster_fear_remaining(mam_pp_ptr->m_ptr) - randint1(mam_pp_ptr->dam / 4)))
@@ -208,7 +208,7 @@ static void cancel_fear_by_pain(player_type *player_ptr, mam_pp_type *mam_pp_ptr
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param mam_pp_ptr 標的モンスター構造体への参照ポインタ
  */
-static void make_monster_fear(player_type *player_ptr, mam_pp_type *mam_pp_ptr)
+static void make_monster_fear(PlayerType *player_ptr, mam_pp_type *mam_pp_ptr)
 {
     monster_race *r_ptr = &r_info[mam_pp_ptr->m_ptr->r_idx];
     if (monster_fear_remaining(mam_pp_ptr->m_ptr) || ((r_ptr->flags3 & RF3_NO_FEAR) == 0))
@@ -229,7 +229,7 @@ static void make_monster_fear(player_type *player_ptr, mam_pp_type *mam_pp_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param mam_pp_ptr 標的モンスター構造体への参照ポインタ
  */
-static void fall_off_horse_by_melee(player_type *player_ptr, mam_pp_type *mam_pp_ptr)
+static void fall_off_horse_by_melee(PlayerType *player_ptr, mam_pp_type *mam_pp_ptr)
 {
     if (!player_ptr->riding || (player_ptr->riding != mam_pp_ptr->m_idx) || (mam_pp_ptr->dam <= 0))
         return;
@@ -253,7 +253,7 @@ static void fall_off_horse_by_melee(player_type *player_ptr, mam_pp_type *mam_pp
  * @param who 打撃を行ったモンスターの参照ID
  * @todo 打撃が当たった時の後処理 (爆発持ちのモンスターを爆発させる等)なので、関数名を変更する必要あり
  */
-void mon_take_hit_mon(player_type *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *dead, bool *fear, concptr note, MONSTER_IDX who)
+void mon_take_hit_mon(PlayerType *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *dead, bool *fear, concptr note, MONSTER_IDX who)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
index c8aeab1..c237ef8 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "combat/combat-options-type.h"
 
-struct player_type;
-void mon_take_hit_mon(player_type *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *dead, bool *fear, concptr note, MONSTER_IDX who);
+class PlayerType;
+void mon_take_hit_mon(PlayerType *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *dead, bool *fear, concptr note, MONSTER_IDX who);
index aecd035..06e21c8 100644 (file)
@@ -29,7 +29,7 @@
 
 #include <iterator>
 
-static void decide_melee_spell_target(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void decide_melee_spell_target(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if ((player_ptr->pet_t_m_idx == 0) || !ms_ptr->pet)
         return;
@@ -40,7 +40,7 @@ static void decide_melee_spell_target(player_type *player_ptr, melee_spell_type
         ms_ptr->target_idx = 0;
 }
 
-static void decide_indirection_melee_spell(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void decide_indirection_melee_spell(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if ((ms_ptr->target_idx != 0) || (ms_ptr->m_ptr->target_y == 0))
         return;
@@ -62,7 +62,7 @@ static void decide_indirection_melee_spell(player_type *player_ptr, melee_spell_
     ms_ptr->ability_flags &= RF_ABILITY_INDIRECT_MASK;
 }
 
-static bool check_melee_spell_projection(player_type *player_ptr, melee_spell_type *ms_ptr)
+static bool check_melee_spell_projection(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (ms_ptr->target_idx != 0)
         return true;
@@ -94,7 +94,7 @@ static bool check_melee_spell_projection(player_type *player_ptr, melee_spell_ty
     return false;
 }
 
-static void check_darkness(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_darkness(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (ms_ptr->ability_flags.has_not(MonsterAbilityType::DARKNESS))
         return;
@@ -121,7 +121,7 @@ static void check_stupid(melee_spell_type *ms_ptr)
     ms_ptr->ability_flags &= RF_ABILITY_NOMAGIC_MASK;
 }
 
-static void check_arena(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_arena(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (!player_ptr->current_floor_ptr->inside_arena && !player_ptr->phase_out)
         return;
@@ -131,7 +131,7 @@ static void check_arena(player_type *player_ptr, melee_spell_type *ms_ptr)
         ms_ptr->ability_flags.reset(MonsterAbilityType::SPECIAL);
 }
 
-static void check_melee_spell_distance(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_melee_spell_distance(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     auto ball_mask_except_rocket = RF_ABILITY_BALL_MASK;
     ball_mask_except_rocket.reset(MonsterAbilityType::ROCKET);
@@ -160,7 +160,7 @@ static void check_melee_spell_distance(player_type *player_ptr, melee_spell_type
     ms_ptr->ability_flags.reset(RF_ABILITY_BIG_BALL_MASK);
 }
 
-static void check_melee_spell_rocket(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_melee_spell_rocket(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (ms_ptr->ability_flags.has_not(MonsterAbilityType::ROCKET))
         return;
@@ -172,7 +172,7 @@ static void check_melee_spell_rocket(player_type *player_ptr, melee_spell_type *
         ms_ptr->ability_flags.reset(MonsterAbilityType::ROCKET);
 }
 
-static void check_melee_spell_beam(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_melee_spell_beam(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (ms_ptr->ability_flags.has_none_of(RF_ABILITY_BEAM_MASK)
         || direct_beam(player_ptr, ms_ptr->m_ptr->fy, ms_ptr->m_ptr->fx, ms_ptr->t_ptr->fy, ms_ptr->t_ptr->fx, ms_ptr->m_ptr))
@@ -181,7 +181,7 @@ static void check_melee_spell_beam(player_type *player_ptr, melee_spell_type *ms
     ms_ptr->ability_flags.reset(RF_ABILITY_BEAM_MASK);
 }
 
-static void check_melee_spell_breath(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_melee_spell_breath(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (ms_ptr->ability_flags.has_none_of(RF_ABILITY_BREATH_MASK))
         return;
@@ -204,7 +204,7 @@ static void check_melee_spell_breath(player_type *player_ptr, melee_spell_type *
     }
 }
 
-static void check_melee_spell_special(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_melee_spell_special(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (ms_ptr->ability_flags.has_not(MonsterAbilityType::SPECIAL))
         return;
@@ -226,7 +226,7 @@ static void check_melee_spell_special(player_type *player_ptr, melee_spell_type
     ms_ptr->ability_flags.reset(MonsterAbilityType::SPECIAL);
 }
 
-static void check_riding(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_riding(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (ms_ptr->m_idx != player_ptr->riding)
         return;
@@ -234,7 +234,7 @@ static void check_riding(player_type *player_ptr, melee_spell_type *ms_ptr)
     ms_ptr->ability_flags.reset(RF_ABILITY_RIDING_MASK);
 }
 
-static void check_pet(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_pet(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (!ms_ptr->pet)
         return;
@@ -261,7 +261,7 @@ static void check_pet(player_type *player_ptr, melee_spell_type *ms_ptr)
     check_melee_spell_special(player_ptr, ms_ptr);
 }
 
-static void check_non_stupid(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_non_stupid(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if ((ms_ptr->r_ptr->flags2 & RF2_STUPID) != 0)
         return;
@@ -286,7 +286,7 @@ static void check_non_stupid(player_type *player_ptr, melee_spell_type *ms_ptr)
         ms_ptr->ability_flags.reset(MonsterAbilityType::SPECIAL);
 }
 
-static void check_smart(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void check_smart(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if ((ms_ptr->r_ptr->flags2 & RF2_SMART) == 0)
         return;
@@ -300,7 +300,7 @@ static void check_smart(player_type *player_ptr, melee_spell_type *ms_ptr)
         ms_ptr->ability_flags.reset(MonsterAbilityType::TELE_LEVEL);
 }
 
-static bool set_melee_spell_set(player_type *player_ptr, melee_spell_type *ms_ptr)
+static bool set_melee_spell_set(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (ms_ptr->ability_flags.none())
         return false;
@@ -310,7 +310,7 @@ static bool set_melee_spell_set(player_type *player_ptr, melee_spell_type *ms_pt
     return !ms_ptr->spells.empty() && player_ptr->playing && !player_ptr->is_dead && !player_ptr->leaving;
 }
 
-bool check_melee_spell_set(player_type *player_ptr, melee_spell_type *ms_ptr)
+bool check_melee_spell_set(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (monster_confused_remaining(ms_ptr->m_ptr))
         return false;
index 8f38128..84b02d7 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 typedef struct melee_spell_type melee_spell_type;
-struct player_type;
-bool check_melee_spell_set(player_type *player_ptr, melee_spell_type *ms_ptr);
+class PlayerType;
+bool check_melee_spell_set(PlayerType *player_ptr, melee_spell_type *ms_ptr);
index 9cc66e9..a796d23 100644 (file)
@@ -11,7 +11,7 @@
 #include "system/monster-type-definition.h"
 #include "system/player-type-definition.h"
 
-melee_spell_type *initialize_melee_spell_type(player_type *player_ptr, melee_spell_type *ms_ptr, MONSTER_IDX m_idx)
+melee_spell_type *initialize_melee_spell_type(PlayerType *player_ptr, melee_spell_type *ms_ptr, MONSTER_IDX m_idx)
 {
     ms_ptr->m_idx = m_idx;
     ms_ptr->y = 0;
index 2c442f0..57e3381 100644 (file)
@@ -33,5 +33,5 @@ typedef struct melee_spell_type {
     EnumClassFlagGroup<MonsterAbilityType> ability_flags;
 } melee_spell_type;
 
-struct player_type;
-melee_spell_type *initialize_melee_spell_type(player_type *player_ptr, melee_spell_type *ms_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+melee_spell_type *initialize_melee_spell_type(PlayerType *player_ptr, melee_spell_type *ms_ptr, MONSTER_IDX m_idx);
index d4405fe..41ebedf 100644 (file)
@@ -29,7 +29,7 @@
 #define RF5_SPELL_SIZE 32
 #define RF6_SPELL_SIZE 32
 
-static bool try_melee_spell(player_type *player_ptr, melee_spell_type *ms_ptr)
+static bool try_melee_spell(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (spell_is_inate(ms_ptr->thrown_spell) || (!ms_ptr->in_no_magic_dungeon && (!monster_stunned_remaining(ms_ptr->m_ptr) || one_in_(2))))
         return false;
@@ -41,7 +41,7 @@ static bool try_melee_spell(player_type *player_ptr, melee_spell_type *ms_ptr)
     return true;
 }
 
-static bool disturb_melee_spell(player_type *player_ptr, melee_spell_type *ms_ptr)
+static bool disturb_melee_spell(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     if (spell_is_inate(ms_ptr->thrown_spell) || !SpellHex(player_ptr).check_hex_barrier(ms_ptr->m_idx, HEX_ANTI_MAGIC))
         return false;
@@ -52,7 +52,7 @@ static bool disturb_melee_spell(player_type *player_ptr, melee_spell_type *ms_pt
     return true;
 }
 
-static void process_special_melee_spell(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void process_special_melee_spell(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     bool is_special_magic = ms_ptr->m_ptr->ml;
     is_special_magic &= ms_ptr->maneable;
@@ -86,7 +86,7 @@ static void process_rememberance(melee_spell_type *ms_ptr)
         ms_ptr->r_ptr->r_cast_spell++;
 }
 
-static void describe_melee_spell(player_type *player_ptr, melee_spell_type *ms_ptr)
+static void describe_melee_spell(PlayerType *player_ptr, melee_spell_type *ms_ptr)
 {
     /* Get the monster name (or "it") */
     monster_desc(player_ptr, ms_ptr->m_name, ms_ptr->m_ptr, 0x00);
@@ -110,7 +110,7 @@ static void describe_melee_spell(player_type *player_ptr, melee_spell_type *ms_p
  * @details
  * The player is only disturbed if able to be affected by the spell.
  */
-bool monst_spell_monst(player_type *player_ptr, MONSTER_IDX m_idx)
+bool monst_spell_monst(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     melee_spell_type tmp_ms;
     melee_spell_type *ms_ptr = initialize_melee_spell_type(player_ptr, &tmp_ms, m_idx);
index abef951..81304df 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool monst_spell_monst(player_type *player_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+bool monst_spell_monst(PlayerType *player_ptr, MONSTER_IDX m_idx);
index 2975e61..5115c0a 100644 (file)
@@ -14,7 +14,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-void describe_melee_method(player_type *player_ptr, mam_type *mam_ptr)
+void describe_melee_method(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     switch (mam_ptr->method) {
     case RBM_HIT: {
@@ -148,7 +148,7 @@ void describe_melee_method(player_type *player_ptr, mam_type *mam_ptr)
     }
 }
 
-void decide_monster_attack_effect(player_type *player_ptr, mam_type *mam_ptr)
+void decide_monster_attack_effect(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     switch (mam_ptr->effect) {
     case RaceBlowEffectType::NONE:
@@ -251,7 +251,7 @@ void decide_monster_attack_effect(player_type *player_ptr, mam_type *mam_ptr)
     }
 }
 
-void describe_monster_missed_monster(player_type *player_ptr, mam_type *mam_ptr)
+void describe_monster_missed_monster(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     switch (mam_ptr->method) {
     case RBM_HIT:
index eff8186..4abb3e5 100644 (file)
@@ -8,7 +8,7 @@ enum be_type {
 };
 
 typedef struct mam_type mam_type;
-struct player_type;
-void describe_melee_method(player_type *player_ptr, mam_type *mam_ptr);
-void decide_monster_attack_effect(player_type *player_ptr, mam_type *mam_ptr);
-void describe_monster_missed_monster(player_type *player_ptr, mam_type *mam_ptr);
+class PlayerType;
+void describe_melee_method(PlayerType *player_ptr, mam_type *mam_ptr);
+void decide_monster_attack_effect(PlayerType *player_ptr, mam_type *mam_ptr);
+void describe_monster_missed_monster(PlayerType *player_ptr, mam_type *mam_ptr);
index 8bf46d8..9c9f585 100644 (file)
@@ -7,7 +7,7 @@
 #include "system/monster-type-definition.h"
 #include "system/player-type-definition.h"
 
-mam_type *initialize_mam_type(player_type *player_ptr, mam_type *mam_ptr, MONRACE_IDX m_idx, MONRACE_IDX t_idx)
+mam_type *initialize_mam_type(PlayerType *player_ptr, mam_type *mam_ptr, MONRACE_IDX m_idx, MONRACE_IDX t_idx)
 {
     mam_ptr->attribute = 0;
     mam_ptr->m_idx = m_idx;
index 6574d98..3d73dce 100644 (file)
@@ -40,5 +40,5 @@ typedef struct mam_type {
     bool dead;
 } mam_type;
 
-struct player_type;
-mam_type *initialize_mam_type(player_type *player_ptr, mam_type *mam_ptr, MONRACE_IDX m_idx, MONRACE_IDX t_idx);
+class PlayerType;
+mam_type *initialize_mam_type(PlayerType *player_ptr, mam_type *mam_ptr, MONRACE_IDX m_idx, MONRACE_IDX t_idx);
index 41c222a..cbbdbac 100644 (file)
@@ -38,7 +38,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-static void heal_monster_by_melee(player_type *player_ptr, mam_type *mam_ptr)
+static void heal_monster_by_melee(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     if (!monster_living(mam_ptr->m_idx) || (mam_ptr->damage <= 2))
         return;
@@ -58,7 +58,7 @@ static void heal_monster_by_melee(player_type *player_ptr, mam_type *mam_ptr)
         msg_format(_("%sは体力を回復したようだ。", "%^s appears healthier."), mam_ptr->m_name);
 }
 
-static void process_blow_effect(player_type *player_ptr, mam_type *mam_ptr)
+static void process_blow_effect(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     monster_race *r_ptr = &r_info[mam_ptr->m_ptr->r_idx];
     switch (mam_ptr->attribute) {
@@ -76,7 +76,7 @@ static void process_blow_effect(player_type *player_ptr, mam_type *mam_ptr)
     }
 }
 
-static void aura_fire_by_melee(player_type *player_ptr, mam_type *mam_ptr)
+static void aura_fire_by_melee(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     monster_race *r_ptr = &r_info[mam_ptr->m_ptr->r_idx];
     monster_race *tr_ptr = &r_info[mam_ptr->t_ptr->r_idx];
@@ -98,7 +98,7 @@ static void aura_fire_by_melee(player_type *player_ptr, mam_type *mam_ptr)
         PROJECT_KILL | PROJECT_STOP | PROJECT_AIMED);
 }
 
-static void aura_cold_by_melee(player_type *player_ptr, mam_type *mam_ptr)
+static void aura_cold_by_melee(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     monster_race *r_ptr = &r_info[mam_ptr->m_ptr->r_idx];
     monster_race *tr_ptr = &r_info[mam_ptr->t_ptr->r_idx];
@@ -120,7 +120,7 @@ static void aura_cold_by_melee(player_type *player_ptr, mam_type *mam_ptr)
         PROJECT_KILL | PROJECT_STOP | PROJECT_AIMED);
 }
 
-static void aura_elec_by_melee(player_type *player_ptr, mam_type *mam_ptr)
+static void aura_elec_by_melee(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     monster_race *r_ptr = &r_info[mam_ptr->m_ptr->r_idx];
     monster_race *tr_ptr = &r_info[mam_ptr->t_ptr->r_idx];
@@ -142,7 +142,7 @@ static void aura_elec_by_melee(player_type *player_ptr, mam_type *mam_ptr)
         PROJECT_KILL | PROJECT_STOP | PROJECT_AIMED);
 }
 
-static bool check_same_monster(player_type *player_ptr, mam_type *mam_ptr)
+static bool check_same_monster(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     if (mam_ptr->m_idx == mam_ptr->t_idx)
         return false;
@@ -157,7 +157,7 @@ static bool check_same_monster(player_type *player_ptr, mam_type *mam_ptr)
     return true;
 }
 
-static void redraw_health_bar(player_type *player_ptr, mam_type *mam_ptr)
+static void redraw_health_bar(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     if (!mam_ptr->t_ptr->ml)
         return;
@@ -192,7 +192,7 @@ static void describe_silly_melee(mam_type *mam_ptr)
 #endif
 }
 
-static void process_monster_attack_effect(player_type *player_ptr, mam_type *mam_ptr)
+static void process_monster_attack_effect(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     if (mam_ptr->pt == AttributeType::NONE)
         return;
@@ -210,7 +210,7 @@ static void process_monster_attack_effect(player_type *player_ptr, mam_type *mam
     aura_elec_by_melee(player_ptr, mam_ptr);
 }
 
-static void process_melee(player_type *player_ptr, mam_type *mam_ptr)
+static void process_melee(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     if (mam_ptr->effect != RaceBlowEffectType::NONE && !check_hit_from_monster_to_monster(mam_ptr->power, mam_ptr->rlev, mam_ptr->ac, monster_stunned_remaining(mam_ptr->m_ptr))) {
         describe_monster_missed_monster(player_ptr, mam_ptr);
@@ -229,7 +229,7 @@ static void process_melee(player_type *player_ptr, mam_type *mam_ptr)
     process_monster_attack_effect(player_ptr, mam_ptr);
 }
 
-static void thief_runaway_by_melee(player_type *player_ptr, mam_type *mam_ptr)
+static void thief_runaway_by_melee(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     if (SpellHex(player_ptr).check_hex_barrier(mam_ptr->m_idx, HEX_ANTI_TELE)) {
         if (mam_ptr->see_m) {
@@ -248,7 +248,7 @@ static void thief_runaway_by_melee(player_type *player_ptr, mam_type *mam_ptr)
     }
 }
 
-static void explode_monster_by_melee(player_type *player_ptr, mam_type *mam_ptr)
+static void explode_monster_by_melee(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     if (!mam_ptr->explode)
         return;
@@ -265,7 +265,7 @@ static void explode_monster_by_melee(player_type *player_ptr, mam_type *mam_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param mam_ptr モンスター乱闘構造体への参照ポインタ
  */
-void repeat_melee(player_type *player_ptr, mam_type *mam_ptr)
+void repeat_melee(PlayerType *player_ptr, mam_type *mam_ptr)
 {
     monster_race *r_ptr = &r_info[mam_ptr->m_ptr->r_idx];
     for (int ap_cnt = 0; ap_cnt < MAX_NUM_BLOWS; ap_cnt++) {
@@ -299,7 +299,7 @@ void repeat_melee(player_type *player_ptr, mam_type *mam_ptr)
  * @param t_idx 目標側モンスターの参照ID
  * @return 実際に打撃処理が行われた場合TRUEを返す
  */
-bool monst_attack_monst(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx)
+bool monst_attack_monst(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx)
 {
     mam_type tmp_mam;
     mam_type *mam_ptr = initialize_mam_type(player_ptr, &tmp_mam, m_idx, t_idx);
index 0015f82..0c7c20c 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool monst_attack_monst(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx);
+class PlayerType;
+bool monst_attack_monst(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx);
index d045c34..a1f4148 100644 (file)
@@ -89,7 +89,7 @@ static bool select_ammo_creation_type(ammo_creation_type &type, PLAYER_LEVEL ple
  * Hook to determine if an object is contertible in an arrow/bolt
  * @return 製造を実際に行ったらTRUE、キャンセルしたらFALSEを返す
  */
-bool create_ammo(player_type *player_ptr)
+bool create_ammo(PlayerType *player_ptr)
 {
     if (cmd_limit_confused(player_ptr) || cmd_limit_blind(player_ptr))
         return false;
index c38f576..a6a1f79 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool create_ammo(player_type *player_ptr);
+class PlayerType;
+bool create_ammo(PlayerType *player_ptr);
index b8b1133..dfc768f 100644 (file)
@@ -22,7 +22,7 @@
  * @param spell 発動する特殊技能のID
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-bool cast_berserk_spell(player_type *player_ptr, mind_berserker_type spell)
+bool cast_berserk_spell(PlayerType *player_ptr, mind_berserker_type spell)
 {
     POSITION y, x;
     DIRECTION dir;
index 7081793..3cb7ee6 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 enum mind_berserker_type : int;
-struct player_type;
-bool cast_berserk_spell(player_type *player_ptr, mind_berserker_type spell);
+class PlayerType;
+bool cast_berserk_spell(PlayerType *player_ptr, mind_berserker_type spell);
index c570566..3a4161d 100644 (file)
@@ -29,7 +29,7 @@
  * do_cmd_cast calls this function if the player's class is 'Blue-Mage'.
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-bool do_cmd_cast_learned(player_type *player_ptr)
+bool do_cmd_cast_learned(PlayerType *player_ptr)
 {
     if (cmd_limit_confused(player_ptr))
         return false;
index 8e0dd83..732ab09 100644 (file)
@@ -10,8 +10,8 @@ enum class BlueMagicType {
     OTHER = 5,
 };
 
-struct player_type;
-bool do_cmd_cast_learned(player_type *player_ptr);
+class PlayerType;
+bool do_cmd_cast_learned(PlayerType *player_ptr);
 
 inline constexpr std::array BLUE_MAGIC_TYPE_LIST = {
     BlueMagicType::BOLT,
index 506873a..57cd5a1 100644 (file)
@@ -26,7 +26,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 結果はどうあれ騎乗したらTRUE
  */
-bool rodeo(player_type *player_ptr)
+bool rodeo(PlayerType *player_ptr)
 {
     GAME_TEXT m_name[MAX_NLEN];
     monster_type *m_ptr;
index f2e1cda..638ba66 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool rodeo(player_type *player_ptr);
+class PlayerType;
+bool rodeo(PlayerType *player_ptr);
index 8067aa0..00ef9ee 100644 (file)
@@ -8,7 +8,7 @@
 #include "system/object-type-definition.h"
 #include "system/player-type-definition.h"
 
-void acquire_chaos_weapon(player_type *player_ptr)
+void acquire_chaos_weapon(PlayerType *player_ptr)
 {
     object_type forge;
     object_type *q_ptr = &forge;
index a041f25..8053e2f 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void acquire_chaos_weapon(player_type *player_ptr);
+class PlayerType;
+void acquire_chaos_weapon(PlayerType *player_ptr);
index 5611996..566a17f 100644 (file)
@@ -329,7 +329,7 @@ AttributeType get_element_type(int realm_idx, int n)
  * @param n 属性の何番目か
  * @return 属性タイプ
  */
-static AttributeType get_element_spells_type(player_type *player_ptr, int n)
+static AttributeType get_element_spells_type(PlayerType *player_ptr, int n)
 {
     auto realm = element_types.at(i2enum<ElementRealmType>(player_ptr->element));
     auto t = realm.type.at(n);
@@ -368,7 +368,7 @@ concptr get_element_name(int realm_idx, int n)
  * @param spell_idx 呪文番号
  * @return 説明文
  */
-static concptr get_element_tip(player_type *player_ptr, int spell_idx)
+static concptr get_element_tip(PlayerType *player_ptr, int spell_idx)
 {
     auto realm = i2enum<ElementRealmType>(player_ptr->element);
     auto spell = i2enum<ElementSpells>(spell_idx);
@@ -382,7 +382,7 @@ static concptr get_element_tip(player_type *player_ptr, int spell_idx)
  * @param spell_idx 呪文番号
  * @return 説明文
  */
-static int get_elemental_elem(player_type *player_ptr, int spell_idx)
+static int get_elemental_elem(PlayerType *player_ptr, int spell_idx)
 {
     (void)player_ptr;
     auto spell = i2enum<ElementSpells>(spell_idx);
@@ -395,7 +395,7 @@ static int get_elemental_elem(player_type *player_ptr, int spell_idx)
  * @param spell_idx 呪文番号
  * @return 説明文
  */
-static mind_type get_elemental_info(player_type *player_ptr, int spell_idx)
+static mind_type get_elemental_info(PlayerType *player_ptr, int spell_idx)
 {
     (void)player_ptr;
     auto spell = i2enum<ElementSpells>(spell_idx);
@@ -409,7 +409,7 @@ static mind_type get_elemental_info(player_type *player_ptr, int spell_idx)
  * @param p バッファ
  * @return なし(pを更新)
  */
-void get_element_effect_info(player_type *player_ptr, int spell_idx, char *p)
+void get_element_effect_info(PlayerType *player_ptr, int spell_idx, char *p)
 {
     PLAYER_LEVEL plev = player_ptr->lev;
     auto spell = i2enum<ElementSpells>(spell_idx);
@@ -471,7 +471,7 @@ void get_element_effect_info(player_type *player_ptr, int spell_idx, char *p)
  * @param spell_idx 呪文番号
  * @return 実行したらTRUE、キャンセルならFALSE
  */
-static bool cast_element_spell(player_type *player_ptr, SPELL_IDX spell_idx)
+static bool cast_element_spell(PlayerType *player_ptr, SPELL_IDX spell_idx)
 {
     auto spell = i2enum<ElementSpells>(spell_idx);
     auto power = element_powers.at(spell);
@@ -624,7 +624,7 @@ static bool cast_element_spell(player_type *player_ptr, SPELL_IDX spell_idx)
  * @param spell_idx 呪文番号
  * @return 失敗率
  */
-static PERCENTAGE decide_element_chance(player_type *player_ptr, mind_type spell)
+static PERCENTAGE decide_element_chance(PlayerType *player_ptr, mind_type spell)
 {
     PERCENTAGE chance = spell.fail;
 
@@ -659,7 +659,7 @@ static PERCENTAGE decide_element_chance(player_type *player_ptr, mind_type spell
  * @param spell_idx 呪文番号
  * @return 消費MP
  */
-static MANA_POINT decide_element_mana_cost(player_type *player_ptr, mind_type spell)
+static MANA_POINT decide_element_mana_cost(PlayerType *player_ptr, mind_type spell)
 {
     (void)player_ptr;
     return spell.mana_cost;
@@ -672,7 +672,7 @@ static MANA_POINT decide_element_mana_cost(player_type *player_ptr, mind_type sp
  * @param only_browse 閲覧モードかどうか
  * @return 選んだらTRUE、選ばなかったらFALSE
  */
-bool get_element_power(player_type *player_ptr, SPELL_IDX *sn, bool only_browse)
+bool get_element_power(PlayerType *player_ptr, SPELL_IDX *sn, bool only_browse)
 {
     SPELL_IDX i;
     int num = 0;
@@ -843,7 +843,7 @@ bool get_element_power(player_type *player_ptr, SPELL_IDX *sn, bool only_browse)
  * @param mana_cost 消費MP
  * @return 詠唱するならTRUE、しないならFALSE
  */
-static bool check_element_mp_sufficiency(player_type *player_ptr, int mana_cost)
+static bool check_element_mp_sufficiency(PlayerType *player_ptr, int mana_cost)
 {
     if (mana_cost <= player_ptr->csp)
         return true;
@@ -862,7 +862,7 @@ static bool check_element_mp_sufficiency(player_type *player_ptr, int mana_cost)
  * @param chance 失敗率
  * @return 詠唱して実行したらTRUE、されなかったらFALSE
  */
-static bool try_cast_element_spell(player_type *player_ptr, SPELL_IDX spell_idx, PERCENTAGE chance)
+static bool try_cast_element_spell(PlayerType *player_ptr, SPELL_IDX spell_idx, PERCENTAGE chance)
 {
     if (randint0(100) >= chance) {
         sound(SOUND_ZAP);
@@ -896,7 +896,7 @@ static bool try_cast_element_spell(player_type *player_ptr, SPELL_IDX spell_idx,
  * @brief 元素魔法コマンドのメインルーチン
  * @param player_ptr プレイヤー情報への参照ポインタ
  */
-void do_cmd_element(player_type *player_ptr)
+void do_cmd_element(PlayerType *player_ptr)
 {
     SPELL_IDX i;
     if (cmd_limit_confused(player_ptr) || !get_element_power(player_ptr, &i, false))
@@ -937,7 +937,7 @@ void do_cmd_element(player_type *player_ptr)
  * @brief 現在プレイヤーが使用可能な元素魔法の一覧表示
  * @param player_ptr プレイヤー情報への参照ポインタ
  */
-void do_cmd_element_browse(player_type *player_ptr)
+void do_cmd_element_browse(PlayerType *player_ptr)
 {
     SPELL_IDX n = 0;
     char temp[62 * 5];
@@ -1020,7 +1020,7 @@ bool is_elemental_genocide_effective(monster_race *r_ptr, AttributeType type)
  * @param em_ptr 魔法効果情報への参照ポインタ
  * @return 効果処理を続けるかどうか
  */
-process_result effect_monster_elemental_genocide(player_type *player_ptr, effect_monster_type *em_ptr)
+process_result effect_monster_elemental_genocide(PlayerType *player_ptr, effect_monster_type *em_ptr)
 {
     auto type = get_element_type(player_ptr->element, 0);
     auto name = get_element_name(player_ptr->element, 0);
@@ -1060,7 +1060,7 @@ process_result effect_monster_elemental_genocide(player_type *player_ptr, effect
  * @details
  * レベルに応じて取得する耐性などの判定に使用する
  */
-bool has_element_resist(player_type *player_ptr, ElementRealmType realm, PLAYER_LEVEL lev)
+bool has_element_resist(PlayerType *player_ptr, ElementRealmType realm, PLAYER_LEVEL lev)
 {
     if (player_ptr->pclass != PlayerClassType::ELEMENTALIST)
         return false;
@@ -1129,7 +1129,7 @@ static int interpret_realm_select_key(int cs, int n, char c)
  * @param n 最後尾の位置
  * @return 領域番号
  */
-static int get_element_realm(player_type *player_ptr, int is, int n)
+static int get_element_realm(PlayerType *player_ptr, int is, int n)
 {
     int cs = std::max(0, is);
     int os = cs;
@@ -1195,7 +1195,7 @@ static int get_element_realm(player_type *player_ptr, int is, int n)
  * @param player_ptr プレイヤー情報への参照ポインタ
  * @return 領域番号
  */
-byte select_element_realm(player_type *player_ptr)
+byte select_element_realm(PlayerType *player_ptr)
 {
     clear_from(10);
 
@@ -1241,7 +1241,7 @@ byte select_element_realm(player_type *player_ptr)
  * @param player_ptr プレイヤー情報への参照ポインタ
  * @param rc_ptr レイシャルパワー情報への参照ポインタ
  */
-void switch_element_racial(player_type *player_ptr, rc_type *rc_ptr)
+void switch_element_racial(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     auto plev = player_ptr->lev;
     auto realm = i2enum<ElementRealmType>(player_ptr->element);
@@ -1330,14 +1330,14 @@ void switch_element_racial(player_type *player_ptr, rc_type *rc_ptr)
 /*!
  * @todo 宣言だけ。後日適切な場所に移動
  */
-static bool door_to_darkness(player_type *player_ptr, POSITION dist);
+static bool door_to_darkness(PlayerType *player_ptr, POSITION dist);
 
 /*!
  * @brief クラスパワーを実行
  * @param player_ptr プレイヤー情報への参照ポインタ
  * @return 実行したらTRUE、しなかったらFALSE
  */
-bool switch_element_execution(player_type *player_ptr)
+bool switch_element_execution(PlayerType *player_ptr)
 {
     auto realm = i2enum<ElementRealmType>(player_ptr->element);
     PLAYER_LEVEL plev = player_ptr->lev;
@@ -1424,7 +1424,7 @@ static bool is_target_grid_dark(floor_type *f_ptr, POSITION y, POSITION x)
  * @breif 暗いところ限定での次元の扉
  * @param player_ptr プレイヤー情報への参照ポインタ
  */
-static bool door_to_darkness(player_type *player_ptr, POSITION dist)
+static bool door_to_darkness(PlayerType *player_ptr, POSITION dist)
 {
     POSITION y = player_ptr->y;
     POSITION x = player_ptr->x;
index b9db8a2..5420c71 100644 (file)
@@ -15,17 +15,17 @@ enum class ElementRealmType {
        MAX
 };
 
-struct player_type;
+class PlayerType;
 struct effect_monster_type;
 struct rc_type;
 
 concptr get_element_title(int realm_idx);
 AttributeType get_element_type(int realm_idx, int n);
 concptr get_element_name(int realm_idx, int n);
-void do_cmd_element(player_type *player_ptr);
-void do_cmd_element_browse(player_type *player_ptr);
-process_result effect_monster_elemental_genocide(player_type *player_ptr, effect_monster_type *em_ptr);
-bool has_element_resist(player_type *player_ptr, ElementRealmType realm, PLAYER_LEVEL lev);
-byte select_element_realm(player_type *player_ptr);
-void switch_element_racial(player_type *player_ptr, rc_type *rc_ptr);
-bool switch_element_execution(player_type *player_ptr);
+void do_cmd_element(PlayerType *player_ptr);
+void do_cmd_element_browse(PlayerType *player_ptr);
+process_result effect_monster_elemental_genocide(PlayerType *player_ptr, effect_monster_type *em_ptr);
+bool has_element_resist(PlayerType *player_ptr, ElementRealmType realm, PLAYER_LEVEL lev);
+byte select_element_realm(PlayerType *player_ptr);
+void switch_element_racial(PlayerType *player_ptr, rc_type *rc_ptr);
+bool switch_element_execution(PlayerType *player_ptr);
index f0f652a..97cede6 100644 (file)
@@ -45,7 +45,7 @@
  * @param player_ptr プレイヤーの参照ポインタ
  * @return 現在溜まっている気の量
  */
-int32_t get_current_ki(player_type *player_ptr)
+int32_t get_current_ki(PlayerType *player_ptr)
 {
     auto data = PlayerClass(player_ptr).get_specific_data<force_trainer_data_type>();
 
@@ -58,7 +58,7 @@ int32_t get_current_ki(player_type *player_ptr)
  * @param is_reset TRUEなら気の量をkiにセットし、FALSEなら加減算を行う
  * @param ki 気の量
  */
-void set_current_ki(player_type *player_ptr, bool is_reset, int32_t ki)
+void set_current_ki(PlayerType *player_ptr, bool is_reset, int32_t ki)
 {
     auto data = PlayerClass(player_ptr).get_specific_data<force_trainer_data_type>();
     if (!data) {
@@ -73,7 +73,7 @@ void set_current_ki(player_type *player_ptr, bool is_reset, int32_t ki)
     data->ki += ki;
 }
 
-bool clear_mind(player_type *player_ptr)
+bool clear_mind(PlayerType *player_ptr)
 {
     if (total_friends) {
         msg_print(_("今はペットを操ることに集中していないと。", "Your pets demand all of your attention."));
@@ -97,7 +97,7 @@ bool clear_mind(player_type *player_ptr)
  * @param v 継続時間
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  */
-void set_lightspeed(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+void set_lightspeed(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -142,7 +142,7 @@ void set_lightspeed(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_sh_force(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_sh_force(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -182,7 +182,7 @@ bool set_tim_sh_force(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 命中したらTRUE
  */
-bool shock_power(player_type *player_ptr)
+bool shock_power(PlayerType *player_ptr)
 {
     int boost = get_current_ki(player_ptr);
     if (heavy_armor(player_ptr))
@@ -252,7 +252,7 @@ bool shock_power(player_type *player_ptr)
  * @param spell 発動する特殊技能のID
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-bool cast_force_spell(player_type *player_ptr, mind_force_trainer_type spell)
+bool cast_force_spell(PlayerType *player_ptr, mind_force_trainer_type spell)
 {
     DIRECTION dir;
     PLAYER_LEVEL plev = player_ptr->lev;
index b3fa110..84d2876 100644 (file)
@@ -2,13 +2,13 @@
 
 #include "system/angband.h"
 
-struct player_type;
-int32_t get_current_ki(player_type *player_ptr);
-void set_current_ki(player_type *player_ptr, bool is_reset, int32_t ki);
-bool clear_mind(player_type *player_ptr);
-void set_lightspeed(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tim_sh_force(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool shock_power(player_type *player_ptr);
+class PlayerType;
+int32_t get_current_ki(PlayerType *player_ptr);
+void set_current_ki(PlayerType *player_ptr, bool is_reset, int32_t ki);
+bool clear_mind(PlayerType *player_ptr);
+void set_lightspeed(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tim_sh_force(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool shock_power(PlayerType *player_ptr);
 
 enum mind_force_trainer_type : int;
-bool cast_force_spell(player_type *player_ptr, mind_force_trainer_type spell);
+bool cast_force_spell(PlayerType *player_ptr, mind_force_trainer_type spell);
index e7d0255..96dac2f 100644 (file)
@@ -6,7 +6,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-bool create_ration(player_type *player_ptr)
+bool create_ration(PlayerType *player_ptr)
 {
     object_type forge;
     object_type *q_ptr = &forge;
index f15e8f8..b16c3e3 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool create_ration(player_type *player_ptr);
+class PlayerType;
+bool create_ration(PlayerType *player_ptr);
index 97a4825..8f2a661 100644 (file)
@@ -6,7 +6,7 @@
 #include "player-info/equipment-info.h"
 #include "system/player-type-definition.h"
 
-static void switch_mind_mindcrafter(player_type *player_ptr, const PLAYER_LEVEL plev, const int power, char *p)
+static void switch_mind_mindcrafter(PlayerType *player_ptr, const PLAYER_LEVEL plev, const int power, char *p)
 {
     switch (power) {
     case 0:
@@ -57,7 +57,7 @@ static void switch_mind_mindcrafter(player_type *player_ptr, const PLAYER_LEVEL
     }
 }
 
-static void switch_mind_ki(player_type *player_ptr, const PLAYER_LEVEL plev, const int power, char *p)
+static void switch_mind_ki(PlayerType *player_ptr, const PLAYER_LEVEL plev, const int power, char *p)
 {
     int boost = get_current_ki(player_ptr);
     if (heavy_armor(player_ptr))
@@ -220,7 +220,7 @@ static void switch_mind_ninja(const PLAYER_LEVEL plev, const int power, char *p)
  * @param use_mind 職業毎の特殊技能ID
  * @param power モンスター魔法のID
  */
-void mindcraft_info(player_type *player_ptr, char *p, MindKindType use_mind, int power)
+void mindcraft_info(PlayerType *player_ptr, char *p, MindKindType use_mind, int power)
 {
     const PLAYER_LEVEL plev = player_ptr->lev;
     strcpy(p, "");
index 00ad3c2..bca6cf5 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 enum class MindKindType;
 
-void mindcraft_info(player_type *player_ptr, char *p, MindKindType use_mind, int power);
+void mindcraft_info(PlayerType *player_ptr, char *p, MindKindType use_mind, int power);
index c239c17..2ef72b4 100644 (file)
@@ -26,7 +26,7 @@
  * @param power 基本効力
  * @return ターンを消費した場合TRUEを返す
  */
-bool eat_magic(player_type *player_ptr, int power)
+bool eat_magic(PlayerType *player_ptr, int power)
 {
     byte fail_type = 1;
     GAME_TEXT o_name[MAX_NLEN];
index e3f5fb7..7133fb8 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool eat_magic(player_type *player_ptr, int power);
+class PlayerType;
+bool eat_magic(PlayerType *player_ptr, int power);
index 69ee1a8..d8f8ba7 100644 (file)
@@ -19,7 +19,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 取り込みを実行したらTRUE、キャンセルしたらFALSEを返す
  */
-bool import_magic_device(player_type *player_ptr)
+bool import_magic_device(PlayerType *player_ptr)
 {
     concptr q = _("どのアイテムの魔力を取り込みますか? ", "Gain power of which item? ");
     concptr s = _("魔力を取り込めるアイテムがない。", "There's nothing with power to absorb.");
index 74a3fc8..f225504 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool import_magic_device(player_type *player_ptr);
+class PlayerType;
+bool import_magic_device(PlayerType *player_ptr);
index 8974de7..bf2f7c0 100644 (file)
@@ -13,7 +13,7 @@
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_resist_magic(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_resist_magic(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
index 641e042..7e365c2 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool set_resist_magic(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+bool set_resist_magic(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
index c3b6496..e39b3cb 100644 (file)
@@ -51,7 +51,7 @@
  * good (Cure Light Wounds, Restore Strength, etc) or
  * bad (Poison, Weakness etc) or 'useless' (Slime Mold Juice, etc).
  */
-bool psychometry(player_type *player_ptr)
+bool psychometry(PlayerType *player_ptr)
 {
     concptr q = _("どのアイテムを調べますか?", "Meditate on which item? ");
     concptr s = _("調べるアイテムがありません。", "You have nothing appropriate.");
@@ -129,7 +129,7 @@ bool psychometry(player_type *player_ptr)
  * @param spell 発動する特殊技能のID
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-bool cast_mindcrafter_spell(player_type *player_ptr, mind_mindcrafter_type spell)
+bool cast_mindcrafter_spell(PlayerType *player_ptr, mind_mindcrafter_type spell)
 {
     bool b = false;
     int dam = 0;
index 5232780..aa7c9d4 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
-struct player_type;
-bool psychometry(player_type *player_ptr);
+class PlayerType;
+bool psychometry(PlayerType *player_ptr);
 
 enum mind_mindcrafter_type : int;
-bool cast_mindcrafter_spell(player_type *player_ptr, mind_mindcrafter_type spell);
+bool cast_mindcrafter_spell(PlayerType *player_ptr, mind_mindcrafter_type spell);
index 64e3e1a..e943b79 100644 (file)
 /*
  * @brief Multishadow effects is determined by turn
  */
-bool check_multishadow(player_type *player_ptr) { return (player_ptr->multishadow != 0) && ((w_ptr->game_turn & 1) != 0); }
+bool check_multishadow(PlayerType *player_ptr) { return (player_ptr->multishadow != 0) && ((w_ptr->game_turn & 1) != 0); }
 
 /*!
  * 静水
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return ペットを操っている場合を除きTRUE
  */
-bool mirror_concentration(player_type *player_ptr)
+bool mirror_concentration(PlayerType *player_ptr)
 {
     if (total_friends) {
         msg_print(_("今はペットを操ることに集中していないと。", "Your pets demand all of your attention."));
@@ -82,7 +82,7 @@ bool mirror_concentration(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param explode 爆発処理を伴うならばTRUE
  */
-void remove_all_mirrors(player_type *player_ptr, bool explode)
+void remove_all_mirrors(PlayerType *player_ptr, bool explode)
 {
     for (POSITION x = 0; x < player_ptr->current_floor_ptr->width; x++) {
         for (POSITION y = 0; y < player_ptr->current_floor_ptr->height; y++) {
@@ -104,7 +104,7 @@ void remove_all_mirrors(player_type *player_ptr, bool explode)
  * @param dam ダメージ量
  * @return 効果があったらTRUEを返す
  */
-bool binding_field(player_type *player_ptr, HIT_POINT dam)
+bool binding_field(PlayerType *player_ptr, HIT_POINT dam)
 {
     POSITION mirror_x[10], mirror_y[10]; /* 鏡はもっと少ない */
     int mirror_num = 0; /* 鏡の数 */
@@ -228,7 +228,7 @@ bool binding_field(player_type *player_ptr, HIT_POINT dam)
  * @param dam ダメージ量
  * @return 効果があったらTRUEを返す
  */
-void seal_of_mirror(player_type *player_ptr, HIT_POINT dam)
+void seal_of_mirror(PlayerType *player_ptr, HIT_POINT dam)
 {
     for (POSITION x = 0; x < player_ptr->current_floor_ptr->width; x++) {
         for (POSITION y = 0; y < player_ptr->current_floor_ptr->height; y++) {
@@ -250,7 +250,7 @@ void seal_of_mirror(player_type *player_ptr, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 常にTRUE
  */
-bool confusing_light(player_type *player_ptr)
+bool confusing_light(PlayerType *player_ptr)
 {
     msg_print(_("辺りを睨んだ...", "You glare at nearby monsters..."));
     slow_monsters(player_ptr, player_ptr->lev);
@@ -265,7 +265,7 @@ bool confusing_light(player_type *player_ptr)
  * @brief 鏡設置処理
  * @return 実際に設置が行われた場合TRUEを返す
  */
-bool place_mirror(player_type *player_ptr)
+bool place_mirror(PlayerType *player_ptr)
 {
     if (!cave_clean_bold(player_ptr->current_floor_ptr, player_ptr->y, player_ptr->x)) {
         msg_print(_("床上のアイテムが呪文を跳ね返した。", "The object resists the spell."));
@@ -292,7 +292,7 @@ bool place_mirror(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return ターンを消費した場合TRUEを返す
  */
-bool mirror_tunnel(player_type *player_ptr)
+bool mirror_tunnel(PlayerType *player_ptr)
 {
     POSITION x = 0, y = 0;
     if (!tgt_pt(player_ptr, &x, &y))
@@ -307,7 +307,7 @@ bool mirror_tunnel(player_type *player_ptr)
 /*
  * Set "multishadow", notice observable changes
  */
-bool set_multishadow(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_multishadow(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -349,7 +349,7 @@ bool set_multishadow(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_dustrobe(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_dustrobe(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -408,7 +408,7 @@ static int number_of_mirrors(floor_type *floor_ptr)
  * @param spell 発動する特殊技能のID
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-bool cast_mirror_spell(player_type *player_ptr, mind_mirror_master_type spell)
+bool cast_mirror_spell(PlayerType *player_ptr, mind_mirror_master_type spell)
 {
     DIRECTION dir;
     PLAYER_LEVEL plev = player_ptr->lev;
index 600c62f..6b2bbdd 100644 (file)
@@ -2,17 +2,17 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool check_multishadow(player_type *player_ptr);
-bool mirror_concentration(player_type *player_ptr);
-void remove_all_mirrors(player_type *player_ptr, bool explode);
-bool binding_field(player_type *player_ptr, HIT_POINT dam);
-void seal_of_mirror(player_type *player_ptr, HIT_POINT dam);
-bool confusing_light(player_type *player_ptr);
-bool place_mirror(player_type *player_ptr);
-bool mirror_tunnel(player_type *player_ptr);
-bool set_multishadow(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_dustrobe(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+bool check_multishadow(PlayerType *player_ptr);
+bool mirror_concentration(PlayerType *player_ptr);
+void remove_all_mirrors(PlayerType *player_ptr, bool explode);
+bool binding_field(PlayerType *player_ptr, HIT_POINT dam);
+void seal_of_mirror(PlayerType *player_ptr, HIT_POINT dam);
+bool confusing_light(PlayerType *player_ptr);
+bool place_mirror(PlayerType *player_ptr);
+bool mirror_tunnel(PlayerType *player_ptr);
+bool set_multishadow(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_dustrobe(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
 
 enum mind_mirror_master_type : int;
-bool cast_mirror_spell(player_type *player_ptr, mind_mirror_master_type spell);
+bool cast_mirror_spell(PlayerType *player_ptr, mind_mirror_master_type spell);
index 36b9935..e4fdef2 100644 (file)
@@ -14,7 +14,7 @@
 #include "util/int-char-converter.h"
 #include "view/display-messages.h"
 
-static void set_stance(player_type *player_ptr, const MonkStanceType new_stance)
+static void set_stance(PlayerType *player_ptr, const MonkStanceType new_stance)
 {
     set_action(player_ptr, ACTION_MONK_STANCE);
     PlayerClass pc(player_ptr);
@@ -33,7 +33,7 @@ static void set_stance(player_type *player_ptr, const MonkStanceType new_stance)
  * @brief 修行僧の構え設定処理
  * @return 構えを変化させたらTRUE、構え不能かキャンセルしたらFALSEを返す。
  */
-bool choose_monk_stance(player_type *player_ptr)
+bool choose_monk_stance(PlayerType *player_ptr)
 {
     if (cmd_limit_confused(player_ptr))
         return false;
index 4a1a798..4c3b4c0 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool choose_monk_stance(player_type *player_ptr);
+class PlayerType;
+bool choose_monk_stance(PlayerType *player_ptr);
index 1b06f96..a26f551 100644 (file)
@@ -68,7 +68,7 @@
  * @param success 判定成功上の処理ならばTRUE
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool kawarimi(player_type *player_ptr, bool success)
+bool kawarimi(PlayerType *player_ptr, bool success)
 {
     auto ninja_data = PlayerClass(player_ptr).get_specific_data<ninja_data_type>();
     if (!ninja_data || !ninja_data->kawarimi) {
@@ -124,7 +124,7 @@ bool kawarimi(player_type *player_ptr, bool success)
  * @param mdeath 目標モンスターが死亡したかを返す
  * @return 作用が実際にあった場合TRUEを返す /  Return value is for checking "done"
  */
-bool rush_attack(player_type *player_ptr, bool *mdeath)
+bool rush_attack(PlayerType *player_ptr, bool *mdeath)
 {
     if (mdeath)
         *mdeath = false;
@@ -217,7 +217,7 @@ bool rush_attack(player_type *player_ptr, bool *mdeath)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-void process_surprise_attack(player_type *player_ptr, player_attack_type *pa_ptr)
+void process_surprise_attack(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     monster_race *r_ptr = &r_info[pa_ptr->m_ptr->r_idx];
     if (!has_melee_weapon(player_ptr, INVEN_MAIN_HAND + pa_ptr->hand) || player_ptr->is_icky_wield[pa_ptr->hand])
@@ -260,7 +260,7 @@ void print_surprise_attack(player_attack_type *pa_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-void calc_surprise_attack_damage(player_type *player_ptr, player_attack_type *pa_ptr)
+void calc_surprise_attack_damage(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     if (pa_ptr->backstab) {
         pa_ptr->attack_damage *= (3 + (player_ptr->lev / 20));
@@ -281,7 +281,7 @@ void calc_surprise_attack_damage(player_type *player_ptr, player_attack_type *pa
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 常にTRUE
  */
-bool hayagake(player_type *player_ptr)
+bool hayagake(PlayerType *player_ptr)
 {
     PlayerEnergy energy(player_ptr);
     if (player_ptr->action == ACTION_HAYAGAKE) {
@@ -308,7 +308,7 @@ bool hayagake(player_type *player_ptr)
  * @param set TRUEならば超隠密状態になる。
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_superstealth(player_type *player_ptr, bool set)
+bool set_superstealth(PlayerType *player_ptr, bool set)
 {
     bool notice = false;
 
@@ -353,7 +353,7 @@ bool set_superstealth(player_type *player_ptr, bool set)
  * @param spell 発動する特殊技能のID
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-bool cast_ninja_spell(player_type *player_ptr, mind_ninja_type spell)
+bool cast_ninja_spell(PlayerType *player_ptr, mind_ninja_type spell)
 {
     POSITION x = 0, y = 0;
     DIRECTION dir;
index 2cc4618..e8c8aac 100644 (file)
@@ -1,14 +1,14 @@
 #pragma once
 
 struct player_attack_type;
-struct player_type;
-bool kawarimi(player_type *player_ptr, bool success);
-bool rush_attack(player_type *player_ptr, bool *mdeath);
-void process_surprise_attack(player_type *player_ptr, player_attack_type *pa_ptr);
+class PlayerType;
+bool kawarimi(PlayerType *player_ptr, bool success);
+bool rush_attack(PlayerType *player_ptr, bool *mdeath);
+void process_surprise_attack(PlayerType *player_ptr, player_attack_type *pa_ptr);
 void print_surprise_attack(player_attack_type *pa_ptr);
-void calc_surprise_attack_damage(player_type *player_ptr, player_attack_type *pa_ptr);
-bool hayagake(player_type *player_ptr);
-bool set_superstealth(player_type *player_ptr, bool set);
+void calc_surprise_attack_damage(PlayerType *player_ptr, player_attack_type *pa_ptr);
+bool hayagake(PlayerType *player_ptr);
+bool set_superstealth(PlayerType *player_ptr, bool set);
 
 enum mind_ninja_type : int;
-bool cast_ninja_spell(player_type *player_ptr, mind_ninja_type spell);
+bool cast_ninja_spell(PlayerType *player_ptr, mind_ninja_type spell);
index 761f087..fdab613 100644 (file)
@@ -21,7 +21,7 @@
 #include "util/enum-converter.h"
 #include "util/int-char-converter.h"
 
-MindPowerGetter::MindPowerGetter(player_type *player_ptr)
+MindPowerGetter::MindPowerGetter(PlayerType *player_ptr)
     : player_ptr(player_ptr)
     , menu_line(use_menu ? 1 : 0)
 {
index 4c03e17..a15afe8 100644 (file)
@@ -5,15 +5,15 @@
 
 struct mind_power;
 struct mind_type;
-struct player_type;
+class PlayerType;
 class MindPowerGetter {
 public:
-    MindPowerGetter(player_type *player_ptr);
+    MindPowerGetter(PlayerType *player_ptr);
     virtual ~MindPowerGetter() = default;
     bool get_mind_power(SPELL_IDX *sn, bool only_browse);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     SPELL_IDX index = 0;
     int num = 0;
     TERM_LEN y = 1;
index 1832b33..e3f0713 100644 (file)
@@ -23,7 +23,7 @@
  * Bless a weapon
  * @return ターン消費を要する処理を行ったならばTRUEを返す
  */
-bool bless_weapon(player_type *player_ptr)
+bool bless_weapon(PlayerType *player_ptr)
 {
     concptr q = _("どのアイテムを祝福しますか?", "Bless which weapon? ");
     concptr s = _("祝福できる武器がありません。", "You have weapon to bless.");
index 4d748b9..6fbfa43 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool bless_weapon(player_type *player_ptr);
+class PlayerType;
+bool bless_weapon(PlayerType *player_ptr);
index 9278c0e..8ffed6a 100644 (file)
@@ -66,7 +66,7 @@ static samurai_slaying_type *initialize_samurai_slaying_type(
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param samurai_slaying_ptr スレイ計算に必要なパラメータ群への参照ポインタ
  */
-static void hissatsu_burning_strike(player_type *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
+static void hissatsu_burning_strike(PlayerType *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
 {
     if (samurai_slaying_ptr->mode != HISSATSU_FIRE)
         return;
@@ -109,7 +109,7 @@ static void hissatsu_burning_strike(player_type *player_ptr, samurai_slaying_typ
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param samurai_slaying_ptr スレイ計算に必要なパラメータ群への参照ポインタ
  */
-static void hissatsu_serpent_tongue(player_type *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
+static void hissatsu_serpent_tongue(PlayerType *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
 {
     if (samurai_slaying_ptr->mode != HISSATSU_POISON)
         return;
@@ -152,7 +152,7 @@ static void hissatsu_zanma_ken(samurai_slaying_type *samurai_slaying_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param samurai_slaying_ptr スレイ計算に必要なパラメータ群への参照ポインタ
  */
-static void hissatsu_rock_smash(player_type *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
+static void hissatsu_rock_smash(PlayerType *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
 {
     if (samurai_slaying_ptr->mode != HISSATSU_HAGAN)
         return;
@@ -173,7 +173,7 @@ static void hissatsu_rock_smash(player_type *player_ptr, samurai_slaying_type *s
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param samurai_slaying_ptr スレイ計算に必要なパラメータ群への参照ポインタ
  */
-static void hissatsu_midare_setsugetsuka(player_type *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
+static void hissatsu_midare_setsugetsuka(PlayerType *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
 {
     if (samurai_slaying_ptr->mode != HISSATSU_COLD)
         return;
@@ -215,7 +215,7 @@ static void hissatsu_midare_setsugetsuka(player_type *player_ptr, samurai_slayin
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param samurai_slaying_ptr スレイ計算に必要なパラメータ群への参照ポインタ
  */
-static void hissatsu_lightning_eagle(player_type *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
+static void hissatsu_lightning_eagle(PlayerType *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
 {
     if (samurai_slaying_ptr->mode != HISSATSU_ELEC)
         return;
@@ -241,7 +241,7 @@ static void hissatsu_lightning_eagle(player_type *player_ptr, samurai_slaying_ty
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param samurai_slaying_ptr スレイ計算に必要なパラメータ群への参照ポインタ
  */
-static void hissatsu_bloody_maelstroem(player_type *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
+static void hissatsu_bloody_maelstroem(PlayerType *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
 {
     auto player_cut = player_ptr->effects()->cut();
     if ((samurai_slaying_ptr->mode == HISSATSU_SEKIRYUKA) && player_cut->is_cut() && monster_living(samurai_slaying_ptr->m_ptr->r_idx)) {
@@ -256,7 +256,7 @@ static void hissatsu_bloody_maelstroem(player_type *player_ptr, samurai_slaying_
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param samurai_slaying_ptr スレイ計算に必要なパラメータ群への参照ポインタ
  */
-static void hissatsu_keiun_kininken(player_type *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
+static void hissatsu_keiun_kininken(PlayerType *player_ptr, samurai_slaying_type *samurai_slaying_ptr)
 {
     if (samurai_slaying_ptr->mode != HISSATSU_UNDEAD)
         return;
@@ -286,7 +286,7 @@ static void hissatsu_keiun_kininken(player_type *player_ptr, samurai_slaying_typ
  * @param mode 剣術のスレイ型ID
  * @return スレイの倍率(/10倍)
  */
-MULTIPLY mult_hissatsu(player_type *player_ptr, MULTIPLY mult, const TrFlags &flags, monster_type *m_ptr, combat_options mode)
+MULTIPLY mult_hissatsu(PlayerType *player_ptr, MULTIPLY mult, const TrFlags &flags, monster_type *m_ptr, combat_options mode)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     samurai_slaying_type tmp_slaying;
@@ -306,7 +306,7 @@ MULTIPLY mult_hissatsu(player_type *player_ptr, MULTIPLY mult, const TrFlags &fl
     return samurai_slaying_ptr->mult;
 }
 
-void concentration(player_type *player_ptr)
+void concentration(PlayerType *player_ptr)
 {
     int max_csp = std::max(player_ptr->msp * 4, player_ptr->lev * 5 + 5);
 
@@ -335,7 +335,7 @@ void concentration(player_type *player_ptr)
  * @brief 剣術家の型設定処理
  * @return 型を変化させたらTRUE、型の構え不能かキャンセルしたらFALSEを返す。
  */
-bool choose_samurai_stance(player_type *player_ptr)
+bool choose_samurai_stance(PlayerType *player_ptr)
 {
     char choice;
     char buf[80];
@@ -415,7 +415,7 @@ bool choose_samurai_stance(player_type *player_ptr)
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  * @return 上昇後の命中率
  */
-int calc_attack_quality(player_type *player_ptr, player_attack_type *pa_ptr)
+int calc_attack_quality(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
     int bonus = player_ptr->to_h[pa_ptr->hand] + o_ptr->to_h;
@@ -442,7 +442,7 @@ int calc_attack_quality(player_type *player_ptr, player_attack_type *pa_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-void mineuchi(player_type *player_ptr, player_attack_type *pa_ptr)
+void mineuchi(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     if (pa_ptr->mode != HISSATSU_MINEUCHI)
         return;
@@ -471,7 +471,7 @@ void mineuchi(player_type *player_ptr, player_attack_type *pa_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-void musou_counterattack(player_type *player_ptr, monap_type *monap_ptr)
+void musou_counterattack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if ((!player_ptr->counter && !PlayerClass(player_ptr).samurai_stance_is(SamuraiStanceType::MUSOU)) || !monap_ptr->alive || player_ptr->is_dead || !monap_ptr->m_ptr->ml
         || (player_ptr->csp <= 7))
index 6df4ce5..5117d8d 100644 (file)
@@ -8,10 +8,10 @@
 typedef struct monap_type monap_type;
 struct monster_type;
 struct player_attack_type;
-struct player_type;
-MULTIPLY mult_hissatsu(player_type *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr, combat_options mode);
-void concentration(player_type *player_ptr);
-bool choose_samurai_stance(player_type* player_ptr);
-int calc_attack_quality(player_type *player_ptr, player_attack_type *pa_ptr);
-void mineuchi(player_type *player_ptr, player_attack_type *pa_ptr);
-void musou_counterattack(player_type *player_ptr, monap_type *monap_ptr);
+class PlayerType;
+MULTIPLY mult_hissatsu(PlayerType *player_ptr, MULTIPLY mult, const TrFlags &flgs, monster_type *m_ptr, combat_options mode);
+void concentration(PlayerType *player_ptr);
+bool choose_samurai_stance(PlayerType* player_ptr);
+int calc_attack_quality(PlayerType *player_ptr, player_attack_type *pa_ptr);
+void mineuchi(PlayerType *player_ptr, player_attack_type *pa_ptr);
+void musou_counterattack(PlayerType *player_ptr, monap_type *monap_ptr);
index 04910a6..f11d8c2 100644 (file)
@@ -130,7 +130,7 @@ static snipe_power const snipe_powers[MAX_SNIPE_POWERS] = {
  * @brief スナイパーの集中度加算
  * @return 集中度を加算した場合は true、そうでなければ false
  */
-static bool snipe_concentrate(player_type *player_ptr)
+static bool snipe_concentrate(PlayerType *player_ptr)
 {
     auto sniper_data = PlayerClass(player_ptr).get_specific_data<sniper_data_type>();
     if (!sniper_data) {
@@ -153,7 +153,7 @@ static bool snipe_concentrate(player_type *player_ptr)
  * スナイパーではない、もしくは集中度がすでに0であればなにもしない。
  * @param msg TRUEならばメッセージを表示する
  */
-void reset_concentration(player_type *player_ptr, bool msg)
+void reset_concentration(PlayerType *player_ptr, bool msg)
 {
     auto sniper_data = PlayerClass(player_ptr).get_specific_data<sniper_data_type>();
     if (!sniper_data) {
@@ -176,7 +176,7 @@ void reset_concentration(player_type *player_ptr, bool msg)
  * @param tdam 算出中のダメージ
  * @return 集中度修正を加えたダメージ
  */
-int boost_concentration_damage(player_type *player_ptr, int tdam)
+int boost_concentration_damage(PlayerType *player_ptr, int tdam)
 {
     auto sniper_data = PlayerClass(player_ptr).get_specific_data<sniper_data_type>();
     const auto sniper_concent = sniper_data ? sniper_data->concent : 0;
@@ -189,7 +189,7 @@ int boost_concentration_damage(player_type *player_ptr, int tdam)
 /*!
  * @brief スナイパーの技能リストを表示する
  */
-void display_snipe_list(player_type *player_ptr)
+void display_snipe_list(PlayerType *player_ptr)
 {
     int i;
     TERM_LEN y = 1;
@@ -238,7 +238,7 @@ void display_snipe_list(player_type *player_ptr)
  * when you run it. It's probably easy to fix but I haven't tried,\n
  * sorry.\n
  */
-static int get_snipe_power(player_type *player_ptr, COMMAND_CODE *sn, bool only_browse)
+static int get_snipe_power(PlayerType *player_ptr, COMMAND_CODE *sn, bool only_browse)
 {
     COMMAND_CODE i;
     int num = 0;
@@ -410,7 +410,7 @@ static int get_snipe_power(player_type *player_ptr, COMMAND_CODE *sn, bool only_
  * @param m_ptr 目標となるモンスターの構造体参照ポインタ
  * @return スレイの倍率(/10倍)
  */
-MULTIPLY calc_snipe_damage_with_slay(player_type *player_ptr, MULTIPLY mult, monster_type *m_ptr, SPELL_IDX snipe_type)
+MULTIPLY calc_snipe_damage_with_slay(PlayerType *player_ptr, MULTIPLY mult, monster_type *m_ptr, SPELL_IDX snipe_type)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     bool seen = is_seen(player_ptr, m_ptr);
@@ -523,7 +523,7 @@ MULTIPLY calc_snipe_damage_with_slay(player_type *player_ptr, MULTIPLY mult, mon
  * @param spell 発動する特殊技能のID
  * @return 処理を実行したらTRUE、キャンセルした場合FALSEを返す。
  */
-static bool cast_sniper_spell(player_type *player_ptr, int spell)
+static bool cast_sniper_spell(PlayerType *player_ptr, int spell)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_BOW];
     SPELL_IDX snipe_type = SP_NONE;
@@ -599,7 +599,7 @@ static bool cast_sniper_spell(player_type *player_ptr, int spell)
 /*!
  * @brief スナイパー技能コマンドのメインルーチン /
  */
-void do_cmd_snipe(player_type *player_ptr)
+void do_cmd_snipe(PlayerType *player_ptr)
 {
     COMMAND_CODE n = 0;
     bool cast;
@@ -626,7 +626,7 @@ void do_cmd_snipe(player_type *player_ptr)
 /*!
  * @brief スナイパー技能コマンドの表示 /
  */
-void do_cmd_snipe_browse(player_type *player_ptr)
+void do_cmd_snipe_browse(PlayerType *player_ptr)
 {
     COMMAND_CODE n = 0;
     int j, line;
index 0304336..7ecdb60 100644 (file)
@@ -3,10 +3,10 @@
 #include "system/angband.h"
 
 struct monster_type;
-struct player_type;
-void reset_concentration(player_type *player_ptr, bool msg);
-void display_snipe_list(player_type *player_ptr);
-MULTIPLY calc_snipe_damage_with_slay(player_type *player_ptr, MULTIPLY mult, monster_type *m_ptr, SPELL_IDX snipe_type);
-void do_cmd_snipe(player_type *player_ptr);
-void do_cmd_snipe_browse(player_type *player_ptr);
-int boost_concentration_damage(player_type *player_ptr, int tdam);
+class PlayerType;
+void reset_concentration(PlayerType *player_ptr, bool msg);
+void display_snipe_list(PlayerType *player_ptr);
+MULTIPLY calc_snipe_damage_with_slay(PlayerType *player_ptr, MULTIPLY mult, monster_type *m_ptr, SPELL_IDX snipe_type);
+void do_cmd_snipe(PlayerType *player_ptr);
+void do_cmd_snipe_browse(PlayerType *player_ptr);
+int boost_concentration_damage(PlayerType *player_ptr, int tdam);
index ad14b5f..33a2e74 100644 (file)
@@ -5,7 +5,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-bool comvert_hp_to_mp(player_type *player_ptr)
+bool comvert_hp_to_mp(PlayerType *player_ptr)
 {
     int gain_sp = take_hit(player_ptr, DAMAGE_USELIFE, player_ptr->lev, _("HPからMPへの無謀な変換", "thoughtless conversion from HP to SP")) / 5;
     if (!gain_sp) {
@@ -24,7 +24,7 @@ bool comvert_hp_to_mp(player_type *player_ptr)
     return true;
 }
 
-bool comvert_mp_to_hp(player_type *player_ptr)
+bool comvert_mp_to_hp(PlayerType *player_ptr)
 {
     if (player_ptr->csp >= player_ptr->lev / 5) {
         player_ptr->csp -= player_ptr->lev / 5;
index 2281542..840c00d 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-bool comvert_hp_to_mp(player_type *player_ptr);
-bool comvert_mp_to_hp(player_type *player_ptr);
+class PlayerType;
+bool comvert_hp_to_mp(PlayerType *player_ptr);
+bool comvert_mp_to_hp(PlayerType *player_ptr);
index d665e7e..1cc253f 100644 (file)
@@ -13,7 +13,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return コマンドの入力先にモンスターがいたらTRUE
  */
-bool hit_and_away(player_type *player_ptr)
+bool hit_and_away(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_direction(player_ptr, &dir, false, false))
@@ -39,7 +39,7 @@ bool hit_and_away(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 常にTRUE
  */
-bool sword_dancing(player_type *player_ptr)
+bool sword_dancing(PlayerType *player_ptr)
 {
     DIRECTION dir;
     POSITION y = 0, x = 0;
index 3dcdc17..da44de8 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-bool hit_and_away(player_type *player_ptr);
-bool sword_dancing(player_type *player_ptr);
+class PlayerType;
+bool hit_and_away(PlayerType *player_ptr);
+bool sword_dancing(PlayerType *player_ptr);
index 8894214..2226baf 100644 (file)
@@ -50,7 +50,7 @@ static concptr const kaji_tips[5] = {
 /*!
  * @brief 所持しているエッセンス一覧を表示する
  */
-static void display_essence(player_type *player_ptr)
+static void display_essence(PlayerType *player_ptr)
 {
     constexpr auto row_count = 21U;
     constexpr auto column_width = 22U;
@@ -108,7 +108,7 @@ static void display_essence(player_type *player_ptr)
  * @brief エッセンスの抽出処理
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void drain_essence(player_type *player_ptr)
+static void drain_essence(PlayerType *player_ptr)
 {
     auto q = _("どのアイテムから抽出しますか?", "Extract from which item? ");
     auto s = _("抽出できるアイテムがありません。", "You have nothing you can extract from.");
@@ -294,7 +294,7 @@ static void display_smith_effect_list(const Smith &smith, const std::vector<Smit
  * @brief エッセンスを実際に付加する
  * @param mode エッセンスの大別ID
  */
-static void add_essence(player_type *player_ptr, SmithCategoryType mode)
+static void add_essence(PlayerType *player_ptr, SmithCategoryType mode)
 {
     OBJECT_IDX item;
     bool flag;
@@ -525,7 +525,7 @@ static void add_essence(player_type *player_ptr, SmithCategoryType mode)
 /*!
  * @brief エッセンスを消去する
  */
-static void erase_essence(player_type *player_ptr)
+static void erase_essence(PlayerType *player_ptr)
 {
     OBJECT_IDX item;
     concptr q, s;
@@ -556,7 +556,7 @@ static void erase_essence(player_type *player_ptr)
  * @brief 鍛冶コマンドのメインルーチン
  * @param only_browse TRUEならばエッセンス一覧の表示のみを行う
  */
-void do_cmd_kaji(player_type *player_ptr, bool only_browse)
+void do_cmd_kaji(PlayerType *player_ptr, bool only_browse)
 {
     COMMAND_CODE mode = 0;
     char choice;
index a9d2009..164f199 100644 (file)
@@ -4,5 +4,5 @@
 // 最終的には鍛冶師ではリファクタリングの前後でのセーブファイル移行を不可にする
 #define MIN_SPECIAL_ESSENCE 200
 
-struct player_type;
-void do_cmd_kaji(player_type *player_ptr, bool only_browse);
+class PlayerType;
+void do_cmd_kaji(PlayerType *player_ptr, bool only_browse);
index f54ee2e..9bcda04 100644 (file)
@@ -70,7 +70,7 @@ static int calc_stun_resistance(player_attack_type *pa_ptr)
  * @return 技のランダム選択回数
  * @details ランダム選択は一番強い技が最終的に選択されるので、回数が多いほど有利
  */
-static int calc_max_blow_selection_times(player_type *player_ptr)
+static int calc_max_blow_selection_times(PlayerType *player_ptr)
 {
     PlayerClass pc(player_ptr);
     if (pc.monk_stance_is(MonkStanceType::BYAKKO))
@@ -91,7 +91,7 @@ static int calc_max_blow_selection_times(player_type *player_ptr)
  * @return 技のランダム選択回数
  * @return 技の行使に必要な最低レベル
  */
-static int select_blow(player_type *player_ptr, player_attack_type *pa_ptr, int max_blow_selection_times)
+static int select_blow(PlayerType *player_ptr, player_attack_type *pa_ptr, int max_blow_selection_times)
 {
     int min_level = 1;
     const martial_arts *old_ptr = &ma_blows[0];
@@ -159,7 +159,7 @@ static int process_monk_additional_effect(player_attack_type *pa_ptr, int *stun_
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 重さ
  */
-static WEIGHT calc_monk_attack_weight(player_type *player_ptr)
+static WEIGHT calc_monk_attack_weight(PlayerType *player_ptr)
 {
     WEIGHT weight = 8;
     if (PlayerClass(player_ptr).monk_stance_is(MonkStanceType::SUZAKU))
@@ -182,7 +182,7 @@ static WEIGHT calc_monk_attack_weight(player_type *player_ptr)
  * @param resist_stun 朦朧への抵抗値
  * @param special_effect 技を繰り出した時の追加効果
  */
-static void process_attack_vital_spot(player_type *player_ptr, player_attack_type *pa_ptr, int *stun_effect, int *resist_stun, const int special_effect)
+static void process_attack_vital_spot(PlayerType *player_ptr, player_attack_type *pa_ptr, int *stun_effect, int *resist_stun, const int special_effect)
 {
     monster_race *r_ptr = &r_info[pa_ptr->m_ptr->r_idx];
     if ((special_effect == MA_KNEE) && ((pa_ptr->attack_damage + player_ptr->to_d[pa_ptr->hand]) < pa_ptr->m_ptr->hp)) {
@@ -208,7 +208,7 @@ static void process_attack_vital_spot(player_type *player_ptr, player_attack_typ
  * @param stun_effect 朦朧の残りターン
  * @param resist_stun 朦朧への抵抗値
  */
-static void print_stun_effect(player_type *player_ptr, player_attack_type *pa_ptr, const int stun_effect, const int resist_stun)
+static void print_stun_effect(PlayerType *player_ptr, player_attack_type *pa_ptr, const int stun_effect, const int resist_stun)
 {
     monster_race *r_ptr = &r_info[pa_ptr->m_ptr->r_idx];
     if (stun_effect && ((pa_ptr->attack_damage + player_ptr->to_d[pa_ptr->hand]) < pa_ptr->m_ptr->hp)) {
@@ -228,7 +228,7 @@ static void print_stun_effect(player_type *player_ptr, player_attack_type *pa_pt
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  * @param g_ptr グリッドへの参照ポインタ
  */
-void process_monk_attack(player_type *player_ptr, player_attack_type *pa_ptr)
+void process_monk_attack(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     int resist_stun = calc_stun_resistance(pa_ptr);
     int max_blow_selection_times = calc_max_blow_selection_times(player_ptr);
@@ -246,7 +246,7 @@ void process_monk_attack(player_type *player_ptr, player_attack_type *pa_ptr)
     print_stun_effect(player_ptr, pa_ptr, stun_effect, resist_stun);
 }
 
-bool double_attack(player_type *player_ptr)
+bool double_attack(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_rep_dir(player_ptr, &dir, false))
index 9b482dd..999d785 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
 struct player_attack_type;
-struct player_type;
-void process_monk_attack(player_type *player_ptr, player_attack_type *pa_ptr);
-bool double_attack(player_type *player_ptr);
+class PlayerType;
+void process_monk_attack(PlayerType *player_ptr, player_attack_type *pa_ptr);
+bool double_attack(PlayerType *player_ptr);
index 68f2df8..a1184bc 100644 (file)
@@ -17,7 +17,7 @@
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  * @details 10% (毒の一次耐性があれば4%、二重耐性ならば1.6%)の確率で耐久が低下し、更に1/10の確率で永久低下する
  */
-void calc_blow_disease(player_type *player_ptr, monap_type *monap_ptr)
+void calc_blow_disease(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_resist_pois(player_ptr))
         monap_ptr->damage = monap_ptr->damage * (randint1(4) + 4) / 9;
@@ -48,7 +48,7 @@ void calc_blow_disease(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-void calc_blow_lose_strength(player_type *player_ptr, monap_type *monap_ptr)
+void calc_blow_lose_strength(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_sustain_str(player_ptr))
         monap_ptr->get_damage = monap_ptr->get_damage * (randint1(4) + 4) / 9;
@@ -66,7 +66,7 @@ void calc_blow_lose_strength(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-void calc_blow_lose_intelligence(player_type *player_ptr, monap_type *monap_ptr)
+void calc_blow_lose_intelligence(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_sustain_int(player_ptr))
         monap_ptr->get_damage = monap_ptr->get_damage * (randint1(4) + 4) / 9;
@@ -84,7 +84,7 @@ void calc_blow_lose_intelligence(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-void calc_blow_lose_wisdom(player_type *player_ptr, monap_type *monap_ptr)
+void calc_blow_lose_wisdom(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_sustain_wis(player_ptr))
         monap_ptr->get_damage = monap_ptr->get_damage * (randint1(4) + 4) / 9;
@@ -102,7 +102,7 @@ void calc_blow_lose_wisdom(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-void calc_blow_lose_dexterity(player_type *player_ptr, monap_type *monap_ptr)
+void calc_blow_lose_dexterity(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_sustain_dex(player_ptr))
         monap_ptr->get_damage = monap_ptr->get_damage * (randint1(4) + 4) / 9;
@@ -120,7 +120,7 @@ void calc_blow_lose_dexterity(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-void calc_blow_lose_constitution(player_type *player_ptr, monap_type *monap_ptr)
+void calc_blow_lose_constitution(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_sustain_con(player_ptr))
         monap_ptr->get_damage = monap_ptr->get_damage * (randint1(4) + 4) / 9;
@@ -138,7 +138,7 @@ void calc_blow_lose_constitution(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-void calc_blow_lose_charisma(player_type *player_ptr, monap_type *monap_ptr)
+void calc_blow_lose_charisma(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_sustain_chr(player_ptr))
         monap_ptr->get_damage = monap_ptr->get_damage * (randint1(4) + 4) / 9;
@@ -156,7 +156,7 @@ void calc_blow_lose_charisma(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-void calc_blow_lose_all(player_type *player_ptr, monap_type *monap_ptr)
+void calc_blow_lose_all(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     int damage_ratio = 100;
     if (has_sustain_str(player_ptr))
index a93a85d..45c0f5f 100644 (file)
@@ -1,12 +1,12 @@
 #pragma once
 
 typedef struct monap_type monap_type;
-struct player_type;
-void calc_blow_disease(player_type *player_ptr, monap_type *monap_ptr);
-void calc_blow_lose_strength(player_type *player_ptr, monap_type *monap_ptr);
-void calc_blow_lose_intelligence(player_type *player_ptr, monap_type *monap_ptr);
-void calc_blow_lose_wisdom(player_type *player_ptr, monap_type *monap_ptr);
-void calc_blow_lose_dexterity(player_type *player_ptr, monap_type *monap_ptr);
-void calc_blow_lose_constitution(player_type *player_ptr, monap_type *monap_ptr);
-void calc_blow_lose_charisma(player_type *player_ptr, monap_type *monap_ptr);
-void calc_blow_lose_all(player_type *player_ptr, monap_type *monap_ptr);
+class PlayerType;
+void calc_blow_disease(PlayerType *player_ptr, monap_type *monap_ptr);
+void calc_blow_lose_strength(PlayerType *player_ptr, monap_type *monap_ptr);
+void calc_blow_lose_intelligence(PlayerType *player_ptr, monap_type *monap_ptr);
+void calc_blow_lose_wisdom(PlayerType *player_ptr, monap_type *monap_ptr);
+void calc_blow_lose_dexterity(PlayerType *player_ptr, monap_type *monap_ptr);
+void calc_blow_lose_constitution(PlayerType *player_ptr, monap_type *monap_ptr);
+void calc_blow_lose_charisma(PlayerType *player_ptr, monap_type *monap_ptr);
+void calc_blow_lose_all(PlayerType *player_ptr, monap_type *monap_ptr);
index 0e1a695..e56b980 100644 (file)
@@ -57,7 +57,7 @@
 #include "util/bit-flags-calculator.h"
 #include "view/display-messages.h"
 
-static bool check_no_blow(player_type *player_ptr, monap_type *monap_ptr)
+static bool check_no_blow(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     auto *r_ptr = &r_info[monap_ptr->m_ptr->r_idx];
     if (any_bits(r_ptr->flags1, RF1_NEVER_BLOW)) {
@@ -77,7 +77,7 @@ static bool check_no_blow(player_type *player_ptr, monap_type *monap_ptr)
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  * @return 攻撃続行ならばTRUE、打ち切りになったらFALSE
  */
-static bool check_monster_continuous_attack(player_type *player_ptr, monap_type *monap_ptr)
+static bool check_monster_continuous_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!monster_is_valid(monap_ptr->m_ptr) || (monap_ptr->method == RBM_NONE)) {
         return false;
@@ -99,7 +99,7 @@ static bool check_monster_continuous_attack(player_type *player_ptr, monap_type
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  * @return briefに書いた条件+確率が満たされたらTRUE、それ以外はFALSE
  */
-static bool effect_protecion_from_evil(player_type *player_ptr, monap_type *monap_ptr)
+static bool effect_protecion_from_evil(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     auto *r_ptr = &r_info[monap_ptr->m_ptr->r_idx];
     if ((player_ptr->protevil <= 0) || none_bits(r_ptr->flags3, RF3_EVIL) || (player_ptr->lev < monap_ptr->rlev) || ((randint0(100) + player_ptr->lev) <= 50)) {
@@ -166,7 +166,7 @@ static void select_cut_stun(monap_type *monap_ptr)
     }
 }
 
-static void calc_player_cut(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_player_cut(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (monap_ptr->do_cut == 0) {
         return;
@@ -180,7 +180,7 @@ static void calc_player_cut(player_type *player_ptr, monap_type *monap_ptr)
 
 /*!
  * @brief 能力値の実値を求める
- * @param raw player_typeに格納されている生値
+ * @param raw PlayerTypeに格納されている生値
  * @return 実値
  * @details AD&Dの記法に則り、19以上の値を取らなくしているので、格納方法が面倒
  */
@@ -202,7 +202,7 @@ static int stat_value(const int raw)
  * 2%の確率で朦朧蓄積ランクを1上げる.
  * 肉体のパラメータが合計80を超える水準に強化されていたら朦朧蓄積ランクを1下げる.
  */
-static void process_player_stun(player_type *player_ptr, monap_type *monap_ptr)
+static void process_player_stun(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (monap_ptr->do_stun == 0) {
         return;
@@ -236,7 +236,7 @@ static void process_player_stun(player_type *player_ptr, monap_type *monap_ptr)
     }
 }
 
-static void monster_explode(player_type *player_ptr, monap_type *monap_ptr)
+static void monster_explode(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!monap_ptr->explode) {
         return;
@@ -250,7 +250,7 @@ static void monster_explode(player_type *player_ptr, monap_type *monap_ptr)
     }
 }
 
-static void describe_attack_evasion(player_type *player_ptr, monap_type *monap_ptr)
+static void describe_attack_evasion(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!monap_ptr->m_ptr->ml) {
         return;
@@ -271,7 +271,7 @@ static void describe_attack_evasion(player_type *player_ptr, monap_type *monap_p
 #endif
 }
 
-static void gain_armor_exp(player_type *player_ptr, monap_type *monap_ptr)
+static void gain_armor_exp(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     const auto o_ptr_mh = &player_ptr->inventory_list[INVEN_MAIN_HAND];
     const auto o_ptr_sh = &player_ptr->inventory_list[INVEN_SUB_HAND];
@@ -304,7 +304,7 @@ static void gain_armor_exp(player_type *player_ptr, monap_type *monap_ptr)
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  * @details 最大4 回/モンスター/ターン、このルーチンを通る
  */
-static bool process_monster_attack_hit(player_type *player_ptr, monap_type *monap_ptr)
+static bool process_monster_attack_hit(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     disturb(player_ptr, true, true);
     if (effect_protecion_from_evil(player_ptr, monap_ptr)) {
@@ -335,7 +335,7 @@ static bool process_monster_attack_hit(player_type *player_ptr, monap_type *mona
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void process_monster_attack_evasion(player_type *player_ptr, monap_type *monap_ptr)
+static void process_monster_attack_evasion(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     switch (monap_ptr->method) {
     case RBM_HIT:
@@ -368,7 +368,7 @@ static void process_monster_attack_evasion(player_type *player_ptr, monap_type *
  * 非自明な類の打撃については、そのダメージが 0 ならば基本的に知識が増えない.
  * 但し、既に一定以上の知識があれば常に知識が増える(何をされたのか察知できる).
  */
-static void increase_blow_type_seen(player_type *player_ptr, monap_type *monap_ptr, const int ap_cnt)
+static void increase_blow_type_seen(PlayerType *player_ptr, monap_type *monap_ptr, const int ap_cnt)
 {
     if (!is_original_ap_and_seen(player_ptr, monap_ptr->m_ptr) || monap_ptr->do_silly_attack) {
         return;
@@ -388,7 +388,7 @@ static void increase_blow_type_seen(player_type *player_ptr, monap_type *monap_p
  * @brief モンスターからプレイヤーへの打撃処理本体
  * @return 打撃に反応してプレイヤーがその場から離脱したかどうか
  */
-static bool process_monster_blows(player_type *player_ptr, monap_type *monap_ptr)
+static bool process_monster_blows(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     auto *r_ptr = &r_info[monap_ptr->m_ptr->r_idx];
     for (auto ap_cnt = 0; ap_cnt < MAX_NUM_BLOWS; ap_cnt++) {
@@ -454,7 +454,7 @@ static bool process_monster_blows(player_type *player_ptr, monap_type *monap_ptr
     return false;
 }
 
-static void postprocess_monster_blows(player_type *player_ptr, monap_type *monap_ptr)
+static void postprocess_monster_blows(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     SpellHex spell_hex(player_ptr, monap_ptr);
     spell_hex.store_vengeful_damage(monap_ptr->get_damage);
@@ -479,7 +479,7 @@ static void postprocess_monster_blows(player_type *player_ptr, monap_type *monap
  * @param m_idx 打撃を行うモンスターのID
  * @return 実際に攻撃処理を行った場合TRUEを返す
  */
-bool make_attack_normal(player_type *player_ptr, MONSTER_IDX m_idx)
+bool make_attack_normal(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monap_type tmp_monap;
     monap_type *monap_ptr = initialize_monap_type(player_ptr, &tmp_monap, m_idx);
index 19a1fa0..ddfb5c2 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool make_attack_normal(player_type *player_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+bool make_attack_normal(PlayerType *player_ptr, MONSTER_IDX m_idx);
index 53f8e92..56b6ba8 100644 (file)
@@ -33,7 +33,7 @@
  * @details
  * 反攻撃の洞窟など、直接攻撃ができない場所では処理をスキップする
  */
-void exe_monster_attack_to_player(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION ny, POSITION nx)
+void exe_monster_attack_to_player(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION ny, POSITION nx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -70,7 +70,7 @@ void exe_monster_attack_to_player(player_type *player_ptr, turn_flags *turn_flag
  * @param m_idx モンスターID
  * @param g_ptr グリッドへの参照ポインタ
  */
-static bool exe_monster_attack_to_monster(player_type *player_ptr, MONSTER_IDX m_idx, grid_type *g_ptr)
+static bool exe_monster_attack_to_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, grid_type *g_ptr)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -108,7 +108,7 @@ static bool exe_monster_attack_to_monster(player_type *player_ptr, MONSTER_IDX m
  * @param can_cross モンスターが地形を踏破できるならばTRUE
  * @return ターン消費が発生したらTRUE
  */
-bool process_monster_attack_to_monster(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, grid_type *g_ptr, bool can_cross)
+bool process_monster_attack_to_monster(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, grid_type *g_ptr, bool can_cross)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
index ae713da..c0f9a36 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct grid_type;;
-struct player_type;
+class PlayerType;
 struct turn_flags;
-void exe_monster_attack_to_player(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION ny, POSITION nx);
-bool process_monster_attack_to_monster(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, grid_type *g_ptr, bool can_cross);
+void exe_monster_attack_to_player(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION ny, POSITION nx);
+bool process_monster_attack_to_monster(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, grid_type *g_ptr, bool can_cross);
index 1b78f39..1f88fa9 100644 (file)
@@ -20,7 +20,7 @@
 #include "timed-effect/timed-effects.h"
 #include "view/display-messages.h"
 
-void process_blind_attack(player_type *player_ptr, monap_type *monap_ptr)
+void process_blind_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_resist_blind(player_ptr) || check_multishadow(player_ptr)) {
         return;
@@ -45,7 +45,7 @@ void process_blind_attack(player_type *player_ptr, monap_type *monap_ptr)
     monap_ptr->obvious = true;
 }
 
-void process_terrify_attack(player_type *player_ptr, monap_type *monap_ptr)
+void process_terrify_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (check_multishadow(player_ptr)) {
         return;
@@ -69,7 +69,7 @@ void process_terrify_attack(player_type *player_ptr, monap_type *monap_ptr)
     }
 }
 
-void process_paralyze_attack(player_type *player_ptr, monap_type *monap_ptr)
+void process_paralyze_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (check_multishadow(player_ptr)) {
         return;
@@ -93,7 +93,7 @@ void process_paralyze_attack(player_type *player_ptr, monap_type *monap_ptr)
     }
 }
 
-void process_lose_all_attack(player_type *player_ptr, monap_type *monap_ptr)
+void process_lose_all_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (do_dec_stat(player_ptr, A_STR)) {
         monap_ptr->obvious = true;
@@ -120,7 +120,7 @@ void process_lose_all_attack(player_type *player_ptr, monap_type *monap_ptr)
     }
 }
 
-void process_stun_attack(player_type *player_ptr, monap_type *monap_ptr)
+void process_stun_attack(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_resist_sound(player_ptr) || check_multishadow(player_ptr)) {
         return;
@@ -137,7 +137,7 @@ void process_stun_attack(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @monap_ptr モンスターからモンスターへの直接攻撃構造体への参照ポインタ
  */
-static void describe_disability(player_type *player_ptr, monap_type *monap_ptr)
+static void describe_disability(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     int stat = randint0(6);
     switch (stat) {
@@ -168,7 +168,7 @@ static void describe_disability(player_type *player_ptr, monap_type *monap_ptr)
     }
 }
 
-void process_monster_attack_time(player_type *player_ptr, monap_type *monap_ptr)
+void process_monster_attack_time(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_resist_time(player_ptr) || check_multishadow(player_ptr)) {
         return;
index e805c09..5ac96d0 100644 (file)
@@ -3,10 +3,10 @@
 #include "system/angband.h"
 
 typedef struct monap_type monap_type;
-struct player_type;
-void process_blind_attack(player_type *player_ptr, monap_type *monap_ptr);
-void process_terrify_attack(player_type *player_ptr, monap_type *monap_ptr);
-void process_paralyze_attack(player_type *player_ptr, monap_type *monap_ptr);
-void process_lose_all_attack(player_type *player_ptr, monap_type *monap_ptr);
-void process_stun_attack(player_type *player_ptr, monap_type *monap_ptr);
-void process_monster_attack_time(player_type *player_ptr, monap_type *monap_ptr);
+class PlayerType;
+void process_blind_attack(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_terrify_attack(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_paralyze_attack(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_lose_all_attack(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_stun_attack(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_monster_attack_time(PlayerType *player_ptr, monap_type *monap_ptr);
index 669a541..48a841d 100644 (file)
@@ -36,7 +36,7 @@
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  * @details 減衰の計算式がpoisではなくnukeなのは仕様 (1/3では減衰が強すぎると判断したため)
  */
-static void calc_blow_poison(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_poison(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (monap_ptr->explode)
         return;
@@ -55,7 +55,7 @@ static void calc_blow_poison(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_disenchant(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_disenchant(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (monap_ptr->explode)
         return;
@@ -78,7 +78,7 @@ static void calc_blow_disenchant(player_type *player_ptr, monap_type *monap_ptr)
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  * @detals 魔道具使用能力向上フラグがあれば、吸収対象のアイテムをスキャンされる回数が半分で済む
  */
-static void calc_blow_un_power(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_un_power(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     int damage_ratio = 1000;
     if (has_dec_mana(player_ptr))
@@ -113,7 +113,7 @@ static void calc_blow_un_power(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_blind(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_blind(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_resist_blind(player_ptr))
         monap_ptr->damage = monap_ptr->damage * (randint1(4) + 3) / 8;
@@ -131,7 +131,7 @@ static void calc_blow_blind(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_confusion(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_confusion(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (monap_ptr->explode) {
         return;
@@ -158,7 +158,7 @@ static void calc_blow_confusion(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_fear(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_fear(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_resist_fear(player_ptr))
         monap_ptr->damage = monap_ptr->damage * (randint1(4) + 3) / 8;
@@ -176,7 +176,7 @@ static void calc_blow_fear(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_paralysis(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_paralysis(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (has_free_act(player_ptr))
         monap_ptr->damage = monap_ptr->damage * (randint1(4) + 3) / 8;
@@ -194,7 +194,7 @@ static void calc_blow_paralysis(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_drain_exp(player_type *player_ptr, monap_type *monap_ptr, const int drain_value, const int hold_exp_prob)
+static void calc_blow_drain_exp(PlayerType *player_ptr, monap_type *monap_ptr, const int drain_value, const int hold_exp_prob)
 {
     int32_t d = damroll(drain_value, 6) + (player_ptr->exp / 100) * MON_DRAIN_LIFE;
     monap_ptr->obvious = true;
@@ -218,7 +218,7 @@ static void calc_blow_drain_exp(player_type *player_ptr, monap_type *monap_ptr,
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_time(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_time(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (monap_ptr->explode)
         return;
@@ -235,7 +235,7 @@ static void calc_blow_time(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_drain_life(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_drain_life(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     int32_t d = damroll(60, 6) + (player_ptr->exp / 100) * MON_DRAIN_LIFE;
     monap_ptr->obvious = true;
@@ -255,7 +255,7 @@ static void calc_blow_drain_life(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-static void calc_blow_drain_mana(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_drain_mana(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     monap_ptr->obvious = true;
     int damage_ratio = 100;
@@ -273,7 +273,7 @@ static void calc_blow_drain_mana(player_type *player_ptr, monap_type *monap_ptr)
     update_smart_learn(player_ptr, monap_ptr->m_idx, DRS_MANA);
 }
 
-static void calc_blow_inertia(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_inertia(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if ((player_ptr->fast > 0) || (player_ptr->pspeed >= 130))
         monap_ptr->damage = monap_ptr->damage * (randint1(4) + 4) / 9;
@@ -289,7 +289,7 @@ static void calc_blow_inertia(player_type *player_ptr, monap_type *monap_ptr)
 /*!
 * @brief 空腹進行度を計算する (急速回復があれば+100%、遅消化があれば-50%)
 */
-static void calc_blow_hungry(player_type *player_ptr, monap_type *monap_ptr)
+static void calc_blow_hungry(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (player_ptr->regenerate)
         monap_ptr->damage = monap_ptr->damage * 2;
@@ -299,7 +299,7 @@ static void calc_blow_hungry(player_type *player_ptr, monap_type *monap_ptr)
     process_monster_attack_hungry(player_ptr, monap_ptr);
 }
 
-void switch_monster_blow_to_player(player_type *player_ptr, monap_type *monap_ptr)
+void switch_monster_blow_to_player(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     switch (monap_ptr->effect) {
     case RaceBlowEffectType::NONE:
index e758774..e7160b2 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 typedef struct monap_type monap_type;
-struct player_type;
-void switch_monster_blow_to_player(player_type *player_ptr, monap_type *monap_ptr);
+class PlayerType;
+void switch_monster_blow_to_player(PlayerType *player_ptr, monap_type *monap_ptr);
index 856802b..ae6aafd 100644 (file)
@@ -9,7 +9,7 @@
 #include "system/monster-type-definition.h"
 #include "system/player-type-definition.h"
 
-monap_type *initialize_monap_type(player_type *player_ptr, monap_type *monap_ptr, MONSTER_IDX m_idx)
+monap_type *initialize_monap_type(PlayerType *player_ptr, monap_type *monap_ptr, MONSTER_IDX m_idx)
 {
 #ifdef JP
     monap_ptr->abbreviate = 0;
index 05aeb92..1e45abf 100644 (file)
@@ -37,5 +37,5 @@ typedef struct monap_type {
     bool fear;
 } monap_type;
 
-struct player_type;
-monap_type *initialize_monap_type(player_type *player_ptr, monap_type *monap_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+monap_type *initialize_monap_type(PlayerType *player_ptr, monap_type *monap_ptr, MONSTER_IDX m_idx);
index 2e68556..6ee1ab4 100644 (file)
@@ -32,7 +32,7 @@
 #include "view/display-messages.h"
 #include "world/world-object.h"
 
-void process_eat_gold(player_type *player_ptr, monap_type *monap_ptr)
+void process_eat_gold(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (!player_ptr->paralyzed && (randint0(100) < (adj_dex_safe[player_ptr->stat_index[A_DEX]] + player_ptr->lev))) {
         msg_print(_("しかし素早く財布を守った!", "You quickly protect your money pouch!"));
@@ -76,7 +76,7 @@ void process_eat_gold(player_type *player_ptr, monap_type *monap_ptr)
  * @monap_ptr モンスターからモンスターへの直接攻撃構造体への参照ポインタ
  * @return 盗まれたらTRUE、何も盗まれなかったらFALSE
  */
-bool check_eat_item(player_type *player_ptr, monap_type *monap_ptr)
+bool check_eat_item(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (monster_confused_remaining(monap_ptr->m_ptr))
         return false;
@@ -99,7 +99,7 @@ bool check_eat_item(player_type *player_ptr, monap_type *monap_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @monap_ptr モンスターからモンスターへの直接攻撃構造体への参照ポインタ
  */
-static void move_item_to_monster(player_type *player_ptr, monap_type *monap_ptr, const OBJECT_IDX o_idx)
+static void move_item_to_monster(PlayerType *player_ptr, monap_type *monap_ptr, const OBJECT_IDX o_idx)
 {
     if (o_idx == 0)
         return;
@@ -124,7 +124,7 @@ static void move_item_to_monster(player_type *player_ptr, monap_type *monap_ptr,
  * @monap_ptr モンスターからモンスターへの直接攻撃構造体への参照ポインタ
  * @details eatとあるがお金や食べ物と違ってなくならない、盗んだモンスターを倒せば取り戻せる
  */
-void process_eat_item(player_type *player_ptr, monap_type *monap_ptr)
+void process_eat_item(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     for (int i = 0; i < 10; i++) {
         OBJECT_IDX o_idx;
@@ -153,7 +153,7 @@ void process_eat_item(player_type *player_ptr, monap_type *monap_ptr)
     }
 }
 
-void process_eat_food(player_type *player_ptr, monap_type *monap_ptr)
+void process_eat_food(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     for (int i = 0; i < 10; i++) {
         INVENTORY_IDX i_idx = (INVENTORY_IDX)randint0(INVEN_PACK);
@@ -177,7 +177,7 @@ void process_eat_food(player_type *player_ptr, monap_type *monap_ptr)
     }
 }
 
-void process_eat_lite(player_type *player_ptr, monap_type *monap_ptr)
+void process_eat_lite(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if ((monap_ptr->o_ptr->xtra4 <= 0) || monap_ptr->o_ptr->is_fixed_artifact())
         return;
@@ -202,7 +202,7 @@ void process_eat_lite(player_type *player_ptr, monap_type *monap_ptr)
  * @details 魔道具使用能力向上フラグがあれば、吸収量は全部ではない
  * 詳細はOSDN #40911の議論を参照のこと
  */
-bool process_un_power(player_type *player_ptr, monap_type *monap_ptr)
+bool process_un_power(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (((monap_ptr->o_ptr->tval != ItemKindType::STAFF) && (monap_ptr->o_ptr->tval != ItemKindType::WAND)) || (monap_ptr->o_ptr->pval == 0))
         return false;
@@ -240,7 +240,7 @@ bool process_un_power(player_type *player_ptr, monap_type *monap_ptr)
     return true;
 }
 
-bool check_drain_hp(player_type *player_ptr, const int32_t d)
+bool check_drain_hp(PlayerType *player_ptr, const int32_t d)
 {
     bool resist_drain = !drain_exp(player_ptr, d, d / 10, 50);
     if (player_ptr->mimic_form) {
@@ -261,7 +261,7 @@ bool check_drain_hp(player_type *player_ptr, const int32_t d)
     }
 }
 
-void process_drain_life(player_type *player_ptr, monap_type *monap_ptr, const bool resist_drain)
+void process_drain_life(PlayerType *player_ptr, monap_type *monap_ptr, const bool resist_drain)
 {
     if ((monap_ptr->damage <= 5) || resist_drain)
         return;
@@ -281,7 +281,7 @@ void process_drain_life(player_type *player_ptr, monap_type *monap_ptr, const bo
         msg_format(_("%sは体力を回復したようだ。", "%^s appears healthier."), monap_ptr->m_name);
 }
 
-void process_drain_mana(player_type *player_ptr, monap_type *monap_ptr)
+void process_drain_mana(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if (check_multishadow(player_ptr)) {
         msg_print(_("攻撃は幻影に命中し、あなたには届かなかった。", "The attack hits Shadow, but you are unharmed!"));
@@ -304,7 +304,7 @@ void process_drain_mana(player_type *player_ptr, monap_type *monap_ptr)
  * @monap_ptr モンスターからモンスターへの直接攻撃構造体への参照ポインタ
  * @details 空腹、衰弱の一歩手前で止める優しさは残す。
  */
-void process_monster_attack_hungry(player_type *player_ptr, monap_type *monap_ptr)
+void process_monster_attack_hungry(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     msg_format(_("あなたは腹が減った!", "You feel hungry!"));
     auto subtracted_food = static_cast<int16_t>(player_ptr->food - monap_ptr->damage);
index 8b0d646..2c0f37a 100644 (file)
@@ -3,15 +3,15 @@
 #include "system/angband.h"
 
 typedef struct monap_type monap_type;
-struct player_type;
-void process_eat_gold(player_type *player_ptr, monap_type *monap_ptr);
-bool check_eat_item(player_type *player_ptr, monap_type *monap_ptr);
-void process_eat_item(player_type *player_ptr, monap_type *monap_ptr);
-void process_eat_food(player_type *player_ptr, monap_type *monap_ptr);
-void process_eat_lite(player_type *player_ptr, monap_type *monap_ptr);
+class PlayerType;
+void process_eat_gold(PlayerType *player_ptr, monap_type *monap_ptr);
+bool check_eat_item(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_eat_item(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_eat_food(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_eat_lite(PlayerType *player_ptr, monap_type *monap_ptr);
 
-bool process_un_power(player_type *player_ptr, monap_type *monap_ptr);
-bool check_drain_hp(player_type *player_ptr, const int32_t d);
-void process_drain_life(player_type *player_ptr, monap_type *monap_ptr, const bool resist_drain);
-void process_drain_mana(player_type *player_ptr, monap_type *monap_ptr);
-void process_monster_attack_hungry(player_type *player_ptr, monap_type *monap_ptr);
+bool process_un_power(PlayerType *player_ptr, monap_type *monap_ptr);
+bool check_drain_hp(PlayerType *player_ptr, const int32_t d);
+void process_drain_life(PlayerType *player_ptr, monap_type *monap_ptr, const bool resist_drain);
+void process_drain_mana(PlayerType *player_ptr, monap_type *monap_ptr);
+void process_monster_attack_hungry(PlayerType *player_ptr, monap_type *monap_ptr);
index 50f7783..3eaedd3 100644 (file)
@@ -38,7 +38,7 @@ static OBJECT_SUBTYPE_VALUE get_coin_type(MONRACE_IDX r_idx)
     return MON_PLAYER;
 }
 
-monster_death_type *initialize_monster_death_type(player_type *player_ptr, monster_death_type *md_ptr, MONSTER_IDX m_idx, bool drop_item)
+monster_death_type *initialize_monster_death_type(PlayerType *player_ptr, monster_death_type *md_ptr, MONSTER_IDX m_idx, bool drop_item)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     md_ptr->m_idx = m_idx;
index 86e8ade..d71c1d3 100644 (file)
@@ -18,5 +18,5 @@ typedef struct monster_death_type {
     uint32_t mo_mode;
 } monster_death_type;
 
-struct player_type;
-monster_death_type *initialize_monster_death_type(player_type *player_ptr, monster_death_type *md_ptr, MONSTER_IDX m_idx, bool drop_item);
+class PlayerType;
+monster_death_type *initialize_monster_death_type(PlayerType *player_ptr, monster_death_type *md_ptr, MONSTER_IDX m_idx, bool drop_item);
index 3ebf108..70b2532 100644 (file)
@@ -49,7 +49,7 @@
 #include "view/display-messages.h"
 #include "world/world.h"
 
-static void write_pet_death(player_type *player_ptr, monster_death_type *md_ptr)
+static void write_pet_death(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     md_ptr->md_y = md_ptr->m_ptr->fy;
     md_ptr->md_x = md_ptr->m_ptr->fx;
@@ -60,7 +60,7 @@ static void write_pet_death(player_type *player_ptr, monster_death_type *md_ptr)
     }
 }
 
-static void on_dead_explosion(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_explosion(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     for (int i = 0; i < 4; i++) {
         if (md_ptr->r_ptr->blow[i].method != RBM_EXPLODE)
@@ -76,7 +76,7 @@ static void on_dead_explosion(player_type *player_ptr, monster_death_type *md_pt
     }
 }
 
-static void on_defeat_arena_monster(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_defeat_arena_monster(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!floor_ptr->inside_arena || is_pet(md_ptr->m_ptr))
@@ -108,7 +108,7 @@ static void on_defeat_arena_monster(player_type *player_ptr, monster_death_type
     exe_write_diary(player_ptr, DIARY_ARENA, player_ptr->arena_number, m_name);
 }
 
-static void drop_corpse(player_type *player_ptr, monster_death_type *md_ptr)
+static void drop_corpse(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     bool is_drop_corpse = one_in_(md_ptr->r_ptr->flags1 & RF1_UNIQUE ? 1 : 4);
@@ -147,7 +147,7 @@ static void drop_corpse(player_type *player_ptr, monster_death_type *md_ptr)
  * @param md_ptr モンスター死亡構造体への参照ポインタ
  * @return 何かドロップするなら1以上、何もドロップしないなら0
  */
-static ARTIFACT_IDX drop_artifact_index(player_type *player_ptr, monster_death_type *md_ptr)
+static ARTIFACT_IDX drop_artifact_index(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     ARTIFACT_IDX a_idx = 0;
     PERCENTAGE chance = 0;
@@ -179,7 +179,7 @@ static ARTIFACT_IDX drop_artifact_index(player_type *player_ptr, monster_death_t
  * @param a_ix ドロップを試みるアーティファクトID
  * @return ドロップするならtrue
  */
-bool drop_single_artifact(player_type *player_ptr, monster_death_type *md_ptr, ARTIFACT_IDX a_idx)
+bool drop_single_artifact(PlayerType *player_ptr, monster_death_type *md_ptr, ARTIFACT_IDX a_idx)
 {
     artifact_type *a_ptr = &a_info[a_idx];
     if (a_ptr->cur_num == 1)
@@ -201,7 +201,7 @@ bool drop_single_artifact(player_type *player_ptr, monster_death_type *md_ptr, A
     return false;
 }
 
-static KIND_OBJECT_IDX drop_dungeon_final_artifact(player_type *player_ptr, monster_death_type *md_ptr, ARTIFACT_IDX a_idx)
+static KIND_OBJECT_IDX drop_dungeon_final_artifact(PlayerType *player_ptr, monster_death_type *md_ptr, ARTIFACT_IDX a_idx)
 {
     auto k_idx = d_info[player_ptr->dungeon_idx].final_object != 0 ? d_info[player_ptr->dungeon_idx].final_object : lookup_kind(ItemKindType::SCROLL, SV_SCROLL_ACQUIREMENT);
     if (d_info[player_ptr->dungeon_idx].final_artifact == 0)
@@ -222,7 +222,7 @@ static KIND_OBJECT_IDX drop_dungeon_final_artifact(player_type *player_ptr, mons
     return d_info[player_ptr->dungeon_idx].final_object ? k_idx : 0;
 }
 
-static void drop_artifact(player_type *player_ptr, monster_death_type *md_ptr)
+static void drop_artifact(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!md_ptr->drop_chosen_item)
         return;
@@ -253,7 +253,7 @@ static void decide_drop_quality(monster_death_type *md_ptr)
         md_ptr->mo_mode |= (AM_GOOD | AM_GREAT);
 }
 
-static int decide_drop_numbers(player_type *player_ptr, monster_death_type *md_ptr, const bool drop_item)
+static int decide_drop_numbers(PlayerType *player_ptr, monster_death_type *md_ptr, const bool drop_item)
 {
     int drop_numbers = 0;
     if ((md_ptr->r_ptr->flags1 & RF1_DROP_60) && (randint0(100) < 60))
@@ -289,7 +289,7 @@ static int decide_drop_numbers(player_type *player_ptr, monster_death_type *md_p
     return drop_numbers;
 }
 
-static void drop_items_golds(player_type *player_ptr, monster_death_type *md_ptr, int drop_numbers)
+static void drop_items_golds(PlayerType *player_ptr, monster_death_type *md_ptr, int drop_numbers)
 {
     int dump_item = 0;
     int dump_gold = 0;
@@ -324,7 +324,7 @@ static void drop_items_golds(player_type *player_ptr, monster_death_type *md_ptr
  * @brief 最終ボス(混沌のサーペント)を倒したときの処理
  * @param player_ptr プレイヤー情報への参照ポインタ
  */
-static void on_defeat_last_boss(player_type *player_ptr)
+static void on_defeat_last_boss(PlayerType *player_ptr)
 {
     w_ptr->total_winner = true;
     add_winner_class(player_ptr->pclass);
@@ -345,7 +345,7 @@ static void on_defeat_last_boss(player_type *player_ptr)
  * @param drop_item TRUEならばモンスターのドロップ処理を行う
  * @param type ラストアタックの属性 (単一属性)
  */
-void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item, AttributeType type)
+void monster_death(PlayerType *player_ptr, MONSTER_IDX m_idx, bool drop_item, AttributeType type)
 {
     AttributeFlags flags;
     flags.clear();
@@ -370,7 +370,7 @@ void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item, A
  * it drops all of its objects, which may disappear in crowded rooms.
  * </pre>
  */
-void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item, AttributeFlags attribute_flags)
+void monster_death(PlayerType *player_ptr, MONSTER_IDX m_idx, bool drop_item, AttributeFlags attribute_flags)
 {
     monster_death_type tmp_md;
     monster_death_type *md_ptr = initialize_monster_death_type(player_ptr, &tmp_md, m_idx, drop_item);
index 28b7835..c208d86 100644 (file)
@@ -4,8 +4,8 @@
 #include "monster-floor/monster-death-util.h"
 #include "effect/attribute-types.h"
 
-struct player_type;
-void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item, AttributeFlags attribute_flags);
-void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item, AttributeType type);
-bool drop_single_artifact(player_type *player_ptr, monster_death_type *md_ptr, ARTIFACT_IDX a_idx);
+class PlayerType;
+void monster_death(PlayerType *player_ptr, MONSTER_IDX m_idx, bool drop_item, AttributeFlags attribute_flags);
+void monster_death(PlayerType *player_ptr, MONSTER_IDX m_idx, bool drop_item, AttributeType type);
+bool drop_single_artifact(PlayerType *player_ptr, monster_death_type *md_ptr, ARTIFACT_IDX a_idx);
 concptr extract_note_dies(MONRACE_IDX r_idx);
index ad1c0ff..1d3fd6e 100644 (file)
@@ -30,7 +30,7 @@
  * @param plus モンスターIDの増減 (1/2 の確率で+1、1/2の確率で-1)
  * @return ペットがモンスターに近づくならばTRUE
  */
-static bool decide_pet_approch_direction(player_type *player_ptr, monster_type *m_ptr, monster_type *t_ptr)
+static bool decide_pet_approch_direction(PlayerType *player_ptr, monster_type *m_ptr, monster_type *t_ptr)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     if (!is_pet(m_ptr))
@@ -56,7 +56,7 @@ static bool decide_pet_approch_direction(player_type *player_ptr, monster_type *
  * @param y モンスターの移動方向Y
  * @param x モンスターの移動方向X
  */
-static void decide_enemy_approch_direction(player_type *player_ptr, MONSTER_IDX m_idx, int start, int plus, POSITION *y, POSITION *x)
+static void decide_enemy_approch_direction(PlayerType *player_ptr, MONSTER_IDX m_idx, int start, int plus, POSITION *y, POSITION *x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -101,7 +101,7 @@ static void decide_enemy_approch_direction(player_type *player_ptr, MONSTER_IDX
  * @param mm 移動するべき方角IDを返す参照ポインタ
  * @return 方向が確定した場合TRUE、接近する敵がそもそもいない場合FALSEを返す
  */
-bool get_enemy_dir(player_type *player_ptr, MONSTER_IDX m_idx, int *mm)
+bool get_enemy_dir(PlayerType *player_ptr, MONSTER_IDX m_idx, int *mm)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -145,7 +145,7 @@ bool get_enemy_dir(player_type *player_ptr, MONSTER_IDX m_idx, int *mm)
  * @return 不規則な方向へ歩くことになったらTRUE
  * @todo "5"とはもしかして「その場に留まる」という意味か?
  */
-static bool random_walk(player_type *player_ptr, DIRECTION *mm, monster_type *m_ptr)
+static bool random_walk(PlayerType *player_ptr, DIRECTION *mm, monster_type *m_ptr)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     if (((r_ptr->flags1 & (RF1_RAND_50 | RF1_RAND_25)) == (RF1_RAND_50 | RF1_RAND_25)) && (randint0(100) < 75)) {
@@ -219,7 +219,7 @@ static bool decide_pet_movement_direction(MonsterSweepGrid *msd)
  * @param aware モンスターがプレイヤーに気付いているならばTRUE、超隠密状態ならばFALSE
  * @return 移動先が存在すればTRUE
  */
-bool decide_monster_movement_direction(player_type *player_ptr, DIRECTION *mm, MONSTER_IDX m_idx, bool aware)
+bool decide_monster_movement_direction(PlayerType *player_ptr, DIRECTION *mm, MONSTER_IDX m_idx, bool aware)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
index 5ed13bd..b51b732 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool get_enemy_dir(player_type *player_ptr, MONSTER_IDX m_idx, int *mm);
-bool decide_monster_movement_direction(player_type *player_ptr, DIRECTION *mm, MONSTER_IDX m_idx, bool aware);
+class PlayerType;
+bool get_enemy_dir(PlayerType *player_ptr, MONSTER_IDX m_idx, int *mm);
+bool decide_monster_movement_direction(PlayerType *player_ptr, DIRECTION *mm, MONSTER_IDX m_idx, bool aware);
index 8158589..4d43fdf 100644 (file)
@@ -66,7 +66,7 @@ static MONSTER_IDX place_monster_m_idx = 0;
  * @return 成功したらtrue
  *
  */
-bool mon_scatter(player_type *player_ptr, MONRACE_IDX r_idx, POSITION *yp, POSITION *xp, POSITION y, POSITION x, POSITION max_dist)
+bool mon_scatter(PlayerType *player_ptr, MONRACE_IDX r_idx, POSITION *yp, POSITION *xp, POSITION y, POSITION x, POSITION max_dist)
 {
     POSITION place_x[MON_SCAT_MAXD];
     POSITION place_y[MON_SCAT_MAXD];
@@ -131,7 +131,7 @@ bool mon_scatter(player_type *player_ptr, MONRACE_IDX r_idx, POSITION *yp, POSIT
  * @details
  * Note that "reproduction" REQUIRES empty space.
  */
-bool multiply_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool clone, BIT_FLAGS mode)
+bool multiply_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, bool clone, BIT_FLAGS mode)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -161,7 +161,7 @@ bool multiply_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool clone, BI
  * @param mode 生成オプション
  * @return 成功したらtrue
  */
-static bool place_monster_group(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode)
+static bool place_monster_group(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode)
 {
     monster_race *r_ptr = &r_info[r_idx];
     int total = randint1(10);
@@ -217,7 +217,7 @@ static bool place_monster_group(player_type *player_ptr, MONSTER_IDX who, POSITI
  * @param r_idx チェックするモンスター種族のID
  * @return 護衛にできるならばtrue
  */
-static bool place_monster_can_escort(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool place_monster_can_escort(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[place_monster_idx];
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[place_monster_m_idx];
@@ -262,7 +262,7 @@ static bool place_monster_can_escort(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param mode 生成オプション
  * @return 生成に成功したらtrue
  */
-bool place_monster_aux(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode)
+bool place_monster_aux(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode)
 {
     monster_race *r_ptr = &r_info[r_idx];
 
@@ -334,7 +334,7 @@ bool place_monster_aux(player_type *player_ptr, MONSTER_IDX who, POSITION y, POS
  * @param mode 生成オプション
  * @return 生成に成功したらtrue
  */
-bool place_monster(player_type *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode)
+bool place_monster(PlayerType *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode)
 {
     get_mon_num_prep(player_ptr, get_monster_hook(player_ptr), get_monster_hook2(player_ptr, y, x));
     MONRACE_IDX r_idx;
@@ -360,7 +360,7 @@ bool place_monster(player_type *player_ptr, POSITION y, POSITION x, BIT_FLAGS mo
  * @param x 生成地点x座標
  * @return 生成に成功したらtrue
  */
-bool alloc_horde(player_type *player_ptr, POSITION y, POSITION x, summon_specific_pf summon_specific)
+bool alloc_horde(PlayerType *player_ptr, POSITION y, POSITION x, summon_specific_pf summon_specific)
 {
     get_mon_num_prep(player_ptr, get_monster_hook(player_ptr), get_monster_hook2(player_ptr, y, x));
 
@@ -419,7 +419,7 @@ bool alloc_horde(player_type *player_ptr, POSITION y, POSITION x, summon_specifi
  * @param def_val 現在の主の生成状態
  * @return 生成に成功したらtrue
  */
-bool alloc_guardian(player_type *player_ptr, bool def_val)
+bool alloc_guardian(PlayerType *player_ptr, bool def_val)
 {
     MONRACE_IDX guardian = d_info[player_ptr->dungeon_idx].final_guardian;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -462,7 +462,7 @@ bool alloc_guardian(player_type *player_ptr, bool def_val)
  * Use "slp" to choose the initial "sleep" status
  * Use "floor_ptr->monster_level" for the monster level
  */
-bool alloc_monster(player_type *player_ptr, POSITION dis, BIT_FLAGS mode, summon_specific_pf summon_specific)
+bool alloc_monster(PlayerType *player_ptr, POSITION dis, BIT_FLAGS mode, summon_specific_pf summon_specific)
 {
     if (alloc_guardian(player_ptr, false))
         return true;
index 5832f32..e5ccbd2 100644 (file)
@@ -3,13 +3,13 @@
 #include "system/angband.h"
 
 enum summon_type : int;
-struct player_type;
-typedef bool (*summon_specific_pf)(player_type *, MONSTER_IDX, POSITION, POSITION, DEPTH, summon_type, BIT_FLAGS);
+class PlayerType;
+typedef bool (*summon_specific_pf)(PlayerType *, MONSTER_IDX, POSITION, POSITION, DEPTH, summon_type, BIT_FLAGS);
 
-bool mon_scatter(player_type *player_ptr, MONRACE_IDX r_idx, POSITION *yp, POSITION *xp, POSITION y, POSITION x, POSITION max_dist);
-bool multiply_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool clone, BIT_FLAGS mode);
-bool place_monster_aux(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode);
-bool place_monster(player_type *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode);
-bool alloc_horde(player_type *player_ptr, POSITION y, POSITION x, summon_specific_pf summon_specific);
-bool alloc_guardian(player_type *player_ptr, bool def_val);
-bool alloc_monster(player_type *player_ptr, POSITION dis, BIT_FLAGS mode, summon_specific_pf summon_specific);
+bool mon_scatter(PlayerType *player_ptr, MONRACE_IDX r_idx, POSITION *yp, POSITION *xp, POSITION y, POSITION x, POSITION max_dist);
+bool multiply_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, bool clone, BIT_FLAGS mode);
+bool place_monster_aux(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode);
+bool place_monster(PlayerType *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode);
+bool alloc_horde(PlayerType *player_ptr, POSITION y, POSITION x, summon_specific_pf summon_specific);
+bool alloc_guardian(PlayerType *player_ptr, bool def_val);
+bool alloc_monster(PlayerType *player_ptr, POSITION dis, BIT_FLAGS mode, summon_specific_pf summon_specific);
index df3f137..4a2e9c8 100644 (file)
@@ -30,7 +30,7 @@
  * @param x X座標
  */
 static void update_monster_lite(
-    player_type *const player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x, const monster_lite_type *const ml_ptr)
+    PlayerType *const player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x, const monster_lite_type *const ml_ptr)
 {
     grid_type *g_ptr;
     int dpf, d;
@@ -82,7 +82,7 @@ static void update_monster_lite(
  * Add a square to the changes array
  */
 static void update_monster_dark(
-    player_type *const player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x, const monster_lite_type *const ml_ptr)
+    PlayerType *const player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x, const monster_lite_type *const ml_ptr)
 {
     grid_type *g_ptr;
     int midpoint, dpf, d;
@@ -131,12 +131,12 @@ static void update_monster_dark(
  * changes are drawn via lite_spot().
  * @todo player-status からのみ呼ばれている。しかしあちらは行数が酷いので要調整
  */
-void update_mon_lite(player_type *player_ptr)
+void update_mon_lite(PlayerType *player_ptr)
 {
     // 座標たちを記録する配列。
     std::vector<Pos2D> points;
 
-    void (*add_mon_lite)(player_type *, std::vector<Pos2D> &, const POSITION, const POSITION, const monster_lite_type *);
+    void (*add_mon_lite)(PlayerType *, std::vector<Pos2D> &, const POSITION, const POSITION, const monster_lite_type *);
     int dis_lim = (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS) && !player_ptr->see_nocto) ? (MAX_SIGHT / 2 + 1) : (MAX_SIGHT + 3);
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (int i = 0; i < floor_ptr->mon_lite_n; i++) {
index a2cb5c7..a62a12e 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
 struct floor_type;
-struct player_type;
-void update_mon_lite(player_type *player_ptr);
+class PlayerType;
+void update_mon_lite(PlayerType *player_ptr);
 void clear_mon_lite(floor_type *floor_ptr);
index cccd0e3..5ba84c9 100644 (file)
@@ -57,7 +57,7 @@ static bool check_hp_for_feat_destruction(feature_type *f_ptr, monster_type *m_p
  * @param can_cross モンスターが地形を踏破できるならばTRUE
  * @return 透過も破壊もしなかった場合はFALSE、それ以外はTRUE
  */
-static bool process_wall(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx, bool can_cross)
+static bool process_wall(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx, bool can_cross)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     grid_type *g_ptr;
@@ -104,7 +104,7 @@ static bool process_wall(player_type *player_ptr, turn_flags *turn_flags_ptr, mo
  * @param nx モンスターのX座標
  * @return ここではドアを開けず、ガラスのドアを開ける可能性があるならTRUE
  */
-static bool bash_normal_door(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
+static bool bash_normal_door(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     grid_type *g_ptr;
@@ -138,7 +138,7 @@ static bool bash_normal_door(player_type *player_ptr, turn_flags *turn_flags_ptr
  * @param g_ptr グリッドへの参照ポインタ
  * @param f_ptr 地形への参照ポインタ
  */
-static void bash_glass_door(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, feature_type *f_ptr, bool may_bash)
+static void bash_glass_door(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, feature_type *f_ptr, bool may_bash)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     if (!may_bash || ((r_ptr->flags2 & RF2_BASH_DOOR) == 0) || f_ptr->flags.has_not(FloorFeatureType::BASH)
@@ -170,7 +170,7 @@ static void bash_glass_door(player_type *player_ptr, turn_flags *turn_flags_ptr,
  * @param nx モンスターのX座標
  * @return モンスターが死亡した場合のみFALSE
  */
-static bool process_door(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
+static bool process_door(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     grid_type *g_ptr;
@@ -215,7 +215,7 @@ static bool process_door(player_type *player_ptr, turn_flags *turn_flags_ptr, mo
  * @param nx モンスターのX座標
  * @return ルーンのある/なし
  */
-static bool process_protection_rune(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
+static bool process_protection_rune(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
 {
     grid_type *g_ptr;
     g_ptr = &player_ptr->current_floor_ptr->grid_array[ny][nx];
@@ -248,7 +248,7 @@ static bool process_protection_rune(player_type *player_ptr, turn_flags *turn_fl
  * @param nx モンスターのX座標
  * @return モンスターが死亡した場合のみFALSE
  */
-static bool process_explosive_rune(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
+static bool process_explosive_rune(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
 {
     grid_type *g_ptr;
     g_ptr = &player_ptr->current_floor_ptr->grid_array[ny][nx];
@@ -293,7 +293,7 @@ static bool process_explosive_rune(player_type *player_ptr, turn_flags *turn_fla
  * @param nx モンスターのX座標
  * @return モンスターが死亡した場合のみFALSE
  */
-static bool process_post_dig_wall(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
+static bool process_post_dig_wall(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, POSITION ny, POSITION nx)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     grid_type *g_ptr;
@@ -339,7 +339,7 @@ static bool process_post_dig_wall(player_type *player_ptr, turn_flags *turn_flag
  * @return 移動が阻害される何か (ドア等)があったらFALSE
  * @todo 少し長いが、これといってブロックとしてまとまった部分もないので暫定でこのままとする
  */
-bool process_monster_movement(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, DIRECTION *mm, POSITION oy, POSITION ox, int *count)
+bool process_monster_movement(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, DIRECTION *mm, POSITION oy, POSITION ox, int *count)
 {
     for (int i = 0; mm[i]; i++) {
         int d = mm[i];
@@ -450,7 +450,7 @@ bool process_monster_movement(player_type *player_ptr, turn_flags *turn_flags_pt
  * @param ox モンスターが元々いたX座標
  * @param aware モンスターがプレイヤーに気付いているならばTRUE、超隠密状態ならばFALSE
  */
-void process_speak_sound(player_type *player_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox, bool aware)
+void process_speak_sound(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox, bool aware)
 {
     if (player_ptr->phase_out)
         return;
index cefc139..ff49cff 100644 (file)
@@ -3,9 +3,9 @@
 #include "system/angband.h"
 
 struct monster_type;
-struct player_type;
+class PlayerType;
 struct turn_flags;
-bool process_monster_movement(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, DIRECTION *mm, POSITION oy, POSITION ox, int *count);
-void process_speak_sound(player_type *player_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox, bool aware);
+bool process_monster_movement(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, DIRECTION *mm, POSITION oy, POSITION ox, int *count);
+void process_speak_sound(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox, bool aware);
 void set_target(monster_type *m_ptr, POSITION y, POSITION x);
 void reset_target(monster_type *m_ptr);
index 5f2bff8..0c483d9 100644 (file)
@@ -100,7 +100,7 @@ static void update_object_flags(const TrFlags &flgs, BIT_FLAGS *flg2, BIT_FLAGS
  * @param o_name アイテム名
  * @param this_o_idx モンスターが乗ったオブジェクトID
  */
-static void monster_pickup_object(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, object_type *o_ptr, bool is_special_object,
+static void monster_pickup_object(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, object_type *o_ptr, bool is_special_object,
     POSITION ny, POSITION nx, GAME_TEXT *m_name, GAME_TEXT *o_name, OBJECT_IDX this_o_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
@@ -149,7 +149,7 @@ static void monster_pickup_object(player_type *player_ptr, turn_flags *turn_flag
  * @param ny 移動後の、モンスターのY座標
  * @param nx 移動後の、モンスターのX座標
  */
-void update_object_by_monster_movement(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION ny, POSITION nx)
+void update_object_by_monster_movement(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION ny, POSITION nx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -185,7 +185,7 @@ void update_object_by_monster_movement(player_type *player_ptr, turn_flags *turn
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param m_ptr モンスター参照ポインタ
  */
-void monster_drop_carried_objects(player_type *player_ptr, monster_type *m_ptr)
+void monster_drop_carried_objects(PlayerType *player_ptr, monster_type *m_ptr)
 {
     for (auto it = m_ptr->hold_o_idx_list.begin(); it != m_ptr->hold_o_idx_list.end();) {
         object_type forge;
index 3bf5e46..0e18489 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct monster_type;
-struct player_type;
+class PlayerType;
 struct turn_flags;
-void update_object_by_monster_movement(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION ny, POSITION nx);
-void monster_drop_carried_objects(player_type *player_ptr, monster_type *m_ptr);
+void update_object_by_monster_movement(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION ny, POSITION nx);
+void monster_drop_carried_objects(PlayerType *player_ptr, monster_type *m_ptr);
index 37453b8..d996a79 100644 (file)
@@ -26,7 +26,7 @@
  * モンスターを削除するとそのモンスターが拾っていたアイテムも同時に削除される。 /
  * When a monster is deleted, all of its objects are deleted.
  */
-void delete_monster_idx(player_type *player_ptr, MONSTER_IDX i)
+void delete_monster_idx(PlayerType *player_ptr, MONSTER_IDX i)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[i];
@@ -97,7 +97,7 @@ void delete_monster_idx(player_type *player_ptr, MONSTER_IDX i)
  * This is an efficient method of simulating multiple calls to the
  * "delete_monster()" function, with no visual effects.
  */
-void wipe_monsters_list(player_type *player_ptr)
+void wipe_monsters_list(PlayerType *player_ptr)
 {
     if (!r_info[MON_BANORLUPART].max_num) {
         if (r_info[MON_BANOR].max_num) {
@@ -153,7 +153,7 @@ void wipe_monsters_list(player_type *player_ptr)
  * @param x 削除位置x座標
  * @param y 削除位置y座標
  */
-void delete_monster(player_type *player_ptr, POSITION y, POSITION x)
+void delete_monster(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
index d39e7a8..5a69da7 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void delete_monster_idx(player_type *player_ptr, MONSTER_IDX i);
-void wipe_monsters_list(player_type *player_ptr);
-void delete_monster(player_type *player_ptr, POSITION y, POSITION x);
+class PlayerType;
+void delete_monster_idx(PlayerType *player_ptr, MONSTER_IDX i);
+void wipe_monsters_list(PlayerType *player_ptr);
+void delete_monster(PlayerType *player_ptr, POSITION y, POSITION x);
index 42a8412..8570fb3 100644 (file)
@@ -34,7 +34,7 @@
  * @param m_name モンスター名称
  * @param see_m モンスターが視界内にいたらTRUE
  */
-static void escape_monster(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, GAME_TEXT *m_name)
+static void escape_monster(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr, GAME_TEXT *m_name)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     if (turn_flags_ptr->is_riding_mon) {
@@ -67,7 +67,7 @@ static void escape_monster(player_type *player_ptr, turn_flags *turn_flags_ptr,
  * @param see_m モンスターが視界内にいたらTRUE
  * @return モンスターがフロアから消えたらTRUE
  */
-bool runaway_monster(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx)
+bool runaway_monster(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
index d020597..e175cb1 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 struct turn_flags;
-bool runaway_monster(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx);
+bool runaway_monster(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx);
index debb157..9910848 100644 (file)
@@ -30,7 +30,7 @@
  * @param d モンスターがいる地点からの距離
  * @return 逃げ込める地点の候補地
  */
-static coordinate_candidate sweep_safe_coordinate(player_type *player_ptr, MONSTER_IDX m_idx, const POSITION *y_offsets, const POSITION *x_offsets, int d)
+static coordinate_candidate sweep_safe_coordinate(PlayerType *player_ptr, MONSTER_IDX m_idx, const POSITION *y_offsets, const POSITION *x_offsets, int d)
 {
     coordinate_candidate candidate = init_coordinate_candidate();
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -91,7 +91,7 @@ static coordinate_candidate sweep_safe_coordinate(player_type *player_ptr, MONST
  *\n
  * Return TRUE if a safe location is available.\n
  */
-bool find_safety(player_type *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSITION *xp)
+bool find_safety(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSITION *xp)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     for (POSITION d = 1; d < 10; d++) {
@@ -124,7 +124,7 @@ bool find_safety(player_type *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSIT
  * @param candidate 隠れられる地点の候補地
  */
 static void sweep_hiding_candidate(
-    player_type *player_ptr, monster_type *m_ptr, const POSITION *y_offsets, const POSITION *x_offsets, coordinate_candidate *candidate)
+    PlayerType *player_ptr, monster_type *m_ptr, const POSITION *y_offsets, const POSITION *x_offsets, coordinate_candidate *candidate)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     for (POSITION i = 0, dx = x_offsets[0], dy = y_offsets[0]; dx != 0 || dy != 0; i++, dx = x_offsets[i], dy = y_offsets[i]) {
@@ -160,7 +160,7 @@ static void sweep_hiding_candidate(
  *\n
  * Return TRUE if a good location is available.\n
  */
-bool find_hiding(player_type *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSITION *xp)
+bool find_hiding(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSITION *xp)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     coordinate_candidate candidate = init_coordinate_candidate();
index e12f78e..4663bc1 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool find_safety(player_type *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSITION *xp);
-bool find_hiding(player_type *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSITION *xp);
+class PlayerType;
+bool find_safety(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSITION *xp);
+bool find_hiding(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION *yp, POSITION *xp);
index 5eed02b..590d7b1 100644 (file)
@@ -40,7 +40,7 @@ bool summon_unique_okay = false;
  * @param r_idx チェックするモンスター種族ID
  * @return 召喚対象にできるならばTRUE
  */
-static bool summon_specific_okay(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool summon_specific_okay(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!mon_hook_dungeon(player_ptr, r_idx))
@@ -97,7 +97,7 @@ static bool is_dead_summoning(summon_type type)
  * ダンジョン及びクエストはdun_level>0となる。
  * 荒野はdun_level==0なので、その場合荒野レベルを返す。
  */
-DEPTH get_dungeon_or_wilderness_level(player_type *player_ptr)
+DEPTH get_dungeon_or_wilderness_level(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (floor_ptr->dun_level > 0)
@@ -117,7 +117,7 @@ DEPTH get_dungeon_or_wilderness_level(player_type *player_ptr)
  * @param mode 生成オプション
  * @return 召喚できたらtrueを返す
  */
-bool summon_specific(player_type *player_ptr, MONSTER_IDX who, POSITION y1, POSITION x1, DEPTH lev, summon_type type, BIT_FLAGS mode)
+bool summon_specific(PlayerType *player_ptr, MONSTER_IDX who, POSITION y1, POSITION x1, DEPTH lev, summon_type type, BIT_FLAGS mode)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (floor_ptr->inside_arena)
@@ -180,7 +180,7 @@ bool summon_specific(player_type *player_ptr, MONSTER_IDX who, POSITION y1, POSI
  * @param mode 生成オプション
  * @return 召喚できたらtrueを返す
  */
-bool summon_named_creature(player_type *player_ptr, MONSTER_IDX who, POSITION oy, POSITION ox, MONRACE_IDX r_idx, BIT_FLAGS mode)
+bool summon_named_creature(PlayerType *player_ptr, MONSTER_IDX who, POSITION oy, POSITION ox, MONRACE_IDX r_idx, BIT_FLAGS mode)
 {
     if ((r_idx <= 0) || (r_idx >= static_cast<MONRACE_IDX>(r_info.size()))) {
         return false;
index 318572d..0074fcf 100644 (file)
@@ -6,6 +6,6 @@ extern int summon_specific_who;
 extern bool summon_unique_okay;
 
 enum summon_type : int;
-struct player_type;
-bool summon_specific(player_type *player_ptr, MONSTER_IDX who, POSITION y1, POSITION x1, DEPTH lev, summon_type type, BIT_FLAGS mode);
-bool summon_named_creature(player_type *player_ptr, MONSTER_IDX who, POSITION oy, POSITION ox, MONRACE_IDX r_idx, BIT_FLAGS mode);
+class PlayerType;
+bool summon_specific(PlayerType *player_ptr, MONSTER_IDX who, POSITION y1, POSITION x1, DEPTH lev, summon_type type, BIT_FLAGS mode);
+bool summon_named_creature(PlayerType *player_ptr, MONSTER_IDX who, POSITION oy, POSITION ox, MONRACE_IDX r_idx, BIT_FLAGS mode);
index 40edba2..4d1ea16 100644 (file)
@@ -35,7 +35,7 @@
  * @param m_idx 逃走するモンスターの参照ID
  * @param mm 移動方向を返す方向IDの参照ポインタ
  */
-MonsterSweepGrid::MonsterSweepGrid(player_type *player_ptr, MONSTER_IDX m_idx, DIRECTION *mm)
+MonsterSweepGrid::MonsterSweepGrid(PlayerType *player_ptr, MONSTER_IDX m_idx, DIRECTION *mm)
     : player_ptr(player_ptr)
     , m_idx(m_idx)
     , mm(mm)
index 28ce2a4..fc54341 100644 (file)
@@ -2,12 +2,12 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class MonsterSweepGrid {
 public:
-    MonsterSweepGrid(player_type *player_ptr, MONSTER_IDX m_idx, DIRECTION *mm);
+    MonsterSweepGrid(PlayerType *player_ptr, MONSTER_IDX m_idx, DIRECTION *mm);
     virtual ~MonsterSweepGrid() = default;
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     MONSTER_IDX m_idx;
     DIRECTION *mm;
     bool get_movable_grid();
index b79cc96..35c6ef8 100644 (file)
@@ -46,7 +46,7 @@
 #include "wizard/wizard-messages.h"
 #include "world/world.h"
 
-static bool is_friendly_idx(player_type *player_ptr, MONSTER_IDX m_idx)
+static bool is_friendly_idx(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     return m_idx > 0 && is_friendly(&player_ptr->current_floor_ptr->m_list[(m_idx)]);
 }
@@ -57,7 +57,7 @@ static bool is_friendly_idx(player_type *player_ptr, MONSTER_IDX m_idx)
  * @return 対象にできるならtrueを返す
  * @todo グローバル変数対策の上 monster_hook.cへ移す。
  */
-static bool monster_hook_tanuki(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool monster_hook_tanuki(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     bool unselectable = any_bits(r_ptr->flags1, RF1_UNIQUE);
@@ -80,7 +80,7 @@ static bool monster_hook_tanuki(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx モンスター種族ID
  * @return モンスター種族の表層ID
  */
-static MONRACE_IDX initial_r_appearance(player_type *player_ptr, MONRACE_IDX r_idx, BIT_FLAGS generate_mode)
+static MONRACE_IDX initial_r_appearance(PlayerType *player_ptr, MONRACE_IDX r_idx, BIT_FLAGS generate_mode)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (is_chargeman(player_ptr) && any_bits(generate_mode, PM_JURAL) && none_bits(generate_mode, PM_MULTIPLY | PM_KAGE))
@@ -107,7 +107,7 @@ static MONRACE_IDX initial_r_appearance(player_type *player_ptr, MONRACE_IDX r_i
  * @param r_idx 生成モンスター種族
  * @return ユニークの生成が不可能な条件ならFALSE、それ以外はTRUE
  */
-static bool check_unique_placeable(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool check_unique_placeable(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     if (player_ptr->phase_out)
         return true;
@@ -142,7 +142,7 @@ static bool check_unique_placeable(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 生成モンスター種族
  * @return 生成が可能ならTRUE、不可能ならFALSE
  */
-static bool check_quest_placeable(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool check_quest_placeable(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (quest_number(player_ptr, floor_ptr->dun_level) == 0)
@@ -175,7 +175,7 @@ static bool check_quest_placeable(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param x 生成位置x座標
  * @return 生成が可能ならTRUE、不可能ならFALSE
  */
-static bool check_procection_rune(player_type *player_ptr, MONRACE_IDX r_idx, POSITION y, POSITION x)
+static bool check_procection_rune(PlayerType *player_ptr, MONRACE_IDX r_idx, POSITION y, POSITION x)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     if (!g_ptr->is_rune_protection())
@@ -195,7 +195,7 @@ static bool check_procection_rune(player_type *player_ptr, MONRACE_IDX r_idx, PO
     return true;
 }
 
-static void warn_unique_generation(player_type *player_ptr, MONRACE_IDX r_idx)
+static void warn_unique_generation(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     if (!player_ptr->warning || !w_ptr->character_dungeon)
         return;
@@ -239,7 +239,7 @@ static void warn_unique_generation(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param mode 生成オプション
  * @return 成功したらtrue
  */
-bool place_monster_one(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode)
+bool place_monster_one(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
index 1f58c1e..6dfaa15 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool place_monster_one(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode);
+class PlayerType;
+bool place_monster_one(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, MONRACE_IDX r_idx, BIT_FLAGS mode);
index 3dc7b89..80e5556 100644 (file)
@@ -25,7 +25,7 @@
  * @param m_idx モンスターID
  * @param see_m モンスターが視界内にいたらTRUE
  */
-static void vanish_nonunique(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m)
+static void vanish_nonunique(PlayerType *player_ptr, MONSTER_IDX m_idx, bool see_m)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     if (see_m) {
@@ -52,7 +52,7 @@ static void vanish_nonunique(player_type *player_ptr, MONSTER_IDX m_idx, bool se
  * パターンは収縮どころか拡散しているが、この際気にしてはいけない
  * @todo ユニークとプレイヤーとの間でしか効果が発生しない。ユニークとその他のモンスター間では何もしなくてよい?
  */
-static void produce_quantum_effect(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m)
+static void produce_quantum_effect(PlayerType *player_ptr, MONSTER_IDX m_idx, bool see_m)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     bool coherent = los(player_ptr, m_ptr->fy, m_ptr->fx, player_ptr->y, player_ptr->x);
@@ -80,7 +80,7 @@ static void produce_quantum_effect(player_type *player_ptr, MONSTER_IDX m_idx, b
  * @param see_m モンスターが視界内にいたらTRUE
  * @return モンスターが量子的効果により消滅したらTRUE
  */
-bool process_quantum_effect(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m)
+bool process_quantum_effect(PlayerType *player_ptr, MONSTER_IDX m_idx, bool see_m)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
index 16db4e3..88c54e9 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool process_quantum_effect(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m);
+class PlayerType;
+bool process_quantum_effect(PlayerType *player_ptr, MONSTER_IDX m_idx, bool see_m);
index 0ef7b8a..857678e 100644 (file)
@@ -53,7 +53,7 @@
  * @param radius 召喚半径 (モンスターが死亡した座標から半径何マス以内に召喚させるか)
  * @param message 召喚時のメッセージ
  */
-static void summon_self(player_type *player_ptr, monster_death_type *md_ptr, summon_type type, int probability, POSITION radius, concptr message)
+static void summon_self(PlayerType *player_ptr, monster_death_type *md_ptr, summon_type type, int probability, POSITION radius, concptr message)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (floor_ptr->inside_arena || player_ptr->phase_out || one_in_(probability))
@@ -75,7 +75,7 @@ static void summon_self(player_type *player_ptr, monster_death_type *md_ptr, sum
         msg_print(message);
 }
 
-static void on_dead_pink_horror(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_pink_horror(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (player_ptr->current_floor_ptr->inside_arena || player_ptr->phase_out)
         return;
@@ -97,7 +97,7 @@ static void on_dead_pink_horror(player_type *player_ptr, monster_death_type *md_
     }
 }
 
-static void on_dead_bloodletter(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_bloodletter(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!md_ptr->drop_chosen_item || (randint1(100) >= 15))
         return;
@@ -109,7 +109,7 @@ static void on_dead_bloodletter(player_type *player_ptr, monster_death_type *md_
     (void)drop_near(player_ptr, q_ptr, -1, md_ptr->md_y, md_ptr->md_x);
 }
 
-static void on_dead_raal(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_raal(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!md_ptr->drop_chosen_item || (floor_ptr->dun_level <= 9))
@@ -132,12 +132,12 @@ static void on_dead_raal(player_type *player_ptr, monster_death_type *md_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param md_ptr モンスター撃破構造体への参照ポインタ
  */
-static void on_dead_dawn(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_dawn(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     summon_self(player_ptr, md_ptr, SUMMON_DAWN, 7, 20, _("新たな戦士が現れた!", "A new warrior steps forth!"));
 }
 
-static void on_dead_unmaker(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_unmaker(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (is_seen(player_ptr, md_ptr->m_ptr)) {
         GAME_TEXT m_name[MAX_NLEN];
@@ -148,7 +148,7 @@ static void on_dead_unmaker(player_type *player_ptr, monster_death_type *md_ptr)
     (void)project(player_ptr, md_ptr->m_idx, 6, md_ptr->md_y, md_ptr->md_x, 100, AttributeType::CHAOS, PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL);
 }
 
-static void on_dead_sacred_treasures(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_sacred_treasures(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if ((player_ptr->ppersonality != PERSONALITY_LAZY) || !md_ptr->drop_chosen_item)
         return;
@@ -183,7 +183,7 @@ static void on_dead_sacred_treasures(player_type *player_ptr, monster_death_type
         a_ptr->cur_num = 1;
 }
 
-static void on_dead_serpent(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_serpent(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!md_ptr->drop_chosen_item)
         return;
@@ -201,7 +201,7 @@ static void on_dead_serpent(player_type *player_ptr, monster_death_type *md_ptr)
     (void)drop_near(player_ptr, q_ptr, -1, md_ptr->md_y, md_ptr->md_x);
 }
 
-static void on_dead_death_sword(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_death_sword(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!md_ptr->drop_chosen_item)
         return;
@@ -212,7 +212,7 @@ static void on_dead_death_sword(player_type *player_ptr, monster_death_type *md_
     (void)drop_near(player_ptr, q_ptr, -1, md_ptr->md_y, md_ptr->md_x);
 }
 
-static void on_dead_can_angel(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_can_angel(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     bool is_drop_can = md_ptr->drop_chosen_item;
     bool is_silver = md_ptr->m_ptr->r_idx == MON_A_SILVER;
@@ -228,7 +228,7 @@ static void on_dead_can_angel(player_type *player_ptr, monster_death_type *md_pt
     (void)drop_near(player_ptr, q_ptr, -1, md_ptr->md_y, md_ptr->md_x);
 }
 
-static void on_dead_rolento(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_rolento(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (is_seen(player_ptr, md_ptr->m_ptr)) {
         GAME_TEXT m_name[MAX_NLEN];
@@ -239,7 +239,7 @@ static void on_dead_rolento(player_type *player_ptr, monster_death_type *md_ptr)
     (void)project(player_ptr, md_ptr->m_idx, 3, md_ptr->md_y, md_ptr->md_x, damroll(20, 10), AttributeType::FIRE, PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL);
 }
 
-static void on_dead_aqua_illusion(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_aqua_illusion(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (player_ptr->current_floor_ptr->inside_arena || player_ptr->phase_out)
         return;
@@ -267,12 +267,12 @@ static void on_dead_aqua_illusion(player_type *player_ptr, monster_death_type *m
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param md_ptr モンスター撃破構造体への参照ポインタ
  */
-static void on_dead_totem_moai(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_totem_moai(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     summon_self(player_ptr, md_ptr, SUMMON_TOTEM_MOAI, 8, 5, _("新たなモアイが現れた!", "A new moai steps forth!"));
 }
 
-static void on_dead_demon_slayer_senior(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_demon_slayer_senior(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!is_seen(player_ptr, md_ptr->m_ptr))
         return;
@@ -282,7 +282,7 @@ static void on_dead_demon_slayer_senior(player_type *player_ptr, monster_death_t
     msg_format(_("あなたの闘気が%sの身体をサイコロ状に切り刻んだ!", "Your fighting spirit chopped %^s's body into dice!"), m_name);
 }
 
-static void on_dead_mirmulnir(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_mirmulnir(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!is_seen(player_ptr, md_ptr->m_ptr))
         return;
@@ -292,7 +292,7 @@ static void on_dead_mirmulnir(player_type *player_ptr, monster_death_type *md_pt
     msg_format(_("%s「ドヴ@ーキン、やめろぉ!」", "%^s says, 'Dov@hkiin! No!!'"), m_name);
 }
 
-static void on_dead_dragon_centipede(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_dragon_centipede(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (player_ptr->current_floor_ptr->inside_arena || player_ptr->phase_out)
         return;
@@ -321,7 +321,7 @@ static void on_dead_dragon_centipede(player_type *player_ptr, monster_death_type
  * @brief ビッグキューちゃん撃破時メッセージ
  * @todo 死亡時の特殊メッセージを表示するだけの処理を複数作るなら、switch/case文に分けられるように汎用化すること
  */
-static void on_dead_big_raven(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_big_raven(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!is_seen(player_ptr, md_ptr->m_ptr))
         return;
@@ -340,7 +340,7 @@ static void on_dead_big_raven(player_type *player_ptr, monster_death_type *md_pt
  * @return 生成したアイテムが装備品ならtrue、それ以外ならfalse
  * @todo 汎用的に使えそうだがどこかにいいファイルはないか?
  */
-static bool make_equipment(player_type *player_ptr, object_type *q_ptr, const BIT_FLAGS drop_mode, const bool is_object_hook_null)
+static bool make_equipment(PlayerType *player_ptr, object_type *q_ptr, const BIT_FLAGS drop_mode, const bool is_object_hook_null)
 {
     q_ptr->wipe();
     (void)make_object(player_ptr, q_ptr, drop_mode);
@@ -383,7 +383,7 @@ static bool make_equipment(player_type *player_ptr, object_type *q_ptr, const BI
  * 最初のアイテム生成でいきなり☆が生成された場合を除き、中途半端な☆ (例:呪われている)は生成しない.
  * このルーチンで★は生成されないので、★生成フラグのキャンセルも不要
  */
-static void on_dead_random_artifact(player_type *player_ptr, monster_death_type *md_ptr, bool (*object_hook_pf)(KIND_OBJECT_IDX k_idx))
+static void on_dead_random_artifact(PlayerType *player_ptr, monster_death_type *md_ptr, bool (*object_hook_pf)(KIND_OBJECT_IDX k_idx))
 {
     object_type forge;
     object_type *q_ptr = &forge;
@@ -423,7 +423,7 @@ static void on_dead_random_artifact(player_type *player_ptr, monster_death_type
  * @brief マニマニのあくま撃破時メッセージ
  * @todo 死亡時の特殊メッセージを表示するだけの処理を複数作るなら、switch/case文に分けられるように汎用化すること
  */
-static void on_dead_manimani(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_manimani(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!is_seen(player_ptr, md_ptr->m_ptr))
         return;
@@ -431,7 +431,7 @@ static void on_dead_manimani(player_type *player_ptr, monster_death_type *md_ptr
     msg_print(_("どこからか声が聞こえる…「ハロー! そして…グッドバイ!」", "Heard a voice from somewhere... 'Hello! And... good bye!'"));
 }
 
-static void drop_specific_item_on_dead(player_type *player_ptr, monster_death_type *md_ptr, bool (*object_hook_pf)(KIND_OBJECT_IDX k_idx))
+static void drop_specific_item_on_dead(PlayerType *player_ptr, monster_death_type *md_ptr, bool (*object_hook_pf)(KIND_OBJECT_IDX k_idx))
 {
     object_type forge;
     object_type *q_ptr = &forge;
@@ -441,7 +441,7 @@ static void drop_specific_item_on_dead(player_type *player_ptr, monster_death_ty
     (void)drop_near(player_ptr, q_ptr, -1, md_ptr->md_y, md_ptr->md_x);
 }
 
-static void on_dead_chest_mimic(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_chest_mimic(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (player_ptr->current_floor_ptr->inside_arena || player_ptr->phase_out)
         return;
@@ -486,7 +486,7 @@ static void on_dead_chest_mimic(player_type *player_ptr, monster_death_type *md_
     }
 }
 
-static void on_dead_mimics(player_type *player_ptr, monster_death_type *md_ptr)
+static void on_dead_mimics(PlayerType *player_ptr, monster_death_type *md_ptr)
 {
     if (!md_ptr->drop_chosen_item)
         return;
@@ -533,7 +533,7 @@ static void on_dead_mimics(player_type *player_ptr, monster_death_type *md_ptr)
     }
 }
 
-static void on_dead_swordfish(player_type *player_ptr, monster_death_type *md_ptr, AttributeFlags attribute_flags)
+static void on_dead_swordfish(PlayerType *player_ptr, monster_death_type *md_ptr, AttributeFlags attribute_flags)
 {
     if (attribute_flags.has_not(AttributeType::COLD) || !md_ptr->drop_chosen_item || (randint1(100) >= 10))
         return;
@@ -541,7 +541,7 @@ static void on_dead_swordfish(player_type *player_ptr, monster_death_type *md_pt
     drop_single_artifact(player_ptr, md_ptr, ART_FROZEN_SWORDFISH);
 }
 
-void switch_special_death(player_type *player_ptr, monster_death_type *md_ptr, AttributeFlags attribute_flags)
+void switch_special_death(PlayerType *player_ptr, monster_death_type *md_ptr, AttributeFlags attribute_flags)
 {
     switch (md_ptr->m_ptr->r_idx) {
     case MON_PINK_HORROR:
index 018dc48..ee3cd28 100644 (file)
@@ -3,5 +3,5 @@
 #include "effect/attribute-types.h"
 
 typedef struct monster_death_type monster_death_type;
-struct player_type;
-void switch_special_death(player_type *player_ptr, monster_death_type *md_ptr, AttributeFlags attribute_flags);
+class PlayerType;
+void switch_special_death(PlayerType *player_ptr, monster_death_type *md_ptr, AttributeFlags attribute_flags);
index 11173b5..f6db500 100644 (file)
@@ -33,7 +33,7 @@ EnumClassFlagGroup<MonsterAbilityType> vault_aux_dragon_mask4;
  * @brief pit/nestの基準となる単種モンスターを決める /
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void vault_prep_clone(player_type *player_ptr)
+void vault_prep_clone(PlayerType *player_ptr)
 {
     get_mon_num_prep(player_ptr, vault_aux_simple, nullptr);
     vault_aux_race = get_mon_num(player_ptr, 0, player_ptr->current_floor_ptr->dun_level + 10, 0);
@@ -44,7 +44,7 @@ void vault_prep_clone(player_type *player_ptr)
  * @brief pit/nestの基準となるモンスターシンボルを決める /
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void vault_prep_symbol(player_type *player_ptr)
+void vault_prep_symbol(PlayerType *player_ptr)
 {
     get_mon_num_prep(player_ptr, vault_aux_simple, nullptr);
     MONRACE_IDX r_idx = get_mon_num(player_ptr, 0, player_ptr->current_floor_ptr->dun_level + 10, 0);
@@ -56,7 +56,7 @@ void vault_prep_symbol(player_type *player_ptr)
  * @brief pit/nestの基準となるドラゴンの種類を決める /
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void vault_prep_dragon(player_type *player_ptr)
+void vault_prep_dragon(PlayerType *player_ptr)
 {
     /* Unused */
     (void)player_ptr;
@@ -89,7 +89,7 @@ void vault_prep_dragon(player_type *player_ptr)
  * @param r_idx モンスターID
  * @return 討伐対象にできるならTRUEを返す。
  */
-bool mon_hook_quest(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_quest(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -123,7 +123,7 @@ bool mon_hook_quest(player_type *player_ptr, MONRACE_IDX r_idx)
  * ダンジョンが火山の場合は、荒野の火山(WILD_VOLCANO)に出ない水棲動物(AQUATIC)は許可しない。
  * </pre>
  */
-bool mon_hook_dungeon(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_dungeon(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     if (!is_in_dungeon(player_ptr) && !player_ptr->current_floor_ptr->inside_quest)
         return true;
@@ -145,7 +145,7 @@ bool mon_hook_dungeon(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 海洋に出現するならばTRUEを返す
  */
-bool mon_hook_ocean(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_ocean(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -159,7 +159,7 @@ bool mon_hook_ocean(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 海岸に出現するならばTRUEを返す
  */
-bool mon_hook_shore(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_shore(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -173,7 +173,7 @@ bool mon_hook_shore(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 荒地に出現するならばTRUEを返す
  */
-bool mon_hook_waste(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_waste(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -187,7 +187,7 @@ bool mon_hook_waste(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 荒地に出現するならばTRUEを返す
  */
-bool mon_hook_town(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_town(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -201,7 +201,7 @@ bool mon_hook_town(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 森林に出現するならばTRUEを返す
  */
-bool mon_hook_wood(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_wood(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -215,7 +215,7 @@ bool mon_hook_wood(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 火山に出現するならばTRUEを返す
  */
-bool mon_hook_volcano(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_volcano(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -229,7 +229,7 @@ bool mon_hook_volcano(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 山地に出現するならばTRUEを返す
  */
-bool mon_hook_mountain(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_mountain(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -243,7 +243,7 @@ bool mon_hook_mountain(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 森林に出現するならばTRUEを返す
  */
-bool mon_hook_grass(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_grass(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -257,7 +257,7 @@ bool mon_hook_grass(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 深い水地形に出現するならばTRUEを返す
  */
-bool mon_hook_deep_water(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_deep_water(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!mon_hook_dungeon(player_ptr, r_idx))
@@ -271,7 +271,7 @@ bool mon_hook_deep_water(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 浅い水地形に出現するならばTRUEを返す
  */
-bool mon_hook_shallow_water(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_shallow_water(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!mon_hook_dungeon(player_ptr, r_idx))
@@ -285,7 +285,7 @@ bool mon_hook_shallow_water(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 溶岩地形に出現するならばTRUEを返す
  */
-bool mon_hook_lava(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_lava(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!mon_hook_dungeon(player_ptr, r_idx))
@@ -299,7 +299,7 @@ bool mon_hook_lava(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定するモンスターの種族ID
  * @return 通常の床地形に出現するならばTRUEを返す
  */
-bool mon_hook_floor(player_type *player_ptr, MONRACE_IDX r_idx)
+bool mon_hook_floor(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -314,7 +314,7 @@ bool mon_hook_floor(player_type *player_ptr, MONRACE_IDX r_idx)
 /*
  * Helper function for "glass room"
  */
-bool vault_aux_lite(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_lite(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -338,7 +338,7 @@ bool vault_aux_lite(player_type *player_ptr, MONRACE_IDX r_idx)
 /*
  * Helper function for "glass room"
  */
-bool vault_aux_shards(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_shards(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -356,7 +356,7 @@ bool vault_aux_shards(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return Vault生成の最低必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_simple(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_simple(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -370,7 +370,7 @@ bool vault_aux_simple(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_jelly(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_jelly(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -394,7 +394,7 @@ bool vault_aux_jelly(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_animal(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_animal(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -412,7 +412,7 @@ bool vault_aux_animal(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_undead(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_undead(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -430,7 +430,7 @@ bool vault_aux_undead(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_chapel_g(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_chapel_g(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     static int chapel_list[] = { MON_NOV_PRIEST, MON_NOV_PALADIN, MON_NOV_PRIEST_G, MON_NOV_PALADIN_G, MON_PRIEST, MON_JADE_MONK, MON_IVORY_MONK,
         MON_ULTRA_PALADIN, MON_EBONY_MONK, MON_W_KNIGHT, MON_KNI_TEMPLAR, MON_PALADIN, MON_TOPAZ_MONK, 0 };
@@ -461,7 +461,7 @@ bool vault_aux_chapel_g(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_kennel(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_kennel(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -479,7 +479,7 @@ bool vault_aux_kennel(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_mimic(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_mimic(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -497,7 +497,7 @@ bool vault_aux_mimic(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_clone(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_clone(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     if (!vault_monster_okay(player_ptr, r_idx))
         return false;
@@ -511,7 +511,7 @@ bool vault_aux_clone(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_symbol_e(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_symbol_e(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -535,7 +535,7 @@ bool vault_aux_symbol_e(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_symbol_g(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_symbol_g(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -559,7 +559,7 @@ bool vault_aux_symbol_g(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_orc(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_orc(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -580,7 +580,7 @@ bool vault_aux_orc(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_troll(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_troll(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -601,7 +601,7 @@ bool vault_aux_troll(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_giant(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_giant(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -625,7 +625,7 @@ bool vault_aux_giant(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_dragon(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_dragon(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -652,7 +652,7 @@ bool vault_aux_dragon(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_demon(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_demon(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -673,7 +673,7 @@ bool vault_aux_demon(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_cthulhu(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_cthulhu(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (!vault_monster_okay(player_ptr, r_idx))
@@ -694,7 +694,7 @@ bool vault_aux_cthulhu(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 確認したいモンスター種族ID
  * @return 生成必要条件を満たしているならTRUEを返す。
  */
-bool vault_aux_dark_elf(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_aux_dark_elf(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     static int dark_elf_list[] = {
         MON_D_ELF,
@@ -764,7 +764,7 @@ bool no_questor_or_bounty_uniques(MONRACE_IDX r_idx)
  * @param r_idx モンスターID
  * @return 死体を食べられるならTRUEを返す。
  */
-bool monster_hook_human(player_type *player_ptr, MONRACE_IDX r_idx)
+bool monster_hook_human(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -784,7 +784,7 @@ bool monster_hook_human(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定対象となるモンスターのID
  * @return 悪夢の元凶となり得るか否か。
  */
-bool get_nightmare(player_type *player_ptr, MONRACE_IDX r_idx)
+bool get_nightmare(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if (none_bits(r_ptr->flags2, RF2_ELDRITCH_HORROR))
@@ -801,7 +801,7 @@ bool get_nightmare(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx 判定したいモンスター種族のID
  * @return 釣れる対象ならばTRUEを返す
  */
-bool monster_is_fishing_target(player_type *player_ptr, MONRACE_IDX r_idx)
+bool monster_is_fishing_target(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -820,7 +820,7 @@ bool monster_is_fishing_target(player_type *player_ptr, MONRACE_IDX r_idx)
  * 自爆以外のなんらかのHP攻撃手段を持っていること。
  * @return 参加できるか否か
  */
-bool monster_can_entry_arena(player_type *player_ptr, MONRACE_IDX r_idx)
+bool monster_can_entry_arena(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -854,7 +854,7 @@ bool monster_can_entry_arena(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param r_idx チェックしたいモンスター種族のID
  * @return 人形にできるならTRUEを返す
  */
-bool item_monster_okay(player_type *player_ptr, MONRACE_IDX r_idx)
+bool item_monster_okay(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -890,7 +890,7 @@ bool item_monster_okay(player_type *player_ptr, MONRACE_IDX r_idx)
  * Line 2 -- forbid uniques
  * Line 3 -- forbid aquatic monsters
  */
-bool vault_monster_okay(player_type *player_ptr, MONRACE_IDX r_idx)
+bool vault_monster_okay(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     return (mon_hook_dungeon(player_ptr, r_idx) && none_bits(r_info[r_idx].flags1, RF1_UNIQUE) && none_bits(r_info[r_idx].flags7, RF7_UNIQUE2)
         && none_bits(r_info[r_idx].flagsr, RFR_RES_ALL) && none_bits(r_info[r_idx].flags7, RF7_AQUATIC));
index 14059e9..4fb5295 100644 (file)
@@ -9,54 +9,54 @@ extern int vault_aux_race;
 extern char vault_aux_char;
 extern EnumClassFlagGroup<MonsterAbilityType> vault_aux_dragon_mask4;
 
-struct player_type;
-bool mon_hook_quest(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_dungeon(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_ocean(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_shore(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_waste(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_town(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_wood(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_volcano(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_wood(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_volcano(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_mountain(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_grass(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_deep_water(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_shallow_water(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_lava(player_type *player_ptr, MONRACE_IDX r_idx);
-bool mon_hook_floor(player_type *player_ptr, MONRACE_IDX r_idx);
-
-void vault_prep_clone(player_type *player_ptr);
-void vault_prep_dragon(player_type *player_ptr);
-void vault_prep_symbol(player_type *player_ptr);
-
-bool vault_aux_lite(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_shards(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_simple(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_jelly(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_animal(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_undead(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_chapel_g(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_kennel(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_mimic(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_clone(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_symbol_e(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_symbol_g(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_orc(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_troll(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_giant(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_dragon(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_demon(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_cthulhu(player_type *player_ptr, MONRACE_IDX r_idx);
-bool vault_aux_dark_elf(player_type *player_ptr, MONRACE_IDX r_idx);
-
-bool vault_monster_okay(player_type *player_ptr, MONRACE_IDX r_idx);
+class PlayerType;
+bool mon_hook_quest(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_dungeon(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_ocean(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_shore(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_waste(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_town(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_wood(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_volcano(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_wood(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_volcano(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_mountain(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_grass(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_deep_water(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_shallow_water(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_lava(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool mon_hook_floor(PlayerType *player_ptr, MONRACE_IDX r_idx);
+
+void vault_prep_clone(PlayerType *player_ptr);
+void vault_prep_dragon(PlayerType *player_ptr);
+void vault_prep_symbol(PlayerType *player_ptr);
+
+bool vault_aux_lite(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_shards(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_simple(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_jelly(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_animal(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_undead(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_chapel_g(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_kennel(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_mimic(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_clone(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_symbol_e(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_symbol_g(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_orc(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_troll(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_giant(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_dragon(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_demon(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_cthulhu(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool vault_aux_dark_elf(PlayerType *player_ptr, MONRACE_IDX r_idx);
+
+bool vault_monster_okay(PlayerType *player_ptr, MONRACE_IDX r_idx);
 
 bool monster_living(MONRACE_IDX r_idx);
 bool no_questor_or_bounty_uniques(MONRACE_IDX r_idx);
-bool monster_hook_human(player_type *player_ptr, MONRACE_IDX r_idx);
-bool get_nightmare(player_type *player_ptr, MONRACE_IDX r_idx);
-bool monster_is_fishing_target(player_type *player_ptr, MONRACE_IDX r_idx);
-bool monster_can_entry_arena(player_type *player_ptr, MONRACE_IDX r_idx);
-bool item_monster_okay(player_type *player_ptr, MONRACE_IDX r_idx);
+bool monster_hook_human(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool get_nightmare(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool monster_is_fishing_target(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool monster_can_entry_arena(PlayerType *player_ptr, MONRACE_IDX r_idx);
+bool item_monster_okay(PlayerType *player_ptr, MONRACE_IDX r_idx);
index 68cff35..526afc9 100644 (file)
@@ -24,7 +24,7 @@
  * @param i1 配列移動元添字
  * @param i2 配列移動先添字
  */
-static void compact_monsters_aux(player_type *player_ptr, MONSTER_IDX i1, MONSTER_IDX i2)
+static void compact_monsters_aux(PlayerType *player_ptr, MONSTER_IDX i1, MONSTER_IDX i2)
 {
     if (i1 == i2)
         return;
@@ -92,7 +92,7 @@ static void compact_monsters_aux(player_type *player_ptr, MONSTER_IDX i1, MONSTE
  * After "compacting" (if needed), we "reorder" the monsters into a more
  * compact order, and we reset the allocation info, and the "live" array.
  */
-void compact_monsters(player_type *player_ptr, int size)
+void compact_monsters(PlayerType *player_ptr, int size)
 {
     if (size)
         msg_print(_("モンスター情報を圧縮しています...", "Compacting monsters..."));
index 5483f5e..1b8e0f6 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void compact_monsters(player_type *player_ptr, int size);
+class PlayerType;
+void compact_monsters(PlayerType *player_ptr, int size);
index 09b921f..9538e24 100644 (file)
@@ -58,7 +58,7 @@
  * @param attribute 与えたダメージの種類 (単一属性)
  * @param note モンスターが倒された際の特別なメッセージ述語
  */
-MonsterDamageProcessor::MonsterDamageProcessor(player_type *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *fear, AttributeType attribute)
+MonsterDamageProcessor::MonsterDamageProcessor(PlayerType *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *fear, AttributeType attribute)
     : player_ptr(player_ptr)
     , m_idx(m_idx)
     , dam(dam)
@@ -77,7 +77,7 @@ MonsterDamageProcessor::MonsterDamageProcessor(player_type *player_ptr, MONSTER_
  * @param attribute_flags 与えたダメージの種類 (複数属性)
  * @param note モンスターが倒された際の特別なメッセージ述語
  */
-MonsterDamageProcessor::MonsterDamageProcessor(player_type *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *fear, AttributeFlags attribute_flags)
+MonsterDamageProcessor::MonsterDamageProcessor(PlayerType *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *fear, AttributeFlags attribute_flags)
     : player_ptr(player_ptr)
     , m_idx(m_idx)
     , dam(dam)
index 0802e02..c012de0 100644 (file)
@@ -9,17 +9,17 @@
 
 struct monster_race;
 struct monster_type;
-struct player_type;
+class PlayerType;
 typedef std::vector<std::tuple<monster_race_type, monster_race_type, monster_race_type>> combined_uniques;
 class MonsterDamageProcessor {
 public:
-    MonsterDamageProcessor(player_type *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *fear, AttributeType type);
-    MonsterDamageProcessor(player_type *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *fear, AttributeFlags attribute_flags);
+    MonsterDamageProcessor(PlayerType *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *fear, AttributeType type);
+    MonsterDamageProcessor(PlayerType *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam, bool *fear, AttributeFlags attribute_flags);
     virtual ~MonsterDamageProcessor() = default;
     bool mon_take_hit(concptr note);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     MONSTER_IDX m_idx;
     HIT_POINT dam;
     bool *fear;
index 82c5c01..f69b50c 100644 (file)
@@ -20,7 +20,7 @@
  * @param m_ptr モンスターの参照ポインタ
  * @param mode 呼称オプション
  */
-void monster_desc(player_type *player_ptr, char *desc, monster_type *m_ptr, BIT_FLAGS mode)
+void monster_desc(PlayerType *player_ptr, char *desc, monster_type *m_ptr, BIT_FLAGS mode)
 {
     monster_race *r_ptr;
     r_ptr = &r_info[m_ptr->ap_r_idx];
@@ -247,7 +247,7 @@ void monster_desc(player_type *player_ptr, char *desc, monster_type *m_ptr, BIT_
  * @details
  * Technically should attempt to treat "Beholder"'s as jelly's
  */
-void message_pain(player_type *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam)
+void message_pain(PlayerType *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
index ad7c8cc..299373b 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 
 struct monster_type;
-struct player_type;
-void monster_desc(player_type *player_ptr, char *desc, monster_type *m_ptr, BIT_FLAGS mode);
-void message_pain(player_type *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam);
+class PlayerType;
+void monster_desc(PlayerType *player_ptr, char *desc, monster_type *m_ptr, BIT_FLAGS mode);
+void message_pain(PlayerType *player_ptr, MONSTER_IDX m_idx, HIT_POINT dam);
index 55318ad..392a318 100644 (file)
@@ -49,7 +49,7 @@ void set_friendly(monster_type *m_ptr) { m_ptr->mflag2.set(MonsterConstantFlagTy
  * @param mode オプション
  * @return 踏破可能ならばTRUEを返す
  */
-bool monster_can_cross_terrain(player_type *player_ptr, FEAT_IDX feat, monster_race *r_ptr, BIT_FLAGS16 mode)
+bool monster_can_cross_terrain(PlayerType *player_ptr, FEAT_IDX feat, monster_race *r_ptr, BIT_FLAGS16 mode)
 {
     feature_type *f_ptr = &f_info[feat];
 
@@ -126,7 +126,7 @@ bool monster_can_cross_terrain(player_type *player_ptr, FEAT_IDX feat, monster_r
  * @param mode オプション
  * @return 踏破可能ならばTRUEを返す
  */
-bool monster_can_enter(player_type *player_ptr, POSITION y, POSITION x, monster_race *r_ptr, BIT_FLAGS16 mode)
+bool monster_can_enter(PlayerType *player_ptr, POSITION y, POSITION x, monster_race *r_ptr, BIT_FLAGS16 mode)
 {
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[y][x];
     if (player_bold(player_ptr, y, x))
@@ -161,7 +161,7 @@ static bool check_hostile_align(byte sub_align1, byte sub_align2)
  * @param n_ptr モンスター2の構造体参照ポインタ
  * @return 敵対関係にあるならばTRUEを返す
  */
-bool are_enemies(player_type *player_ptr, monster_type *m_ptr, monster_type *n_ptr)
+bool are_enemies(PlayerType *player_ptr, monster_type *m_ptr, monster_type *n_ptr)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     monster_race *s_ptr = &r_info[n_ptr->r_idx];
@@ -201,7 +201,7 @@ bool are_enemies(player_type *player_ptr, monster_type *m_ptr, monster_type *n_p
  * @details
  * If user is player, m_ptr == nullptr.
  */
-bool monster_has_hostile_align(player_type *player_ptr, monster_type *m_ptr, int pa_good, int pa_evil, monster_race *r_ptr)
+bool monster_has_hostile_align(PlayerType *player_ptr, monster_type *m_ptr, int pa_good, int pa_evil, monster_race *r_ptr)
 {
     byte sub_align1 = SUB_ALIGN_NEUTRAL;
     byte sub_align2 = SUB_ALIGN_NEUTRAL;
@@ -229,7 +229,7 @@ bool monster_has_hostile_align(player_type *player_ptr, monster_type *m_ptr, int
     return false;
 }
 
-bool is_original_ap_and_seen(player_type *player_ptr, monster_type *m_ptr) { return m_ptr->ml && !player_ptr->hallucinated && (m_ptr->ap_r_idx == m_ptr->r_idx); }
+bool is_original_ap_and_seen(PlayerType *player_ptr, monster_type *m_ptr) { return m_ptr->ml && !player_ptr->hallucinated && (m_ptr->ap_r_idx == m_ptr->r_idx); }
 
 /*  Determine monster race appearance index is same as race index */
 bool is_original_ap(monster_type *m_ptr) { return m_ptr->ap_r_idx == m_ptr->r_idx; }
@@ -297,7 +297,7 @@ MONRACE_IDX real_r_idx(monster_type *m_ptr)
  * @param m_idx モンスターID
  * @param m_name モンスター名を入力する配列
  */
-void monster_name(player_type *player_ptr, MONSTER_IDX m_idx, char *m_name)
+void monster_name(PlayerType *player_ptr, MONSTER_IDX m_idx, char *m_name)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_desc(player_ptr, m_name, m_ptr, 0x00);
index 25a317a..3f7087f 100644 (file)
@@ -9,12 +9,12 @@
 #define CEM_P_CAN_ENTER_PATTERN 0x0002
 struct monster_race;
 struct monster_type;
-struct player_type;
-bool monster_can_cross_terrain(player_type *player_ptr, FEAT_IDX feat, monster_race *r_ptr, BIT_FLAGS16 mode);
-bool monster_can_enter(player_type *player_ptr, POSITION y, POSITION x, monster_race *r_ptr, BIT_FLAGS16 mode);
-bool are_enemies(player_type *player_ptr, monster_type *m_ptr1, monster_type *m_ptr2);
-bool monster_has_hostile_align(player_type *player_ptr, monster_type *m_ptr, int pa_good, int pa_evil, monster_race *r_ptr);
-bool is_original_ap_and_seen(player_type *player_ptr, monster_type *m_ptr);
+class PlayerType;
+bool monster_can_cross_terrain(PlayerType *player_ptr, FEAT_IDX feat, monster_race *r_ptr, BIT_FLAGS16 mode);
+bool monster_can_enter(PlayerType *player_ptr, POSITION y, POSITION x, monster_race *r_ptr, BIT_FLAGS16 mode);
+bool are_enemies(PlayerType *player_ptr, monster_type *m_ptr1, monster_type *m_ptr2);
+bool monster_has_hostile_align(PlayerType *player_ptr, monster_type *m_ptr, int pa_good, int pa_evil, monster_race *r_ptr);
+bool is_original_ap_and_seen(PlayerType *player_ptr, monster_type *m_ptr);
 
 bool is_friendly(monster_type *m_ptr);
 bool is_pet(monster_type *m_ptr);
@@ -24,4 +24,4 @@ bool is_mimicry(monster_type *m_ptr);
 
 monster_race *real_r_ptr(monster_type *m_ptr);
 MONRACE_IDX real_r_idx(monster_type *m_ptr);
-void monster_name(player_type *player_ptr, MONSTER_IDX m_idx, char *m_name);
+void monster_name(PlayerType *player_ptr, MONSTER_IDX m_idx, char *m_name);
index f4c7eb5..74928a9 100644 (file)
@@ -86,7 +86,7 @@ MONSTER_IDX m_pop(floor_type *floor_ptr)
  * @param max_level 最大生成階
  * @return 選択されたモンスター生成種族
  */
-MONRACE_IDX get_mon_num(player_type *player_ptr, DEPTH min_level, DEPTH max_level, BIT_FLAGS option)
+MONRACE_IDX get_mon_num(PlayerType *player_ptr, DEPTH min_level, DEPTH max_level, BIT_FLAGS option)
 {
     int r_idx;
     monster_race *r_ptr;
@@ -195,7 +195,7 @@ MONRACE_IDX get_mon_num(player_type *player_ptr, DEPTH min_level, DEPTH max_leve
  * @param r_idx モンスター種族ID
  * @return 対象にできるならtrueを返す
  */
-static bool monster_hook_chameleon_lord(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool monster_hook_chameleon_lord(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_race *r_ptr = &r_info[r_idx];
@@ -234,7 +234,7 @@ static bool monster_hook_chameleon_lord(player_type *player_ptr, MONRACE_IDX r_i
  * @return 対象にできるならtrueを返す
  * @todo グローバル変数対策の上 monster_hook.cへ移す。
  */
-static bool monster_hook_chameleon(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool monster_hook_chameleon(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_race *r_ptr = &r_info[r_idx];
@@ -277,7 +277,7 @@ static bool monster_hook_chameleon(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param born 生成時の初変身先指定ならばtrue
  * @param r_idx 旧モンスター種族のID
  */
-void choose_new_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool born, MONRACE_IDX r_idx)
+void choose_new_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, bool born, MONRACE_IDX r_idx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
index bc5b089..0995cff 100644 (file)
@@ -6,10 +6,10 @@
 
 struct floor_type;
 struct monster_race;
-struct player_type;
+class PlayerType;
 MONSTER_IDX m_pop(floor_type *floor_ptr);
 
-MONRACE_IDX get_mon_num(player_type *player_ptr, DEPTH min_level, DEPTH max_level, BIT_FLAGS option);
-void choose_new_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool born, MONRACE_IDX r_idx);
+MONRACE_IDX get_mon_num(PlayerType *player_ptr, DEPTH min_level, DEPTH max_level, BIT_FLAGS option);
+void choose_new_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, bool born, MONRACE_IDX r_idx);
 SPEED get_mspeed(floor_type *player_ptr, monster_race *r_ptr);
 int get_monster_crowd_number(floor_type *floor_ptr, MONSTER_IDX m_idx);
index 2a5503b..6d2bae8 100644 (file)
@@ -3,7 +3,7 @@
  * @date 2020/03/07
  * @author Hourier
  * @details
- * 概ね、player_type 構造体が引数でない場合はここへ移動させることを検討しても良い
+ * 概ね、PlayerType 構造体が引数でない場合はここへ移動させることを検討しても良い
  * 引数に入っていたらここには移動させないこと
  */
 
index 87525ce..8d3796a 100644 (file)
 #include "target/projection-path-calculator.h"
 #include "view/display-messages.h"
 
-void decide_drop_from_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool is_riding_mon);
-bool process_stealth(player_type *player_ptr, MONSTER_IDX m_idx);
-bool vanish_summoned_children(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m);
-bool awake_monster(player_type *player_ptr, MONSTER_IDX m_idx);
-void process_angar(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m);
-bool explode_grenade(player_type *player_ptr, MONSTER_IDX m_idx);
-bool decide_monster_multiplication(player_type *player_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox);
-void process_special(player_type *player_ptr, MONSTER_IDX m_idx);
-bool cast_spell(player_type *player_ptr, MONSTER_IDX m_idx, bool aware);
+void decide_drop_from_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, bool is_riding_mon);
+bool process_stealth(PlayerType *player_ptr, MONSTER_IDX m_idx);
+bool vanish_summoned_children(PlayerType *player_ptr, MONSTER_IDX m_idx, bool see_m);
+bool awake_monster(PlayerType *player_ptr, MONSTER_IDX m_idx);
+void process_angar(PlayerType *player_ptr, MONSTER_IDX m_idx, bool see_m);
+bool explode_grenade(PlayerType *player_ptr, MONSTER_IDX m_idx);
+bool decide_monster_multiplication(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox);
+void process_special(PlayerType *player_ptr, MONSTER_IDX m_idx);
+bool cast_spell(PlayerType *player_ptr, MONSTER_IDX m_idx, bool aware);
 
-bool process_monster_fear(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx);
+bool process_monster_fear(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx);
 
-void sweep_monster_process(player_type *player_ptr);
-bool decide_process_continue(player_type *player_ptr, monster_type *m_ptr);
+void sweep_monster_process(PlayerType *player_ptr);
+bool decide_process_continue(PlayerType *player_ptr, monster_type *m_ptr);
 
 /*!
  * @brief モンスター単体の1ターン行動処理メインルーチン /
@@ -112,7 +112,7 @@ bool decide_process_continue(player_type *player_ptr, monster_type *m_ptr);
  *\n
  * A "direction" of "5" means "pick a random direction".\n
  */
-void process_monster(player_type *player_ptr, MONSTER_IDX m_idx)
+void process_monster(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -190,7 +190,7 @@ void process_monster(player_type *player_ptr, MONSTER_IDX m_idx)
  * @param m_idx モンスターID
  * @return モンスターがプレイヤーに気付いているならばTRUE、超隠密状態ならばFALSE
  */
-bool process_stealth(player_type *player_ptr, MONSTER_IDX m_idx)
+bool process_stealth(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     auto ninja_data = PlayerClass(player_ptr).get_specific_data<ninja_data_type>();
     if (!ninja_data || !ninja_data->s_stealth)
@@ -217,7 +217,7 @@ bool process_stealth(player_type *player_ptr, MONSTER_IDX m_idx)
  * @param m_idx モンスターID
  * @param is_riding_mon 騎乗中であればTRUE
  */
-void decide_drop_from_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool is_riding_mon)
+void decide_drop_from_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, bool is_riding_mon)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -242,7 +242,7 @@ void decide_drop_from_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool i
  * @param see_m モンスターが視界内にいたらTRUE
  * @return 召喚モンスターが消滅したらTRUE
  */
-bool vanish_summoned_children(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m)
+bool vanish_summoned_children(PlayerType *player_ptr, MONSTER_IDX m_idx, bool see_m)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
 
@@ -275,7 +275,7 @@ bool vanish_summoned_children(player_type *player_ptr, MONSTER_IDX m_idx, bool s
  * @param m_idx モンスターID
  * @return 寝たままならFALSE、起きているor起きたらTRUE
  */
-bool awake_monster(player_type *player_ptr, MONSTER_IDX m_idx)
+bool awake_monster(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -304,7 +304,7 @@ bool awake_monster(player_type *player_ptr, MONSTER_IDX m_idx)
  * @param m_idx モンスターID
  * @param see_m モンスターが視界内にいたらTRUE
  */
-void process_angar(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m)
+void process_angar(PlayerType *player_ptr, MONSTER_IDX m_idx, bool see_m)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -348,7 +348,7 @@ void process_angar(player_type *player_ptr, MONSTER_IDX m_idx, bool see_m)
  * @param m_idx モンスターID
  * @return 爆死したらTRUE
  */
-bool explode_grenade(player_type *player_ptr, MONSTER_IDX m_idx)
+bool explode_grenade(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     if (m_ptr->r_idx != MON_GRENADE)
@@ -364,7 +364,7 @@ bool explode_grenade(player_type *player_ptr, MONSTER_IDX m_idx)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param m_idx モンスターID
  */
-void process_special(player_type *player_ptr, MONSTER_IDX m_idx)
+void process_special(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -395,7 +395,7 @@ void process_special(player_type *player_ptr, MONSTER_IDX m_idx)
  * @param ox 分裂元モンスターのX座標
  * @return 実際に分裂したらTRUEを返す
  */
-bool decide_monster_multiplication(player_type *player_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox)
+bool decide_monster_multiplication(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -435,7 +435,7 @@ bool decide_monster_multiplication(player_type *player_ptr, MONSTER_IDX m_idx, P
  * @param aware モンスターがプレイヤーに気付いているならばTRUE、超隠密状態ならばFALSE
  * @return 魔法を唱えられなければ強制的にFALSE、その後モンスターが実際に魔法を唱えればTRUE
  */
-bool cast_spell(player_type *player_ptr, MONSTER_IDX m_idx, bool aware)
+bool cast_spell(PlayerType *player_ptr, MONSTER_IDX m_idx, bool aware)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -470,7 +470,7 @@ bool cast_spell(player_type *player_ptr, MONSTER_IDX m_idx, bool aware)
  * @param aware モンスターがプレイヤーに気付いているならばTRUE、超隠密状態ならばFALSE
  * @return モンスターが戦いを決意したらTRUE
  */
-bool process_monster_fear(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx)
+bool process_monster_fear(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     bool is_battle_determined = !turn_flags_ptr->do_turn && !turn_flags_ptr->do_move && monster_fear_remaining(m_ptr) && turn_flags_ptr->aware;
@@ -520,7 +520,7 @@ bool process_monster_fear(player_type *player_ptr, turn_flags *turn_flags_ptr, M
  * changes (flags, attacks, spells), we induce a redraw of the monster\n
  * recall window.\n
  */
-void process_monsters(player_type *player_ptr)
+void process_monsters(PlayerType *player_ptr)
 {
     old_race_flags tmp_flags;
     old_race_flags *old_race_flags_ptr = init_old_race_flags(&tmp_flags);
@@ -539,7 +539,7 @@ void process_monsters(player_type *player_ptr)
  * @brief フロア内のモンスターについてターン終了時の処理を繰り返す
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void sweep_monster_process(player_type *player_ptr)
+void sweep_monster_process(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (MONSTER_IDX i = floor_ptr->m_max - 1; i >= 1; i--) {
@@ -583,7 +583,7 @@ void sweep_monster_process(player_type *player_ptr)
  * @param m_ptr モンスターへの参照ポインタ
  * @return 後続処理が必要ならTRUE
  */
-bool decide_process_continue(player_type *player_ptr, monster_type *m_ptr)
+bool decide_process_continue(PlayerType *player_ptr, monster_type *m_ptr)
 {
     monster_race *r_ptr;
     r_ptr = &r_info[m_ptr->r_idx];
index cd4b582..076c5d4 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void process_monsters(player_type *player_ptr);
-void process_monster(player_type *player_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+void process_monsters(PlayerType *player_ptr);
+void process_monster(PlayerType *player_ptr, MONSTER_IDX m_idx);
index aac3fcd..5761a77 100644 (file)
 
 /*!
  * @brief モンスターをペットにする
- * @param player_type プレイヤーへの参照ポインタ
+ * @param PlayerType プレイヤーへの参照ポインタ
  * @param m_ptr モンスター情報構造体の参照ポインタ
  */
-void set_pet(player_type *player_ptr, monster_type *m_ptr)
+void set_pet(PlayerType *player_ptr, monster_type *m_ptr)
 {
     QuestCompletionChecker(player_ptr, m_ptr).complete();
     m_ptr->mflag2.set(MonsterConstantFlagType::PET);
@@ -45,7 +45,7 @@ void set_pet(player_type *player_ptr, monster_type *m_ptr)
  * Makes the monster hostile towards the player
  * @param m_ptr モンスター情報構造体の参照ポインタ
  */
-void set_hostile(player_type *player_ptr, monster_type *m_ptr)
+void set_hostile(PlayerType *player_ptr, monster_type *m_ptr)
 {
     if (player_ptr->phase_out)
         return;
@@ -58,7 +58,7 @@ void set_hostile(player_type *player_ptr, monster_type *m_ptr)
  * Anger the monster
  * @param m_ptr モンスター情報構造体の参照ポインタ
  */
-void anger_monster(player_type *player_ptr, monster_type *m_ptr)
+void anger_monster(PlayerType *player_ptr, monster_type *m_ptr)
 {
     if (player_ptr->phase_out || !is_friendly(m_ptr))
         return;
@@ -94,7 +94,7 @@ static void mproc_remove(floor_type *floor_ptr, MONSTER_IDX m_idx, int mproc_typ
  * @param v セットする値
  * @return 別途更新処理が必要な場合TRUEを返す
  */
-bool set_monster_csleep(player_type *player_ptr, MONSTER_IDX m_idx, int v)
+bool set_monster_csleep(PlayerType *player_ptr, MONSTER_IDX m_idx, int v)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -138,7 +138,7 @@ bool set_monster_csleep(player_type *player_ptr, MONSTER_IDX m_idx, int v)
  * @param v セットする値
  * @return 別途更新処理が必要な場合TRUEを返す
  */
-bool set_monster_fast(player_type *player_ptr, MONSTER_IDX m_idx, int v)
+bool set_monster_fast(PlayerType *player_ptr, MONSTER_IDX m_idx, int v)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -169,7 +169,7 @@ bool set_monster_fast(player_type *player_ptr, MONSTER_IDX m_idx, int v)
 /*
  * Set "m_ptr->mtimed[MTIMED_SLOW]", notice observable changes
  */
-bool set_monster_slow(player_type *player_ptr, MONSTER_IDX m_idx, int v)
+bool set_monster_slow(PlayerType *player_ptr, MONSTER_IDX m_idx, int v)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -205,7 +205,7 @@ bool set_monster_slow(player_type *player_ptr, MONSTER_IDX m_idx, int v)
  * @param v セットする値
  * @return 別途更新処理が必要な場合TRUEを返す
  */
-bool set_monster_stunned(player_type *player_ptr, MONSTER_IDX m_idx, int v)
+bool set_monster_stunned(PlayerType *player_ptr, MONSTER_IDX m_idx, int v)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -235,7 +235,7 @@ bool set_monster_stunned(player_type *player_ptr, MONSTER_IDX m_idx, int v)
  * @param v セットする値
  * @return 別途更新処理が必要な場合TRUEを返す
  */
-bool set_monster_confused(player_type *player_ptr, MONSTER_IDX m_idx, int v)
+bool set_monster_confused(PlayerType *player_ptr, MONSTER_IDX m_idx, int v)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -265,7 +265,7 @@ bool set_monster_confused(player_type *player_ptr, MONSTER_IDX m_idx, int v)
  * @param v セットする値
  * @return 別途更新処理が必要な場合TRUEを返す
  */
-bool set_monster_monfear(player_type *player_ptr, MONSTER_IDX m_idx, int v)
+bool set_monster_monfear(PlayerType *player_ptr, MONSTER_IDX m_idx, int v)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -308,7 +308,7 @@ bool set_monster_monfear(player_type *player_ptr, MONSTER_IDX m_idx, int v)
  * @param energy_need TRUEならば無敵解除時に行動ターン消費を行う
  * @return 別途更新処理が必要な場合TRUEを返す
  */
-bool set_monster_invulner(player_type *player_ptr, MONSTER_IDX m_idx, int v, bool energy_need)
+bool set_monster_invulner(PlayerType *player_ptr, MONSTER_IDX m_idx, int v, bool energy_need)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -351,7 +351,7 @@ bool set_monster_invulner(player_type *player_ptr, MONSTER_IDX m_idx, int v, boo
  * @param vs_player TRUEならば時間停止開始処理を行う
  * @return 時間停止が行われている状態ならばTRUEを返す
  */
-bool set_monster_timewalk(player_type *player_ptr, int num, MONRACE_IDX who, bool vs_player)
+bool set_monster_timewalk(PlayerType *player_ptr, int num, MONRACE_IDX who, bool vs_player)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[hack_m_idx];
     if (w_ptr->timewalk_m_idx)
index 506108f..20de43d 100644 (file)
@@ -3,16 +3,16 @@
 #include "system/angband.h"
 
 struct monster_type;
-struct player_type;
+class PlayerType;
 void set_friendly(monster_type *m_ptr);
-void set_pet(player_type *player_ptr, monster_type *m_ptr);
-void set_hostile(player_type *player_ptr, monster_type *m_ptr);
-void anger_monster(player_type *player_ptr, monster_type *m_ptr);
-bool set_monster_csleep(player_type *player_ptr, MONSTER_IDX m_idx, int v);
-bool set_monster_fast(player_type *player_ptr, MONSTER_IDX m_idx, int v);
-bool set_monster_slow(player_type *player_ptr, MONSTER_IDX m_idx, int v);
-bool set_monster_stunned(player_type *player_ptr, MONSTER_IDX m_idx, int v);
-bool set_monster_confused(player_type *player_ptr, MONSTER_IDX m_idx, int v);
-bool set_monster_monfear(player_type *player_ptr, MONSTER_IDX m_idx, int v);
-bool set_monster_invulner(player_type *player_ptr, MONSTER_IDX m_idx, int v, bool energy_need);
-bool set_monster_timewalk(player_type *player_ptr, int num, MONRACE_IDX who, bool vs_player);
+void set_pet(PlayerType *player_ptr, monster_type *m_ptr);
+void set_hostile(PlayerType *player_ptr, monster_type *m_ptr);
+void anger_monster(PlayerType *player_ptr, monster_type *m_ptr);
+bool set_monster_csleep(PlayerType *player_ptr, MONSTER_IDX m_idx, int v);
+bool set_monster_fast(PlayerType *player_ptr, MONSTER_IDX m_idx, int v);
+bool set_monster_slow(PlayerType *player_ptr, MONSTER_IDX m_idx, int v);
+bool set_monster_stunned(PlayerType *player_ptr, MONSTER_IDX m_idx, int v);
+bool set_monster_confused(PlayerType *player_ptr, MONSTER_IDX m_idx, int v);
+bool set_monster_monfear(PlayerType *player_ptr, MONSTER_IDX m_idx, int v);
+bool set_monster_invulner(PlayerType *player_ptr, MONSTER_IDX m_idx, int v, bool energy_need);
+bool set_monster_timewalk(PlayerType *player_ptr, int num, MONRACE_IDX who, bool vs_player);
index d8c4274..fa2d703 100644 (file)
@@ -67,7 +67,7 @@ DEPTH monster_level_idx(floor_type *floor_ptr, MONSTER_IDX m_idx)
  * @return 修正を行った結果のダメージ量
  * @details RES_ALL持ちはAC軽減後のダメージを1/100に補正する. 光の剣は無敵を無効化する. 一定確率で無敵は貫通できる.
  */
-HIT_POINT mon_damage_mod(player_type *player_ptr, monster_type *m_ptr, HIT_POINT dam, bool is_psy_spear)
+HIT_POINT mon_damage_mod(PlayerType *player_ptr, monster_type *m_ptr, HIT_POINT dam, bool is_psy_spear)
 {
     auto *r_ptr = &r_info[m_ptr->r_idx];
     if ((r_ptr->flagsr & RFR_RES_ALL) && dam > 0) {
@@ -158,7 +158,7 @@ void mproc_init(floor_type *floor_ptr)
  * @param m_idx モンスター参照ID
  * @param mtimed_idx 更新するモンスターの時限ステータスID
  */
-static void process_monsters_mtimed_aux(player_type *player_ptr, MONSTER_IDX m_idx, int mtimed_idx)
+static void process_monsters_mtimed_aux(PlayerType *player_ptr, MONSTER_IDX m_idx, int mtimed_idx)
 {
     auto *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     switch (mtimed_idx) {
@@ -341,7 +341,7 @@ static void process_monsters_mtimed_aux(player_type *player_ptr, MONSTER_IDX m_i
  * Process the counters of monsters (once per 10 game turns)\n
  * These functions are to process monsters' counters same as player's.
  */
-void process_monsters_mtimed(player_type *player_ptr, int mtimed_idx)
+void process_monsters_mtimed(PlayerType *player_ptr, int mtimed_idx)
 {
     auto *floor_ptr = player_ptr->current_floor_ptr;
     const auto &cur_mproc_list = floor_ptr->mproc_list[mtimed_idx];
@@ -362,7 +362,7 @@ void process_monsters_mtimed(player_type *player_ptr, int mtimed_idx)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param m_idx 魔力消去を受けるモンスターの参照ID
  */
-void dispel_monster_status(player_type *player_ptr, MONSTER_IDX m_idx)
+void dispel_monster_status(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     auto *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     GAME_TEXT m_name[MAX_NLEN];
@@ -393,7 +393,7 @@ void dispel_monster_status(player_type *player_ptr, MONSTER_IDX m_idx)
  * @param m_idx 経験値を得るモンスターの参照ID
  * @param s_idx 撃破されたモンスター種族の参照ID
  */
-void monster_gain_exp(player_type *player_ptr, MONSTER_IDX m_idx, MONRACE_IDX s_idx)
+void monster_gain_exp(PlayerType *player_ptr, MONSTER_IDX m_idx, MONRACE_IDX s_idx)
 {
     if (m_idx <= 0 || s_idx <= 0) {
         return;
index 9c32e1c..d535347 100644 (file)
@@ -3,18 +3,18 @@
 #include "system/angband.h"
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 struct monster_type;
 bool monster_is_powerful(floor_type *floor_ptr, MONSTER_IDX m_idx);
 DEPTH monster_level_idx(floor_type *floor_ptr, MONSTER_IDX m_idx);
 
-HIT_POINT mon_damage_mod(player_type *player_ptr, monster_type *m_ptr, HIT_POINT dam, bool is_psy_spear);
+HIT_POINT mon_damage_mod(PlayerType *player_ptr, monster_type *m_ptr, HIT_POINT dam, bool is_psy_spear);
 bool monster_is_valid(monster_type *m_ptr);
 
-void dispel_monster_status(player_type *player_ptr, MONSTER_IDX m_idx);
-void monster_gain_exp(player_type *player_ptr, MONSTER_IDX m_idx, MONRACE_IDX s_idx);
+void dispel_monster_status(PlayerType *player_ptr, MONSTER_IDX m_idx);
+void monster_gain_exp(PlayerType *player_ptr, MONSTER_IDX m_idx, MONRACE_IDX s_idx);
 
-void process_monsters_mtimed(player_type *player_ptr, int mtimed_idx);
+void process_monsters_mtimed(PlayerType *player_ptr, int mtimed_idx);
 
 TIME_EFFECT monster_csleep_remaining(monster_type *m_ptr);
 TIME_EFFECT monster_fast_remaining(monster_type *m_ptr);
index a8612ba..2e18fa5 100644 (file)
@@ -67,7 +67,7 @@ typedef struct um_type {
  * @param ox 移動後の、モンスターのX座標
  * @return アイテム等に影響を及ぼしたらTRUE
  */
-bool update_riding_monster(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox, POSITION ny, POSITION nx)
+bool update_riding_monster(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox, POSITION ny, POSITION nx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[ny][nx];
@@ -97,7 +97,7 @@ bool update_riding_monster(player_type *player_ptr, turn_flags *turn_flags_ptr,
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param turn_flags_ptr ターン経過処理フラグへの参照ポインタ
  */
-void update_player_type(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_race *r_ptr)
+void update_player_type(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_race *r_ptr)
 {
     if (turn_flags_ptr->do_view) {
         player_ptr->update |= PU_FLOW;
@@ -117,7 +117,7 @@ void update_player_type(player_type *player_ptr, turn_flags *turn_flags_ptr, mon
  * @param turn_flags_ptr ターン経過処理フラグへの参照ポインタ
  * @param m_ptr モンスターへの参照ポインタ
  */
-void update_monster_race_flags(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr)
+void update_monster_race_flags(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     if (!is_original_ap_and_seen(player_ptr, m_ptr))
@@ -151,7 +151,7 @@ void update_monster_race_flags(player_type *player_ptr, turn_flags *turn_flags_p
  * @param window ウィンドウフラグ
  * @param old_race_flags_ptr モンスターフラグへの参照ポインタ
  */
-void update_player_window(player_type *player_ptr, old_race_flags *old_race_flags_ptr)
+void update_player_window(PlayerType *player_ptr, old_race_flags *old_race_flags_ptr)
 {
     monster_race *r_ptr;
     r_ptr = &r_info[player_ptr->monster_race_idx];
@@ -164,7 +164,7 @@ void update_player_window(player_type *player_ptr, old_race_flags *old_race_flag
     }
 }
 
-static um_type *initialize_um_type(player_type *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx, bool full)
+static um_type *initialize_um_type(PlayerType *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx, bool full)
 {
     um_ptr->m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     um_ptr->do_disturb = disturb_move;
@@ -177,7 +177,7 @@ static um_type *initialize_um_type(player_type *player_ptr, um_type *um_ptr, MON
     return um_ptr;
 }
 
-static POSITION decide_updated_distance(player_type *player_ptr, um_type *um_ptr)
+static POSITION decide_updated_distance(PlayerType *player_ptr, um_type *um_ptr)
 {
     if (!um_ptr->full)
         return um_ptr->m_ptr->cdis;
@@ -211,7 +211,7 @@ static void update_smart_stupid_flags(monster_race *r_ptr)
  * @param m_idx モンスターID
  * @return WEIRD_MINDフラグがあるならTRUE
  */
-static bool update_weird_telepathy(player_type *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
+static bool update_weird_telepathy(PlayerType *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
 {
     monster_race *r_ptr = &r_info[um_ptr->m_ptr->r_idx];
     if ((r_ptr->flags2 & RF2_WEIRD_MIND) == 0)
@@ -230,7 +230,7 @@ static bool update_weird_telepathy(player_type *player_ptr, um_type *um_ptr, MON
     return true;
 }
 
-static void update_telepathy_sight(player_type *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
+static void update_telepathy_sight(PlayerType *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
 {
     monster_race *r_ptr = &r_info[um_ptr->m_ptr->r_idx];
     if (PlayerClass(player_ptr).samurai_stance_is(SamuraiStanceType::MUSOU)) {
@@ -261,7 +261,7 @@ static void update_telepathy_sight(player_type *player_ptr, um_type *um_ptr, MON
         update_smart_stupid_flags(r_ptr);
 }
 
-static void update_specific_race_telepathy(player_type *player_ptr, um_type *um_ptr)
+static void update_specific_race_telepathy(PlayerType *player_ptr, um_type *um_ptr)
 {
     monster_race *r_ptr = &r_info[um_ptr->m_ptr->r_idx];
     if ((player_ptr->esp_animal) && (r_ptr->flags3 & RF3_ANIMAL)) {
@@ -349,7 +349,7 @@ static void update_specific_race_telepathy(player_type *player_ptr, um_type *um_
     }
 }
 
-static bool check_cold_blood(player_type *player_ptr, um_type *um_ptr, const POSITION distance)
+static bool check_cold_blood(PlayerType *player_ptr, um_type *um_ptr, const POSITION distance)
 {
     if (distance > player_ptr->see_infra)
         return false;
@@ -363,7 +363,7 @@ static bool check_cold_blood(player_type *player_ptr, um_type *um_ptr, const POS
     return true;
 }
 
-static bool check_invisible(player_type *player_ptr, um_type *um_ptr)
+static bool check_invisible(PlayerType *player_ptr, um_type *um_ptr)
 {
     if (!player_can_see_bold(player_ptr, um_ptr->fy, um_ptr->fx))
         return false;
@@ -387,7 +387,7 @@ static bool check_invisible(player_type *player_ptr, um_type *um_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param um_ptr モンスター情報アップデート構造体への参照ポインタ
  */
-static void decide_sight_invisible_monster(player_type *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
+static void decide_sight_invisible_monster(PlayerType *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
 {
     POSITION distance = decide_updated_distance(player_ptr, um_ptr);
     monster_race *r_ptr = &r_info[um_ptr->m_ptr->r_idx];
@@ -431,7 +431,7 @@ static void decide_sight_invisible_monster(player_type *player_ptr, um_type *um_
  * @param m_idx フロアのモンスター番号
  * @details 感知した結果、エルドリッチホラー持ちがいたら精神を破壊する
  */
-static void update_invisible_monster(player_type *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
+static void update_invisible_monster(PlayerType *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
 {
     if (um_ptr->m_ptr->ml)
         return;
@@ -465,7 +465,7 @@ static void update_invisible_monster(player_type *player_ptr, um_type *um_ptr, M
     }
 }
 
-static void update_visible_monster(player_type *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
+static void update_visible_monster(PlayerType *player_ptr, um_type *um_ptr, MONSTER_IDX m_idx)
 {
     if (!um_ptr->m_ptr->ml)
         return;
@@ -483,7 +483,7 @@ static void update_visible_monster(player_type *player_ptr, um_type *um_ptr, MON
         disturb(player_ptr, true, true);
 }
 
-static bool update_clear_monster(player_type *player_ptr, um_type *um_ptr)
+static bool update_clear_monster(PlayerType *player_ptr, um_type *um_ptr)
 {
     if (!um_ptr->easy)
         return false;
@@ -502,7 +502,7 @@ static bool update_clear_monster(player_type *player_ptr, um_type *um_ptr)
  * @param m_idx 更新するモンスター情報のID
  * @param full プレイヤーとの距離更新を行うならばtrue
  */
-void update_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool full)
+void update_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, bool full)
 {
     um_type tmp_um;
     um_type *um_ptr = initialize_um_type(player_ptr, &tmp_um, m_idx, full);
@@ -535,7 +535,7 @@ void update_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool full)
  * @param full 距離更新を行うならtrue
  * @todo モンスターの感知状況しか更新していないように見える。関数名変更を検討する
  */
-void update_monsters(player_type *player_ptr, bool full)
+void update_monsters(PlayerType *player_ptr, bool full)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (MONSTER_IDX i = 1; i < floor_ptr->m_max; i++) {
@@ -552,7 +552,7 @@ void update_monsters(player_type *player_ptr, bool full)
  * @param m_idx 更新を行う「モンスター情報ID
  * @param what 学習対象ID
  */
-void update_smart_learn(player_type *player_ptr, MONSTER_IDX m_idx, int what)
+void update_smart_learn(PlayerType *player_ptr, MONSTER_IDX m_idx, int what)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
index 19d0a1d..9292cfc 100644 (file)
@@ -5,12 +5,12 @@
 struct monster_race;
 struct monster_type;
 struct old_race_flags;;
-struct player_type;
+class PlayerType;
 struct turn_flags;
-bool update_riding_monster(player_type *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox, POSITION ny, POSITION nx);
-void update_player_type(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_race *r_ptr);
-void update_monster_race_flags(player_type *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr);
-void update_player_window(player_type *player_ptr, old_race_flags *old_race_flags_ptr);
-void update_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool full);
-void update_monsters(player_type *player_ptr, bool full);
-void update_smart_learn(player_type *player_ptr, MONSTER_IDX m_idx, int what);
+bool update_riding_monster(PlayerType *player_ptr, turn_flags *turn_flags_ptr, MONSTER_IDX m_idx, POSITION oy, POSITION ox, POSITION ny, POSITION nx);
+void update_player_type(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_race *r_ptr);
+void update_monster_race_flags(PlayerType *player_ptr, turn_flags *turn_flags_ptr, monster_type *m_ptr);
+void update_player_window(PlayerType *player_ptr, old_race_flags *old_race_flags_ptr);
+void update_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, bool full);
+void update_monsters(PlayerType *player_ptr, bool full);
+void update_smart_learn(PlayerType *player_ptr, MONSTER_IDX m_idx, int what);
index e4250f4..48837ed 100644 (file)
@@ -51,7 +51,7 @@ summon_type summon_specific_type = SUMMON_NONE;
  * @param r_idx チェックするモンスター種族ID
  * @return 召喚条件が一致するならtrue / Return TRUE is the monster is OK and FALSE otherwise
  */
-static bool restrict_monster_to_dungeon(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool restrict_monster_to_dungeon(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     DUNGEON_IDX d_idx = player_ptr->dungeon_idx;
     dungeon_type *d_ptr = &d_info[d_idx];
@@ -239,7 +239,7 @@ static bool restrict_monster_to_dungeon(player_type *player_ptr, MONRACE_IDX r_i
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 地勢にあったモンスターの生成条件関数
  */
-monsterrace_hook_type get_monster_hook(player_type *player_ptr)
+monsterrace_hook_type get_monster_hook(PlayerType *player_ptr)
 {
     if ((player_ptr->current_floor_ptr->dun_level > 0) || (player_ptr->current_floor_ptr->inside_quest > 0))
         return (monsterrace_hook_type)mon_hook_dungeon;
@@ -273,7 +273,7 @@ monsterrace_hook_type get_monster_hook(player_type *player_ptr)
  * @brief 指定された広域マップ座標の地勢を元にモンスターの生成条件関数を返す
  * @return 地勢にあったモンスターの生成条件関数
  */
-monsterrace_hook_type get_monster_hook2(player_type *player_ptr, POSITION y, POSITION x)
+monsterrace_hook_type get_monster_hook2(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     feature_type *f_ptr = &f_info[player_ptr->current_floor_ptr->grid_array[y][x].feat];
     if (f_ptr->flags.has(FloorFeatureType::WATER))
@@ -296,7 +296,7 @@ monsterrace_hook_type get_monster_hook2(player_type *player_ptr, POSITION y, POS
  * モンスター生成テーブル alloc_race_table の各要素の基本重み prob1 を指定条件
  * に従って変更し、結果を prob2 に書き込む。
  */
-static errr do_get_mon_num_prep(player_type *player_ptr, const monsterrace_hook_type hook1, const monsterrace_hook_type hook2, const bool restrict_to_dungeon)
+static errr do_get_mon_num_prep(PlayerType *player_ptr, const monsterrace_hook_type hook1, const monsterrace_hook_type hook2, const bool restrict_to_dungeon)
 {
     const floor_type *const floor_ptr = player_ptr->current_floor_ptr;
 
@@ -392,7 +392,7 @@ static errr do_get_mon_num_prep(player_type *player_ptr, const monsterrace_hook_
  *
  * get_mon_num() を呼ぶ前に get_mon_num_prep() 系関数のいずれかを呼ぶこと。
  */
-errr get_mon_num_prep(player_type *player_ptr, const monsterrace_hook_type hook1, const monsterrace_hook_type hook2)
+errr get_mon_num_prep(PlayerType *player_ptr, const monsterrace_hook_type hook1, const monsterrace_hook_type hook2)
 {
     return do_get_mon_num_prep(player_ptr, hook1, hook2, true);
 }
@@ -403,7 +403,7 @@ errr get_mon_num_prep(player_type *player_ptr, const monsterrace_hook_type hook1
  *
  * get_mon_num() を呼ぶ前に get_mon_num_prep 系関数のいずれかを呼ぶこと。
  */
-errr get_mon_num_prep_bounty(player_type *player_ptr)
+errr get_mon_num_prep_bounty(PlayerType *player_ptr)
 {
     return do_get_mon_num_prep(player_ptr, nullptr, nullptr, false);
 }
index fca0d21..331dde1 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-typedef bool (*monsterrace_hook_type)(player_type *, MONRACE_IDX);
+class PlayerType;
+typedef bool (*monsterrace_hook_type)(PlayerType *, MONRACE_IDX);
 
 extern MONSTER_IDX hack_m_idx;
 extern MONSTER_IDX hack_m_idx_ii;
@@ -11,7 +11,7 @@ extern int chameleon_change_m_idx;
 enum summon_type : int;
 extern summon_type summon_specific_type;
 
-monsterrace_hook_type get_monster_hook(player_type *player_ptr);
-monsterrace_hook_type get_monster_hook2(player_type *player_ptr, POSITION y, POSITION x);
-errr get_mon_num_prep(player_type *player_ptr, monsterrace_hook_type hook1, monsterrace_hook_type hook2);
-errr get_mon_num_prep_bounty(player_type *player_ptr);
+monsterrace_hook_type get_monster_hook(PlayerType *player_ptr);
+monsterrace_hook_type get_monster_hook2(PlayerType *player_ptr, POSITION y, POSITION x);
+errr get_mon_num_prep(PlayerType *player_ptr, monsterrace_hook_type hook1, monsterrace_hook_type hook2);
+errr get_mon_num_prep_bounty(PlayerType *player_ptr);
index 8f04c5d..f27fbcf 100644 (file)
@@ -24,7 +24,7 @@
 #include "system/player-type-definition.h"
 #include "util/enum-converter.h"
 
-static MonsterSpellResult monspell_to_player_impl(player_type *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx)
+static MonsterSpellResult monspell_to_player_impl(PlayerType *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     // clang-format off
     switch (ms_type) {
@@ -132,7 +132,7 @@ static MonsterSpellResult monspell_to_player_impl(player_type *player_ptr, Monst
 }
 
 static MonsterSpellResult monspell_to_monster_impl(
-    player_type *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, bool is_special_spell)
+    PlayerType *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, bool is_special_spell)
 {
     // clang-format off
     switch (ms_type) {
@@ -246,7 +246,7 @@ static MonsterSpellResult monspell_to_monster_impl(
  * @param x 対象の地点のx座標
  * @param m_idx 呪文を唱えるモンスターID
  */
-MonsterSpellResult monspell_to_player(player_type *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx)
+MonsterSpellResult monspell_to_player(PlayerType *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     // 特技使用前の時点でプレイヤーがモンスターを視認できているかチェック(ラーニングの必要条件)。
     const bool player_could_see_monster = spell_learnable(player_ptr, m_idx);
@@ -272,10 +272,10 @@ MonsterSpellResult monspell_to_player(player_type *player_ptr, MonsterAbilityTyp
  * @param m_idx 呪文を唱えるモンスターID
  * @param t_idx 呪文を受けるモンスターID。プレイヤーの場合はdummyで0とする。
  * @param is_special_spell 特殊な行動である時TRUE
- * @todo モンスターからモンスターへの呪文なのにplayer_typeが引数になり得るのは間違っている……
+ * @todo モンスターからモンスターへの呪文なのにPlayerTypeが引数になり得るのは間違っている……
  */
 MonsterSpellResult monspell_to_monster(
-    player_type *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, bool is_special_spell)
+    PlayerType *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, bool is_special_spell)
 {
     // 特技使用前の時点でプレイヤーがモンスターを視認できているかチェック(ラーニングの必要条件)。
     const bool player_could_see_monster = spell_learnable(player_ptr, m_idx);
index 7a090b6..dc0306b 100644 (file)
@@ -6,7 +6,7 @@ struct MonsterSpellResult;
 
 enum class MonsterAbilityType;
 
-struct player_type;
-MonsterSpellResult monspell_to_player(player_type *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx);
+class PlayerType;
+MonsterSpellResult monspell_to_player(PlayerType *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx);
 MonsterSpellResult monspell_to_monster(
-    player_type *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, bool is_special_spell);
+    PlayerType *player_ptr, MonsterAbilityType ms_type, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, bool is_special_spell);
index 84b0f16..9a6a3d3 100644 (file)
@@ -8,7 +8,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-void add_cheat_remove_flags_element(player_type *player_ptr, msr_type *msr_ptr)
+void add_cheat_remove_flags_element(PlayerType *player_ptr, msr_type *msr_ptr)
 {
     if (has_resist_acid(player_ptr))
         msr_ptr->smart.set(MonsterSmartLearnType::RES_ACID);
index bbe6a43..a0b12d8 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
 typedef struct msr_type msr_type;
-struct player_type;
-void add_cheat_remove_flags_element(player_type *player_ptr, msr_type *msr_ptr);
+class PlayerType;
+void add_cheat_remove_flags_element(PlayerType *player_ptr, msr_type *msr_ptr);
 void check_element_resistance(msr_type *msr_ptr);
index 150c4da..022f940 100644 (file)
@@ -7,7 +7,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-void add_cheat_remove_flags_others(player_type *player_ptr, msr_type *msr_ptr)
+void add_cheat_remove_flags_others(PlayerType *player_ptr, msr_type *msr_ptr)
 {
     if (has_resist_neth(player_ptr))
         msr_ptr->smart.set(MonsterSmartLearnType::RES_NETH);
@@ -52,7 +52,7 @@ void add_cheat_remove_flags_others(player_type *player_ptr, msr_type *msr_ptr)
         msr_ptr->smart.set(MonsterSmartLearnType::IMM_MANA);
 }
 
-static void check_nether_resistance(player_type *player_ptr, msr_type *msr_ptr)
+static void check_nether_resistance(PlayerType *player_ptr, msr_type *msr_ptr)
 {
     if (msr_ptr->smart.has_not(MonsterSmartLearnType::RES_NETH))
         return;
@@ -86,7 +86,7 @@ static void check_lite_resistance(msr_type *msr_ptr)
         msr_ptr->ability_flags.reset(MonsterAbilityType::BA_LITE);
 }
 
-static void check_dark_resistance(player_type *player_ptr, msr_type *msr_ptr)
+static void check_dark_resistance(PlayerType *player_ptr, msr_type *msr_ptr)
 {
     if (msr_ptr->smart.has_not(MonsterSmartLearnType::RES_DARK))
         return;
@@ -173,7 +173,7 @@ static void check_reflection(msr_type *msr_ptr)
         msr_ptr->ability_flags.reset(MonsterAbilityType::MISSILE);
 }
 
-void check_high_resistances(player_type *player_ptr, msr_type *msr_ptr)
+void check_high_resistances(PlayerType *player_ptr, msr_type *msr_ptr)
 {
     check_nether_resistance(player_ptr, msr_ptr);
     check_lite_resistance(msr_ptr);
index 72d6957..b6b8c1a 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
 typedef struct msr_type msr_type;
-struct player_type;
-void add_cheat_remove_flags_others(player_type *player_ptr, msr_type *msr_ptr);
-void check_high_resistances(player_type *player_ptr, msr_type *msr_ptr);
+class PlayerType;
+void add_cheat_remove_flags_others(PlayerType *player_ptr, msr_type *msr_ptr);
+void check_high_resistances(PlayerType *player_ptr, msr_type *msr_ptr);
index f367c6a..41bd75b 100644 (file)
@@ -11,7 +11,7 @@
 #include "system/monster-type-definition.h"
 #include "system/player-type-definition.h"
 
-static void add_cheat_remove_flags(player_type *player_ptr, msr_type *msr_ptr)
+static void add_cheat_remove_flags(PlayerType *player_ptr, msr_type *msr_ptr)
 {
     if (!smart_cheat)
         return;
@@ -28,7 +28,7 @@ static void add_cheat_remove_flags(player_type *player_ptr, msr_type *msr_ptr)
  * @param f5p モンスター魔法のフラグリスト2
  * @param f6p モンスター魔法のフラグリスト3
  */
-void remove_bad_spells(MONSTER_IDX m_idx, player_type *player_ptr, EnumClassFlagGroup<MonsterAbilityType> &ability_flags)
+void remove_bad_spells(MONSTER_IDX m_idx, PlayerType *player_ptr, EnumClassFlagGroup<MonsterAbilityType> &ability_flags)
 {
     msr_type tmp_msr;
     msr_type *msr_ptr = initialize_msr_type(player_ptr, &tmp_msr, m_idx, ability_flags);
index 1b9c822..ba8ebe9 100644 (file)
@@ -5,5 +5,5 @@
 #include "monster-race/race-ability-flags.h"
 #include "util/flag-group.h"
 
-struct player_type;
-void remove_bad_spells(MONSTER_IDX m_idx, player_type *player_ptr, EnumClassFlagGroup<MonsterAbilityType> &ability_flags);
+class PlayerType;
+void remove_bad_spells(MONSTER_IDX m_idx, PlayerType *player_ptr, EnumClassFlagGroup<MonsterAbilityType> &ability_flags);
index 7084cad..c6c86f4 100644 (file)
@@ -5,7 +5,7 @@
 #include "system/monster-type-definition.h"
 #include "system/player-type-definition.h"
 
-msa_type *initialize_msa_type(player_type *player_ptr, msa_type *msa_ptr, MONSTER_IDX m_idx)
+msa_type *initialize_msa_type(PlayerType *player_ptr, msa_type *msa_ptr, MONSTER_IDX m_idx)
 {
     msa_ptr->m_idx = m_idx;
     msa_ptr->m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
index bdbfff2..68d1476 100644 (file)
@@ -38,5 +38,5 @@ typedef struct msa_type {
     DEPTH rlev;
 } msa_type;
 
-struct player_type;
-msa_type *initialize_msa_type(player_type *player_ptr, msa_type *msa_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+msa_type *initialize_msa_type(PlayerType *player_ptr, msa_type *msa_ptr, MONSTER_IDX m_idx);
index ba0c8ec..682ef1f 100644 (file)
@@ -51,7 +51,7 @@ static void set_no_magic_mask(msa_type *msa_ptr)
     msa_ptr->ability_flags.reset(RF_ABILITY_NOMAGIC_MASK);
 }
 
-static void check_mspell_stupid(player_type *player_ptr, msa_type *msa_ptr)
+static void check_mspell_stupid(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     msa_ptr->in_no_magic_dungeon = d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::NO_MAGIC) && floor_ptr->dun_level
@@ -62,7 +62,7 @@ static void check_mspell_stupid(player_type *player_ptr, msa_type *msa_ptr)
     msa_ptr->ability_flags &= RF_ABILITY_NOMAGIC_MASK;
 }
 
-static void check_mspell_smart(player_type *player_ptr, msa_type *msa_ptr)
+static void check_mspell_smart(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if ((msa_ptr->r_ptr->flags2 & RF2_SMART) == 0)
         return;
@@ -76,7 +76,7 @@ static void check_mspell_smart(player_type *player_ptr, msa_type *msa_ptr)
     }
 }
 
-static void check_mspell_arena(player_type *player_ptr, msa_type *msa_ptr)
+static void check_mspell_arena(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if (!player_ptr->current_floor_ptr->inside_arena && !player_ptr->phase_out)
         return;
@@ -87,7 +87,7 @@ static void check_mspell_arena(player_type *player_ptr, msa_type *msa_ptr)
         msa_ptr->ability_flags.reset(MonsterAbilityType::SPECIAL);
 }
 
-static bool check_mspell_non_stupid(player_type *player_ptr, msa_type *msa_ptr)
+static bool check_mspell_non_stupid(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if ((msa_ptr->r_ptr->flags2 & RF2_STUPID) != 0)
         return true;
@@ -119,7 +119,7 @@ static void set_mspell_list(msa_type *msa_ptr)
     EnumClassFlagGroup<MonsterAbilityType>::get_flags(msa_ptr->ability_flags, std::back_inserter(msa_ptr->mspells));
 }
 
-static void describe_mspell_monster(player_type *player_ptr, msa_type *msa_ptr)
+static void describe_mspell_monster(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     monster_desc(player_ptr, msa_ptr->m_name, msa_ptr->m_ptr, 0x00);
 
@@ -131,7 +131,7 @@ static void describe_mspell_monster(player_type *player_ptr, msa_type *msa_ptr)
 #endif
 }
 
-static bool switch_do_spell(player_type *player_ptr, msa_type *msa_ptr)
+static bool switch_do_spell(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     switch (msa_ptr->do_spell) {
     case DO_SPELL_NONE: {
@@ -158,7 +158,7 @@ static bool switch_do_spell(player_type *player_ptr, msa_type *msa_ptr)
     }
 }
 
-static bool check_mspell_continuation(player_type *player_ptr, msa_type *msa_ptr)
+static bool check_mspell_continuation(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if (msa_ptr->ability_flags.none())
         return false;
@@ -179,7 +179,7 @@ static bool check_mspell_continuation(player_type *player_ptr, msa_type *msa_ptr
     return true;
 }
 
-static bool check_mspell_unexploded(player_type *player_ptr, msa_type *msa_ptr)
+static bool check_mspell_unexploded(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     PERCENTAGE fail_rate = 25 - (msa_ptr->rlev + 3) / 4;
     if (msa_ptr->r_ptr->flags2 & RF2_STUPID)
@@ -205,7 +205,7 @@ static bool check_mspell_unexploded(player_type *player_ptr, msa_type *msa_ptr)
  *
  * ターゲット (msa_ptr->y, msa_ptr->x) は設定済みとする。
  */
-static bool check_thrown_mspell(player_type *player_ptr, msa_type *msa_ptr)
+static bool check_thrown_mspell(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     // プレイヤーがモンスターを正しく視認できていれば思い出に残る。
     // FIXME: ここで処理するのはおかしいような?
@@ -256,7 +256,7 @@ static bool check_thrown_mspell(player_type *player_ptr, msa_type *msa_ptr)
     }
 }
 
-static void check_mspell_imitation(player_type *player_ptr, msa_type *msa_ptr)
+static void check_mspell_imitation(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     bool seen = (!player_ptr->blind && msa_ptr->m_ptr->ml);
     bool can_imitate = player_has_los_bold(player_ptr, msa_ptr->m_ptr->fy, msa_ptr->m_ptr->fx);
@@ -295,7 +295,7 @@ static void remember_mspell(msa_type *msa_ptr)
  * @param m_idx モンスター構造体配列のID
  * @return 実際に特殊技能を利用したらTRUEを返す
  */
-bool make_attack_spell(player_type *player_ptr, MONSTER_IDX m_idx)
+bool make_attack_spell(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     msa_type tmp_msa;
     msa_type *msa_ptr = initialize_msa_type(player_ptr, &tmp_msa, m_idx);
index ca654c7..9f7ef0a 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool make_attack_spell(player_type *player_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+bool make_attack_spell(PlayerType *player_ptr, MONSTER_IDX m_idx);
index c4a74fc..6e83c71 100644 (file)
@@ -28,7 +28,7 @@
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF4_BA_NUKE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF4_BA_NUKE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが放射能球を放った。", "%^s casts a ball of radiation."),
         _("%^sが%sに放射能球を放った。", "%^s casts a ball of radiation at %s."));
@@ -57,7 +57,7 @@ MonsterSpellResult spell_RF4_BA_NUKE(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF4_BA_CHAO(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF4_BA_CHAO(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが恐ろしげにつぶやいた。", "%^s mumbles frighteningly."),
         _("%^sが純ログルスを放った。", "%^s invokes a raw Logrus."), _("%^sが%sに純ログルスを放った。", "%^s invokes raw Logrus upon %s."));
@@ -86,7 +86,7 @@ MonsterSpellResult spell_RF4_BA_CHAO(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_ACID(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_ACID(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがアシッド・ボールの呪文を唱えた。", "%^s casts an acid ball."),
@@ -117,7 +117,7 @@ MonsterSpellResult spell_RF5_BA_ACID(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_ELEC(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_ELEC(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがサンダー・ボールの呪文を唱えた。", "%^s casts a lightning ball."),
@@ -148,7 +148,7 @@ MonsterSpellResult spell_RF5_BA_ELEC(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_FIRE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_FIRE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg;
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
@@ -188,7 +188,7 @@ MonsterSpellResult spell_RF5_BA_FIRE(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_COLD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_COLD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがアイス・ボールの呪文を唱えた。", "%^s casts a frost ball."),
@@ -219,7 +219,7 @@ MonsterSpellResult spell_RF5_BA_COLD(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_POIS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_POIS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが悪臭雲の呪文を唱えた。", "%^s casts a stinking cloud."),
         _("%^sが%sに向かって悪臭雲の呪文を唱えた。", "%^s casts a stinking cloud at %s."));
@@ -248,7 +248,7 @@ MonsterSpellResult spell_RF5_BA_POIS(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_NETH(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_NETH(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが地獄球の呪文を唱えた。", "%^s casts a nether ball."),
         _("%^sが%sに向かって地獄球の呪文を唱えた。", "%^s casts a nether ball at %s."));
@@ -277,7 +277,7 @@ MonsterSpellResult spell_RF5_BA_NETH(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_WATE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_WATE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     bool known = monster_near_player(player_ptr->current_floor_ptr, m_idx, t_idx);
     bool see_either = see_monster(player_ptr, m_idx) || see_monster(player_ptr, t_idx);
@@ -317,7 +317,7 @@ MonsterSpellResult spell_RF5_BA_WATE(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_MANA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_MANA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かを力強くつぶやいた。", "%^s mumbles powerfully."),
         _("%^sが魔力の嵐の呪文を念じた。", "%^s invokes a mana storm."), _("%^sが%sに対して魔力の嵐の呪文を念じた。", "%^s invokes a mana storm upon %s."));
@@ -344,7 +344,7 @@ MonsterSpellResult spell_RF5_BA_MANA(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_DARK(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_DARK(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かを力強くつぶやいた。", "%^s mumbles powerfully."),
         _("%^sが暗黒の嵐の呪文を念じた。", "%^s invokes a darkness storm."),
@@ -374,7 +374,7 @@ MonsterSpellResult spell_RF5_BA_DARK(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BA_LITE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BA_LITE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かを力強くつぶやいた。", "%^s mumbles powerfully."),
         _("%^sがスターバーストの呪文を念じた。", "%^s invokes a starburst."),
index 4d79b6a..8ab2026 100644 (file)
@@ -4,16 +4,16 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
-MonsterSpellResult spell_RF4_BA_NUKE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF4_BA_CHAO(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_ACID(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_ELEC(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_FIRE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_COLD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_POIS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_NETH(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_WATE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_MANA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_DARK(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BA_LITE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF4_BA_NUKE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF4_BA_CHAO(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_ACID(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_ELEC(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_FIRE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_COLD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_POIS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_NETH(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_WATE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_MANA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_DARK(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BA_LITE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
index fde6b6b..8d4e370 100644 (file)
@@ -25,7 +25,7 @@
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF4_SHOOT(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF4_SHOOT(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが奇妙な音を発した。", "%^s makes a strange noise."),
         _("%^sが矢を放った。", "%^s fires an arrow."),
@@ -57,7 +57,7 @@ MonsterSpellResult spell_RF4_SHOOT(player_type *player_ptr, POSITION y, POSITION
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_ACID(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_ACID(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがアシッド・ボルトの呪文を唱えた。", "%^s casts an acid bolt."),
@@ -89,7 +89,7 @@ MonsterSpellResult spell_RF5_BO_ACID(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_ELEC(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_ELEC(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがサンダー・ボルトの呪文を唱えた。", "%^s casts a lightning bolt."),
@@ -121,7 +121,7 @@ MonsterSpellResult spell_RF5_BO_ELEC(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_FIRE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_FIRE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがファイア・ボルトの呪文を唱えた。", "%^s casts a fire bolt."),
@@ -153,7 +153,7 @@ MonsterSpellResult spell_RF5_BO_FIRE(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_COLD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_COLD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがアイス・ボルトの呪文を唱えた。", "%^s casts a frost bolt."),
@@ -185,7 +185,7 @@ MonsterSpellResult spell_RF5_BO_COLD(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_NETH(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_NETH(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが地獄の矢の呪文を唱えた。", "%^s casts a nether bolt."),
         _("%^sが%sに向かって地獄の矢の呪文を唱えた。", "%^s casts a nether bolt at %s."));
@@ -216,7 +216,7 @@ MonsterSpellResult spell_RF5_BO_NETH(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_WATE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_WATE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがウォーター・ボルトの呪文を唱えた。", "%^s casts a water bolt."),
@@ -247,7 +247,7 @@ MonsterSpellResult spell_RF5_BO_WATE(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_MANA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_MANA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが魔力の矢の呪文を唱えた。", "%^s casts a mana bolt."),
         _("%^sが%sに向かって魔力の矢の呪文を唱えた。", "%^s casts a mana bolt at %s."));
@@ -277,7 +277,7 @@ MonsterSpellResult spell_RF5_BO_MANA(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_PLAS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_PLAS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがプラズマ・ボルトの呪文を唱えた。", "%^s casts a plasma bolt."),
@@ -308,7 +308,7 @@ MonsterSpellResult spell_RF5_BO_PLAS(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BO_ICEE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BO_ICEE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが極寒の矢の呪文を唱えた。", "%^s casts an ice bolt."),
         _("%^sが%sに向かって極寒の矢の呪文を唱えた。", "%^s casts an ice bolt at %s."));
@@ -339,7 +339,7 @@ MonsterSpellResult spell_RF5_BO_ICEE(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_MISSILE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_MISSILE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがマジック・ミサイルの呪文を唱えた。", "%^s casts a magic missile."),
index a0ea45b..36af844 100644 (file)
@@ -4,15 +4,15 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
-MonsterSpellResult spell_RF4_SHOOT(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_ACID(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_ELEC(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_FIRE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_COLD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_NETH(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_WATE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_MANA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_PLAS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BO_ICEE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_MISSILE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF4_SHOOT(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_ACID(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_ELEC(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_FIRE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_COLD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_NETH(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_WATE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_MANA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_PLAS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BO_ICEE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_MISSILE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
index 3b3c2db..02fef1f 100644 (file)
@@ -56,7 +56,7 @@ static bool spell_RF4_BREATH_special_message(MONSTER_IDX r_idx, AttributeType GF
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF4_BREATH(player_type *player_ptr, AttributeType GF_TYPE, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF4_BREATH(PlayerType *player_ptr, AttributeType GF_TYPE, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     HIT_POINT dam, drs_type = 0;
     concptr type_s;
index df08b53..cd9a464 100644 (file)
@@ -5,5 +5,5 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
-MonsterSpellResult spell_RF4_BREATH(player_type *player_ptr, AttributeType GF_TYPE, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF4_BREATH(PlayerType *player_ptr, AttributeType GF_TYPE, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
index 097e605..c516bc9 100644 (file)
@@ -66,7 +66,7 @@
  * @param x1 判定を行いたいマスのX座標
  * @return 召還に相応しいならばTRUEを返す
  */
-bool summon_possible(player_type *player_ptr, POSITION y1, POSITION x1)
+bool summon_possible(PlayerType *player_ptr, POSITION y1, POSITION x1)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (POSITION y = y1 - 2; y <= y1 + 2; y++) {
@@ -95,7 +95,7 @@ bool summon_possible(player_type *player_ptr, POSITION y1, POSITION x1)
  * @param m_ptr 判定を行いたいモンスターの構造体参照ポインタ
  * @return 死者復活が有効な状態ならばTRUEを返す。
  */
-bool raise_possible(player_type *player_ptr, monster_type *m_ptr)
+bool raise_possible(PlayerType *player_ptr, monster_type *m_ptr)
 {
     POSITION y = m_ptr->fy;
     POSITION x = m_ptr->fx;
@@ -144,7 +144,7 @@ bool raise_possible(player_type *player_ptr, monster_type *m_ptr)
  * no equally friendly monster is\n
  * between the attacker and target.\n
  */
-bool clean_shot(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, bool is_friend)
+bool clean_shot(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, bool is_friend)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     uint16_t grid_g[512];
@@ -187,7 +187,7 @@ bool clean_shot(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2,
  * @param monspell モンスター魔法のID
  * @param target_type モンスターからモンスターへ撃つならMONSTER_TO_MONSTER、モンスターからプレイヤーならMONSTER_TO_PLAYER
  */
-ProjectResult bolt(player_type *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, AttributeType typ, int dam_hp, int target_type)
+ProjectResult bolt(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, AttributeType typ, int dam_hp, int target_type)
 {
     BIT_FLAGS flg = 0;
     switch (target_type) {
@@ -216,7 +216,7 @@ ProjectResult bolt(player_type *player_ptr, MONSTER_IDX m_idx, POSITION y, POSIT
  * @param monspell モンスター魔法のID
  * @param target_type モンスターからモンスターへ撃つならMONSTER_TO_MONSTER、モンスターからプレイヤーならMONSTER_TO_PLAYER
  */
-ProjectResult beam(player_type *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, AttributeType typ, int dam_hp, int target_type)
+ProjectResult beam(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, AttributeType typ, int dam_hp, int target_type)
 {
     BIT_FLAGS flg = 0;
     switch (target_type) {
@@ -245,7 +245,7 @@ ProjectResult beam(player_type *player_ptr, MONSTER_IDX m_idx, POSITION y, POSIT
  * @param monspell モンスター魔法のID
  * @param target_type モンスターからモンスターへ撃つならMONSTER_TO_MONSTER、モンスターからプレイヤーならMONSTER_TO_PLAYER
  */
-ProjectResult breath(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, AttributeType typ, int dam_hp, POSITION rad, bool breath, int target_type)
+ProjectResult breath(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, AttributeType typ, int dam_hp, POSITION rad, bool breath, int target_type)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
index df0d5a4..a5ca0f3 100644 (file)
@@ -7,12 +7,12 @@ struct ProjectResult;
 enum class MonsterAbilityType;
 
 struct monster_type;
-struct player_type;
-bool clean_shot(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, bool is_friend);
-bool summon_possible(player_type *player_ptr, POSITION y1, POSITION x1);
-bool raise_possible(player_type *player_ptr, monster_type *m_ptr);
+class PlayerType;
+bool clean_shot(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, bool is_friend);
+bool summon_possible(PlayerType *player_ptr, POSITION y1, POSITION x1);
+bool raise_possible(PlayerType *player_ptr, monster_type *m_ptr);
 bool spell_is_inate(MonsterAbilityType spell);
-ProjectResult beam(player_type *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, AttributeType typ, int dam_hp, int target_type);
-ProjectResult bolt(player_type *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, AttributeType typ, int dam_hp, int target_type);
+ProjectResult beam(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, AttributeType typ, int dam_hp, int target_type);
+ProjectResult bolt(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION y, POSITION x, AttributeType typ, int dam_hp, int target_type);
 ProjectResult breath(
-    player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, AttributeType typ, int dam_hp, POSITION rad, bool breath, int target_type);
+    PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, AttributeType typ, int dam_hp, POSITION rad, bool breath, int target_type);
index 46648a8..5f6c773 100644 (file)
@@ -27,7 +27,7 @@
  * @param MS_TYPE 呪文の番号
  * @param TARGET_TYPE プレイヤーを対象とする場合MONSTER_TO_PLAYER、モンスターを対象とする場合MONSTER_TO_MONSTER
  */
-static MonsterSpellResult spell_RF5_CAUSE(player_type *player_ptr, AttributeType GF_TYPE, HIT_POINT dam, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx,
+static MonsterSpellResult spell_RF5_CAUSE(PlayerType *player_ptr, AttributeType GF_TYPE, HIT_POINT dam, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx,
     concptr msg1, concptr msg2, concptr msg3, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid(dam);
@@ -71,7 +71,7 @@ static MonsterSpellResult spell_RF5_CAUSE(player_type *player_ptr, AttributeType
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_CAUSE_1(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_CAUSE_1(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     concptr msg1 = _("%^sが何かをつぶやいた。", "%^s mumbles.");
     concptr msg2 = _("%^sがあなたを指さして呪った。", "%^s points at you and curses.");
@@ -93,7 +93,7 @@ MonsterSpellResult spell_RF5_CAUSE_1(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_CAUSE_2(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_CAUSE_2(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     concptr msg1 = _("%^sが何かをつぶやいた。", "%^s mumbles.");
     concptr msg2 = _("%^sがあなたを指さして恐ろしげに呪った。", "%^s points at you and curses horribly.");
@@ -115,7 +115,7 @@ MonsterSpellResult spell_RF5_CAUSE_2(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_CAUSE_3(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_CAUSE_3(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     concptr msg1 = _("%^sが何かを大声で叫んだ。", "%^s mumbles loudly.");
     concptr msg2 = _("%^sがあなたを指さして恐ろしげに呪文を唱えた!", "%^s points at you, incanting terribly!");
@@ -137,7 +137,7 @@ MonsterSpellResult spell_RF5_CAUSE_3(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_CAUSE_4(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_CAUSE_4(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     concptr msg1 = _("%^sが「お前は既に死んでいる」と叫んだ。", "%^s screams the word 'DIE!'");
     concptr msg2 = _("%^sがあなたの秘孔を突いて「お前は既に死んでいる」と叫んだ。", "%^s points at you, screaming the word DIE!");
index fbb89d7..1623605 100644 (file)
@@ -4,8 +4,8 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
-MonsterSpellResult spell_RF5_CAUSE_1(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_CAUSE_2(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_CAUSE_3(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_CAUSE_4(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF5_CAUSE_1(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_CAUSE_2(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_CAUSE_3(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_CAUSE_4(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
index e037626..4fff768 100644 (file)
@@ -66,7 +66,7 @@ static HIT_POINT monspell_damage_roll(HIT_POINT dam, int dice_num, int dice_side
  * @return 攻撃呪文のダメージを返す。攻撃呪文以外は-1を返す。
  */
 static HIT_POINT monspell_damage_base(
-    player_type *player_ptr, MonsterAbilityType ms_type, int hp, int rlev, bool powerful, int shoot_dd, int shoot_ds, int shoot_base, int TYPE)
+    PlayerType *player_ptr, MonsterAbilityType ms_type, int hp, int rlev, bool powerful, int shoot_dd, int shoot_ds, int shoot_base, int TYPE)
 {
     HIT_POINT dam = 0, dice_num = 0, dice_side = 0, mult = 1, div = 1;
 
@@ -450,7 +450,7 @@ void monspell_shoot_dice(monster_race *r_ptr, int *dd, int *ds)
  * @param TYPE  DAM_MAXで最大値を返し、DAM_MINで最小値を返す。DAM_ROLLはダイスを振って値を決定する。
  * @return 攻撃呪文のダメージを返す。攻撃呪文以外は-1を返す。
  */
-HIT_POINT monspell_damage(player_type *player_ptr, MonsterAbilityType ms_type, MONSTER_IDX m_idx, int TYPE)
+HIT_POINT monspell_damage(PlayerType *player_ptr, MonsterAbilityType ms_type, MONSTER_IDX m_idx, int TYPE)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -471,7 +471,7 @@ HIT_POINT monspell_damage(player_type *player_ptr, MonsterAbilityType ms_type, M
  * @param TYPE  DAM_MAXで最大値を返し、DAM_MINで最小値を返す。DAM_ROLLはダイスを振って値を決定する。
  * @return 攻撃呪文のダメージを返す。攻撃呪文以外は-1を返す。
  */
-HIT_POINT monspell_race_damage(player_type *player_ptr, MonsterAbilityType ms_type, MONRACE_IDX r_idx, int TYPE)
+HIT_POINT monspell_race_damage(PlayerType *player_ptr, MonsterAbilityType ms_type, MONRACE_IDX r_idx, int TYPE)
 {
     monster_race *r_ptr = &r_info[r_idx];
     DEPTH rlev = ((r_ptr->level >= 1) ? r_ptr->level : 1);
@@ -491,7 +491,7 @@ HIT_POINT monspell_race_damage(player_type *player_ptr, MonsterAbilityType ms_ty
  * @param TYPE  DAM_MAXで最大値を返し、DAM_MINで最小値を返す。DAM_ROLLはダイスを振って値を決定する。
  * @return 攻撃呪文のダメージを返す。攻撃呪文以外は-1を返す。
  */
-HIT_POINT monspell_bluemage_damage(player_type *player_ptr, MonsterAbilityType ms_type, PLAYER_LEVEL plev, int TYPE)
+HIT_POINT monspell_bluemage_damage(PlayerType *player_ptr, MonsterAbilityType ms_type, PLAYER_LEVEL plev, int TYPE)
 {
     int hp = player_ptr->chp;
     int shoot_dd = 1, shoot_ds = 1, shoot_base = 0;
index de5d970..35520ac 100644 (file)
@@ -14,7 +14,7 @@ enum spell_flag_type {
 };
 
 enum class MonsterAbilityType;
-struct player_type;
-HIT_POINT monspell_damage(player_type *player_ptr, MonsterAbilityType ms_type, MONSTER_IDX m_idx, int TYPE);
-HIT_POINT monspell_race_damage(player_type *player_ptr, MonsterAbilityType ms_type, MONRACE_IDX r_idx, int TYPE);
-HIT_POINT monspell_bluemage_damage(player_type *player_ptr, MonsterAbilityType ms_type, PLAYER_LEVEL plev, int TYPE);
+class PlayerType;
+HIT_POINT monspell_damage(PlayerType *player_ptr, MonsterAbilityType ms_type, MONSTER_IDX m_idx, int TYPE);
+HIT_POINT monspell_race_damage(PlayerType *player_ptr, MonsterAbilityType ms_type, MONRACE_IDX r_idx, int TYPE);
+HIT_POINT monspell_bluemage_damage(PlayerType *player_ptr, MonsterAbilityType ms_type, PLAYER_LEVEL plev, int TYPE);
index fdc5bff..c2b80b3 100644 (file)
@@ -34,7 +34,7 @@
 /*!
  * @brief プレイヤーに魔力消去効果を与える。
  */
-static void dispel_player(player_type *player_ptr)
+static void dispel_player(PlayerType *player_ptr)
 {
     (void)set_fast(player_ptr, 0, true);
     set_lightspeed(player_ptr, 0, true);
@@ -112,7 +112,7 @@ static void dispel_player(player_type *player_ptr)
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF4_DISPEL(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF4_DISPEL(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid();
     res.learnable = TARGET_TYPE == MONSTER_TO_PLAYER;
index b437933..26d6def 100644 (file)
@@ -4,5 +4,5 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
-MonsterSpellResult spell_RF4_DISPEL(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF4_DISPEL(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
index c1715b5..b13d294 100644 (file)
@@ -50,7 +50,7 @@
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF4_SHRIEK(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int target_type)
+MonsterSpellResult spell_RF4_SHRIEK(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int target_type)
 {
     mspell_cast_msg_simple msg(_("%^sがかん高い金切り声をあげた。", "%^s makes a high pitched shriek."),
         _("%^sが%sに向かって叫んだ。", "%^s shrieks at %s."));
@@ -80,7 +80,7 @@ MonsterSpellResult spell_RF4_SHRIEK(MONSTER_IDX m_idx, player_type *player_ptr,
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_WORLD(player_type *player_ptr, MONSTER_IDX m_idx)
+MonsterSpellResult spell_RF6_WORLD(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     GAME_TEXT m_name[MAX_NLEN];
@@ -100,7 +100,7 @@ MonsterSpellResult spell_RF6_WORLD(player_type *player_ptr, MONSTER_IDX m_idx)
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_BLINK(player_type *player_ptr, MONSTER_IDX m_idx, int TARGET_TYPE, bool is_quantum_effect)
+MonsterSpellResult spell_RF6_BLINK(PlayerType *player_ptr, MONSTER_IDX m_idx, int TARGET_TYPE, bool is_quantum_effect)
 {
     const auto res = MonsterSpellResult::make_valid();
 
@@ -135,7 +135,7 @@ MonsterSpellResult spell_RF6_BLINK(player_type *player_ptr, MONSTER_IDX m_idx, i
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_TPORT(player_type *player_ptr, MONSTER_IDX m_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_TPORT(PlayerType *player_ptr, MONSTER_IDX m_idx, int TARGET_TYPE)
 {
     const auto res = MonsterSpellResult::make_valid();
 
@@ -167,7 +167,7 @@ MonsterSpellResult spell_RF6_TPORT(player_type *player_ptr, MONSTER_IDX m_idx, i
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_TELE_TO(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_TELE_TO(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid();
     res.learnable = TARGET_TYPE == MONSTER_TO_PLAYER;
@@ -235,7 +235,7 @@ MonsterSpellResult spell_RF6_TELE_TO(player_type *player_ptr, MONSTER_IDX m_idx,
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_TELE_AWAY(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_TELE_AWAY(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid();
     res.learnable = TARGET_TYPE == MONSTER_TO_PLAYER;
@@ -311,7 +311,7 @@ MonsterSpellResult spell_RF6_TELE_AWAY(player_type *player_ptr, MONSTER_IDX m_id
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_TELE_LEVEL(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_TELE_LEVEL(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     const auto res = MonsterSpellResult::make_valid();
 
@@ -368,7 +368,7 @@ MonsterSpellResult spell_RF6_TELE_LEVEL(player_type *player_ptr, MONSTER_IDX m_i
  *
  * プレイヤーが対象かつ暗闇ならラーニング可。
  */
-MonsterSpellResult spell_RF6_DARKNESS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_DARKNESS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg;
     concptr msg_done;
@@ -439,7 +439,7 @@ MonsterSpellResult spell_RF6_DARKNESS(player_type *player_ptr, POSITION y, POSIT
  *
  * ラーニング可。
  */
-MonsterSpellResult spell_RF6_TRAPS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
+MonsterSpellResult spell_RF6_TRAPS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     GAME_TEXT m_name[MAX_NLEN];
     monster_name(player_ptr, m_idx, m_name);
@@ -467,7 +467,7 @@ MonsterSpellResult spell_RF6_TRAPS(player_type *player_ptr, POSITION y, POSITION
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_RAISE_DEAD(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_RAISE_DEAD(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
index 8f18826..a738b93 100644 (file)
@@ -4,14 +4,14 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
-MonsterSpellResult spell_RF4_SHRIEK(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_WORLD(player_type *player_ptr, MONSTER_IDX m_idx);
-MonsterSpellResult spell_RF6_BLINK(player_type *player_ptr, MONSTER_IDX m_idx, int TARGET_TYPE, bool is_quantum_effect);
-MonsterSpellResult spell_RF6_TPORT(player_type *player_ptr, MONSTER_IDX m_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_TELE_TO(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_TELE_AWAY(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_TELE_LEVEL(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_DARKNESS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_TRAPS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
-MonsterSpellResult spell_RF6_RAISE_DEAD(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF4_SHRIEK(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_WORLD(PlayerType *player_ptr, MONSTER_IDX m_idx);
+MonsterSpellResult spell_RF6_BLINK(PlayerType *player_ptr, MONSTER_IDX m_idx, int TARGET_TYPE, bool is_quantum_effect);
+MonsterSpellResult spell_RF6_TPORT(PlayerType *player_ptr, MONSTER_IDX m_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_TELE_TO(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_TELE_AWAY(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_TELE_LEVEL(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_DARKNESS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_TRAPS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
+MonsterSpellResult spell_RF6_RAISE_DEAD(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
index a373727..1264fdf 100644 (file)
@@ -48,7 +48,7 @@
  * @param m_ptr 使用するモンスターの構造体参照ポインタ
  * @return ビームが到達可能ならばTRUEを返す
  */
-bool direct_beam(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, monster_type *m_ptr)
+bool direct_beam(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, monster_type *m_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     uint16_t grid_g[512];
@@ -90,7 +90,7 @@ bool direct_beam(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2,
  * @param is_friend TRUEならば、プレイヤーを巻き込む時にブレスの判定をFALSEにする。
  * @return ブレスを直接当てられるならばTRUEを返す
  */
-bool breath_direct(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, POSITION rad, AttributeType typ, bool is_friend)
+bool breath_direct(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, POSITION rad, AttributeType typ, bool is_friend)
 {
     BIT_FLAGS flg;
     switch (typ) {
@@ -185,7 +185,7 @@ bool breath_direct(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y
  * @param tx 目標X座標を返す参照ポインタ
  * @param flg 判定のフラグ配列
  */
-void get_project_point(player_type *player_ptr, POSITION sy, POSITION sx, POSITION *ty, POSITION *tx, BIT_FLAGS flg)
+void get_project_point(PlayerType *player_ptr, POSITION sy, POSITION sx, POSITION *ty, POSITION *tx, BIT_FLAGS flg)
 {
     uint16_t path_g[128];
     int path_n = projection_path(player_ptr, path_g, get_max_range(player_ptr), sy, sx, *ty, *tx, flg);
@@ -210,7 +210,7 @@ void get_project_point(player_type *player_ptr, POSITION sy, POSITION sx, POSITI
  * @param t_idx 目標のモンスターID
  * @return 魔力消去を使うべきならばTRUEを変えす。
  */
-bool dispel_check_monster(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx)
+bool dispel_check_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx)
 {
     monster_type *t_ptr = &player_ptr->current_floor_ptr->m_list[t_idx];
     if (monster_invulner_remaining(t_ptr))
@@ -231,7 +231,7 @@ bool dispel_check_monster(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_ID
  * @param m_idx モンスターの構造体配列ID
  * @return 魔力消去をかけるべきならTRUEを返す。
  */
-bool dispel_check(player_type *player_ptr, MONSTER_IDX m_idx)
+bool dispel_check(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     if (is_invuln(player_ptr))
         return true;
index d1c628c..d996ddf 100644 (file)
@@ -4,9 +4,9 @@
 #include "effect/attribute-types.h"
 
 struct monster_type;
-struct player_type;
-bool direct_beam(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, monster_type *m_ptr);
-bool breath_direct(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, POSITION rad, AttributeType typ, bool is_friend);
-void get_project_point(player_type *player_ptr, POSITION sy, POSITION sx, POSITION *ty, POSITION *tx, BIT_FLAGS flg);
-bool dispel_check_monster(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx);
-bool dispel_check(player_type *player_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+bool direct_beam(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, monster_type *m_ptr);
+bool breath_direct(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, POSITION rad, AttributeType typ, bool is_friend);
+void get_project_point(PlayerType *player_ptr, POSITION sy, POSITION sx, POSITION *ty, POSITION *tx, BIT_FLAGS flg);
+bool dispel_check_monster(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx);
+bool dispel_check(PlayerType *player_ptr, MONSTER_IDX m_idx);
index 42f3f00..147d67d 100644 (file)
@@ -14,7 +14,7 @@
  *
  * モンスターが特技を使う前にプレイヤーがモンスターを視認できているかどうかの判定用。
  */
-bool spell_learnable(player_type *player_ptr, MONSTER_IDX m_idx)
+bool spell_learnable(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     bool seen = (!player_ptr->blind && m_ptr->ml);
index a4f64d2..ad25303 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool spell_learnable(player_type *player_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+bool spell_learnable(PlayerType *player_ptr, MONSTER_IDX m_idx);
index dc5bcac..a022a88 100644 (file)
@@ -37,7 +37,7 @@
  * @param path_check 射線を判定するための関数ポインタ
  * @return 有効な座標があった場合TRUEを返す
  */
-bool adjacent_grid_check(player_type *player_ptr, monster_type *m_ptr, POSITION *yp, POSITION *xp, FloorFeatureType f_flag, path_check_pf path_check)
+bool adjacent_grid_check(PlayerType *player_ptr, monster_type *m_ptr, POSITION *yp, POSITION *xp, FloorFeatureType f_flag, path_check_pf path_check)
 {
     static int tonari_y[4][8] = { { -1, -1, -1, 0, 0, 1, 1, 1 }, { -1, -1, -1, 0, 0, 1, 1, 1 }, { 1, 1, 1, 0, 0, -1, -1, -1 }, { 1, 1, 1, 0, 0, -1, -1, -1 } };
     static int tonari_x[4][8] = { { -1, 0, 1, -1, 1, -1, 0, 1 }, { 1, 0, -1, 1, -1, 1, 0, -1 }, { -1, 0, 1, -1, 1, -1, 0, 1 }, { 1, 0, -1, 1, -1, 1, 0, -1 } };
@@ -70,7 +70,7 @@ bool adjacent_grid_check(player_type *player_ptr, monster_type *m_ptr, POSITION
     return false;
 }
 
-void decide_lite_range(player_type *player_ptr, msa_type *msa_ptr)
+void decide_lite_range(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if (msa_ptr->ability_flags.has_not(MonsterAbilityType::BR_LITE))
         return;
@@ -106,7 +106,7 @@ static void feature_projection(floor_type *floor_ptr, msa_type *msa_ptr)
         msa_ptr->do_spell = DO_SPELL_BR_LITE;
 }
 
-static void check_lite_area_by_mspell(player_type *player_ptr, msa_type *msa_ptr)
+static void check_lite_area_by_mspell(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if (msa_ptr->ability_flags.has(MonsterAbilityType::BR_DISI) && (msa_ptr->m_ptr->cdis < get_max_range(player_ptr) / 2)
         && in_disintegration_range(player_ptr->current_floor_ptr, msa_ptr->m_ptr->fy, msa_ptr->m_ptr->fx, msa_ptr->y, msa_ptr->x)
@@ -134,7 +134,7 @@ static void check_lite_area_by_mspell(player_type *player_ptr, msa_type *msa_ptr
     }
 }
 
-static void decide_lite_breath(player_type *player_ptr, msa_type *msa_ptr)
+static void decide_lite_breath(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if (msa_ptr->success)
         return;
@@ -160,7 +160,7 @@ static void decide_lite_breath(player_type *player_ptr, msa_type *msa_ptr)
     msa_ptr->success = true;
 }
 
-bool decide_lite_projection(player_type *player_ptr, msa_type *msa_ptr)
+bool decide_lite_projection(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if (projectable(player_ptr, msa_ptr->m_ptr->fy, msa_ptr->m_ptr->fx, msa_ptr->y, msa_ptr->x)) {
         feature_projection(player_ptr->current_floor_ptr, msa_ptr);
@@ -176,7 +176,7 @@ bool decide_lite_projection(player_type *player_ptr, msa_type *msa_ptr)
     return msa_ptr->success;
 }
 
-void decide_lite_area(player_type *player_ptr, msa_type *msa_ptr)
+void decide_lite_area(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     if (msa_ptr->ability_flags.has_not(MonsterAbilityType::DARKNESS))
         return;
index 2859b26..c3b652a 100644 (file)
@@ -4,10 +4,10 @@
 
 struct monster_type;
 typedef struct msa_type msa_type;
-struct player_type;
-typedef bool (*path_check_pf)(player_type *, POSITION, POSITION, POSITION, POSITION);
+class PlayerType;
+typedef bool (*path_check_pf)(PlayerType *, POSITION, POSITION, POSITION, POSITION);
 enum class FloorFeatureType;
-bool adjacent_grid_check(player_type *player_ptr, monster_type *m_ptr, POSITION *yp, POSITION *xp, FloorFeatureType f_flag, path_check_pf path_check);
-void decide_lite_range(player_type *player_ptr, msa_type *msa_ptr);
-bool decide_lite_projection(player_type *player_ptr, msa_type *msa_ptr);
-void decide_lite_area(player_type *player_ptr, msa_type *msa_ptr);
+bool adjacent_grid_check(PlayerType *player_ptr, monster_type *m_ptr, POSITION *yp, POSITION *xp, FloorFeatureType f_flag, path_check_pf path_check);
+void decide_lite_range(PlayerType *player_ptr, msa_type *msa_ptr);
+bool decide_lite_projection(PlayerType *player_ptr, msa_type *msa_ptr);
+void decide_lite_area(PlayerType *player_ptr, msa_type *msa_ptr);
index 7703b9c..893a7e9 100644 (file)
@@ -31,7 +31,7 @@
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF4_ROCKET(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF4_ROCKET(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かを射った。", "%^s shoots something."), _("%^sがロケットを発射した。", "%^s fires a rocket."),
         _("%^sが%sにロケットを発射した。", "%^s fires a rocket at %s."));
@@ -60,7 +60,7 @@ MonsterSpellResult spell_RF4_ROCKET(player_type *player_ptr, POSITION y, POSITIO
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF6_HAND_DOOM(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_HAND_DOOM(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_simple msg(_("%^sが<破滅の手>を放った!", "%^s invokes the Hand of Doom!"),
         _("%^sが%sに<破滅の手>を放った!", "%^s invokes the Hand of Doom upon %s!"));
@@ -92,7 +92,7 @@ MonsterSpellResult spell_RF6_HAND_DOOM(player_type *player_ptr, POSITION y, POSI
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF6_PSY_SPEAR(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_PSY_SPEAR(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが光の剣を放った。", "%^s throw a Psycho-Spear."),
         _("%^sが%sに向かって光の剣を放った。", "%^s throw a Psycho-spear at %s."));
index c384d06..e56f74d 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct MonsterSpellResult;
-struct player_type;
-MonsterSpellResult spell_RF4_ROCKET(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_HAND_DOOM(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_PSY_SPEAR(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF4_ROCKET(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_HAND_DOOM(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_PSY_SPEAR(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
index 784ba28..63970a0 100644 (file)
@@ -198,7 +198,7 @@ static bool spell_world(MonsterAbilityType spell)
  * @param spell 判定対象のID
  * @return 特別効果魔法のIDならばTRUEを返す。
  */
-static bool spell_special(player_type *player_ptr, MonsterAbilityType spell)
+static bool spell_special(PlayerType *player_ptr, MonsterAbilityType spell)
 {
     if (player_ptr->phase_out)
         return false;
@@ -260,7 +260,7 @@ static bool spell_dispel(MonsterAbilityType spell)
  * This function may well be an efficiency bottleneck.\n
  * @todo 長過ぎる。切り分けが必要
  */
-MonsterAbilityType choose_attack_spell(player_type *player_ptr, msa_type *msa_ptr)
+MonsterAbilityType choose_attack_spell(PlayerType *player_ptr, msa_type *msa_ptr)
 {
     std::vector<MonsterAbilityType> escape;
     std::vector<MonsterAbilityType> attack;
index e77eed5..ef3c760 100644 (file)
@@ -4,5 +4,5 @@
 
 enum class MonsterAbilityType;
 typedef struct msa_type msa_type;
-struct player_type;
-MonsterAbilityType choose_attack_spell(player_type *player_ptr, msa_type *msa_ptr);
+class PlayerType;
+MonsterAbilityType choose_attack_spell(PlayerType *player_ptr, msa_type *msa_ptr);
index dbfb931..7755e52 100644 (file)
@@ -42,7 +42,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param m_idx 呪文を唱えるモンスターID
  */
-static MonsterSpellResult spell_RF6_SPECIAL_BANORLUPART(player_type *player_ptr, MONSTER_IDX m_idx)
+static MonsterSpellResult spell_RF6_SPECIAL_BANORLUPART(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -109,7 +109,7 @@ static MonsterSpellResult spell_RF6_SPECIAL_BANORLUPART(player_type *player_ptr,
  * @param t_idx 呪文を受けるモンスターID。プレイヤーの場合はdummyで0とする。
  * @param TARGET_TYPE プレイヤーを対象とする場合MONSTER_TO_PLAYER、モンスターを対象とする場合MONSTER_TO_MONSTER
  */
-static MonsterSpellResult spell_RF6_SPECIAL_ROLENTO(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+static MonsterSpellResult spell_RF6_SPECIAL_ROLENTO(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     int count = 0, k;
     int num = 1 + randint1(3);
@@ -138,7 +138,7 @@ static MonsterSpellResult spell_RF6_SPECIAL_ROLENTO(player_type *player_ptr, POS
  * @param t_idx 呪文を受けるモンスターID。プレイヤーの場合はdummyで0とする。
  * @param TARGET_TYPE プレイヤーを対象とする場合MONSTER_TO_PLAYER、モンスターを対象とする場合MONSTER_TO_MONSTER
  */
-static MonsterSpellResult spell_RF6_SPECIAL_B(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+static MonsterSpellResult spell_RF6_SPECIAL_B(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_simple msg;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -222,7 +222,7 @@ static MonsterSpellResult spell_RF6_SPECIAL_B(player_type *player_ptr, POSITION
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_SPECIAL(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_SPECIAL(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
index 5ec0a5e..7e14227 100644 (file)
@@ -4,5 +4,5 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
-MonsterSpellResult spell_RF6_SPECIAL(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF6_SPECIAL(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
index 7d6f125..99f46ce 100644 (file)
@@ -59,7 +59,7 @@ mspell_cast_msg_bad_status_to_monster::mspell_cast_msg_bad_status_to_monster(con
  * @param resist 耐性の有無を判別するフラグ
  * @param saved_throw 抵抗に成功したか判別するフラグ
  */
-void spell_badstatus_message_to_player(player_type *player_ptr, MONSTER_IDX m_idx, const mspell_cast_msg_bad_status_to_player &msgs, bool resist,
+void spell_badstatus_message_to_player(PlayerType *player_ptr, MONSTER_IDX m_idx, const mspell_cast_msg_bad_status_to_player &msgs, bool resist,
     bool saved_throw)
 {
     GAME_TEXT m_name[MAX_NLEN];
@@ -89,7 +89,7 @@ void spell_badstatus_message_to_player(player_type *player_ptr, MONSTER_IDX m_id
  * @param resist 耐性の有無を判別するフラグ
  * @param saved_throw 抵抗に成功したか判別するフラグ
  */
-void spell_badstatus_message_to_mons(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_bad_status_to_monster &msgs, bool resist,
+void spell_badstatus_message_to_mons(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_bad_status_to_monster &msgs, bool resist,
     bool saved_throw)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -133,7 +133,7 @@ void spell_badstatus_message_to_mons(player_type *player_ptr, MONSTER_IDX m_idx,
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_DRAIN_MANA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_DRAIN_MANA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     GAME_TEXT m_name[MAX_NLEN], t_name[MAX_NLEN];
     monster_name(player_ptr, m_idx, m_name);
@@ -168,7 +168,7 @@ MonsterSpellResult spell_RF5_DRAIN_MANA(player_type *player_ptr, POSITION y, POS
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_MIND_BLAST(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_MIND_BLAST(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     bool seen = (!player_ptr->blind && m_ptr->ml);
@@ -206,7 +206,7 @@ MonsterSpellResult spell_RF5_MIND_BLAST(player_type *player_ptr, POSITION y, POS
  *
  * プレイヤーに当たったらラーニング可。
  */
-MonsterSpellResult spell_RF5_BRAIN_SMASH(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BRAIN_SMASH(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     bool seen = (!player_ptr->blind && m_ptr->ml);
@@ -241,7 +241,7 @@ MonsterSpellResult spell_RF5_BRAIN_SMASH(player_type *player_ptr, POSITION y, PO
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_SCARE(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_SCARE(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid();
     res.learnable = TARGET_TYPE == MONSTER_TO_PLAYER;
@@ -297,7 +297,7 @@ MonsterSpellResult spell_RF5_SCARE(MONSTER_IDX m_idx, player_type *player_ptr, M
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_BLIND(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_BLIND(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid();
     res.learnable = TARGET_TYPE == MONSTER_TO_PLAYER;
@@ -362,7 +362,7 @@ MonsterSpellResult spell_RF5_BLIND(MONSTER_IDX m_idx, player_type *player_ptr, M
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_CONF(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_CONF(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid();
     res.learnable = TARGET_TYPE == MONSTER_TO_PLAYER;
@@ -419,7 +419,7 @@ MonsterSpellResult spell_RF5_CONF(MONSTER_IDX m_idx, player_type *player_ptr, MO
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_HOLD(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_HOLD(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid();
     res.learnable = TARGET_TYPE == MONSTER_TO_PLAYER;
@@ -475,7 +475,7 @@ MonsterSpellResult spell_RF5_HOLD(MONSTER_IDX m_idx, player_type *player_ptr, MO
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_HASTE(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_HASTE(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     bool see_m = see_monster(player_ptr, m_idx);
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
@@ -507,7 +507,7 @@ MonsterSpellResult spell_RF6_HASTE(player_type *player_ptr, MONSTER_IDX m_idx, M
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF5_SLOW(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF5_SLOW(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     auto res = MonsterSpellResult::make_valid();
     res.learnable = TARGET_TYPE == MONSTER_TO_PLAYER;
@@ -573,7 +573,7 @@ MonsterSpellResult spell_RF5_SLOW(MONSTER_IDX m_idx, player_type *player_ptr, MO
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_HEAL(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_HEAL(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     const auto res = MonsterSpellResult::make_valid();
 
@@ -639,7 +639,7 @@ MonsterSpellResult spell_RF6_HEAL(player_type *player_ptr, MONSTER_IDX m_idx, MO
  *
  * ラーニング不可。
  */
-MonsterSpellResult spell_RF6_INVULNER(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_INVULNER(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     bool seen = (!player_ptr->blind && m_ptr->ml);
@@ -680,7 +680,7 @@ MonsterSpellResult spell_RF6_INVULNER(player_type *player_ptr, MONSTER_IDX m_idx
  *
  * ラーニング可。
  */
-MonsterSpellResult spell_RF6_FORGET(player_type *player_ptr, MONSTER_IDX m_idx)
+MonsterSpellResult spell_RF6_FORGET(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     DEPTH rlev = monster_level_idx(player_ptr->current_floor_ptr, m_idx);
     GAME_TEXT m_name[MAX_NLEN];
index 12c3df0..b03ff62 100644 (file)
@@ -4,7 +4,7 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
+class PlayerType;
 
 struct mspell_cast_msg_bad_status_to_player {
     mspell_cast_msg_bad_status_to_player(concptr blind, concptr not_blind, concptr resist, concptr saved_throw);
@@ -24,19 +24,19 @@ struct mspell_cast_msg_bad_status_to_monster {
     concptr success; /*成功時*/
 };
 
-void spell_badstatus_message_to_player(player_type *player_ptr, MONSTER_IDX m_idx, const mspell_cast_msg_bad_status_to_player &msgs, bool resist,
+void spell_badstatus_message_to_player(PlayerType *player_ptr, MONSTER_IDX m_idx, const mspell_cast_msg_bad_status_to_player &msgs, bool resist,
     bool saved_throw);
-void spell_badstatus_message_to_mons(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_bad_status_to_monster &msgs, bool resist,
+void spell_badstatus_message_to_mons(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_bad_status_to_monster &msgs, bool resist,
     bool saved_throw);
-MonsterSpellResult spell_RF5_DRAIN_MANA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_MIND_BLAST(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BRAIN_SMASH(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_SCARE(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_BLIND(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_CONF(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_HOLD(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_HASTE(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF5_SLOW(MONSTER_IDX m_idx, player_type *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_HEAL(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_INVULNER(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_FORGET(player_type *player_ptr, MONSTER_IDX m_idx);
+MonsterSpellResult spell_RF5_DRAIN_MANA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_MIND_BLAST(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BRAIN_SMASH(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_SCARE(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_BLIND(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_CONF(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_HOLD(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_HASTE(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF5_SLOW(MONSTER_IDX m_idx, PlayerType *player_ptr, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_HEAL(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_INVULNER(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_FORGET(PlayerType *player_ptr, MONSTER_IDX m_idx);
index e437587..85b68d0 100644 (file)
@@ -56,7 +56,7 @@ static BIT_FLAGS monster_u_mode(floor_type *floor_ptr, MONSTER_IDX m_idx)
  * @param m_idx 呪文を唱えるモンスターID
  * @return 召喚したモンスターの数を返す。
  */
-static MONSTER_NUMBER summon_Kin(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+static MONSTER_NUMBER summon_Kin(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     int count = 0;
     for (int k = 0; k < 4; k++) {
@@ -67,7 +67,7 @@ static MONSTER_NUMBER summon_Kin(player_type *player_ptr, POSITION y, POSITION x
 }
 
 static void decide_summon_kin_caster(
-    player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int target_type, concptr m_name, concptr m_poss, const bool known)
+    PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int target_type, concptr m_name, concptr m_poss, const bool known)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -114,7 +114,7 @@ static void decide_summon_kin_caster(
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_KIN(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int target_type)
+MonsterSpellResult spell_RF6_S_KIN(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int target_type)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -211,7 +211,7 @@ MonsterSpellResult spell_RF6_S_KIN(player_type *player_ptr, POSITION y, POSITION
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_CYBER(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_CYBER(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     int count = 0;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -254,7 +254,7 @@ MonsterSpellResult spell_RF6_S_CYBER(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_MONSTER(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_MONSTER(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが魔法で仲間を召喚した!", "%^s magically summons help!"),
         _("%^sが魔法で仲間を召喚した!", "%^s magically summons help!"));
@@ -297,7 +297,7 @@ MonsterSpellResult spell_RF6_S_MONSTER(player_type *player_ptr, POSITION y, POSI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_MONSTERS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_MONSTERS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sが魔法でモンスターを召喚した!", "%^s magically summons monsters!"), _("%^sが魔法でモンスターを召喚した!", "%^s magically summons monsters!"));
@@ -340,7 +340,7 @@ MonsterSpellResult spell_RF6_S_MONSTERS(player_type *player_ptr, POSITION y, POS
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_ANT(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_ANT(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが魔法でアリを召喚した。", "%^s magically summons ants."),
         _("%^sが魔法でアリを召喚した。", "%^s magically summons ants."));
@@ -379,7 +379,7 @@ MonsterSpellResult spell_RF6_S_ANT(player_type *player_ptr, POSITION y, POSITION
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_SPIDER(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_SPIDER(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."), _("%^sが魔法でクモを召喚した。", "%^s magically summons spiders."),
         _("%^sが魔法でクモを召喚した。", "%^s magically summons spiders."));
@@ -418,7 +418,7 @@ MonsterSpellResult spell_RF6_S_SPIDER(player_type *player_ptr, POSITION y, POSIT
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_HOUND(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_HOUND(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sが魔法でハウンドを召喚した。", "%^s magically summons hounds."), _("%^sが魔法でハウンドを召喚した。", "%^s magically summons hounds."));
@@ -457,7 +457,7 @@ MonsterSpellResult spell_RF6_S_HOUND(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_HYDRA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_HYDRA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sが魔法でヒドラを召喚した。", "%^s magically summons hydras."), _("%^sが魔法でヒドラを召喚した。", "%^s magically summons hydras."));
@@ -496,7 +496,7 @@ MonsterSpellResult spell_RF6_S_HYDRA(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_ANGEL(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_ANGEL(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sが魔法で天使を召喚した!", "%^s magically summons an angel!"), _("%^sが魔法で天使を召喚した!", "%^s magically summons an angel!"));
@@ -546,7 +546,7 @@ MonsterSpellResult spell_RF6_S_ANGEL(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_DEMON(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_DEMON(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sは魔法で混沌の宮廷から悪魔を召喚した!", "%^s magically summons a demon from the Courts of Chaos!"),
@@ -585,7 +585,7 @@ MonsterSpellResult spell_RF6_S_DEMON(player_type *player_ptr, POSITION y, POSITI
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_UNDEAD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_UNDEAD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sが魔法でアンデッドの強敵を召喚した!", "%^s magically summons an undead adversary!"),
@@ -624,7 +624,7 @@ MonsterSpellResult spell_RF6_S_UNDEAD(player_type *player_ptr, POSITION y, POSIT
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_DRAGON(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_DRAGON(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sが魔法でドラゴンを召喚した!", "%^s magically summons a dragon!"), _("%^sが魔法でドラゴンを召喚した!", "%^s magically summons a dragon!"));
@@ -665,7 +665,7 @@ MonsterSpellResult spell_RF6_S_DRAGON(player_type *player_ptr, POSITION y, POSIT
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_HI_UNDEAD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_HI_UNDEAD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     GAME_TEXT m_name[MAX_NLEN];
     monster_name(player_ptr, m_idx, m_name);
@@ -720,7 +720,7 @@ MonsterSpellResult spell_RF6_S_HI_UNDEAD(player_type *player_ptr, POSITION y, PO
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_HI_DRAGON(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_HI_DRAGON(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sが魔法で古代ドラゴンを召喚した!", "%^s magically summons ancient dragons!"),
@@ -765,7 +765,7 @@ MonsterSpellResult spell_RF6_S_HI_DRAGON(player_type *player_ptr, POSITION y, PO
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_AMBERITES(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_AMBERITES(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sがアンバーの王族を召喚した!", "%^s magically summons Lords of Amber!"),
@@ -806,7 +806,7 @@ MonsterSpellResult spell_RF6_S_AMBERITES(player_type *player_ptr, POSITION y, PO
  *
  * プレイヤーが対象ならラーニング可。
  */
-MonsterSpellResult spell_RF6_S_UNIQUE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MonsterSpellResult spell_RF6_S_UNIQUE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     mspell_cast_msg_blind msg(_("%^sが何かをつぶやいた。", "%^s mumbles."),
         _("%^sが魔法で特別な強敵を召喚した!", "%^s magically summons special opponents!"),
index 17390b8..38936b1 100644 (file)
@@ -4,20 +4,20 @@
 
 struct MonsterSpellResult;
 
-struct player_type;
-MonsterSpellResult spell_RF6_S_KIN(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_CYBER(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_MONSTER(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_MONSTERS(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_ANT(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_SPIDER(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_HOUND(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_HYDRA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_ANGEL(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_DEMON(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_UNDEAD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_DRAGON(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_HI_UNDEAD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_HI_DRAGON(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_AMBERITES(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MonsterSpellResult spell_RF6_S_UNIQUE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+class PlayerType;
+MonsterSpellResult spell_RF6_S_KIN(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_CYBER(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_MONSTER(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_MONSTERS(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_ANT(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_SPIDER(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_HOUND(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_HYDRA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_ANGEL(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_DEMON(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_UNDEAD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_DRAGON(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_HI_UNDEAD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_HI_DRAGON(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_AMBERITES(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MonsterSpellResult spell_RF6_S_UNIQUE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
index 7d6fbcb..d888c8e 100644 (file)
@@ -32,7 +32,7 @@ mspell_cast_msg_simple::mspell_cast_msg_simple(concptr to_player, concptr to_mon
 * @param m_idx モンスターID
 * @return プレイヤーがモンスターを見ることができるならTRUE、そうでなければFALSEを返す。
 */
-bool see_monster(player_type* player_ptr, MONSTER_IDX m_idx)
+bool see_monster(PlayerType* player_ptr, MONSTER_IDX m_idx)
 {
     monster_type* m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     return is_seen(player_ptr, m_ptr);
@@ -62,7 +62,7 @@ bool monster_near_player(floor_type* floor_ptr, MONSTER_IDX m_idx, MONSTER_IDX t
  * @param TARGET_TYPE プレイヤーを対象とする場合MONSTER_TO_PLAYER、モンスターを対象とする場合MONSTER_TO_MONSTER
  * @return メッセージを表示した場合trueを返す。
  */
-bool monspell_message_base(player_type* player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg &msgs, bool msg_flag_aux, int TARGET_TYPE)
+bool monspell_message_base(PlayerType* player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg &msgs, bool msg_flag_aux, int TARGET_TYPE)
 {
     bool notice = false;
     floor_type* floor_ptr = player_ptr->current_floor_ptr;
@@ -110,7 +110,7 @@ bool monspell_message_base(player_type* player_ptr, MONSTER_IDX m_idx, MONSTER_I
 * @param TARGET_TYPE プレイヤーを対象とする場合MONSTER_TO_PLAYER、モンスターを対象とする場合MONSTER_TO_MONSTER
  * @return メッセージを表示した場合trueを返す。
  */
-bool monspell_message(player_type* player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_blind &msgs, int TARGET_TYPE)
+bool monspell_message(PlayerType* player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_blind &msgs, int TARGET_TYPE)
 {
     return monspell_message_base(player_ptr, m_idx, t_idx, mspell_cast_msg(msgs.blind, msgs.blind, msgs.to_player, msgs.to_mons), player_ptr->blind > 0, TARGET_TYPE);
 }
@@ -123,7 +123,7 @@ bool monspell_message(player_type* player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_
 * @param msgs メッセージの構造体
 * @param TARGET_TYPE プレイヤーを対象とする場合MONSTER_TO_PLAYER、モンスターを対象とする場合MONSTER_TO_MONSTER
 */
-void simple_monspell_message(player_type* player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_simple &msgs, int TARGET_TYPE)
+void simple_monspell_message(PlayerType* player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_simple &msgs, int TARGET_TYPE)
 {
     monspell_message_base(player_ptr, m_idx, t_idx, mspell_cast_msg(msgs.to_player, msgs.to_mons,
         msgs.to_player, msgs.to_mons), player_ptr->blind > 0, TARGET_TYPE);
index e017249..6f1d5ac 100644 (file)
@@ -12,7 +12,7 @@
 #define RF6_SPELL_START 32 * 5
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 
 struct mspell_cast_msg {
     mspell_cast_msg(concptr to_player_true, concptr to_mons_true, concptr to_player_false, concptr to_mons_false);
@@ -38,8 +38,8 @@ struct mspell_cast_msg_simple {
     concptr to_mons; /*!< モンスター対象*/
 };
 
-bool see_monster(player_type *player_ptr, MONSTER_IDX m_idx);
+bool see_monster(PlayerType *player_ptr, MONSTER_IDX m_idx);
 bool monster_near_player(floor_type *floor_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx);
-bool monspell_message_base(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg &msgs, bool msg_flag_aux, int TARGET_TYPE);
-bool monspell_message(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_blind &msgs, int TARGET_TYPE);
-void simple_monspell_message(player_type *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_simple &msgs, int TARGET_TYPE);
+bool monspell_message_base(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg &msgs, bool msg_flag_aux, int TARGET_TYPE);
+bool monspell_message(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_blind &msgs, int TARGET_TYPE);
+void simple_monspell_message(PlayerType *player_ptr, MONSTER_IDX m_idx, MONSTER_IDX t_idx, const mspell_cast_msg_simple &msgs, int TARGET_TYPE);
index 4b480b2..5e22f71 100644 (file)
@@ -8,7 +8,7 @@
 #include "system/monster-type-definition.h"
 #include "system/player-type-definition.h"
 
-msr_type *initialize_msr_type(player_type *player_ptr, msr_type *msr_ptr, MONSTER_IDX m_idx, const EnumClassFlagGroup<MonsterAbilityType> &ability_flags)
+msr_type *initialize_msr_type(PlayerType *player_ptr, msr_type *msr_ptr, MONSTER_IDX m_idx, const EnumClassFlagGroup<MonsterAbilityType> &ability_flags)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     msr_ptr->r_ptr = &r_info[m_ptr->r_idx];
index 7093906..96dfaa1 100644 (file)
@@ -13,6 +13,6 @@ typedef struct msr_type {
     EnumClassFlagGroup<MonsterSmartLearnType> smart;
 } msr_type;
 
-struct player_type;
-msr_type *initialize_msr_type(player_type *player_ptr, msr_type *msr_ptr, MONSTER_IDX m_idx, const EnumClassFlagGroup<MonsterAbilityType> &ability_flags);
+class PlayerType;
+msr_type *initialize_msr_type(PlayerType *player_ptr, msr_type *msr_ptr, MONSTER_IDX m_idx, const EnumClassFlagGroup<MonsterAbilityType> &ability_flags);
 bool int_outof(monster_race *r_ptr, PERCENTAGE prob);
index 18a399a..ed2ed66 100644 (file)
@@ -26,7 +26,7 @@
  * @param m_idx 呪文を唱えるモンスターID
  * @return 召喚したモンスターの数を返す。
  */
-MONSTER_NUMBER summon_EAGLE(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_EAGLE(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 4 + randint1(3);
@@ -46,7 +46,7 @@ MONSTER_NUMBER summon_EAGLE(player_type *player_ptr, POSITION y, POSITION x, int
  * @param m_idx 呪文を唱えるモンスターID
  * @return 召喚したモンスターの数を返す。
  */
-MONSTER_NUMBER summon_EDGE(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_EDGE(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 2 + randint1(1 + rlev / 20);
@@ -67,7 +67,7 @@ MONSTER_NUMBER summon_EDGE(player_type *player_ptr, POSITION y, POSITION x, int
  * @param TARGET_TYPE プレイヤーを対象とする場合MONSTER_TO_PLAYER、モンスターを対象とする場合MONSTER_TO_MONSTER
  * @return 召喚したモンスターの数を返す。
  */
-MONSTER_NUMBER summon_guardian(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
+MONSTER_NUMBER summon_guardian(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE)
 {
     int num = 2 + randint1(3);
     bool mon_to_mon = (TARGET_TYPE == MONSTER_TO_MONSTER);
@@ -101,7 +101,7 @@ MONSTER_NUMBER summon_guardian(player_type *player_ptr, POSITION y, POSITION x,
  * @param m_idx 呪文を唱えるモンスターID
  * @return 召喚したモンスターの数を返す。
  */
-MONSTER_NUMBER summon_LOCKE_CLONE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_LOCKE_CLONE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = randint1(3);
@@ -121,7 +121,7 @@ MONSTER_NUMBER summon_LOCKE_CLONE(player_type *player_ptr, POSITION y, POSITION
  * @param m_idx 呪文を唱えるモンスターID
  * @return 召喚したモンスターの数を返す。
  */
-MONSTER_NUMBER summon_LOUSE(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_LOUSE(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 2 + randint1(3);
@@ -131,7 +131,7 @@ MONSTER_NUMBER summon_LOUSE(player_type *player_ptr, POSITION y, POSITION x, int
     return count;
 }
 
-MONSTER_NUMBER summon_MOAI(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_MOAI(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 3 + randint1(3);
@@ -141,7 +141,7 @@ MONSTER_NUMBER summon_MOAI(player_type *player_ptr, POSITION y, POSITION x, int
     return count;
 }
 
-MONSTER_NUMBER summon_DEMON_SLAYER(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_DEMON_SLAYER(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     monster_race *r_ptr = &r_info[MON_DEMON_SLAYER_MEMBER];
     if (r_ptr->max_num == 0) {
@@ -167,7 +167,7 @@ MONSTER_NUMBER summon_DEMON_SLAYER(player_type *player_ptr, POSITION y, POSITION
  * @param m_idx 呪文を唱えるモンスターID
  * @return 召喚したモンスターの数を返す。
  */
-MONSTER_NUMBER summon_NAZGUL(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_NAZGUL(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     BIT_FLAGS mode = 0L;
     POSITION cy = y;
@@ -218,7 +218,7 @@ MONSTER_NUMBER summon_NAZGUL(player_type *player_ptr, POSITION y, POSITION x, MO
     return count;
 }
 
-MONSTER_NUMBER summon_APOCRYPHA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_APOCRYPHA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 4 + randint1(4);
@@ -229,7 +229,7 @@ MONSTER_NUMBER summon_APOCRYPHA(player_type *player_ptr, POSITION y, POSITION x,
     return count;
 }
 
-MONSTER_NUMBER summon_HIGHEST_DRAGON(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_HIGHEST_DRAGON(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 4 + randint1(4);
@@ -239,7 +239,7 @@ MONSTER_NUMBER summon_HIGHEST_DRAGON(player_type *player_ptr, POSITION y, POSITI
     return count;
 }
 
-MONSTER_NUMBER summon_PYRAMID(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_PYRAMID(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 2 + randint1(3);
@@ -249,7 +249,7 @@ MONSTER_NUMBER summon_PYRAMID(player_type *player_ptr, POSITION y, POSITION x, i
     return count;
 }
 
-MONSTER_NUMBER summon_EYE_PHORN(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_EYE_PHORN(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 2 + randint1(1 + rlev / 20);
@@ -259,7 +259,7 @@ MONSTER_NUMBER summon_EYE_PHORN(player_type *player_ptr, POSITION y, POSITION x,
     return count;
 }
 
-MONSTER_NUMBER summon_VESPOID(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_VESPOID(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     int count = 0;
     int num = 2 + randint1(3);
@@ -269,7 +269,7 @@ MONSTER_NUMBER summon_VESPOID(player_type *player_ptr, POSITION y, POSITION x, i
     return count;
 }
 
-MONSTER_NUMBER summon_THUNDERS(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_THUNDERS(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     auto count = (MONSTER_NUMBER)0;
     auto num = 11;
@@ -288,7 +288,7 @@ MONSTER_NUMBER summon_THUNDERS(player_type *player_ptr, POSITION y, POSITION x,
  * @param m_idx 呪文を唱えるモンスターID
  * @return 召喚したモンスターの数を返す。
  */
-MONSTER_NUMBER summon_YENDER_WIZARD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_YENDER_WIZARD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx)
 {
     auto *r_ptr = &r_info[MON_YENDOR_WIZARD_2];
     if (r_ptr->max_num == 0) {
@@ -306,7 +306,7 @@ MONSTER_NUMBER summon_YENDER_WIZARD(player_type *player_ptr, POSITION y, POSITIO
     return count;
 }
 
-MONSTER_NUMBER summon_PLASMA(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
+MONSTER_NUMBER summon_PLASMA(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx)
 {
     auto count = 0;
     auto num = 2 + randint1(1 + rlev / 20);
index 247b87a..d97f494 100644 (file)
@@ -2,20 +2,20 @@
 
 #include "system/angband.h"
 
-struct player_type;
-MONSTER_NUMBER summon_EAGLE(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_EDGE(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_guardian(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
-MONSTER_NUMBER summon_LOCKE_CLONE(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_LOUSE(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_MOAI(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_DEMON_SLAYER(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_NAZGUL(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_APOCRYPHA(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_HIGHEST_DRAGON(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_PYRAMID(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_EYE_PHORN(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_VESPOID(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_YENDER_WIZARD(player_type *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_THUNDERS(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
-MONSTER_NUMBER summon_PLASMA(player_type *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+class PlayerType;
+MONSTER_NUMBER summon_EAGLE(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_EDGE(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_guardian(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx, MONSTER_IDX t_idx, int TARGET_TYPE);
+MONSTER_NUMBER summon_LOCKE_CLONE(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_LOUSE(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_MOAI(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_DEMON_SLAYER(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_NAZGUL(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_APOCRYPHA(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_HIGHEST_DRAGON(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_PYRAMID(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_EYE_PHORN(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_VESPOID(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_YENDER_WIZARD(PlayerType *player_ptr, POSITION y, POSITION x, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_THUNDERS(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
+MONSTER_NUMBER summon_PLASMA(PlayerType *player_ptr, POSITION y, POSITION x, int rlev, MONSTER_IDX m_idx);
index 2d8e1eb..7e1d36e 100644 (file)
@@ -21,7 +21,7 @@
  * @return 召喚条件が一致するならtrue
  * @details
  */
-bool check_summon_specific(player_type *player_ptr, MONRACE_IDX summoner_idx, MONRACE_IDX r_idx)
+bool check_summon_specific(PlayerType *player_ptr, MONRACE_IDX summoner_idx, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     bool is_match = false;
index f3e01c0..63de247 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool check_summon_specific(player_type *player_ptr, MONRACE_IDX summoner_idx, MONRACE_IDX r_idx);
+class PlayerType;
+bool check_summon_specific(PlayerType *player_ptr, MONRACE_IDX summoner_idx, MONRACE_IDX r_idx);
index 54b545c..dc7f95d 100644 (file)
@@ -3,7 +3,7 @@
 #include "mutation/mutation-util.h"
 #include "system/player-type-definition.h"
 
-void switch_gain_mutation(player_type *player_ptr, glm_type *glm_ptr)
+void switch_gain_mutation(PlayerType *player_ptr, glm_type *glm_ptr)
 {
     switch (glm_ptr->choose_mut ? glm_ptr->choose_mut : (player_ptr->pclass == PlayerClassType::BERSERKER ? 74 + randint1(119) : randint1(193))) {
     case 1:
index 023d359..3f507fe 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 typedef struct glm_type glm_type;
-struct player_type;
-void switch_gain_mutation(player_type *player_ptr, glm_type *gm_ptr);
+class PlayerType;
+void switch_gain_mutation(PlayerType *player_ptr, glm_type *gm_ptr);
index eed86c6..e85eb80 100644 (file)
@@ -3,7 +3,7 @@
 #include "mutation/mutation-util.h"
 #include "system/player-type-definition.h"
 
-void switch_lose_mutation(player_type *player_ptr, glm_type *glm_ptr)
+void switch_lose_mutation(PlayerType *player_ptr, glm_type *glm_ptr)
 {
     switch ((glm_ptr->choose_mut != 0) ? glm_ptr->choose_mut : randint1(193)) {
     case 1:
index 69b1bbc..72e7e47 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 typedef struct glm_type glm_type;
-struct player_type;
-void switch_lose_mutation(player_type *player_ptr, glm_type *glm_ptr);
+class PlayerType;
+void switch_lose_mutation(PlayerType *player_ptr, glm_type *glm_ptr);
index a65888a..27e4f27 100644 (file)
@@ -19,7 +19,7 @@
  * @brief 現在プレイヤー得ている突然変異の数を返す。
  * @return 現在得ている突然変異の数
  */
-static int count_mutations(player_type *player_ptr)
+static int count_mutations(PlayerType *player_ptr)
 {
     return player_ptr->muta.count();
 }
@@ -32,7 +32,7 @@ static int count_mutations(player_type *player_ptr)
  * Beastman get 10 "free" mutations and only 5% decrease per additional mutation.
  * Max 90% decrease in regeneration speed.
  */
-int calc_mutant_regenerate_mod(player_type *player_ptr)
+int calc_mutant_regenerate_mod(PlayerType *player_ptr)
 {
     int regen;
     int mod = 10;
index 30864f2..62b9572 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-int calc_mutant_regenerate_mod(player_type *player_ptr);
+class PlayerType;
+int calc_mutant_regenerate_mod(PlayerType *player_ptr);
index f72c81a..b98050e 100644 (file)
@@ -11,7 +11,7 @@
 #include "util/bit-flags-calculator.h"
 #include "view/display-messages.h"
 
-static void sweep_gain_mutation(player_type *player_ptr, glm_type *gm_ptr)
+static void sweep_gain_mutation(PlayerType *player_ptr, glm_type *gm_ptr)
 {
     int attempts_left = 20;
     if (gm_ptr->choose_mut)
@@ -27,7 +27,7 @@ static void sweep_gain_mutation(player_type *player_ptr, glm_type *gm_ptr)
     }
 }
 
-static void race_dependent_mutation(player_type *player_ptr, glm_type *gm_ptr)
+static void race_dependent_mutation(PlayerType *player_ptr, glm_type *gm_ptr)
 {
     if (gm_ptr->choose_mut != 0)
         return;
@@ -62,7 +62,7 @@ static void race_dependent_mutation(player_type *player_ptr, glm_type *gm_ptr)
     }
 }
 
-static void neutralize_base_status(player_type *player_ptr, glm_type *gm_ptr)
+static void neutralize_base_status(PlayerType *player_ptr, glm_type *gm_ptr)
 {
     if (gm_ptr->muta_which == PlayerMutationType::PUNY) {
         if (player_ptr->muta.has(PlayerMutationType::HYPER_STR)) {
@@ -174,7 +174,7 @@ static void neutralize_base_status(player_type *player_ptr, glm_type *gm_ptr)
     }
 }
 
-static void neutralize_other_status(player_type *player_ptr, glm_type *gm_ptr)
+static void neutralize_other_status(PlayerType *player_ptr, glm_type *gm_ptr)
 {
     if (gm_ptr->muta_which == PlayerMutationType::COWARDICE) {
         if (player_ptr->muta.has(PlayerMutationType::FEARLESS)) {
@@ -202,7 +202,7 @@ static void neutralize_other_status(player_type *player_ptr, glm_type *gm_ptr)
  * @brief プレイヤーに突然変異を与える
  * @param choose_mut 与えたい突然変異のID、0ならばランダムに選択
  */
-bool gain_mutation(player_type *player_ptr, MUTATION_IDX choose_mut)
+bool gain_mutation(PlayerType *player_ptr, MUTATION_IDX choose_mut)
 {
     glm_type tmp_gm;
     glm_type *gm_ptr = initialize_glm_type(&tmp_gm, choose_mut);
@@ -228,7 +228,7 @@ bool gain_mutation(player_type *player_ptr, MUTATION_IDX choose_mut)
     return true;
 }
 
-static void sweep_lose_mutation(player_type *player_ptr, glm_type *glm_ptr)
+static void sweep_lose_mutation(PlayerType *player_ptr, glm_type *glm_ptr)
 {
     int attempts_left = 20;
     if (glm_ptr->choose_mut)
@@ -251,7 +251,7 @@ static void sweep_lose_mutation(player_type *player_ptr, glm_type *glm_ptr)
  * @brief プレイヤーから突然変異を取り除く
  * @param choose_mut 取り除きたい突然変異のID、0ならばランダムに消去
  */
-bool lose_mutation(player_type *player_ptr, MUTATION_IDX choose_mut)
+bool lose_mutation(PlayerType *player_ptr, MUTATION_IDX choose_mut)
 {
     glm_type tmp_glm;
     glm_type *glm_ptr = initialize_glm_type(&tmp_glm, choose_mut);
@@ -269,7 +269,7 @@ bool lose_mutation(player_type *player_ptr, MUTATION_IDX choose_mut)
     return true;
 }
 
-void lose_all_mutations(player_type *player_ptr)
+void lose_all_mutations(PlayerType *player_ptr)
 {
     if (player_ptr->muta.any()) {
         chg_virtue(player_ptr, V_CHANCE, -5);
index e71cf4e..f0ae022 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool gain_mutation(player_type *player_ptr, MUTATION_IDX choose_mut);
-bool lose_mutation(player_type *player_ptr, MUTATION_IDX choose_mut);
-void lose_all_mutations(player_type *player_ptr);
+class PlayerType;
+bool gain_mutation(PlayerType *player_ptr, MUTATION_IDX choose_mut);
+bool lose_mutation(PlayerType *player_ptr, MUTATION_IDX choose_mut);
+void lose_all_mutations(PlayerType *player_ptr);
index cbe6ff4..3f95e54 100644 (file)
@@ -52,7 +52,7 @@
 #include "term/screen-processor.h"
 #include "view/display-messages.h"
 
-static bool get_hack_dir(player_type *player_ptr, DIRECTION *dp)
+static bool get_hack_dir(PlayerType *player_ptr, DIRECTION *dp)
 {
     *dp = 0;
     char command;
@@ -112,7 +112,7 @@ static bool get_hack_dir(player_type *player_ptr, DIRECTION *dp)
  * @brief 10ゲームターンが進行するごとに突然変異の発動判定を行う処理
  * / Handle mutation effects once every 10 game turns
  */
-void process_world_aux_mutation(player_type *player_ptr)
+void process_world_aux_mutation(PlayerType *player_ptr)
 {
     if (player_ptr->muta.none() || player_ptr->phase_out || player_ptr->wild_mode) {
         return;
@@ -471,7 +471,7 @@ void process_world_aux_mutation(player_type *player_ptr)
     }
 }
 
-bool drop_weapons(player_type *player_ptr)
+bool drop_weapons(PlayerType *player_ptr)
 {
     INVENTORY_IDX slot = 0;
     object_type *o_ptr = nullptr;
index 1ab1b92..4e2c459 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void process_world_aux_mutation(player_type *player_ptr);
-bool drop_weapons(player_type *player_ptr);
+class PlayerType;
+void process_world_aux_mutation(PlayerType *player_ptr);
+bool drop_weapons(PlayerType *player_ptr);
index fbd3be8..20d5c49 100644 (file)
@@ -26,7 +26,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return コマンドの入力方向に地形があればTRUE
  */
-bool eat_rock(player_type *player_ptr)
+bool eat_rock(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_direction(player_ptr, &dir, false, false))
index b1df1b7..ee9ac26 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool eat_rock(player_type *player_ptr);
+class PlayerType;
+bool eat_rock(PlayerType *player_ptr);
index d792d8f..171e168 100644 (file)
@@ -12,7 +12,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool activate_missile_1(player_type *player_ptr)
+bool activate_missile_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは眩しいくらいに明るく輝いている...", "It glows extremely brightly..."));
@@ -23,7 +23,7 @@ bool activate_missile_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_missile_2(player_type *player_ptr)
+bool activate_missile_2(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("魔法のトゲが現れた...", "It grows magical spikes..."));
@@ -34,7 +34,7 @@ bool activate_missile_2(player_type *player_ptr)
     return true;
 }
 
-bool activate_missile_3(player_type *player_ptr)
+bool activate_missile_3(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -45,7 +45,7 @@ bool activate_missile_3(player_type *player_ptr)
     return true;
 }
 
-bool activate_bolt_acid_1(player_type *player_ptr)
+bool activate_bolt_acid_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは酸に覆われた...", "It is covered in acid..."));
@@ -56,7 +56,7 @@ bool activate_bolt_acid_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_bolt_elec_1(player_type *player_ptr)
+bool activate_bolt_elec_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは火花に覆われた...", "It is covered in sparks..."));
@@ -67,7 +67,7 @@ bool activate_bolt_elec_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_bolt_fire_1(player_type *player_ptr)
+bool activate_bolt_fire_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは炎に覆われた...", "It is covered in fire..."));
@@ -78,7 +78,7 @@ bool activate_bolt_fire_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_bolt_cold_1(player_type *player_ptr)
+bool activate_bolt_cold_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは霜に覆われた...", "It is covered in frost..."));
@@ -89,7 +89,7 @@ bool activate_bolt_cold_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_bolt_hypodynamia_1(player_type *player_ptr, concptr name)
+bool activate_bolt_hypodynamia_1(PlayerType *player_ptr, concptr name)
 {
     DIRECTION dir;
     msg_format(_("あなたは%sに敵を締め殺すよう命じた。", "You order the %s to strangle your opponent."), name);
@@ -100,7 +100,7 @@ bool activate_bolt_hypodynamia_1(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_bolt_hypodynamia_2(player_type *player_ptr)
+bool activate_bolt_hypodynamia_2(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("黒く輝いている...", "It glows black..."));
@@ -111,7 +111,7 @@ bool activate_bolt_hypodynamia_2(player_type *player_ptr)
     return true;
 }
 
-bool activate_bolt_drain_1(player_type *player_ptr)
+bool activate_bolt_drain_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -124,7 +124,7 @@ bool activate_bolt_drain_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_bolt_drain_2(player_type *player_ptr)
+bool activate_bolt_drain_2(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -137,7 +137,7 @@ bool activate_bolt_drain_2(player_type *player_ptr)
     return true;
 }
 
-bool activate_bolt_mana(player_type *player_ptr, concptr name)
+bool activate_bolt_mana(PlayerType *player_ptr, concptr name)
 {
     DIRECTION dir;
     msg_format(_("%sに魔法のトゲが現れた...", "The %s grows magical spikes..."), name);
@@ -148,7 +148,7 @@ bool activate_bolt_mana(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_ball_pois_1(player_type *player_ptr)
+bool activate_ball_pois_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは濃緑色に脈動している...", "It throbs deep green..."));
@@ -159,7 +159,7 @@ bool activate_ball_pois_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_cold_1(player_type *player_ptr)
+bool activate_ball_cold_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは霜に覆われた...", "It is covered in frost..."));
@@ -170,7 +170,7 @@ bool activate_ball_cold_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_cold_2(player_type *player_ptr)
+bool activate_ball_cold_2(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは青く激しく輝いた...", "It glows an intense blue..."));
@@ -181,7 +181,7 @@ bool activate_ball_cold_2(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_cold_3(player_type *player_ptr)
+bool activate_ball_cold_3(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("明るく白色に輝いている...", "It glows bright white..."));
@@ -192,7 +192,7 @@ bool activate_ball_cold_3(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_fire_1(player_type *player_ptr)
+bool activate_ball_fire_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは赤く激しく輝いた...", "It glows an intense red..."));
@@ -203,7 +203,7 @@ bool activate_ball_fire_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_fire_2(player_type *player_ptr, concptr name)
+bool activate_ball_fire_2(PlayerType *player_ptr, concptr name)
 {
     DIRECTION dir;
     msg_format(_("%sから炎が吹き出した...", "The %s rages in fire..."), name);
@@ -214,7 +214,7 @@ bool activate_ball_fire_2(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_ball_fire_3(player_type *player_ptr)
+bool activate_ball_fire_3(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("深赤色に輝いている...", "It glows deep red..."));
@@ -225,7 +225,7 @@ bool activate_ball_fire_3(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_fire_4(player_type *player_ptr)
+bool activate_ball_fire_4(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは赤く激しく輝いた...", "It glows an intense red..."));
@@ -236,7 +236,7 @@ bool activate_ball_fire_4(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_elec_2(player_type *player_ptr)
+bool activate_ball_elec_2(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("電気がパチパチ音を立てた...", "It crackles with electricity..."));
@@ -247,7 +247,7 @@ bool activate_ball_elec_2(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_elec_3(player_type *player_ptr)
+bool activate_ball_elec_3(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("深青色に輝いている...", "It glows deep blue..."));
@@ -258,7 +258,7 @@ bool activate_ball_elec_3(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_acid_1(player_type *player_ptr)
+bool activate_ball_acid_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは黒く激しく輝いた...", "It glows an intense black..."));
@@ -269,7 +269,7 @@ bool activate_ball_acid_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_nuke_1(player_type *player_ptr)
+bool activate_ball_nuke_1(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("それは緑に激しく輝いた...", "It glows an intense green..."));
@@ -280,7 +280,7 @@ bool activate_ball_nuke_1(player_type *player_ptr)
     return true;
 }
 
-bool activate_rocket(player_type *player_ptr)
+bool activate_rocket(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -291,7 +291,7 @@ bool activate_rocket(player_type *player_ptr)
     return true;
 }
 
-bool activate_ball_water(player_type *player_ptr, concptr name)
+bool activate_ball_water(PlayerType *player_ptr, concptr name)
 {
     DIRECTION dir;
     msg_format(_("%sが深い青色に鼓動している...", "The %s throbs deep blue..."), name);
@@ -302,7 +302,7 @@ bool activate_ball_water(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_ball_lite(player_type *player_ptr, concptr name)
+bool activate_ball_lite(PlayerType *player_ptr, concptr name)
 {
     HIT_POINT num = damroll(5, 3);
     POSITION y = 0, x = 0;
@@ -324,7 +324,7 @@ bool activate_ball_lite(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_ball_dark(player_type *player_ptr, concptr name)
+bool activate_ball_dark(PlayerType *player_ptr, concptr name)
 {
     DIRECTION dir;
     msg_format(_("%sが深い闇に覆われた...", "The %s is covered in pitch-darkness..."), name);
@@ -335,7 +335,7 @@ bool activate_ball_dark(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_ball_mana(player_type *player_ptr, concptr name)
+bool activate_ball_mana(PlayerType *player_ptr, concptr name)
 {
     DIRECTION dir;
     msg_format(_("%sが青白く光った...", "The %s becomes pale..."), name);
index dd0054c..7b162d9 100644 (file)
@@ -2,33 +2,33 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool activate_missile_1(player_type *player_ptr);
-bool activate_missile_2(player_type *player_ptr);
-bool activate_missile_3(player_type *player_ptr);
-bool activate_bolt_acid_1(player_type *player_ptr);
-bool activate_bolt_elec_1(player_type *player_ptr);
-bool activate_bolt_fire_1(player_type *player_ptr);
-bool activate_bolt_cold_1(player_type *player_ptr);
-bool activate_bolt_hypodynamia_1(player_type *player_ptr, concptr name);
-bool activate_bolt_hypodynamia_2(player_type *player_ptr);
-bool activate_bolt_drain_1(player_type *player_ptr);
-bool activate_bolt_drain_2(player_type *player_ptr);
-bool activate_bolt_mana(player_type *player_ptr, concptr name);
-bool activate_ball_pois_1(player_type *player_ptr);
-bool activate_ball_cold_1(player_type *player_ptr);
-bool activate_ball_cold_2(player_type *player_ptr);
-bool activate_ball_cold_3(player_type *player_ptr);
-bool activate_ball_fire_1(player_type *player_ptr);
-bool activate_ball_fire_2(player_type *player_ptr, concptr name);
-bool activate_ball_fire_3(player_type *player_ptr);
-bool activate_ball_fire_4(player_type *player_ptr);
-bool activate_ball_elec_2(player_type *player_ptr);
-bool activate_ball_elec_3(player_type *player_ptr);
-bool activate_ball_acid_1(player_type *player_ptr);
-bool activate_ball_nuke_1(player_type *player_ptr);
-bool activate_rocket(player_type *player_ptr);
-bool activate_ball_water(player_type *player_ptr, concptr name);
-bool activate_ball_lite(player_type *player_ptr, concptr name);
-bool activate_ball_dark(player_type *player_ptr, concptr name);
-bool activate_ball_mana(player_type *player_ptr, concptr name);
+class PlayerType;
+bool activate_missile_1(PlayerType *player_ptr);
+bool activate_missile_2(PlayerType *player_ptr);
+bool activate_missile_3(PlayerType *player_ptr);
+bool activate_bolt_acid_1(PlayerType *player_ptr);
+bool activate_bolt_elec_1(PlayerType *player_ptr);
+bool activate_bolt_fire_1(PlayerType *player_ptr);
+bool activate_bolt_cold_1(PlayerType *player_ptr);
+bool activate_bolt_hypodynamia_1(PlayerType *player_ptr, concptr name);
+bool activate_bolt_hypodynamia_2(PlayerType *player_ptr);
+bool activate_bolt_drain_1(PlayerType *player_ptr);
+bool activate_bolt_drain_2(PlayerType *player_ptr);
+bool activate_bolt_mana(PlayerType *player_ptr, concptr name);
+bool activate_ball_pois_1(PlayerType *player_ptr);
+bool activate_ball_cold_1(PlayerType *player_ptr);
+bool activate_ball_cold_2(PlayerType *player_ptr);
+bool activate_ball_cold_3(PlayerType *player_ptr);
+bool activate_ball_fire_1(PlayerType *player_ptr);
+bool activate_ball_fire_2(PlayerType *player_ptr, concptr name);
+bool activate_ball_fire_3(PlayerType *player_ptr);
+bool activate_ball_fire_4(PlayerType *player_ptr);
+bool activate_ball_elec_2(PlayerType *player_ptr);
+bool activate_ball_elec_3(PlayerType *player_ptr);
+bool activate_ball_acid_1(PlayerType *player_ptr);
+bool activate_ball_nuke_1(PlayerType *player_ptr);
+bool activate_rocket(PlayerType *player_ptr);
+bool activate_ball_water(PlayerType *player_ptr, concptr name);
+bool activate_ball_lite(PlayerType *player_ptr, concptr name);
+bool activate_ball_dark(PlayerType *player_ptr, concptr name);
+bool activate_ball_mana(PlayerType *player_ptr, concptr name);
index efafc8f..a739873 100644 (file)
@@ -21,7 +21,7 @@
  * @param o_ptr 対象のオブジェクト構造体ポインタ
  * @return 発動実行の是非を返す。
  */
-bool activate_dragon_breath(player_type *player_ptr, object_type *o_ptr)
+bool activate_dragon_breath(PlayerType *player_ptr, object_type *o_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -56,7 +56,7 @@ bool activate_dragon_breath(player_type *player_ptr, object_type *o_ptr)
     return true;
 }
 
-bool activate_breath_fire(player_type *player_ptr, object_type *o_ptr)
+bool activate_breath_fire(PlayerType *player_ptr, object_type *o_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -69,7 +69,7 @@ bool activate_breath_fire(player_type *player_ptr, object_type *o_ptr)
     return true;
 }
 
-bool activate_breath_cold(player_type *player_ptr, object_type *o_ptr)
+bool activate_breath_cold(PlayerType *player_ptr, object_type *o_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
index 21de64f..38808c0 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool activate_dragon_breath(player_type *player_ptr, object_type *o_ptr);
-bool activate_breath_fire(player_type *player_ptr, object_type *o_ptr);
-bool activate_breath_cold(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool activate_dragon_breath(PlayerType *player_ptr, object_type *o_ptr);
+bool activate_breath_fire(PlayerType *player_ptr, object_type *o_ptr);
+bool activate_breath_cold(PlayerType *player_ptr, object_type *o_ptr);
index 5aa507b..46e241b 100644 (file)
@@ -4,7 +4,7 @@
 #include "system/player-type-definition.h"
 #include "target/target-getter.h"
 
-bool activate_charm_animal(player_type *player_ptr)
+bool activate_charm_animal(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -14,7 +14,7 @@ bool activate_charm_animal(player_type *player_ptr)
     return true;
 }
 
-bool activate_charm_undead(player_type *player_ptr)
+bool activate_charm_undead(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -24,7 +24,7 @@ bool activate_charm_undead(player_type *player_ptr)
     return true;
 }
 
-bool activate_charm_other(player_type *player_ptr)
+bool activate_charm_other(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -34,13 +34,13 @@ bool activate_charm_other(player_type *player_ptr)
     return true;
 }
 
-bool activate_charm_animals(player_type *player_ptr)
+bool activate_charm_animals(PlayerType *player_ptr)
 {
     (void)charm_animals(player_ptr, player_ptr->lev * 2);
     return true;
 }
 
-bool activate_charm_others(player_type *player_ptr)
+bool activate_charm_others(PlayerType *player_ptr)
 {
     (void)charm_monsters(player_ptr, player_ptr->lev * 2);
     return true;
index 6932e18..9ec35a1 100644 (file)
@@ -1,8 +1,8 @@
 #pragma once
 
-struct player_type;
-bool activate_charm_animal(player_type *player_ptr);
-bool activate_charm_undead(player_type *player_ptr);
-bool activate_charm_other(player_type *player_ptr);
-bool activate_charm_animals(player_type *player_ptr);
-bool activate_charm_others(player_type *player_ptr);
+class PlayerType;
+bool activate_charm_animal(PlayerType *player_ptr);
+bool activate_charm_undead(PlayerType *player_ptr);
+bool activate_charm_other(PlayerType *player_ptr);
+bool activate_charm_animals(PlayerType *player_ptr);
+bool activate_charm_others(PlayerType *player_ptr);
index 13d2235..a1c9d87 100644 (file)
@@ -3,14 +3,14 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-bool activate_genocide(player_type *player_ptr)
+bool activate_genocide(PlayerType *player_ptr)
 {
     msg_print(_("深青色に輝いている...", "It glows deep blue..."));
     (void)symbol_genocide(player_ptr, 200, true);
     return true;
 }
 
-bool activate_mass_genocide(player_type *player_ptr)
+bool activate_mass_genocide(PlayerType *player_ptr)
 {
     msg_print(_("ひどく鋭い音が流れ出た...", "It lets out a long, shrill note..."));
     (void)mass_genocide(player_ptr, 200, true);
index a84d2ec..2a390b3 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-bool activate_genocide(player_type *player_ptr);
-bool activate_mass_genocide(player_type *player_ptr);
+class PlayerType;
+bool activate_genocide(PlayerType *player_ptr);
+bool activate_mass_genocide(PlayerType *player_ptr);
index 42ed15e..dc78f9a 100644 (file)
@@ -54,7 +54,7 @@
 #include "util/quarks.h"
 #include "view/display-messages.h"
 
-bool activate_sunlight(player_type *player_ptr)
+bool activate_sunlight(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -65,7 +65,7 @@ bool activate_sunlight(player_type *player_ptr)
     return true;
 }
 
-bool activate_confusion(player_type *player_ptr)
+bool activate_confusion(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("様々な色の火花を発している...", "It glows in scintillating colours..."));
@@ -76,7 +76,7 @@ bool activate_confusion(player_type *player_ptr)
     return true;
 }
 
-bool activate_banish_evil(player_type *player_ptr)
+bool activate_banish_evil(PlayerType *player_ptr)
 {
     if (banish_evil(player_ptr, 100))
         msg_print(_("アーティファクトの力が邪悪を打ち払った!", "The power of the artifact banishes evil!"));
@@ -84,7 +84,7 @@ bool activate_banish_evil(player_type *player_ptr)
     return true;
 }
 
-bool activate_scare(player_type *player_ptr)
+bool activate_scare(PlayerType *player_ptr)
 {
     if (music_singing_any(player_ptr))
         stop_singing(player_ptr);
@@ -98,7 +98,7 @@ bool activate_scare(player_type *player_ptr)
     return true;
 }
 
-bool activate_aggravation(player_type *player_ptr, object_type *o_ptr, concptr name)
+bool activate_aggravation(PlayerType *player_ptr, object_type *o_ptr, concptr name)
 {
     if (o_ptr->name1 == ART_HYOUSIGI)
         msg_print(_("拍子木を打った。", "You beat your wooden clappers."));
@@ -109,7 +109,7 @@ bool activate_aggravation(player_type *player_ptr, object_type *o_ptr, concptr n
     return true;
 }
 
-bool activate_stone_mud(player_type *player_ptr)
+bool activate_stone_mud(PlayerType *player_ptr)
 {
     DIRECTION dir;
     msg_print(_("鼓動している...", "It pulsates..."));
@@ -120,7 +120,7 @@ bool activate_stone_mud(player_type *player_ptr)
     return true;
 }
 
-bool activate_judgement(player_type *player_ptr, concptr name)
+bool activate_judgement(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sは赤く明るく光った!", "The %s flashes bright red!"), name);
     chg_virtue(player_ptr, V_KNOWLEDGE, 1);
@@ -140,7 +140,7 @@ bool activate_judgement(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_telekinesis(player_type *player_ptr, concptr name)
+bool activate_telekinesis(PlayerType *player_ptr, concptr name)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -151,7 +151,7 @@ bool activate_telekinesis(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_unique_detection(player_type *player_ptr)
+bool activate_unique_detection(PlayerType *player_ptr)
 {
     monster_type *m_ptr;
     monster_race *r_ptr;
@@ -172,7 +172,7 @@ bool activate_unique_detection(player_type *player_ptr)
     return true;
 }
 
-bool activate_dispel_curse(player_type *player_ptr, concptr name)
+bool activate_dispel_curse(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが真実を照らし出す...", "The %s exhibits the truth..."), name);
     (void)remove_all_curse(player_ptr);
@@ -180,49 +180,49 @@ bool activate_dispel_curse(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_cure_lw(player_type *player_ptr)
+bool activate_cure_lw(PlayerType *player_ptr)
 {
     (void)BadStatusSetter(player_ptr).afraidness(0);
     (void)hp_player(player_ptr, 30);
     return true;
 }
 
-bool activate_grand_cross(player_type *player_ptr)
+bool activate_grand_cross(PlayerType *player_ptr)
 {
     msg_print(_("「闇に還れ!」", "You say, 'Return to darkness!'"));
     (void)project(player_ptr, 0, 8, player_ptr->y, player_ptr->x, (randint1(100) + 200) * 2, AttributeType::HOLY_FIRE, PROJECT_KILL | PROJECT_ITEM | PROJECT_GRID);
     return true;
 }
 
-bool activate_call_chaos(player_type *player_ptr)
+bool activate_call_chaos(PlayerType *player_ptr)
 {
     msg_print(_("様々な色の火花を発している...", "It glows in scintillating colours..."));
     call_chaos(player_ptr);
     return true;
 }
 
-bool activate_dispel_evil(player_type *player_ptr)
+bool activate_dispel_evil(PlayerType *player_ptr)
 {
     msg_print(_("神聖な雰囲気が充満した...", "It floods the area with goodness..."));
     dispel_evil(player_ptr, player_ptr->lev * 5);
     return true;
 }
 
-bool activate_dispel_good(player_type *player_ptr)
+bool activate_dispel_good(PlayerType *player_ptr)
 {
     msg_print(_("邪悪な雰囲気が充満した...", "It floods the area with evil..."));
     dispel_good(player_ptr, player_ptr->lev * 5);
     return true;
 }
 
-bool activate_all_monsters_detection(player_type *player_ptr)
+bool activate_all_monsters_detection(PlayerType *player_ptr)
 {
     (void)detect_monsters_invis(player_ptr, 255);
     (void)detect_monsters_normal(player_ptr, 255);
     return true;
 }
 
-bool activate_all_detection(player_type *player_ptr)
+bool activate_all_detection(PlayerType *player_ptr)
 {
     msg_print(_("白く明るく輝いている...", "It glows bright white..."));
     msg_print(_("心にイメージが浮かんできた...", "An image forms in your mind..."));
@@ -230,7 +230,7 @@ bool activate_all_detection(player_type *player_ptr)
     return true;
 }
 
-bool activate_extra_detection(player_type *player_ptr)
+bool activate_extra_detection(PlayerType *player_ptr)
 {
     msg_print(_("明るく輝いている...", "It glows brightly..."));
     detect_all(player_ptr, DETECT_RAD_DEFAULT);
@@ -239,7 +239,7 @@ bool activate_extra_detection(player_type *player_ptr)
     return true;
 }
 
-bool activate_fully_identification(player_type *player_ptr)
+bool activate_fully_identification(PlayerType *player_ptr)
 {
     msg_print(_("黄色く輝いている...", "It glows yellow..."));
     identify_fully(player_ptr, false);
@@ -251,12 +251,12 @@ bool activate_fully_identification(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 発動に成功したらTRUE
  */
-bool activate_identification(player_type *player_ptr)
+bool activate_identification(PlayerType *player_ptr)
 {
     return ident_spell(player_ptr, false);
 }
 
-bool activate_pesticide(player_type *player_ptr)
+bool activate_pesticide(PlayerType *player_ptr)
 {
     msg_print(_("あなたは害虫を一掃した。", "You exterminate some pests."));
     (void)dispel_monsters(player_ptr, 4);
@@ -268,13 +268,13 @@ bool activate_pesticide(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 発動に成功したらTRUE
  */
-bool activate_whirlwind(player_type *player_ptr)
+bool activate_whirlwind(PlayerType *player_ptr)
 {
     massacre(player_ptr);
     return true;
 }
 
-bool activate_blinding_light(player_type *player_ptr, concptr name)
+bool activate_blinding_light(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが眩しい光で輝いた...", "The %s gleams with blinding light..."), name);
     (void)fire_ball(player_ptr, AttributeType::LITE, 0, 300, 6);
@@ -282,39 +282,39 @@ bool activate_blinding_light(player_type *player_ptr, concptr name)
     return true;
 }
 
-bool activate_sleep(player_type *player_ptr)
+bool activate_sleep(PlayerType *player_ptr)
 {
     msg_print(_("深青色に輝いている...", "It glows deep blue..."));
     sleep_monsters_touch(player_ptr);
     return true;
 }
 
-bool activate_door_destroy(player_type *player_ptr)
+bool activate_door_destroy(PlayerType *player_ptr)
 {
     msg_print(_("明るい赤色に輝いている...", "It glows bright red..."));
     destroy_doors_touch(player_ptr);
     return true;
 }
 
-bool activate_earthquake(player_type *player_ptr)
+bool activate_earthquake(PlayerType *player_ptr)
 {
     earthquake(player_ptr, player_ptr->y, player_ptr->x, 5, 0);
     return true;
 }
 
-bool activate_recharge(player_type *player_ptr)
+bool activate_recharge(PlayerType *player_ptr)
 {
     recharge(player_ptr, 130);
     return true;
 }
 
-bool activate_recharge_extra(player_type *player_ptr, concptr name)
+bool activate_recharge_extra(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが白く輝いた...", "The %s gleams with blinding light..."), name);
     return recharge(player_ptr, 1000);
 }
 
-bool activate_shikofumi(player_type *player_ptr)
+bool activate_shikofumi(PlayerType *player_ptr)
 {
     msg_print(_("力強く四股を踏んだ。", "You stamp. (as if you are in a ring.)"));
     (void)BadStatusSetter(player_ptr).afraidness(0);
@@ -323,13 +323,13 @@ bool activate_shikofumi(player_type *player_ptr)
     return true;
 }
 
-bool activate_terror(player_type *player_ptr)
+bool activate_terror(PlayerType *player_ptr)
 {
     turn_monsters(player_ptr, 40 + player_ptr->lev);
     return true;
 }
 
-bool activate_map_light(player_type *player_ptr)
+bool activate_map_light(PlayerType *player_ptr)
 {
     msg_print(_("眩しく輝いた...", "It shines brightly..."));
     map_area(player_ptr, DETECT_RAD_MAP);
@@ -337,21 +337,21 @@ bool activate_map_light(player_type *player_ptr)
     return true;
 }
 
-bool activate_exploding_rune(player_type *player_ptr)
+bool activate_exploding_rune(PlayerType *player_ptr)
 {
     msg_print(_("明るい赤色に輝いている...", "It glows bright red..."));
     create_rune_explosion(player_ptr, player_ptr->y, player_ptr->x);
     return true;
 }
 
-bool activate_protection_rune(player_type *player_ptr)
+bool activate_protection_rune(PlayerType *player_ptr)
 {
     msg_print(_("ブルーに明るく輝いている...", "It glows light blue..."));
     create_rune_protection_one(player_ptr);
     return true;
 }
 
-bool activate_protection_elbereth(player_type *player_ptr)
+bool activate_protection_elbereth(PlayerType *player_ptr)
 {
     BadStatusSetter bss(player_ptr);
     msg_print(_("エルベレスよ、我を護り給え!", "A Elbereth gilthoniel!"));
@@ -364,26 +364,26 @@ bool activate_protection_elbereth(player_type *player_ptr)
     return true;
 }
 
-bool activate_light(player_type *player_ptr, concptr name)
+bool activate_light(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sから澄んだ光があふれ出た...", "The %s wells with clear light..."), name);
     (void)lite_area(player_ptr, damroll(2, 15), 3);
     return true;
 }
 
-bool activate_recall(player_type *player_ptr)
+bool activate_recall(PlayerType *player_ptr)
 {
     msg_print(_("やわらかな白色に輝いている...", "It glows soft white..."));
     return recall_player(player_ptr, randint0(21) + 15);
 }
 
-bool activate_tree_creation(player_type *player_ptr, object_type *o_ptr, concptr name)
+bool activate_tree_creation(PlayerType *player_ptr, object_type *o_ptr, concptr name)
 {
     msg_format(_("%s%sから明るい緑の光があふれ出た...", "The %s%s wells with clear light..."), name, quark_str(o_ptr->art_name));
     return tree_creation(player_ptr, player_ptr->y, player_ptr->x);
 }
 
-bool activate_animate_dead(player_type *player_ptr, object_type *o_ptr)
+bool activate_animate_dead(PlayerType *player_ptr, object_type *o_ptr)
 {
     msg_print(_("黄金色の光が溢れ出た...", "It emitted a golden light..."));
     if (o_ptr->name1 > 0)
@@ -392,7 +392,7 @@ bool activate_animate_dead(player_type *player_ptr, object_type *o_ptr)
     return animate_dead(player_ptr, 0, player_ptr->y, player_ptr->x);
 }
 
-bool activate_detect_treasure(player_type *player_ptr)
+bool activate_detect_treasure(PlayerType *player_ptr)
 {
     msg_print(_("金と銀に彩られている...", "It shines with gold and silver..."));
     return detect_treasure(player_ptr, DETECT_RAD_DEFAULT);
index bdc4ef3..02e99b7 100644 (file)
@@ -3,43 +3,43 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-bool activate_sunlight(player_type *player_ptr);
-bool activate_confusion(player_type *player_ptr);
-bool activate_banish_evil(player_type *player_ptr);
-bool activate_scare(player_type *player_ptr);
-bool activate_aggravation(player_type *player_ptr, object_type *o_ptr, concptr name);
-bool activate_stone_mud(player_type *player_ptr);
-bool activate_judgement(player_type *player_ptr, concptr name);
-bool activate_telekinesis(player_type *player_ptr, concptr name);
-bool activate_unique_detection(player_type *player_ptr);
-bool activate_dispel_curse(player_type *player_ptr, concptr name);
-bool activate_cure_lw(player_type *player_ptr);
-bool activate_grand_cross(player_type *player_ptr);
-bool activate_call_chaos(player_type *player_ptr);
-bool activate_dispel_evil(player_type *player_ptr);
-bool activate_dispel_good(player_type *player_ptr);
-bool activate_all_monsters_detection(player_type *player_ptr);
-bool activate_all_detection(player_type *player_ptr);
-bool activate_extra_detection(player_type *player_ptr);
-bool activate_fully_identification(player_type *player_ptr);
-bool activate_identification(player_type *player_ptr);
-bool activate_pesticide(player_type *player_ptr);
-bool activate_whirlwind(player_type *player_ptr);
-bool activate_blinding_light(player_type *player_ptr, concptr name);
-bool activate_sleep(player_type *player_ptr);
-bool activate_door_destroy(player_type *player_ptr);
-bool activate_earthquake(player_type *player_ptr);
-bool activate_recharge(player_type *player_ptr);
-bool activate_recharge_extra(player_type *player_ptr, concptr name);
-bool activate_shikofumi(player_type *player_ptr);
-bool activate_terror(player_type *player_ptr);
-bool activate_map_light(player_type *player_ptr);
-bool activate_exploding_rune(player_type *player_ptr);
-bool activate_protection_rune(player_type *player_ptr);
-bool activate_protection_elbereth(player_type *player_ptr);
-bool activate_light(player_type *player_ptr, concptr name);
-bool activate_recall(player_type *player_ptr);
-bool activate_tree_creation(player_type *player_ptr, object_type *o_ptr, concptr name);
-bool activate_animate_dead(player_type *player_ptr, object_type *o_ptr);
-bool activate_detect_treasure(player_type *player_ptr);
+class PlayerType;
+bool activate_sunlight(PlayerType *player_ptr);
+bool activate_confusion(PlayerType *player_ptr);
+bool activate_banish_evil(PlayerType *player_ptr);
+bool activate_scare(PlayerType *player_ptr);
+bool activate_aggravation(PlayerType *player_ptr, object_type *o_ptr, concptr name);
+bool activate_stone_mud(PlayerType *player_ptr);
+bool activate_judgement(PlayerType *player_ptr, concptr name);
+bool activate_telekinesis(PlayerType *player_ptr, concptr name);
+bool activate_unique_detection(PlayerType *player_ptr);
+bool activate_dispel_curse(PlayerType *player_ptr, concptr name);
+bool activate_cure_lw(PlayerType *player_ptr);
+bool activate_grand_cross(PlayerType *player_ptr);
+bool activate_call_chaos(PlayerType *player_ptr);
+bool activate_dispel_evil(PlayerType *player_ptr);
+bool activate_dispel_good(PlayerType *player_ptr);
+bool activate_all_monsters_detection(PlayerType *player_ptr);
+bool activate_all_detection(PlayerType *player_ptr);
+bool activate_extra_detection(PlayerType *player_ptr);
+bool activate_fully_identification(PlayerType *player_ptr);
+bool activate_identification(PlayerType *player_ptr);
+bool activate_pesticide(PlayerType *player_ptr);
+bool activate_whirlwind(PlayerType *player_ptr);
+bool activate_blinding_light(PlayerType *player_ptr, concptr name);
+bool activate_sleep(PlayerType *player_ptr);
+bool activate_door_destroy(PlayerType *player_ptr);
+bool activate_earthquake(PlayerType *player_ptr);
+bool activate_recharge(PlayerType *player_ptr);
+bool activate_recharge_extra(PlayerType *player_ptr, concptr name);
+bool activate_shikofumi(PlayerType *player_ptr);
+bool activate_terror(PlayerType *player_ptr);
+bool activate_map_light(PlayerType *player_ptr);
+bool activate_exploding_rune(PlayerType *player_ptr);
+bool activate_protection_rune(PlayerType *player_ptr);
+bool activate_protection_elbereth(PlayerType *player_ptr);
+bool activate_light(PlayerType *player_ptr, concptr name);
+bool activate_recall(PlayerType *player_ptr);
+bool activate_tree_creation(PlayerType *player_ptr, object_type *o_ptr, concptr name);
+bool activate_animate_dead(PlayerType *player_ptr, object_type *o_ptr);
+bool activate_detect_treasure(PlayerType *player_ptr);
index 7a63cca..2e783eb 100644 (file)
@@ -12,7 +12,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool activate_resistance_elements(player_type *player_ptr)
+bool activate_resistance_elements(PlayerType *player_ptr)
 {
     msg_print(_("様々な色に輝いている...", "It glows many colours..."));
     (void)set_oppose_acid(player_ptr, randint1(40) + 40, false);
@@ -29,7 +29,7 @@ bool activate_resistance_elements(player_type *player_ptr)
  * @param name アイテム名
  * @return 発動をキャンセルした場合FALSE、それ以外はTRUEを返す
  */
-bool activate_acid_ball_and_resistance(player_type *player_ptr, concptr name)
+bool activate_acid_ball_and_resistance(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが黒く輝いた...", "The %s grows black."), name);
 
@@ -49,7 +49,7 @@ bool activate_acid_ball_and_resistance(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 発動をキャンセルした場合FALSE、それ以外はTRUEを返す
  */
-bool activate_elec_ball_and_resistance(player_type *player_ptr, concptr name)
+bool activate_elec_ball_and_resistance(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが青く輝いた...", "The %s grows blue."), name);
 
@@ -69,7 +69,7 @@ bool activate_elec_ball_and_resistance(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 発動をキャンセルした場合FALSE、それ以外はTRUEを返す
  */
-bool activate_fire_ball_and_resistance(player_type *player_ptr, concptr name)
+bool activate_fire_ball_and_resistance(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが赤く輝いた...", "The %s grows red."), name);
 
@@ -89,7 +89,7 @@ bool activate_fire_ball_and_resistance(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 発動をキャンセルした場合FALSE、それ以外はTRUEを返す
  */
-bool activate_cold_ball_and_resistance(player_type *player_ptr, concptr name)
+bool activate_cold_ball_and_resistance(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが白く輝いた...", "The %s grows white."), name);
 
@@ -109,7 +109,7 @@ bool activate_cold_ball_and_resistance(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 発動をキャンセルした場合FALSE、それ以外はTRUEを返す
  */
-bool activate_pois_ball_and_resistance(player_type *player_ptr, concptr name)
+bool activate_pois_ball_and_resistance(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが緑に輝いた...", "The %s grows green."), name);
 
@@ -129,7 +129,7 @@ bool activate_pois_ball_and_resistance(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 常にTRUE
  */
-bool activate_resistance_acid(player_type *player_ptr, concptr name)
+bool activate_resistance_acid(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが黒く輝いた...", "The %s grows black."), name);
     (void)set_oppose_acid(player_ptr, randint1(20) + 20, false);
@@ -142,7 +142,7 @@ bool activate_resistance_acid(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 常にTRUE
  */
-bool activate_resistance_elec(player_type *player_ptr, concptr name)
+bool activate_resistance_elec(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが青く輝いた...", "The %s grows blue."), name);
     (void)set_oppose_elec(player_ptr, randint1(20) + 20, false);
@@ -155,7 +155,7 @@ bool activate_resistance_elec(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 常にTRUE
  */
-bool activate_resistance_fire(player_type *player_ptr, concptr name)
+bool activate_resistance_fire(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが赤く輝いた...", "The %s grows red."), name);
     (void)set_oppose_fire(player_ptr, randint1(20) + 20, false);
@@ -168,7 +168,7 @@ bool activate_resistance_fire(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 常にTRUE
  */
-bool activate_resistance_cold(player_type *player_ptr, concptr name)
+bool activate_resistance_cold(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが白く輝いた...", "The %s grows white."), name);
     (void)set_oppose_cold(player_ptr, randint1(20) + 20, false);
@@ -181,14 +181,14 @@ bool activate_resistance_cold(player_type *player_ptr, concptr name)
  * @param name アイテム名
  * @return 常にTRUE
  */
-bool activate_resistance_pois(player_type *player_ptr, concptr name)
+bool activate_resistance_pois(PlayerType *player_ptr, concptr name)
 {
     msg_format(_("%sが緑に輝いた...", "The %s grows green."), name);
     (void)set_oppose_pois(player_ptr, randint1(20) + 20, false);
     return true;
 }
 
-bool activate_ultimate_resistance(player_type *player_ptr)
+bool activate_ultimate_resistance(PlayerType *player_ptr)
 {
     TIME_EFFECT v = randint1(25) + 25;
     (void)BadStatusSetter(player_ptr).afraidness(0);
index f27c146..c9ec17a 100644 (file)
@@ -2,16 +2,16 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool activate_resistance_elements(player_type *player_ptr);
-bool activate_resistance_acid(player_type *player_ptr, concptr name);
-bool activate_resistance_elec(player_type *player_ptr, concptr name);
-bool activate_resistance_fire(player_type *player_ptr, concptr name);
-bool activate_resistance_cold(player_type *player_ptr, concptr name);
-bool activate_resistance_pois(player_type *player_ptr, concptr name);
-bool activate_acid_ball_and_resistance(player_type *player_ptr, concptr name);
-bool activate_elec_ball_and_resistance(player_type *player_ptr, concptr name);
-bool activate_fire_ball_and_resistance(player_type *player_ptr, concptr name);
-bool activate_cold_ball_and_resistance(player_type *player_ptr, concptr name);
-bool activate_pois_ball_and_resistance(player_type *player_ptr, concptr name);
-bool activate_ultimate_resistance(player_type *player_ptr);
+class PlayerType;
+bool activate_resistance_elements(PlayerType *player_ptr);
+bool activate_resistance_acid(PlayerType *player_ptr, concptr name);
+bool activate_resistance_elec(PlayerType *player_ptr, concptr name);
+bool activate_resistance_fire(PlayerType *player_ptr, concptr name);
+bool activate_resistance_cold(PlayerType *player_ptr, concptr name);
+bool activate_resistance_pois(PlayerType *player_ptr, concptr name);
+bool activate_acid_ball_and_resistance(PlayerType *player_ptr, concptr name);
+bool activate_elec_ball_and_resistance(PlayerType *player_ptr, concptr name);
+bool activate_fire_ball_and_resistance(PlayerType *player_ptr, concptr name);
+bool activate_cold_ball_and_resistance(PlayerType *player_ptr, concptr name);
+bool activate_pois_ball_and_resistance(PlayerType *player_ptr, concptr name);
+bool activate_ultimate_resistance(PlayerType *player_ptr);
index 9051018..cf38b70 100644 (file)
@@ -40,7 +40,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-bool switch_activation(player_type *player_ptr, object_type **o_ptr_ptr, const activation_type *const act_ptr, concptr name)
+bool switch_activation(PlayerType *player_ptr, object_type **o_ptr_ptr, const activation_type *const act_ptr, concptr name)
 {
     object_type *o_ptr = (*o_ptr_ptr);
 
index 7d9077c..2fd8e9d 100644 (file)
@@ -4,5 +4,5 @@
 
 struct activation_type;
 struct object_type;
-struct player_type;
-bool switch_activation(player_type *player_ptr, object_type **o_ptr_ptr, const activation_type *const act_ptr, concptr name);
+class PlayerType;
+bool switch_activation(PlayerType *player_ptr, object_type **o_ptr_ptr, const activation_type *const act_ptr, concptr name);
index a1375c0..3dac170 100644 (file)
@@ -11,7 +11,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool activate_teleport_away(player_type *player_ptr)
+bool activate_teleport_away(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -21,7 +21,7 @@ bool activate_teleport_away(player_type *player_ptr)
     return true;
 }
 
-bool activate_escape(player_type *player_ptr)
+bool activate_escape(PlayerType *player_ptr)
 {
     switch (randint1(13)) {
     case 1:
@@ -54,7 +54,7 @@ bool activate_escape(player_type *player_ptr)
     }
 }
 
-bool activate_teleport_level(player_type *player_ptr)
+bool activate_teleport_level(PlayerType *player_ptr)
 {
     if (!get_check(_("本当に他の階にテレポートしますか?", "Are you sure? (Teleport Level)")))
         return false;
@@ -63,20 +63,20 @@ bool activate_teleport_level(player_type *player_ptr)
     return true;
 }
 
-bool activate_dimension_door(player_type *player_ptr)
+bool activate_dimension_door(PlayerType *player_ptr)
 {
     msg_print(_("次元の扉が開いた。目的地を選んで下さい。", "You open a dimensional gate. Choose a destination."));
     return dimension_door(player_ptr);
 }
 
-bool activate_teleport(player_type *player_ptr)
+bool activate_teleport(PlayerType *player_ptr)
 {
     msg_print(_("周りの空間が歪んでいる...", "It twists space around you..."));
     teleport_player(player_ptr, 100, TELEPORT_SPONTANEOUS);
     return true;
 }
 
-bool activate_phase_door(player_type *player_ptr)
+bool activate_phase_door(PlayerType *player_ptr)
 {
     teleport_player(player_ptr, 10, TELEPORT_SPONTANEOUS);
     return true;
index eaf218e..54b8900 100644 (file)
@@ -1,9 +1,9 @@
 #pragma once
 
-struct player_type;
-bool activate_teleport_away(player_type *player_ptr);
-bool activate_escape(player_type *player_ptr);
-bool activate_teleport_level(player_type *player_ptr);
-bool activate_dimension_door(player_type *player_ptr);
-bool activate_teleport(player_type *player_ptr);
-bool activate_phase_door(player_type *player_ptr);
+class PlayerType;
+bool activate_teleport_away(PlayerType *player_ptr);
+bool activate_escape(PlayerType *player_ptr);
+bool activate_teleport_level(PlayerType *player_ptr);
+bool activate_dimension_door(PlayerType *player_ptr);
+bool activate_teleport(PlayerType *player_ptr);
+bool activate_phase_door(PlayerType *player_ptr);
index 8bf4a47..db30be1 100644 (file)
@@ -4,7 +4,7 @@
 #include "system/object-type-definition.h"
 #include "system/player-type-definition.h"
 
-ae_type *initialize_ae_type(player_type *player_ptr, ae_type *ae_ptr, const INVENTORY_IDX item)
+ae_type *initialize_ae_type(PlayerType *player_ptr, ae_type *ae_ptr, const INVENTORY_IDX item)
 {
     ae_ptr->o_ptr = ref_item(player_ptr, item);
     ae_ptr->lev = k_info[ae_ptr->o_ptr->k_idx].level;
index a7a99e5..f96c5cd 100644 (file)
@@ -13,5 +13,5 @@ typedef struct ae_type {
     int fail;
 } ae_type;
 
-struct player_type;
-ae_type *initialize_ae_type(player_type *player_ptr, ae_type *ae_ptr, const INVENTORY_IDX item);
+class PlayerType;
+ae_type *initialize_ae_type(PlayerType *player_ptr, ae_type *ae_ptr, const INVENTORY_IDX item);
index 90c3593..5d5346e 100644 (file)
@@ -23,7 +23,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-AmuletEnchanter::AmuletEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+AmuletEnchanter::AmuletEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : player_ptr(player_ptr)
     , o_ptr(o_ptr)
     , level(level)
index 8fbafcf..6476d20 100644 (file)
@@ -4,10 +4,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class AmuletEnchanter : EnchanterBase {
 public:
-    AmuletEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    AmuletEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~AmuletEnchanter() = default;
     void apply_magic() override;
 
@@ -18,7 +18,7 @@ protected:
     void give_cursed() override;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     object_type *o_ptr;
     DEPTH level;
     int power;
index 78d1599..f4fa607 100644 (file)
@@ -20,7 +20,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-ArmorEnchanter::ArmorEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+ArmorEnchanter::ArmorEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : AbstractProtectorEnchanter{ o_ptr, level, power }
     , player_ptr(player_ptr)
 {
index f69a40b..7b50ae8 100644 (file)
@@ -5,10 +5,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class ArmorEnchanter : AbstractProtectorEnchanter {
 public:
-    ArmorEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    ArmorEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~ArmorEnchanter() = default;
     void apply_magic() override;
 
@@ -19,6 +19,6 @@ protected:
     void give_cursed() override;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     bool is_high_ego_generated = false;
 };
index e8fb61a..acc4b6a 100644 (file)
@@ -20,7 +20,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-BootsEnchanter::BootsEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+BootsEnchanter::BootsEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : AbstractProtectorEnchanter{ o_ptr, level, power }
     , player_ptr(player_ptr)
 {
index 9a244d8..cc4d695 100644 (file)
@@ -5,10 +5,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class BootsEnchanter : AbstractProtectorEnchanter {
 public:
-    BootsEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    BootsEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~BootsEnchanter() = default;
     void apply_magic() override;
 
@@ -19,5 +19,5 @@ protected:
     void give_cursed() override{};
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index 30083b6..dab001f 100644 (file)
@@ -18,7 +18,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-CloakEnchanter::CloakEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+CloakEnchanter::CloakEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : AbstractProtectorEnchanter{ o_ptr, level, power }
     , player_ptr(player_ptr)
 {
index bf2958a..c4415dc 100644 (file)
@@ -5,10 +5,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class CloakEnchanter : AbstractProtectorEnchanter {
 public:
-    CloakEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    CloakEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~CloakEnchanter() = default;
     void apply_magic() override;
 
@@ -19,5 +19,5 @@ protected:
     void give_cursed() override{};
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index 6cd5ea4..cb9a374 100644 (file)
@@ -18,7 +18,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-CrownEnchanter::CrownEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+CrownEnchanter::CrownEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : AbstractProtectorEnchanter{ o_ptr, level, power }
     , player_ptr(player_ptr)
 {
index 78b7167..eb3ecd0 100644 (file)
@@ -5,10 +5,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class CrownEnchanter : AbstractProtectorEnchanter {
 public:
-    CrownEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    CrownEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~CrownEnchanter() = default;
     void apply_magic() override;
 
@@ -19,5 +19,5 @@ protected:
     void give_cursed() override;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index 55ed969..fb9b42e 100644 (file)
@@ -20,7 +20,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-GlovesEnchanter::GlovesEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+GlovesEnchanter::GlovesEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : AbstractProtectorEnchanter{ o_ptr, level, power }
     , player_ptr(player_ptr)
 {
index a7bf1e8..de3f3be 100644 (file)
@@ -5,10 +5,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class GlovesEnchanter : AbstractProtectorEnchanter {
 public:
-    GlovesEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    GlovesEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~GlovesEnchanter() = default;
     void apply_magic() override;
 
@@ -19,5 +19,5 @@ protected:
     void give_cursed() override{};
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index 67e4387..ae72367 100644 (file)
@@ -20,7 +20,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-HelmEnchanter::HelmEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+HelmEnchanter::HelmEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : AbstractProtectorEnchanter{ o_ptr, level, power }
     , player_ptr(player_ptr)
 {
index e42adac..1f128a6 100644 (file)
@@ -5,10 +5,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class HelmEnchanter : AbstractProtectorEnchanter {
 public:
-    HelmEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    HelmEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~HelmEnchanter() = default;
     void apply_magic() override;
 
@@ -19,5 +19,5 @@ protected:
     void give_cursed() override;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index aac0a47..e94cb53 100644 (file)
@@ -38,7 +38,7 @@
  * @details
  * Hack -- note the special code for various items
  */
-void apply_magic_others(player_type *player_ptr, object_type *o_ptr, int power)
+void apply_magic_others(PlayerType *player_ptr, object_type *o_ptr, int power)
 {
     object_kind *k_ptr = &k_info[o_ptr->k_idx];
 
index e8aec98..dacd633 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-void apply_magic_others(player_type *player_ptr, object_type *o_ptr, int power);
+class PlayerType;
+void apply_magic_others(PlayerType *player_ptr, object_type *o_ptr, int power);
index 264fed6..cc989de 100644 (file)
@@ -23,7 +23,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-RingEnchanter::RingEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+RingEnchanter::RingEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : player_ptr(player_ptr)
     , o_ptr(o_ptr)
     , level(level)
index 3421ec8..3cca710 100644 (file)
@@ -4,10 +4,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class RingEnchanter : EnchanterBase {
 public:
-    RingEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    RingEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~RingEnchanter() = default;
     void apply_magic() override;
 
@@ -18,7 +18,7 @@ protected:
     void give_cursed() override;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     object_type *o_ptr;
     DEPTH level;
     int power;
index 5faa3d9..1132471 100644 (file)
@@ -20,7 +20,7 @@
  * @param level 生成基準階
  * @param power 生成ランク
  */
-ShieldEnchanter::ShieldEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+ShieldEnchanter::ShieldEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
     : AbstractProtectorEnchanter{ o_ptr, level, power }
     , player_ptr(player_ptr)
 {
index 8e24c1a..03091f6 100644 (file)
@@ -5,10 +5,10 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class ShieldEnchanter : AbstractProtectorEnchanter {
 public:
-    ShieldEnchanter(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+    ShieldEnchanter(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
     virtual ~ShieldEnchanter() = default;
     void apply_magic() override;
 
@@ -19,5 +19,5 @@ protected:
     void give_cursed() override{};
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index 149da70..9f95867 100644 (file)
@@ -29,7 +29,7 @@
  * Hack -- note special base damage dice boosting\n
  * Hack -- note special processing for weapon/digger\n
  */
-void apply_magic_weapon(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power)
+void apply_magic_weapon(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power)
 {
     HIT_PROB tohit1 = randint1(5) + (HIT_PROB)m_bonus(5, level);
     HIT_POINT todam1 = randint1(5) + (HIT_POINT)m_bonus(5, level);
index 498f019..82644a5 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-void apply_magic_weapon(player_type *player_ptr, object_type *o_ptr, DEPTH level, int power);
+class PlayerType;
+void apply_magic_weapon(PlayerType *player_ptr, object_type *o_ptr, DEPTH level, int power);
index 865d00c..0bf008d 100644 (file)
@@ -49,7 +49,7 @@
  * @details
  * エゴ&アーティファクトの生成、呪い、pval強化
  */
-void apply_magic_to_object(player_type *player_ptr, object_type *o_ptr, DEPTH lev, BIT_FLAGS mode)
+void apply_magic_to_object(PlayerType *player_ptr, object_type *o_ptr, DEPTH lev, BIT_FLAGS mode)
 {
     if (player_ptr->ppersonality == PERSONALITY_MUNCHKIN)
         lev += randint0(player_ptr->lev / 2 + 10);
index c6f8e2d..1903f7a 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-void apply_magic_to_object(player_type *player_ptr, object_type *o_ptr, DEPTH lev, BIT_FLAGS mode);
+class PlayerType;
+void apply_magic_to_object(PlayerType *player_ptr, object_type *o_ptr, DEPTH lev, BIT_FLAGS mode);
index 4aa422f..f491e65 100644 (file)
@@ -11,7 +11,7 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class EnchanterBase {
 public:
     virtual void apply_magic() = 0;
index f4861b4..9781339 100644 (file)
@@ -59,7 +59,7 @@ CurseTraitType get_curse(int power, object_type *o_ptr)
  * @param chance 呪いの基本確率
  * @param heavy_chance さらに重い呪いとなる確率
  */
-void curse_equipment(player_type *player_ptr, PERCENTAGE chance, PERCENTAGE heavy_chance)
+void curse_equipment(PlayerType *player_ptr, PERCENTAGE chance, PERCENTAGE heavy_chance)
 {
     if (randint1(100) > chance)
         return;
index 5e55ad9..54387fe 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 enum class CurseTraitType;
 CurseTraitType get_curse(int power, object_type *o_ptr);
-void curse_equipment(player_type *player_ptr, PERCENTAGE chance, PERCENTAGE heavy_chance);
+void curse_equipment(PlayerType *player_ptr, PERCENTAGE chance, PERCENTAGE heavy_chance);
index e8c60de..293eb5c 100644 (file)
@@ -267,6 +267,6 @@ struct ego_item_type {
 extern std::vector<ego_item_type> e_info;
 
 struct object_type;
-struct player_type;
+class PlayerType;
 byte get_random_ego(byte slot, bool good);
 void apply_ego(object_type *o_ptr, DEPTH lev);
index 00dc03d..f488ad4 100644 (file)
@@ -47,7 +47,7 @@ int addable_count(smith_data_type *smith_data, std::vector<SmithEssenceType> ess
 /*!
  * @brief 鍛冶クラスコンストラクタ
  */
-Smith::Smith(player_type *player_ptr)
+Smith::Smith(PlayerType *player_ptr)
     : player_ptr(player_ptr)
     , smith_data(PlayerClass(player_ptr).get_specific_data<smith_data_type>())
 {
index aa668ae..70f4f41 100644 (file)
@@ -9,7 +9,7 @@
 #include <unordered_map>
 
 struct object_type;
-struct player_type;
+class PlayerType;
 class ISmithInfo;
 struct essence_drain_type;
 class ItemTester;
@@ -28,7 +28,7 @@ public:
     //! エッセンスとその抽出量を表すタプルのリスト
     using DrainEssenceResult = std::vector<std::tuple<SmithEssenceType, int>>;
 
-    Smith(player_type *player_ptr);
+    Smith(PlayerType *player_ptr);
 
     static const std::vector<SmithEssenceType> &get_essence_list();
     static concptr get_essence_name(SmithEssenceType essence);
@@ -58,6 +58,6 @@ private:
     static const std::vector<essence_drain_type> essence_drain_info_table;
     static const std::vector<std::shared_ptr<ISmithInfo>> smith_info_table;
 
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     std::shared_ptr<smith_data_type> smith_data;
 };
index 03a5f8c..39173c4 100644 (file)
@@ -26,7 +26,7 @@ BasicSmithInfo::BasicSmithInfo(SmithEffectType effect, concptr name, SmithCatego
 {
 }
 
-bool BasicSmithInfo::add_essence(player_type *, object_type *o_ptr, int) const
+bool BasicSmithInfo::add_essence(PlayerType *, object_type *o_ptr, int) const
 {
     o_ptr->smith_effect = effect;
 
@@ -87,7 +87,7 @@ ActivationSmithInfo::ActivationSmithInfo(SmithEffectType effect, concptr name, S
 {
 }
 
-bool ActivationSmithInfo::add_essence(player_type *, object_type *o_ptr, int) const
+bool ActivationSmithInfo::add_essence(PlayerType *, object_type *o_ptr, int) const
 {
     o_ptr->smith_act_idx = this->act_idx;
 
@@ -114,7 +114,7 @@ EnchantWeaponSmithInfo::EnchantWeaponSmithInfo(SmithEffectType effect, concptr n
 {
 }
 
-bool EnchantWeaponSmithInfo::add_essence(player_type *player_ptr, object_type *o_ptr, int) const
+bool EnchantWeaponSmithInfo::add_essence(PlayerType *player_ptr, object_type *o_ptr, int) const
 {
     const auto max_val = player_ptr->lev / 5 + 5;
     if ((o_ptr->to_h >= max_val) && (o_ptr->to_d >= max_val)) {
@@ -141,7 +141,7 @@ EnchantArmourSmithInfo::EnchantArmourSmithInfo(SmithEffectType effect, concptr n
 {
 }
 
-bool EnchantArmourSmithInfo::add_essence(player_type *player_ptr, object_type *o_ptr, int) const
+bool EnchantArmourSmithInfo::add_essence(PlayerType *player_ptr, object_type *o_ptr, int) const
 {
     const auto max_val = player_ptr->lev / 5 + 5;
     if (o_ptr->to_a >= max_val) {
@@ -163,7 +163,7 @@ SustainSmithInfo::SustainSmithInfo(SmithEffectType effect, concptr name, SmithCa
 {
 }
 
-bool SustainSmithInfo::add_essence(player_type *, object_type *o_ptr, int) const
+bool SustainSmithInfo::add_essence(PlayerType *, object_type *o_ptr, int) const
 {
     o_ptr->art_flags.set(TR_IGNORE_ACID);
     o_ptr->art_flags.set(TR_IGNORE_ELEC);
@@ -183,7 +183,7 @@ SlayingGlovesSmithInfo::SlayingGlovesSmithInfo(SmithEffectType effect, concptr n
 {
 }
 
-bool SlayingGlovesSmithInfo::add_essence(player_type *player_ptr, object_type *o_ptr, int number) const
+bool SlayingGlovesSmithInfo::add_essence(PlayerType *player_ptr, object_type *o_ptr, int number) const
 {
     BasicSmithInfo::add_essence(player_ptr, o_ptr, number);
 
index d8aafbe..44e5099 100644 (file)
@@ -12,7 +12,7 @@ enum class SmithCategoryType;
 enum class SmithEssenceType : int16_t;
 enum class RandomArtActType : short;
 
-struct player_type;
+class PlayerType;
 struct object_type;
 
 /*!
@@ -29,7 +29,7 @@ public:
      * @param number 付与を行うエッセンスの個数
      * @return 鍛冶効果の付与に成功した場合は true、失敗した場合は false
      */
-    virtual bool add_essence(player_type *player_ptr, object_type *o_ptr, int number) const = 0;
+    virtual bool add_essence(PlayerType *player_ptr, object_type *o_ptr, int number) const = 0;
 
     /*!
      * @brief 鍛冶効果を消去する
@@ -71,7 +71,7 @@ protected:
 class BasicSmithInfo : public ISmithInfo {
 public:
     BasicSmithInfo(SmithEffectType effect, concptr name, SmithCategoryType category, std::vector<SmithEssenceType> need_essences, int consumption, TrFlags add_flags);
-    virtual bool add_essence(player_type *player_ptr, object_type *o_ptr, int number) const override;
+    virtual bool add_essence(PlayerType *player_ptr, object_type *o_ptr, int number) const override;
     virtual void erase_essence(object_type *o_ptr) const override;
     virtual TrFlags tr_flags() const override;
     virtual bool can_give_smith_effect(const object_type *o_ptr) const final override;
@@ -88,7 +88,7 @@ private:
 class ActivationSmithInfo : public ISmithInfo {
 public:
     ActivationSmithInfo(SmithEffectType effect, concptr name, SmithCategoryType category, std::vector<SmithEssenceType> need_essences, int consumption, RandomArtActType act_idx);
-    virtual bool add_essence(player_type *player_ptr, object_type *o_ptr, int number) const override;
+    virtual bool add_essence(PlayerType *player_ptr, object_type *o_ptr, int number) const override;
     virtual void erase_essence(object_type *) const override;
     virtual bool can_give_smith_effect(const object_type *o_ptr) const override;
 
@@ -103,7 +103,7 @@ private:
 class EnchantWeaponSmithInfo : public ISmithInfo {
 public:
     EnchantWeaponSmithInfo(SmithEffectType effect, concptr name, SmithCategoryType category, std::vector<SmithEssenceType> need_essences, int consumption);
-    virtual bool add_essence(player_type *player_ptr, object_type *o_ptr, int number) const override;
+    virtual bool add_essence(PlayerType *player_ptr, object_type *o_ptr, int number) const override;
     virtual void erase_essence(object_type *) const override {}
     virtual bool can_give_smith_effect(const object_type *o_ptr) const override;
 };
@@ -115,7 +115,7 @@ public:
 class EnchantArmourSmithInfo : public ISmithInfo {
 public:
     EnchantArmourSmithInfo(SmithEffectType effect, concptr name, SmithCategoryType category, std::vector<SmithEssenceType> need_essences, int consumption);
-    virtual bool add_essence(player_type *player_ptr, object_type *o_ptr, int number) const override;
+    virtual bool add_essence(PlayerType *player_ptr, object_type *o_ptr, int number) const override;
     virtual void erase_essence(object_type *) const override {}
     virtual bool can_give_smith_effect(const object_type *o_ptr) const override;
 };
@@ -127,7 +127,7 @@ public:
 class SustainSmithInfo : public ISmithInfo {
 public:
     SustainSmithInfo(SmithEffectType effect, concptr name, SmithCategoryType category, std::vector<SmithEssenceType> need_essences, int consumption);
-    virtual bool add_essence(player_type *player_ptr, object_type *o_ptr, int number) const override;
+    virtual bool add_essence(PlayerType *player_ptr, object_type *o_ptr, int number) const override;
     virtual void erase_essence(object_type *) const override {}
     virtual bool can_give_smith_effect(const object_type *o_ptr) const override;
 };
@@ -139,7 +139,7 @@ public:
 class SlayingGlovesSmithInfo : public BasicSmithInfo {
 public:
     SlayingGlovesSmithInfo(SmithEffectType effect, concptr name, SmithCategoryType category, std::vector<SmithEssenceType> need_essences, int consumption);
-    virtual bool add_essence(player_type *player_ptr, object_type *o_ptr, int number) const override;
+    virtual bool add_essence(PlayerType *player_ptr, object_type *o_ptr, int number) const override;
     virtual void erase_essence(object_type *) const override;
 
 private:
index ffb20ab..152b44f 100644 (file)
@@ -73,7 +73,7 @@ static void print_chainsword_noise(object_type *o_ptr)
  * @param vorpal_cut メッタ斬りにできるかどうか
  * @param vorpal_chance ヴォーパル倍率上昇の機会値
  */
-void process_vorpal_attack(player_type *player_ptr, player_attack_type *pa_ptr, const bool vorpal_cut, const int vorpal_chance)
+void process_vorpal_attack(PlayerType *player_ptr, player_attack_type *pa_ptr, const bool vorpal_cut, const int vorpal_chance)
 {
     if (!vorpal_cut)
         return;
index 98473a1..4a1da30 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct player_attack_type;
-struct player_type;
-void process_vorpal_attack(player_type *player_ptr, player_attack_type *pa_ptr, const bool vorpal_cut, const int vorpal_chance);
+class PlayerType;
+void process_vorpal_attack(PlayerType *player_ptr, player_attack_type *pa_ptr, const bool vorpal_cut, const int vorpal_chance);
index be97026..e4d79ec 100644 (file)
@@ -11,7 +11,7 @@
  * @param o_ptr 判定するオブジェクトの構造体参照ポインタ
  * @return オブジェクトが防具として装備できるならTRUEを返す。
  */
-bool item_tester_hook_wear(player_type *player_ptr, const object_type *o_ptr)
+bool item_tester_hook_wear(PlayerType *player_ptr, const object_type *o_ptr)
 {
     if ((o_ptr->tval == ItemKindType::SOFT_ARMOR) && (o_ptr->sval == SV_ABUNAI_MIZUGI))
         if (player_ptr->psex == SEX_MALE)
index f4e1402..7934bca 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool item_tester_hook_wear(player_type *player_ptr, const object_type *o_ptr);
+class PlayerType;
+bool item_tester_hook_wear(PlayerType *player_ptr, const object_type *o_ptr);
index 6c59a79..3cb897b 100644 (file)
@@ -22,7 +22,7 @@
  * @param o_ptr 判定したいオブジェクトの構造体参照ポインタ
  * @return 食べることが可能ならばTRUEを返す
  */
-bool item_tester_hook_eatable(player_type *player_ptr, const object_type *o_ptr)
+bool item_tester_hook_eatable(PlayerType *player_ptr, const object_type *o_ptr)
 {
     if (o_ptr->tval == ItemKindType::FOOD)
         return true;
@@ -45,7 +45,7 @@ bool item_tester_hook_eatable(player_type *player_ptr, const object_type *o_ptr)
  * @param o_ptr 判定したいオブジェクトの構造体参照ポインタ
  * @return 飲むことが可能ならばTRUEを返す
  */
-bool item_tester_hook_quaff(player_type *player_ptr, const object_type *o_ptr)
+bool item_tester_hook_quaff(PlayerType *player_ptr, const object_type *o_ptr)
 {
     if (o_ptr->tval == ItemKindType::POTION)
         return true;
@@ -62,7 +62,7 @@ bool item_tester_hook_quaff(player_type *player_ptr, const object_type *o_ptr)
  * @param o_ptr 破壊可能かを確認したいオブジェクトの構造体参照ポインタ
  * @return オブジェクトが破壊可能ならばTRUEを返す
  */
-bool can_player_destroy_object(player_type *player_ptr, object_type *o_ptr)
+bool can_player_destroy_object(PlayerType *player_ptr, object_type *o_ptr)
 {
     /* Artifacts cannot be destroyed */
     if (!o_ptr->is_artifact())
index 1d36846..ed5974f 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool item_tester_hook_eatable(player_type *player_ptr, const object_type *o_ptr);
-bool item_tester_hook_quaff(player_type *player_ptr, const object_type *o_ptr);
-bool can_player_destroy_object(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool item_tester_hook_eatable(PlayerType *player_ptr, const object_type *o_ptr);
+bool item_tester_hook_quaff(PlayerType *player_ptr, const object_type *o_ptr);
+bool can_player_destroy_object(PlayerType *player_ptr, object_type *o_ptr);
index 7bf68e5..f5b6287 100644 (file)
@@ -17,7 +17,7 @@
  * @param o_ptr 判定したいオブジェクトの構造体参照ポインタ
  * @return 利用可能ならばTRUEを返す
  */
-bool item_tester_hook_use(player_type *player_ptr, const object_type *o_ptr)
+bool item_tester_hook_use(PlayerType *player_ptr, const object_type *o_ptr)
 {
     if (o_ptr->tval == player_ptr->tval_ammo)
         return true;
@@ -53,7 +53,7 @@ bool item_tester_hook_use(player_type *player_ptr, const object_type *o_ptr)
  * @param o_ptr 判定したいオブ会ジェクトの構造体参照ポインタ
  * @return 学習できる魔道書ならばTRUEを返す
  */
-bool item_tester_learn_spell(player_type *player_ptr, const object_type *o_ptr)
+bool item_tester_learn_spell(PlayerType *player_ptr, const object_type *o_ptr)
 {
     int32_t choices = realm_choices2[enum2i(player_ptr->pclass)];
     if (player_ptr->pclass == PlayerClassType::PRIEST) {
index 8fe6551..d1fbeb0 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool item_tester_hook_use(player_type *player_ptr, const object_type *o_ptr);
-bool item_tester_learn_spell(player_type *player_ptr, const object_type *o_ptr);
+class PlayerType;
+bool item_tester_hook_use(PlayerType *player_ptr, const object_type *o_ptr);
+bool item_tester_learn_spell(PlayerType *player_ptr, const object_type *o_ptr);
 bool item_tester_high_level_book(const object_type *o_ptr);
index 0ddf8f3..fc718b7 100644 (file)
@@ -17,7 +17,7 @@
  * @param o_ptr 対象のオブジェクト構造体ポインタ
  * @return オブジェクトが報酬対象になるならTRUEを返す
  */
-bool object_is_bounty(player_type *player_ptr, object_type *o_ptr)
+bool object_is_bounty(PlayerType *player_ptr, object_type *o_ptr)
 {
     int i;
 
index 4e6b6c6..918aa17 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-bool object_is_bounty(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool object_is_bounty(PlayerType *player_ptr, object_type *o_ptr);
 bool object_is_quest_target(QUEST_IDX quest_idx, object_type *o_ptr);
index 95a6b8d..ada561f 100644 (file)
@@ -13,7 +13,7 @@
  * @param o_ptr 対象のオブジェクト構造体ポインタ
  * @return オブジェクトが適正武器ならばTRUEを返す
  */
-bool object_is_favorite(player_type *player_ptr, const object_type *o_ptr)
+bool object_is_favorite(PlayerType *player_ptr, const object_type *o_ptr)
 {
     /* Only melee weapons match */
     if (!(o_ptr->tval == ItemKindType::POLEARM || o_ptr->tval == ItemKindType::SWORD || o_ptr->tval == ItemKindType::DIGGING || o_ptr->tval == ItemKindType::HAFTED)) {
index b4cf19d..9251928 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool object_is_favorite(player_type *player_ptr, const object_type *o_ptr);
+class PlayerType;
+bool object_is_favorite(PlayerType *player_ptr, const object_type *o_ptr);
index da22fc0..a0a62cf 100644 (file)
@@ -4,7 +4,7 @@
 #include "timed-effect/player-stun.h"
 #include "view/display-messages.h"
 
-ItemUseChecker::ItemUseChecker(player_type* player_ptr)
+ItemUseChecker::ItemUseChecker(PlayerType* player_ptr)
     : player_ptr(player_ptr)
 {
 }
index 9aaa8f5..3aac03e 100644 (file)
@@ -2,14 +2,14 @@
 
 #include <string>
 
-struct player_type;
+class PlayerType;
 class ItemUseChecker {
 public:
-    ItemUseChecker(player_type *player_ptr);
+    ItemUseChecker(PlayerType *player_ptr);
     virtual ~ItemUseChecker() = default;
 
     bool check_stun(std::string_view mes) const;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index 40b78d3..0410a81 100644 (file)
@@ -56,7 +56,7 @@
  * @brief コンストラクタ
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-ObjectQuaffEntity::ObjectQuaffEntity(player_type *player_ptr)
+ObjectQuaffEntity::ObjectQuaffEntity(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index 3828e8d..2269365 100644 (file)
@@ -2,16 +2,16 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ObjectQuaffEntity {
 public:
-    ObjectQuaffEntity(player_type *player_ptr);
+    ObjectQuaffEntity(PlayerType *player_ptr);
     virtual ~ObjectQuaffEntity() = default;
 
     void execute(INVENTORY_IDX item);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 
     bool check_can_quaff();
     bool booze();
index 3788d41..ba680b0 100644 (file)
@@ -71,7 +71,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param item 読むオブジェクトの所持品ID
  */
-ObjectReadEntity::ObjectReadEntity(player_type *player_ptr, INVENTORY_IDX item)
+ObjectReadEntity::ObjectReadEntity(PlayerType *player_ptr, INVENTORY_IDX item)
     : player_ptr(player_ptr)
     , item(item)
 {
index 88f0258..3ce2e44 100644 (file)
@@ -2,16 +2,16 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ObjectReadEntity {
 public:
-    ObjectReadEntity(player_type *player_ptr, INVENTORY_IDX item);
+    ObjectReadEntity(PlayerType *player_ptr, INVENTORY_IDX item);
     virtual ~ObjectReadEntity() = default;
 
     void execute(bool known);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     INVENTORY_IDX item;
 
     bool check_can_read();
index 4da641d..529acd2 100644 (file)
@@ -66,7 +66,7 @@
 #include "view/object-describer.h"
 #include "wizard/wizard-messages.h"
 
-ObjectThrowEntity::ObjectThrowEntity(player_type *player_ptr, object_type *q_ptr, const int delay_factor_val, const int mult, const bool boomerang, const OBJECT_IDX shuriken)
+ObjectThrowEntity::ObjectThrowEntity(PlayerType *player_ptr, object_type *q_ptr, const int delay_factor_val, const int mult, const bool boomerang, const OBJECT_IDX shuriken)
     : q_ptr(q_ptr)
     , player_ptr(player_ptr)
     , shuriken(shuriken)
index 798a4a2..5db2c0f 100644 (file)
 struct grid_type;
 struct monster_type;
 struct object_type;
-struct player_type;
+class PlayerType;
 class ObjectThrowEntity {
 public:
     ObjectThrowEntity() = default;
     ObjectThrowEntity(
-        player_type *player_ptr, object_type *q_ptr, const int delay_factor_val, const int mult, const bool boomerang, const OBJECT_IDX shuriken);
+        PlayerType *player_ptr, object_type *q_ptr, const int delay_factor_val, const int mult, const bool boomerang, const OBJECT_IDX shuriken);
     virtual ~ObjectThrowEntity() = default;
 
     object_type *q_ptr;
@@ -45,7 +45,7 @@ public:
     void drop_thrown_item();
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     OBJECT_IDX shuriken;
     int mult;
     int msec;
index 3219de1..cf38e05 100644 (file)
@@ -33,7 +33,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param item 使うオブジェクトの所持品ID
  */
-ObjectUseEntity::ObjectUseEntity(player_type* player_ptr, INVENTORY_IDX item)
+ObjectUseEntity::ObjectUseEntity(PlayerType* player_ptr, INVENTORY_IDX item)
     : player_ptr(player_ptr)
     , item(item)
 {
index f6e8a5e..4258361 100644 (file)
@@ -2,16 +2,16 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ObjectUseEntity {
 public:
-    ObjectUseEntity(player_type *player_ptr, INVENTORY_IDX item);
+    ObjectUseEntity(PlayerType *player_ptr, INVENTORY_IDX item);
     virtual ~ObjectUseEntity() = default;
 
     void execute();
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     INVENTORY_IDX item;
 
     bool check_can_use();
index 1baf726..7a6e490 100644 (file)
@@ -32,7 +32,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param item 使うオブジェクトの所持品ID
  */
-ObjectZapRodEntity::ObjectZapRodEntity(player_type* player_ptr)
+ObjectZapRodEntity::ObjectZapRodEntity(PlayerType* player_ptr)
     : player_ptr(player_ptr)
 {
 }
index be4dcb3..d674da5 100644 (file)
@@ -2,16 +2,16 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ObjectZapRodEntity {
 public:
-    ObjectZapRodEntity(player_type *player_ptr);
+    ObjectZapRodEntity(PlayerType *player_ptr);
     virtual ~ObjectZapRodEntity() = default;
 
     void execute(INVENTORY_IDX item);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 
     bool check_can_zap();
 };
index 16157a8..44a8abd 100644 (file)
@@ -25,7 +25,7 @@
 #include "view/display-messages.h"
 #include "view/object-describer.h"
 
-ObjectZapWandEntity::ObjectZapWandEntity(player_type *player_ptr)
+ObjectZapWandEntity::ObjectZapWandEntity(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index 9494858..74299e7 100644 (file)
@@ -2,16 +2,16 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ObjectZapWandEntity {
 public:
-    ObjectZapWandEntity(player_type *player_ptr);
+    ObjectZapWandEntity(PlayerType *player_ptr);
     virtual ~ObjectZapWandEntity() = default;
 
     void execute(INVENTORY_IDX item);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 
     bool check_can_zap() const;
 };
index 8332525..08b2532 100644 (file)
@@ -25,7 +25,7 @@ TvalItemTester::TvalItemTester(ItemKindType tval)
  * @param test_func そのオブジェクトが条件に合うならtrueを返すメンバ関数を指定する
  */
 FuncItemTester::FuncItemTester(TestMemberFunctionPtr test_func)
-    : test_func([f = test_func](player_type *, const object_type *o_ptr) { return (o_ptr->*f)(); })
+    : test_func([f = test_func](PlayerType *, const object_type *o_ptr) { return (o_ptr->*f)(); })
 {
 }
 
@@ -35,17 +35,17 @@ FuncItemTester::FuncItemTester(TestMemberFunctionPtr test_func)
  * @param test_func 引数に object_type へのポインタを取り、そのオブジェクトが条件に合うならtrueを返す関数を指定する
  */
 FuncItemTester::FuncItemTester(std::function<bool(const object_type *)> test_func)
-    : test_func([f = std::move(test_func)](player_type *, const object_type *o_ptr) { return f(o_ptr); })
+    : test_func([f = std::move(test_func)](PlayerType *, const object_type *o_ptr) { return f(o_ptr); })
 {
 }
 
 /*!
  * @brief Construct a new Func Item Tester:: Func Item Tester object
  *
- * @param test_func 引数に player_type へのポインタと object_type へのポインタを取り、そのオブジェクトが条件に合うならtrueを返す関数を指定する
- * @param player_ptr test_func の player_type へのポインタの引数に対して渡すポインタを指定する
+ * @param test_func 引数に PlayerType へのポインタと object_type へのポインタを取り、そのオブジェクトが条件に合うならtrueを返す関数を指定する
+ * @param player_ptr test_func の PlayerType へのポインタの引数に対して渡すポインタを指定する
  */
-FuncItemTester::FuncItemTester(std::function<bool(player_type *, const object_type *)> test_func, player_type *player_ptr)
+FuncItemTester::FuncItemTester(std::function<bool(PlayerType *, const object_type *)> test_func, PlayerType *player_ptr)
     : test_func(std::move(test_func))
     , player_ptr(player_ptr)
 {
index a283bc1..bab7af2 100644 (file)
@@ -6,7 +6,7 @@
 #include <memory>
 
 struct object_type;
-struct player_type;
+class PlayerType;
 
 /*!
  * @brief アイテムの絞り込み条件をテストする基底クラス
@@ -73,11 +73,11 @@ public:
     using TestMemberFunctionPtr = bool (object_type::*)() const;
     explicit FuncItemTester(TestMemberFunctionPtr test_func);
     explicit FuncItemTester(std::function<bool(const object_type *)> test_func);
-    explicit FuncItemTester(std::function<bool(player_type *, const object_type *)> test_func, player_type *player_ptr);
+    explicit FuncItemTester(std::function<bool(PlayerType *, const object_type *)> test_func, PlayerType *player_ptr);
 
 private:
     virtual bool okay_impl(const object_type *o_ptr) const;
 
-    std::function<bool(player_type *, const object_type *)> test_func;
-    player_type *player_ptr;
+    std::function<bool(PlayerType *, const object_type *)> test_func;
+    PlayerType *player_ptr;
 };
index 1cff56c..73870f4 100644 (file)
@@ -15,7 +15,7 @@
  * @brief 10ゲームターンが進行する毎に光源の寿命を減らす処理
  * / Handle burning fuel every 10 game turns
  */
-void reduce_lite_life(player_type* player_ptr)
+void reduce_lite_life(PlayerType* player_ptr)
 {
     object_type* o_ptr = &player_ptr->inventory_list[INVEN_LITE];
     if (o_ptr->tval != ItemKindType::LITE)
@@ -38,7 +38,7 @@ void reduce_lite_life(player_type* player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param o_ptr 現在光源として使っているオブジェクトの構造体参照ポインタ
  */
-void notice_lite_change(player_type* player_ptr, object_type* o_ptr)
+void notice_lite_change(PlayerType* player_ptr, object_type* o_ptr)
 {
     if ((o_ptr->xtra4 < 100) || (!(o_ptr->xtra4 % 100))) {
         player_ptr->window_flags |= (PW_EQUIP);
index 65776d1..981fc2c 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-void reduce_lite_life(player_type *player_ptr);
-void notice_lite_change(player_type* player_ptr, object_type* o_ptr);
+class PlayerType;
+void reduce_lite_life(PlayerType *player_ptr);
+void notice_lite_change(PlayerType* player_ptr, object_type* o_ptr);
index dfdbb57..4e5bb3a 100644 (file)
@@ -246,7 +246,7 @@ bool ObjectBreaker::can_destroy(object_type *o_ptr) const
  *    o_ptr --- pointer to the potion object.
  * </pre>
  */
-bool potion_smash_effect(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, KIND_OBJECT_IDX k_idx)
+bool potion_smash_effect(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, KIND_OBJECT_IDX k_idx)
 {
     int radius = 2;
     AttributeType dt = AttributeType::NONE;
@@ -393,7 +393,7 @@ bool potion_smash_effect(player_type *player_ptr, MONSTER_IDX who, POSITION y, P
  * @details
  * Note that artifacts never break, see the "drop_near()" function.
  */
-PERCENTAGE breakage_chance(player_type *player_ptr, object_type *o_ptr, bool has_archer_bonus, SPELL_IDX snipe_type)
+PERCENTAGE breakage_chance(PlayerType *player_ptr, object_type *o_ptr, bool has_archer_bonus, SPELL_IDX snipe_type)
 {
     /* Examine the snipe type */
     if (snipe_type) {
index b8d57ca..9e6711d 100644 (file)
@@ -4,10 +4,10 @@
 #include "object-enchant/tr-types.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 
-bool potion_smash_effect(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, KIND_OBJECT_IDX k_idx);
-PERCENTAGE breakage_chance(player_type *player_ptr, object_type *o_ptr, bool has_archer_bonus, SPELL_IDX snipe_type);
+bool potion_smash_effect(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x, KIND_OBJECT_IDX k_idx);
+PERCENTAGE breakage_chance(PlayerType *player_ptr, object_type *o_ptr, bool has_archer_bonus, SPELL_IDX snipe_type);
 
 class ObjectBreaker {
 protected:
index 57e08ef..47bd8e0 100644 (file)
@@ -207,7 +207,7 @@ char index_to_label(int i) { return (i < INVEN_MAIN_HAND) ? (I2A(i)) : (I2A(i -
  * @param o_ptr 名称を取得する元のオブジェクト構造体参照ポインタ
  * @return 対応する装備部位ID
  */
-int16_t wield_slot(player_type *player_ptr, const object_type *o_ptr)
+int16_t wield_slot(PlayerType *player_ptr, const object_type *o_ptr)
 {
     switch (o_ptr->tval) {
     case ItemKindType::DIGGING:
@@ -278,7 +278,7 @@ int16_t wield_slot(player_type *player_ptr, const object_type *o_ptr)
  * @param book_sval ベースアイテムのsval
  * @return 使用可能な魔法書ならばTRUEを返す。
  */
-bool check_book_realm(player_type *player_ptr, const ItemKindType book_tval, const OBJECT_SUBTYPE_VALUE book_sval)
+bool check_book_realm(PlayerType *player_ptr, const ItemKindType book_tval, const OBJECT_SUBTYPE_VALUE book_sval)
 {
     if (book_tval < ItemKindType::LIFE_BOOK)
         return false;
@@ -292,7 +292,7 @@ bool check_book_realm(player_type *player_ptr, const ItemKindType book_tval, con
     return (get_realm1_book(player_ptr) == book_tval) || (get_realm2_book(player_ptr) == book_tval);
 }
 
-object_type *ref_item(player_type *player_ptr, INVENTORY_IDX item)
+object_type *ref_item(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     return item >= 0 ? &player_ptr->inventory_list[item] : &(floor_ptr->o_list[0 - item]);
index 98795c4..15060a8 100644 (file)
@@ -6,10 +6,10 @@
 #define OBJ_GOLD_LIST 480 /* First "gold" entry */
 
 struct object_type;
-struct player_type;
+class PlayerType;
 concptr activation_explanation(object_type *o_ptr);
 char index_to_label(int i);
-int16_t wield_slot(player_type *player_ptr, const object_type *o_ptr);
-bool check_book_realm(player_type *player_ptr, const ItemKindType book_tval, const OBJECT_SUBTYPE_VALUE book_sval);
-object_type *ref_item(player_type *player_ptr, INVENTORY_IDX item);
+int16_t wield_slot(PlayerType *player_ptr, const object_type *o_ptr);
+bool check_book_realm(PlayerType *player_ptr, const ItemKindType book_tval, const OBJECT_SUBTYPE_VALUE book_sval);
+object_type *ref_item(PlayerType *player_ptr, INVENTORY_IDX item);
 TERM_COLOR object_attr(object_type *o_ptr);
index ff632b1..d51ab78 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 int32_t flag_cost(const object_type *o_ptr, int plusses);
index bcfbb8b..3308359 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 PRICE object_value(const object_type *o_ptr);
 PRICE object_value_real(const object_type *o_ptr);
index 5608a65..fe2a088 100644 (file)
@@ -45,7 +45,7 @@
  * Calculate spell damages
  * @return 警告を行う
  */
-object_type *choose_warning_item(player_type *player_ptr)
+object_type *choose_warning_item(PlayerType *player_ptr)
 {
     int choices[INVEN_TOTAL - INVEN_MAIN_HAND];
 
@@ -77,7 +77,7 @@ object_type *choose_warning_item(player_type *player_ptr)
  * @param dam 基本ダメージ
  * @param max 算出した最大ダメージを返すポインタ
  */
-static void spell_damcalc(player_type *player_ptr, monster_type *m_ptr, AttributeType typ, HIT_POINT dam, int *max)
+static void spell_damcalc(PlayerType *player_ptr, monster_type *m_ptr, AttributeType typ, HIT_POINT dam, int *max)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
     int rlev = r_ptr->level;
@@ -250,7 +250,7 @@ static void spell_damcalc(player_type *player_ptr, monster_type *m_ptr, Attribut
  * @param m_idx 魔法を行使するモンスターのID
  * @param max 算出した最大ダメージを返すポインタ
  */
-static void spell_damcalc_by_spellnum(player_type *player_ptr, MonsterAbilityType ms_type, AttributeType typ, MONSTER_IDX m_idx, int *max)
+static void spell_damcalc_by_spellnum(PlayerType *player_ptr, MonsterAbilityType ms_type, AttributeType typ, MONSTER_IDX m_idx, int *max)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     HIT_POINT dam = monspell_damage(player_ptr, ms_type, m_idx, DAM_MAX);
@@ -264,7 +264,7 @@ static void spell_damcalc_by_spellnum(player_type *player_ptr, MonsterAbilityTyp
  * @param blow_ptr モンスターの打撃能力の構造体参照ポインタ
  * @return 算出された最大ダメージを返す。
  */
-static int blow_damcalc(monster_type *m_ptr, player_type *player_ptr, monster_blow *blow_ptr)
+static int blow_damcalc(monster_type *m_ptr, PlayerType *player_ptr, monster_blow *blow_ptr)
 {
     int dam = blow_ptr->d_dice * blow_ptr->d_side;
     int dummy_max = 0;
@@ -339,7 +339,7 @@ static int blow_damcalc(monster_type *m_ptr, player_type *player_ptr, monster_bl
  * @param yy 危険性を調査するマスのY座標
  * @return 警告を無視して進むことを選択するかか問題が無ければTRUE、警告に従ったならFALSEを返す。
  */
-bool process_warning(player_type *player_ptr, POSITION xx, POSITION yy)
+bool process_warning(PlayerType *player_ptr, POSITION xx, POSITION yy)
 {
     POSITION mx, my;
     grid_type *g_ptr;
index 417eb13..cb662a5 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-object_type *choose_warning_item(player_type *player_ptr);
-bool process_warning(player_type *player_ptr, POSITION xx, POSITION yy);
+class PlayerType;
+object_type *choose_warning_item(PlayerType *player_ptr);
+bool process_warning(PlayerType *player_ptr, POSITION xx, POSITION yy);
index 88d853d..2bf7a8d 100644 (file)
@@ -32,7 +32,7 @@
  * @param mode 表示オプション
  * @return 特筆すべき情報が一つでもあった場合TRUE、一つもなく表示がキャンセルされた場合FALSEを返す。
  */
-bool screen_object(player_type *player_ptr, object_type *o_ptr, BIT_FLAGS mode)
+bool screen_object(PlayerType *player_ptr, object_type *o_ptr, BIT_FLAGS mode)
 {
     char temp[70 * 20];
     concptr info[128];
index 2342789..1374bd1 100644 (file)
@@ -5,5 +5,5 @@
 #define SCROBJ_FAKE_OBJECT 0x00000001
 #define SCROBJ_FORCE_DETAIL 0x00000002
 struct object_type;
-struct player_type;
-bool screen_object(player_type *player_ptr, object_type *o_ptr, BIT_FLAGS mode);
+class PlayerType;
+bool screen_object(PlayerType *player_ptr, object_type *o_ptr, BIT_FLAGS mode);
index 4d2d189..4d18457 100644 (file)
@@ -42,7 +42,7 @@ void object_known(object_type *o_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param o_ptr *鑑定*済にするオブジェクトの構造体参照ポインタ
  */
-void object_aware(player_type *player_ptr, object_type *o_ptr)
+void object_aware(PlayerType *player_ptr, object_type *o_ptr)
 {
     const bool is_already_awared = o_ptr->is_aware();
 
index da024a7..5827a7a 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct object_type;
-struct player_type;
+class PlayerType;
 void object_known(object_type *o_ptr);
-void object_aware(player_type *player_ptr, object_type *o_ptr);
+void object_aware(PlayerType *player_ptr, object_type *o_ptr);
 void object_tried(object_type *o_ptr);
index 88b0c4e..7e4e46d 100644 (file)
@@ -32,7 +32,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param heavy 重度の擬似鑑定を行うならばTRUE
  */
-static void sense_inventory_aux(player_type *player_ptr, INVENTORY_IDX slot, bool heavy)
+static void sense_inventory_aux(PlayerType *player_ptr, INVENTORY_IDX slot, bool heavy)
 {
     object_type *o_ptr = &player_ptr->inventory_list[slot];
     GAME_TEXT o_name[MAX_NLEN];
@@ -127,7 +127,7 @@ static void sense_inventory_aux(player_type *player_ptr, INVENTORY_IDX slot, boo
  *   Class 4 = Ranger  --> slow but heavy  (changed!)\n
  *   Class 5 = Paladin --> slow but heavy\n
  */
-void sense_inventory1(player_type *player_ptr)
+void sense_inventory1(PlayerType *player_ptr)
 {
     PLAYER_LEVEL plev = player_ptr->lev;
     bool heavy = false;
@@ -299,7 +299,7 @@ void sense_inventory1(player_type *player_ptr)
 /*!
  * @brief 1プレイヤーターン毎に武器、防具以外の擬似鑑定が行われるかを判定する。
  */
-void sense_inventory2(player_type *player_ptr)
+void sense_inventory2(PlayerType *player_ptr)
 {
     PLAYER_LEVEL plev = player_ptr->lev;
     object_type *o_ptr;
index 3dfeb3f..025d3fc 100644 (file)
@@ -3,8 +3,8 @@
 #include "object-enchant/item-feeling.h"
 
 struct object_type;
-struct player_type;
-void sense_inventory1(player_type *player_ptr);
-void sense_inventory2(player_type* player_ptr);
+class PlayerType;
+void sense_inventory1(PlayerType *player_ptr);
+void sense_inventory2(PlayerType* player_ptr);
 item_feel_type pseudo_value_check_heavy(object_type *o_ptr);
 item_feel_type pseudo_value_check_light(object_type *o_ptr);
index e379b0a..5811529 100644 (file)
@@ -33,7 +33,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param monap_ptr モンスターからプレイヤーへの直接攻撃構造体への参照ポインタ
  */
-void check_fall_off_horse(player_type *player_ptr, monap_type *monap_ptr)
+void check_fall_off_horse(PlayerType *player_ptr, monap_type *monap_ptr)
 {
     if ((player_ptr->riding == 0) || (monap_ptr->damage == 0))
         return;
@@ -53,7 +53,7 @@ void check_fall_off_horse(player_type *player_ptr, monap_type *monap_ptr)
  * @return FALSEなら落馬しないことで確定、TRUEなら処理続行
  * @details レベルの低い乗馬からは落馬しにくい
  */
-static bool calc_fall_off_possibility(player_type *player_ptr, const HIT_POINT dam, const bool force, monster_race *r_ptr)
+static bool calc_fall_off_possibility(PlayerType *player_ptr, const HIT_POINT dam, const bool force, monster_race *r_ptr)
 {
     if (force)
         return true;
@@ -83,7 +83,7 @@ static bool calc_fall_off_possibility(player_type *player_ptr, const HIT_POINT d
  * @param force TRUEならば強制的に落馬する
  * @return 実際に落馬したらTRUEを返す
  */
-bool process_fall_off_horse(player_type *player_ptr, HIT_POINT dam, bool force)
+bool process_fall_off_horse(PlayerType *player_ptr, HIT_POINT dam, bool force)
 {
     POSITION sy = 0;
     POSITION sx = 0;
index 8f8c7c5..31277d1 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 
 typedef struct monap_type monap_type;
-struct player_type;
-void check_fall_off_horse(player_type *player_ptr, monap_type *monap_ptr);
-bool process_fall_off_horse(player_type *player_ptr, HIT_POINT dam, bool force);
+class PlayerType;
+void check_fall_off_horse(PlayerType *player_ptr, monap_type *monap_ptr);
+bool process_fall_off_horse(PlayerType *player_ptr, HIT_POINT dam, bool force);
index 95f3302..c01ba4b 100644 (file)
@@ -24,7 +24,7 @@ int total_friends = 0;
  * @param now_riding trueなら下馬処理、falseならば騎乗処理
  * @return 可能ならばtrueを返す
  */
-bool can_player_ride_pet(player_type *player_ptr, grid_type *g_ptr, bool now_riding)
+bool can_player_ride_pet(PlayerType *player_ptr, grid_type *g_ptr, bool now_riding)
 {
     bool old_character_xtra = w_ptr->character_xtra;
     MONSTER_IDX old_riding = player_ptr->riding;
@@ -64,7 +64,7 @@ bool can_player_ride_pet(player_type *player_ptr, grid_type *g_ptr, bool now_rid
  * @brief ペットの維持コスト計算
  * @return 維持コスト(%)
  */
-PERCENTAGE calculate_upkeep(player_type *player_ptr)
+PERCENTAGE calculate_upkeep(PlayerType *player_ptr)
 {
     bool has_a_unique = false;
     DEPTH total_friend_levels = 0;
index 652d00e..7a837f8 100644 (file)
@@ -43,6 +43,6 @@ enum pet_permission {
 extern int total_friends;
 
 struct grid_type;;
-struct player_type;
-bool can_player_ride_pet(player_type *player_ptr, grid_type *g_ptr, bool now_riding);
-PERCENTAGE calculate_upkeep(player_type *player_ptr);
+class PlayerType;
+bool can_player_ride_pet(PlayerType *player_ptr, grid_type *g_ptr, bool now_riding);
+PERCENTAGE calculate_upkeep(PlayerType *player_ptr);
index f800325..0ed6941 100644 (file)
@@ -13,7 +13,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerCharisma::PlayerCharisma(player_type *player_ptr)
+PlayerCharisma::PlayerCharisma(PlayerType *player_ptr)
     : PlayerBasicStatistics(player_ptr)
 {
 }
index 0e85028..21012e9 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "player-status/player-basic-statistics.h"
 
-struct player_type;
+class PlayerType;
 class PlayerCharisma : public PlayerBasicStatistics {
 public:
-    PlayerCharisma(player_type *player_ptr);
+    PlayerCharisma(PlayerType *player_ptr);
 
     BIT_FLAGS get_all_flags() override;
     BIT_FLAGS get_bad_flags() override;
index b9ccd3e..ccc7133 100644 (file)
@@ -14,7 +14,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerConstitution::PlayerConstitution(player_type *player_ptr)
+PlayerConstitution::PlayerConstitution(PlayerType *player_ptr)
     : PlayerBasicStatistics(player_ptr)
 {
 }
index 2ccf63c..668f857 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "player-status/player-basic-statistics.h"
 
-struct player_type;
+class PlayerType;
 class PlayerConstitution : public PlayerBasicStatistics {
 public:
-    PlayerConstitution(player_type *player_ptr);
+    PlayerConstitution(PlayerType *player_ptr);
 
 protected:
     void set_locals() override;
index 4048751..485bbb0 100644 (file)
@@ -14,7 +14,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerDexterity::PlayerDexterity(player_type* player_ptr)
+PlayerDexterity::PlayerDexterity(PlayerType* player_ptr)
     : PlayerBasicStatistics(player_ptr)
 {
 }
index c109841..e25b266 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "player-status/player-basic-statistics.h"
 
-struct player_type;
+class PlayerType;
 class PlayerDexterity : public PlayerBasicStatistics {
 public:
-    PlayerDexterity(player_type *player_ptr);
+    PlayerDexterity(PlayerType *player_ptr);
 
 protected:
     void set_locals() override;
index d99a309..ac38451 100644 (file)
@@ -14,7 +14,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerIntelligence::PlayerIntelligence(player_type *player_ptr)
+PlayerIntelligence::PlayerIntelligence(PlayerType *player_ptr)
     : PlayerBasicStatistics(player_ptr)
 {
 }
index a250886..b0d32a0 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "player-status/player-basic-statistics.h"
 
-struct player_type;
+class PlayerType;
 class PlayerIntelligence : public PlayerBasicStatistics {
 public:
-    PlayerIntelligence(player_type *player_ptr);
+    PlayerIntelligence(PlayerType *player_ptr);
 
 protected:
     void set_locals() override;
index af0cdfd..af8236c 100644 (file)
@@ -14,7 +14,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerStrength::PlayerStrength(player_type *player_ptr)
+PlayerStrength::PlayerStrength(PlayerType *player_ptr)
     : PlayerBasicStatistics(player_ptr)
 {
 }
index 47455f4..1167fcd 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "player-status/player-basic-statistics.h"
 
-struct player_type;
+class PlayerType;
 class PlayerStrength : public PlayerBasicStatistics {
 public:
-    PlayerStrength(player_type *player_ptr);
+    PlayerStrength(PlayerType *player_ptr);
 
 protected:
     void set_locals() override;
index ad71dee..cd41a14 100644 (file)
@@ -12,7 +12,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerWisdom::PlayerWisdom(player_type *player_ptr)
+PlayerWisdom::PlayerWisdom(PlayerType *player_ptr)
     : PlayerBasicStatistics(player_ptr)
 {
 }
index 563b190..f88e90b 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "player-status/player-basic-statistics.h"
 
-struct player_type;
+class PlayerType;
 class PlayerWisdom : public PlayerBasicStatistics {
 public:
-    PlayerWisdom(player_type *player_ptr);
+    PlayerWisdom(PlayerType *player_ptr);
 
 protected:
     void set_locals() override;
index 86415e7..fae2783 100644 (file)
@@ -47,7 +47,7 @@
  * @details
  * カオス属性や混乱の手
  */
-static void attack_confuse(player_type *player_ptr, player_attack_type *pa_ptr, bool can_resist = true)
+static void attack_confuse(PlayerType *player_ptr, player_attack_type *pa_ptr, bool can_resist = true)
 {
     if (player_ptr->special_attack & ATTACK_CONFUSE) {
         player_ptr->special_attack &= ~(ATTACK_CONFUSE);
@@ -77,7 +77,7 @@ static void attack_confuse(player_type *player_ptr, player_attack_type *pa_ptr,
  * @details
  * 魔術属性
  */
-static void attack_stun(player_type *player_ptr, player_attack_type *pa_ptr, bool can_resist = true)
+static void attack_stun(PlayerType *player_ptr, player_attack_type *pa_ptr, bool can_resist = true)
 {
     monster_race *r_ptr = pa_ptr->r_ptr;
     if (any_bits(r_ptr->flags3, RF3_NO_STUN)) {
@@ -100,7 +100,7 @@ static void attack_stun(player_type *player_ptr, player_attack_type *pa_ptr, boo
  * @details
  * 魔術属性
  */
-static void attack_scare(player_type *player_ptr, player_attack_type *pa_ptr, bool can_resist = true)
+static void attack_scare(PlayerType *player_ptr, player_attack_type *pa_ptr, bool can_resist = true)
 {
     monster_race *r_ptr = pa_ptr->r_ptr;
     if (any_bits(r_ptr->flags3, RF3_NO_FEAR)) {
@@ -122,7 +122,7 @@ static void attack_scare(player_type *player_ptr, player_attack_type *pa_ptr, bo
  * @details
  * 魔術属性
  */
-static void attack_dispel(player_type *player_ptr, player_attack_type *pa_ptr)
+static void attack_dispel(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     if (pa_ptr->r_ptr->ability_flags.has_none_of(RF_ABILITY_ATTACK_MASK) && pa_ptr->r_ptr->ability_flags.has_none_of(RF_ABILITY_INDIRECT_MASK))
         return;
@@ -150,7 +150,7 @@ static void attack_dispel(player_type *player_ptr, player_attack_type *pa_ptr)
  * @details
  * 魔術属性
  */
-static void attack_probe(player_type *player_ptr, player_attack_type *pa_ptr)
+static void attack_probe(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     msg_print(_("刃が敵を調査した...", "The blade probed your enemy..."));
     msg_print(nullptr);
@@ -167,7 +167,7 @@ static void attack_probe(player_type *player_ptr, player_attack_type *pa_ptr)
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  * @return 抵抗されたらTRUE、アウェイされるならFALSE
  */
-static bool judge_tereprt_resistance(player_type *player_ptr, player_attack_type *pa_ptr)
+static bool judge_tereprt_resistance(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     monster_race *r_ptr = pa_ptr->r_ptr;
     if ((r_ptr->flagsr & RFR_RES_TELE) == 0)
@@ -198,7 +198,7 @@ static bool judge_tereprt_resistance(player_type *player_ptr, player_attack_type
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  * @param num 現在の攻撃回数 (テレポートしてしまったら追加攻撃できないのでその補正)
  */
-static void attack_teleport_away(player_type *player_ptr, player_attack_type *pa_ptr, int *num)
+static void attack_teleport_away(PlayerType *player_ptr, player_attack_type *pa_ptr, int *num)
 {
     if (judge_tereprt_resistance(player_ptr, pa_ptr))
         return;
@@ -216,7 +216,7 @@ static void attack_teleport_away(player_type *player_ptr, player_attack_type *pa
  * @param y モンスターのY座標
  * @param x モンスターのX座標
  */
-static void attack_polymorph(player_type *player_ptr, player_attack_type *pa_ptr, POSITION y, POSITION x)
+static void attack_polymorph(PlayerType *player_ptr, player_attack_type *pa_ptr, POSITION y, POSITION x)
 {
     monster_race *r_ptr = pa_ptr->r_ptr;
     if (((r_ptr->flags1 & (RF1_UNIQUE | RF1_QUESTOR)) != 0) || ((r_ptr->flagsr & RFR_EFF_RES_CHAO_MASK) != 0))
@@ -238,7 +238,7 @@ static void attack_polymorph(player_type *player_ptr, player_attack_type *pa_ptr
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-static void attack_golden_hammer(player_type *player_ptr, player_attack_type *pa_ptr)
+static void attack_golden_hammer(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[pa_ptr->m_idx];
@@ -263,7 +263,7 @@ static void attack_golden_hammer(player_type *player_ptr, player_attack_type *pa
  * @param x モンスターのX座標
  * @param num 現在の攻撃回数
  */
-void change_monster_stat(player_type *player_ptr, player_attack_type *pa_ptr, const POSITION y, const POSITION x, int *num)
+void change_monster_stat(PlayerType *player_ptr, player_attack_type *pa_ptr, const POSITION y, const POSITION x, int *num)
 {
     monster_race *r_ptr = &r_info[pa_ptr->m_ptr->r_idx];
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
index bf1c27d..f17e57e 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 struct player_attack_type;
-struct player_type;
-void change_monster_stat(player_type *player_ptr, player_attack_type *pa_ptr, const POSITION y, const POSITION x, int *num);
+class PlayerType;
+void change_monster_stat(PlayerType *player_ptr, player_attack_type *pa_ptr, const POSITION y, const POSITION x, int *num);
index dfdf6ef..9ae9d0c 100644 (file)
@@ -25,7 +25,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-void decide_blood_sucking(player_type *player_ptr, player_attack_type *pa_ptr)
+void decide_blood_sucking(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     bool is_blood_sucker = pa_ptr->flags.has(TR_VAMPIRIC);
     is_blood_sucker |= pa_ptr->chaos_effect == CE_VAMPIRIC;
@@ -56,7 +56,7 @@ void calc_drain(player_attack_type *pa_ptr)
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  * @param is_human モンスターが人間かどうか
  */
-static void drain_muramasa(player_type *player_ptr, player_attack_type *pa_ptr, const bool is_human)
+static void drain_muramasa(PlayerType *player_ptr, player_attack_type *pa_ptr, const bool is_human)
 {
     if (!is_human)
         return;
@@ -95,7 +95,7 @@ static void drain_muramasa(player_type *player_ptr, player_attack_type *pa_ptr,
  * @param drain_msg 吸血をした旨のメッセージを表示するかどうか
  * @details 1行目の5がマジックナンバーで良く分からなかったので、取り敢えず元々あったコメントをベースに定数宣言しておいた
  */
-static void drain_result(player_type *player_ptr, player_attack_type *pa_ptr, bool *drain_msg)
+static void drain_result(PlayerType *player_ptr, player_attack_type *pa_ptr, bool *drain_msg)
 {
     const int real_drain = 5;
     if (pa_ptr->drain_result <= real_drain)
@@ -137,7 +137,7 @@ static void drain_result(player_type *player_ptr, player_attack_type *pa_ptr, bo
  * @param drain_msg 吸血をした旨のメッセージを表示するかどうか
  * @details モンスターが死んだ場合、(ゲームのフレーバー的に)吸血しない
  */
-void process_drain(player_type *player_ptr, player_attack_type *pa_ptr, const bool is_human, bool *drain_msg)
+void process_drain(PlayerType *player_ptr, player_attack_type *pa_ptr, const bool is_human, bool *drain_msg)
 {
     if (!pa_ptr->can_drain || (pa_ptr->drain_result <= 0))
         return;
index d77b014..ee1a252 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct player_attack_type;
-struct player_type;
-void decide_blood_sucking(player_type *player_ptr, player_attack_type *pa_ptr);
+class PlayerType;
+void decide_blood_sucking(PlayerType *player_ptr, player_attack_type *pa_ptr);
 void calc_drain(player_attack_type *pa_ptr);
-void process_drain(player_type *player_ptr, player_attack_type *pa_ptr, const bool is_human, bool *drain_msg);
+void process_drain(PlayerType *player_ptr, player_attack_type *pa_ptr, const bool is_human, bool *drain_msg);
index 12c4b14..95e7b6e 100644 (file)
@@ -65,7 +65,7 @@
  * @brief プレイヤーの攻撃情報を初期化する(コンストラクタ以外の分)
  */
 static player_attack_type *initialize_player_attack_type(
-    player_attack_type *pa_ptr, player_type *player_ptr, POSITION y, POSITION x, int16_t hand, combat_options mode, bool *fear, bool *mdeath)
+    player_attack_type *pa_ptr, PlayerType *player_ptr, POSITION y, POSITION x, int16_t hand, combat_options mode, bool *fear, bool *mdeath)
 {
     auto floor_ptr = player_ptr->current_floor_ptr;
     auto g_ptr = &floor_ptr->grid_array[y][x];
@@ -90,7 +90,7 @@ static player_attack_type *initialize_player_attack_type(
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-static void attack_classify(player_type *player_ptr, player_attack_type *pa_ptr)
+static void attack_classify(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     switch (player_ptr->pclass) {
     case PlayerClassType::ROGUE:
@@ -113,7 +113,7 @@ static void attack_classify(player_type *player_ptr, player_attack_type *pa_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-static void get_bare_knuckle_exp(player_type *player_ptr, player_attack_type *pa_ptr)
+static void get_bare_knuckle_exp(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     monster_race *r_ptr = &r_info[pa_ptr->m_ptr->r_idx];
     if ((r_ptr->level + 10) <= player_ptr->lev)
@@ -127,7 +127,7 @@ static void get_bare_knuckle_exp(player_type *player_ptr, player_attack_type *pa
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-static void get_weapon_exp(player_type *player_ptr, player_attack_type *pa_ptr)
+static void get_weapon_exp(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     auto *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
 
@@ -139,7 +139,7 @@ static void get_weapon_exp(player_type *player_ptr, player_attack_type *pa_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-static void get_attack_exp(player_type *player_ptr, player_attack_type *pa_ptr)
+static void get_attack_exp(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     monster_race *r_ptr = &r_info[pa_ptr->m_ptr->r_idx];
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
@@ -160,7 +160,7 @@ static void get_attack_exp(player_type *player_ptr, player_attack_type *pa_ptr)
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  * @details 毒針は確定で1回
  */
-static void calc_num_blow(player_type *player_ptr, player_attack_type *pa_ptr)
+static void calc_num_blow(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     if ((pa_ptr->mode == HISSATSU_KYUSHO) || (pa_ptr->mode == HISSATSU_MINEUCHI) || (pa_ptr->mode == HISSATSU_3DAN) || (pa_ptr->mode == HISSATSU_IAI))
         pa_ptr->num_blow = 1;
@@ -183,7 +183,7 @@ static void calc_num_blow(player_type *player_ptr, player_attack_type *pa_ptr)
  * 吸血20%、地震0.12%、混乱26.892%、テレポート・アウェイ1.494%、変身1.494% /
  * Vampiric 20%, Quake 0.12%, Confusion 26.892%, Teleport away 1.494% and Polymorph 1.494%
  */
-static chaotic_effect select_chaotic_effect(player_type *player_ptr, player_attack_type *pa_ptr)
+static chaotic_effect select_chaotic_effect(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     if (pa_ptr->flags.has_not(TR_CHAOTIC) || one_in_(2))
         return CE_NONE;
@@ -209,7 +209,7 @@ static chaotic_effect select_chaotic_effect(player_type *player_ptr, player_atta
  * @param pa_ptr プレイヤー攻撃情報への参照ポインタ
  * @return 魔術属性効果
  */
-static MagicalBrandEffectType select_magical_brand_effect(player_type *player_ptr, player_attack_type *pa_ptr)
+static MagicalBrandEffectType select_magical_brand_effect(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     if (pa_ptr->flags.has_not(TR_BRAND_MAGIC))
         return MagicalBrandEffectType::NONE;
@@ -258,7 +258,7 @@ static DICE_NUMBER magical_brand_extra_dice(player_attack_type *pa_ptr)
  * 打撃に使用する武器または武器以外の装備品が地震を起こすなら、
  * ダメージ量が50より多いか1/7で地震を起こす
  */
-static bool does_equip_cause_earthquake(player_type *player_ptr, player_attack_type *pa_ptr)
+static bool does_equip_cause_earthquake(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     if (!player_ptr->earthquake)
         return false;
@@ -308,7 +308,7 @@ static bool does_weapon_has_flag(BIT_FLAGS &attacker_flags, player_attack_type *
  * @param vorpal_chance ヴォーパル倍率上昇の機会値
  * @return 攻撃の結果、地震を起こすことになったらTRUE、それ以外はFALSE
  */
-static void process_weapon_attack(player_type *player_ptr, player_attack_type *pa_ptr, bool *do_quake, const bool vorpal_cut, const int vorpal_chance)
+static void process_weapon_attack(PlayerType *player_ptr, player_attack_type *pa_ptr, bool *do_quake, const bool vorpal_cut, const int vorpal_chance)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
     auto dd = o_ptr->dd + player_ptr->to_dd[pa_ptr->hand] + magical_brand_extra_dice(pa_ptr);
@@ -339,7 +339,7 @@ static void process_weapon_attack(player_type *player_ptr, player_attack_type *p
  * @param vorpal_change ヴォーパル倍率上昇の機会値
  * @details 取り敢えず素手と仮定し1とする.
  */
-static void calc_attack_damage(player_type *player_ptr, player_attack_type *pa_ptr, bool *do_quake, const bool vorpal_cut, const int vorpal_chance)
+static void calc_attack_damage(PlayerType *player_ptr, player_attack_type *pa_ptr, bool *do_quake, const bool vorpal_cut, const int vorpal_chance)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
     pa_ptr->attack_damage = 1;
@@ -358,7 +358,7 @@ static void calc_attack_damage(player_type *player_ptr, player_attack_type *pa_p
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-static void apply_damage_bonus(player_type *player_ptr, player_attack_type *pa_ptr)
+static void apply_damage_bonus(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     pa_ptr->attack_damage += player_ptr->to_d[pa_ptr->hand];
     pa_ptr->drain_result += player_ptr->to_d[pa_ptr->hand];
@@ -412,7 +412,7 @@ static void apply_damage_negative_effect(player_attack_type *pa_ptr, bool is_zan
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  * @return 死んだらTRUE、生きていたらFALSE
  */
-static bool check_fear_death(player_type *player_ptr, player_attack_type *pa_ptr, const int num, const bool is_lowlevel)
+static bool check_fear_death(PlayerType *player_ptr, player_attack_type *pa_ptr, const int num, const bool is_lowlevel)
 {
     MonsterDamageProcessor mdp(player_ptr, pa_ptr->m_idx, pa_ptr->attack_damage, pa_ptr->fear, pa_ptr->attribute_flags);
     if (!mdp.mon_take_hit(nullptr))
@@ -452,7 +452,7 @@ static bool check_fear_death(player_type *player_ptr, player_attack_type *pa_ptr
  * @param is_ej_nullified 蜘蛛相手ならばTRUE
  */
 static void apply_actual_attack(
-    player_type *player_ptr, player_attack_type *pa_ptr, bool *do_quake, const bool is_zantetsu_nullified, const bool is_ej_nullified)
+    PlayerType *player_ptr, player_attack_type *pa_ptr, bool *do_quake, const bool is_zantetsu_nullified, const bool is_ej_nullified)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + pa_ptr->hand];
     int vorpal_chance = ((o_ptr->name1 == ART_VORPAL_BLADE) || (o_ptr->name1 == ART_CHAINSWORD)) ? 2 : 4;
@@ -487,7 +487,7 @@ static void apply_actual_attack(
  * @param y モンスターのY座標
  * @param x モンスターのX座標
  */
-static void cause_earthquake(player_type *player_ptr, player_attack_type *pa_ptr, const bool do_quake, const POSITION y, const POSITION x)
+static void cause_earthquake(PlayerType *player_ptr, player_attack_type *pa_ptr, const bool do_quake, const POSITION y, const POSITION x)
 {
     if (!do_quake)
         return;
@@ -509,7 +509,7 @@ static void cause_earthquake(player_type *player_ptr, player_attack_type *pa_ptr
  * @details
  * If no "weapon" is available, then "punch" the monster one time.
  */
-void exe_player_attack_to_monster(player_type *player_ptr, POSITION y, POSITION x, bool *fear, bool *mdeath, int16_t hand, combat_options mode)
+void exe_player_attack_to_monster(PlayerType *player_ptr, POSITION y, POSITION x, bool *fear, bool *mdeath, int16_t hand, combat_options mode)
 {
     bool do_quake = false;
     bool drain_msg = true;
@@ -571,7 +571,7 @@ void exe_player_attack_to_monster(player_type *player_ptr, POSITION y, POSITION
  * @brief 皆殺し(全方向攻撃)処理
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void massacre(player_type *player_ptr)
+void massacre(PlayerType *player_ptr)
 {
     grid_type *g_ptr;
     monster_type *m_ptr;
index 11c2ae5..4ca4186 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 #include "combat/combat-options-type.h"
 
-struct player_type;
-void exe_player_attack_to_monster(player_type *player_ptr, POSITION y, POSITION x, bool *fear, bool *mdeath, int16_t hand, combat_options mode);
-void massacre(player_type *player_ptr);
+class PlayerType;
+void exe_player_attack_to_monster(PlayerType *player_ptr, POSITION y, POSITION x, bool *fear, bool *mdeath, int16_t hand, combat_options mode);
+void massacre(PlayerType *player_ptr);
index 16ab938..6a74335 100644 (file)
@@ -29,7 +29,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerClass::PlayerClass(player_type *player_ptr)
+PlayerClass::PlayerClass(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
@@ -329,7 +329,7 @@ void PlayerClass::set_monk_stance(MonkStanceType stance) const
 
 /**
  * @brief プレイヤーの職業にで使用する職業固有データ領域を初期化する
- * @details 事前条件: player_type の職業や領域が決定済みであること
+ * @details 事前条件: PlayerType の職業や領域が決定済みであること
  */
 void PlayerClass::init_specific_data()
 {
index 18261e6..80bfe0b 100644 (file)
@@ -14,7 +14,7 @@ enum class MonkStanceType : uint8_t;
 
 class PlayerClass {
 public:
-    PlayerClass(player_type *player_ptr);
+    PlayerClass(PlayerType *player_ptr);
     virtual ~PlayerClass() = default;
 
     TrFlags tr_flags() const;
@@ -38,7 +38,7 @@ public:
     std::shared_ptr<T> get_specific_data() const;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
 
 /**
index ea316bb..1b1f760 100644 (file)
@@ -20,7 +20,7 @@
  * @param base_race true の場合、仮に変身している場合でも元の種族について扱う。 false の場合変身している種族について扱う。
  * 引数を省略した場合は false
  */
-PlayerRace::PlayerRace(player_type *player_ptr, bool base_race)
+PlayerRace::PlayerRace(PlayerType *player_ptr, bool base_race)
     : player_ptr(player_ptr)
     , base_race(base_race)
 {
index 282d21c..85e243c 100644 (file)
@@ -5,11 +5,11 @@
 enum class PlayerRaceType;
 enum class PlayerRaceLifeType;
 enum class PlayerRaceFoodType;
-struct player_type;
+class PlayerType;
 struct player_race_info;
 class PlayerRace {
 public:
-    PlayerRace(player_type *player_ptr, bool base_race = false);
+    PlayerRace(PlayerType *player_ptr, bool base_race = false);
     virtual ~PlayerRace() = default;
 
     TrFlags tr_flags() const;
@@ -28,6 +28,6 @@ public:
     int16_t additional_constitution() const;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     bool base_race;
 };
index fd0d810..501a5d8 100644 (file)
@@ -16,7 +16,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerAlignment::PlayerAlignment(player_type *player_ptr)
+PlayerAlignment::PlayerAlignment(PlayerType *player_ptr)
 {
     this->player_ptr = player_ptr;
 }
index f0c76d8..e38b6c7 100644 (file)
@@ -2,15 +2,15 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class PlayerAlignment {
 public:
-    PlayerAlignment(player_type *player_ptr);
+    PlayerAlignment(PlayerType *player_ptr);
     virtual ~PlayerAlignment() = default;
     concptr get_alignment_description(bool with_value = false);
     void update_alignment();
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     concptr alignment_label();
     void bias_good_alignment(int value);
     void bias_evil_alignment(int value);
index adc5526..1f50bac 100644 (file)
@@ -7,7 +7,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-void set_equipment_influence(player_type *player_ptr, self_info_type *self_ptr)
+void set_equipment_influence(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     for (int k = INVEN_MAIN_HAND; k < INVEN_TOTAL; k++) {
         object_type *o_ptr = &player_ptr->inventory_list[k];
@@ -55,7 +55,7 @@ void set_equipment_influence(player_type *player_ptr, self_info_type *self_ptr)
         self_ptr->info[self_ptr->line++] = _("あなたの攻撃速度は装備によって影響を受けている。", "Your attack speed is affected by your equipment.");
 }
 
-void set_status_sustain_info(player_type *player_ptr, self_info_type *self_ptr)
+void set_status_sustain_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (has_sustain_str(player_ptr)) {
         self_ptr->info[self_ptr->line++] = _("あなたの腕力は維持されている。", "Your strength is sustained.");
index 8240033..bb59d99 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct self_info_type;
-void set_equipment_influence(player_type *player_ptr, self_info_type *self_ptr);
-void set_status_sustain_info(player_type *player_ptr, self_info_type *self_ptr);
+void set_equipment_influence(PlayerType *player_ptr, self_info_type *self_ptr);
+void set_status_sustain_info(PlayerType *player_ptr, self_info_type *self_ptr);
index cd003b2..3f473fa 100644 (file)
@@ -5,7 +5,7 @@
 #include "system/player-type-definition.h"
 
 /*!< @todo 並び順の都合で連番を付ける。まとめても良いならまとめてしまう予定 */
-void set_body_improvement_info_1(player_type *player_ptr, self_info_type *self_ptr)
+void set_body_improvement_info_1(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (is_blessed(player_ptr))
         self_ptr->info[self_ptr->line++] = _("あなたは高潔さを感じている。", "You feel rightous.");
@@ -30,7 +30,7 @@ void set_body_improvement_info_1(player_type *player_ptr, self_info_type *self_p
 }
 
 /*!< @todo 並び順の都合で連番を付ける。まとめても良いならまとめてしまう予定 */
-void set_body_improvement_info_2(player_type *player_ptr, self_info_type *self_ptr)
+void set_body_improvement_info_2(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (player_ptr->new_spells)
         self_ptr->info[self_ptr->line++] = _("あなたは呪文や祈りを学ぶことができる。", "You can learn some spells/prayers.");
@@ -61,7 +61,7 @@ void set_body_improvement_info_2(player_type *player_ptr, self_info_type *self_p
 }
 
 /*!< @todo 並び順の都合で連番を付ける。まとめても良いならまとめてしまう予定 */
-void set_body_improvement_info_3(player_type *player_ptr, self_info_type *self_ptr)
+void set_body_improvement_info_3(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (player_ptr->hold_exp)
         self_ptr->info[self_ptr->line++] = _("あなたは自己の経験値をしっかりと維持する。", "You have a firm hold on your experience.");
@@ -122,7 +122,7 @@ void set_body_improvement_info_3(player_type *player_ptr, self_info_type *self_p
 }
 
 /*!< @todo 並び順の都合で連番を付ける。まとめても良いならまとめてしまう予定 */
-void set_body_improvement_info_4(player_type *player_ptr, self_info_type *self_ptr)
+void set_body_improvement_info_4(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (has_resist_fear(player_ptr))
         self_ptr->info[self_ptr->line++] = _("あなたは全く恐怖を感じない。", "You are completely fearless.");
index e63ea22..29d20f6 100644 (file)
@@ -1,8 +1,8 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct self_info_type;
-void set_body_improvement_info_1(player_type *player_ptr, self_info_type *self_ptr);
-void set_body_improvement_info_2(player_type *player_ptr, self_info_type *self_ptr);
-void set_body_improvement_info_3(player_type *player_ptr, self_info_type *self_ptr);
-void set_body_improvement_info_4(player_type *player_ptr, self_info_type *self_ptr);
+void set_body_improvement_info_1(PlayerType *player_ptr, self_info_type *self_ptr);
+void set_body_improvement_info_2(PlayerType *player_ptr, self_info_type *self_ptr);
+void set_body_improvement_info_3(PlayerType *player_ptr, self_info_type *self_ptr);
+void set_body_improvement_info_4(PlayerType *player_ptr, self_info_type *self_ptr);
index 39ad26e..0e0ea1f 100644 (file)
@@ -4,7 +4,7 @@
 #include "realm/realm-types.h"
 #include "system/player-type-definition.h"
 
-void set_class_ability_info(player_type *player_ptr, self_info_type *self_ptr)
+void set_class_ability_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     switch (player_ptr->pclass) {
     case PlayerClassType::WARRIOR:
index de51664..dc695bc 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct self_info_type;
-void set_class_ability_info(player_type *player_ptr, self_info_type *self_ptr);
+void set_class_ability_info(PlayerType *player_ptr, self_info_type *self_ptr);
index 595ee99..ff393da 100644 (file)
@@ -12,7 +12,7 @@
  * @param i 判定する手のID(右手:INVEN_MAIN_HAND 左手:INVEN_SUB_HAND)
  * @return 持っているならばTRUE
  */
-bool has_melee_weapon(player_type *player_ptr, int slot)
+bool has_melee_weapon(PlayerType *player_ptr, int slot)
 {
     const auto o_ptr = &player_ptr->inventory_list[slot];
     return o_ptr->k_idx && o_ptr->is_melee_weapon();
@@ -23,7 +23,7 @@ bool has_melee_weapon(player_type *player_ptr, int slot)
  * @param riding_control 乗馬中により片手を必要としている状態ならばTRUEを返す。
  * @return 開いている手のビットフラグ
  */
-BIT_FLAGS16 empty_hands(player_type *player_ptr, bool riding_control)
+BIT_FLAGS16 empty_hands(PlayerType *player_ptr, bool riding_control)
 {
     BIT_FLAGS16 status = EMPTY_HAND_NONE;
     if (!player_ptr->inventory_list[INVEN_MAIN_HAND].k_idx)
@@ -41,7 +41,7 @@ BIT_FLAGS16 empty_hands(player_type *player_ptr, bool riding_control)
     return status;
 }
 
-bool can_two_hands_wielding(player_type *player_ptr)
+bool can_two_hands_wielding(PlayerType *player_ptr)
 {
     return !player_ptr->riding || any_bits(player_ptr->pet_extra_flags, PF_TWO_HANDS);
 }
@@ -50,7 +50,7 @@ bool can_two_hands_wielding(player_type *player_ptr)
  * @brief プレイヤーが防具重量制限のある職業時にペナルティを受ける状態にあるかどうかを返す。
  * @return ペナルティが適用されるならばTRUE。
  */
-bool heavy_armor(player_type *player_ptr)
+bool heavy_armor(PlayerType *player_ptr)
 {
     if ((player_ptr->pclass != PlayerClassType::MONK) && (player_ptr->pclass != PlayerClassType::FORCETRAINER) && (player_ptr->pclass != PlayerClassType::NINJA))
         return false;
index fbf5206..ea5a987 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool has_melee_weapon(player_type *player_ptr, int i);
-BIT_FLAGS16 empty_hands(player_type *player_ptr, bool riding_control);
-bool can_two_hands_wielding(player_type *player_ptr);
-bool heavy_armor(player_type *player_ptr);
+class PlayerType;
+bool has_melee_weapon(PlayerType *player_ptr, int i);
+BIT_FLAGS16 empty_hands(PlayerType *player_ptr, bool riding_control);
+bool can_two_hands_wielding(PlayerType *player_ptr);
+bool heavy_armor(PlayerType *player_ptr);
index 6e24145..d0e7979 100644 (file)
@@ -6,7 +6,7 @@
 #include "util/bit-flags-calculator.h"
 
 /*!< @todo FEAELESS フラグも記述して問題ないと思われる */
-void set_mutation_info(player_type *player_ptr, self_info_type *self_ptr)
+void set_mutation_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (player_ptr->muta.none())
         return;
index f39e1b9..5c31bb2 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct self_info_type;
-void set_mutation_info(player_type *player_ptr, self_info_type *self_ptr);
+void set_mutation_info(PlayerType *player_ptr, self_info_type *self_ptr);
index 0833fe6..05178e2 100644 (file)
@@ -9,7 +9,7 @@
  * @details
  *  使用可能レベル以上を条件とする。
  */
-void set_race_ability_info(player_type *player_ptr, self_info_type *self_ptr)
+void set_race_ability_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     switch (player_ptr->prace) {
     case PlayerRaceType::DWARF:
index 343f522..639458e 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct self_info_type;
-void set_race_ability_info(player_type *player_ptr, self_info_type *self_ptr);
+void set_race_ability_info(PlayerType *player_ptr, self_info_type *self_ptr);
index 15aa24c..bcd4604 100644 (file)
@@ -17,7 +17,7 @@ const player_race_info *rp_ptr;
  * @param player_ptr プレイヤー情報への参照ポインタ
  * @return シンボル文字
  */
-SYMBOL_CODE get_summon_symbol_from_player(player_type *player_ptr)
+SYMBOL_CODE get_summon_symbol_from_player(PlayerType *player_ptr)
 {
     SYMBOL_CODE symbol = 'N';
     auto mmc_ptr = PlayerRace(player_ptr).get_info();
index 786c5bb..90fc188 100644 (file)
@@ -111,5 +111,5 @@ struct player_race_info {
 
 extern const player_race_info *rp_ptr;
 
-struct player_type;
-SYMBOL_CODE get_summon_symbol_from_player(player_type *player_ptr);
+class PlayerType;
+SYMBOL_CODE get_summon_symbol_from_player(PlayerType *player_ptr);
index 4665ee0..c39253e 100644 (file)
@@ -6,7 +6,7 @@
 #include "status/element-resistance.h"
 #include "system/player-type-definition.h"
 
-void set_element_resistance_info(player_type *player_ptr, self_info_type *self_ptr)
+void set_element_resistance_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     const auto race_tr_flags = PlayerRace(player_ptr).tr_flags();
 
@@ -56,7 +56,7 @@ void set_element_resistance_info(player_type *player_ptr, self_info_type *self_p
         self_ptr->info[self_ptr->line++] = _("あなたは毒への耐性を持っている。", "You are resistant to poison.");
 }
 
-void set_high_resistance_info(player_type *player_ptr, self_info_type *self_ptr)
+void set_high_resistance_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (has_resist_lite(player_ptr))
         self_ptr->info[self_ptr->line++] = _("あなたは閃光への耐性を持っている。", "You are resistant to bright light.");
index bfe65c0..8833af2 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct self_info_type;
-void set_element_resistance_info(player_type *player_ptr, self_info_type *self_ptr);
-void set_high_resistance_info(player_type *player_ptr, self_info_type *self_ptr);
+void set_element_resistance_info(PlayerType *player_ptr, self_info_type *self_ptr);
+void set_high_resistance_info(PlayerType *player_ptr, self_info_type *self_ptr);
index b751075..6cea35f 100644 (file)
@@ -32,7 +32,7 @@
 #include "timed-effect/timed-effects.h"
 #include "view/display-self-info.h"
 
-static void set_bad_status_info(player_type *player_ptr, self_info_type *self_ptr)
+static void set_bad_status_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     auto effects = player_ptr->effects();
     if (player_ptr->blind)
@@ -57,7 +57,7 @@ static void set_bad_status_info(player_type *player_ptr, self_info_type *self_pt
         self_ptr->info[self_ptr->line++] = _("あなたは幻覚を見ている。", "You are hallucinating.");
 }
 
-static void set_curse_info(player_type *player_ptr, self_info_type *self_ptr)
+static void set_curse_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (player_ptr->cursed.has(CurseTraitType::TY_CURSE))
         self_ptr->info[self_ptr->line++] = _("あなたは邪悪な怨念に包まれている。", "You carry an ancient foul curse.");
@@ -114,7 +114,7 @@ static void set_curse_info(player_type *player_ptr, self_info_type *self_ptr)
         self_ptr->info[self_ptr->line++] = _("あなたは魔力を吸われている。", "You occasionally lose spell points for no reason.");
 }
 
-static void set_special_attack_info(player_type *player_ptr, self_info_type *self_ptr)
+static void set_special_attack_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (player_ptr->special_attack & ATTACK_CONFUSE)
         self_ptr->info[self_ptr->line++] = _("あなたの手は赤く輝いている。", "Your hands are glowing dull red.");
@@ -135,7 +135,7 @@ static void set_special_attack_info(player_type *player_ptr, self_info_type *sel
         self_ptr->info[self_ptr->line++] = _("あなたの手は毒に覆われている。", "You can strike the enemy with poison.");
 }
 
-static void set_esp_info(player_type *player_ptr, self_info_type *self_ptr)
+static void set_esp_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     if (player_ptr->telepathy)
         self_ptr->info[self_ptr->line++] = _("あなたはテレパシー能力を持っている。", "You have ESP.");
@@ -194,7 +194,7 @@ static void set_esp_info(player_type *player_ptr, self_info_type *self_ptr)
  * Use the "show_file()" method, perhaps.
  * </pre>
  */
-void self_knowledge(player_type *player_ptr)
+void self_knowledge(PlayerType *player_ptr)
 {
     self_info_type tmp_si;
     self_info_type *self_ptr = initialize_self_info_type(&tmp_si);
@@ -264,7 +264,7 @@ static concptr report_magic_durations[] = { _("ごく短い間", "for a short ti
 /*!
  * @brief 現在の一時的効果一覧を返す / Report all currently active magical effects.
  */
-void report_magics(player_type *player_ptr)
+void report_magics(PlayerType *player_ptr)
 {
     int i = 0;
     concptr info[128];
index c01027a..6241bd9 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void self_knowledge(player_type *player_ptr);
-void report_magics(player_type *player_ptr);
+class PlayerType;
+void self_knowledge(PlayerType *player_ptr);
+void report_magics(PlayerType *player_ptr);
index 76d2f05..f29ecc4 100644 (file)
@@ -100,7 +100,7 @@ static void set_slay_info(self_info_type *self_ptr)
         self_ptr->info[self_ptr->line++] = _("あなたの武器はドラゴンに対して特に強い力を発揮する。", "Your weapon is especially deadly against dragons.");
 }
 
-void set_weapon_effect_info(player_type *player_ptr, self_info_type *self_ptr)
+void set_weapon_effect_info(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND];
     if (o_ptr->k_idx == 0)
index 4202635..f5a8a11 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct self_info_type;
-void set_weapon_effect_info(player_type *player_ptr, self_info_type *self_ptr);
+void set_weapon_effect_info(PlayerType *player_ptr, self_info_type *self_ptr);
index c62645d..df71425 100644 (file)
@@ -17,7 +17,7 @@
 #include "util/bit-flags-calculator.h"
 #include "util/enum-converter.h"
 
-PlayerBasicStatistics::PlayerBasicStatistics(player_type *player_ptr)
+PlayerBasicStatistics::PlayerBasicStatistics(PlayerType *player_ptr)
     : PlayerStatusBase(player_ptr)
 {
 }
index 5493a25..1cc72e5 100644 (file)
@@ -3,7 +3,7 @@
 #include "player-ability/player-ability-types.h"
 #include "player-status/player-status-base.h"
 
-struct player_type;
+class PlayerType;
 class PlayerBasicStatistics : public PlayerStatusBase {
 public:
     void update_value();
@@ -11,7 +11,7 @@ public:
     int16_t get_value() override;
 
 protected:
-    PlayerBasicStatistics(player_type *player_ptr);
+    PlayerBasicStatistics(PlayerType *player_ptr);
 
     player_ability_type ability_type{};
     int16_t race_value() override;
index 7f70a44..2599fa2 100644 (file)
@@ -8,7 +8,7 @@
 #include "player-status/player-energy.h"
 #include "system/player-type-definition.h"
 
-PlayerEnergy::PlayerEnergy(player_type *player_ptr)
+PlayerEnergy::PlayerEnergy(PlayerType *player_ptr)
 {
     this->player_ptr = player_ptr;
 }
@@ -46,7 +46,7 @@ void PlayerEnergy::div_player_turn_energy(ENERGY need_cost)
 
 /*
  * @brief ターン消費をなくす (主にコマンド実行に失敗した場合)
- * @param player_type プレイヤーへの参照ポインタ
+ * @param PlayerType プレイヤーへの参照ポインタ
  */
 void PlayerEnergy::reset_player_turn()
 {
index 563147f..673b9c6 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class PlayerEnergy {
 public:
-    PlayerEnergy(player_type *player_ptr);
+    PlayerEnergy(PlayerType *player_ptr);
     virtual ~PlayerEnergy() = default;
     void set_player_turn_energy(ENERGY need_cost); // 代入.
     void add_player_turn_energy(ENERGY need_cost); // 加算.
@@ -14,5 +14,5 @@ public:
     void div_player_turn_energy(ENERGY need_cost); // 除算.
     void reset_player_turn();
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index c986921..4c1aab7 100644 (file)
@@ -7,7 +7,7 @@
 #include "system/player-type-definition.h"
 #include "util/enum-converter.h"
 
-PlayerInfravision::PlayerInfravision(player_type *player_ptr)
+PlayerInfravision::PlayerInfravision(PlayerType *player_ptr)
     : PlayerStatusBase(player_ptr)
 {
 }
index ef1daed..61e1e14 100644 (file)
@@ -3,7 +3,7 @@
 
 class PlayerInfravision : public PlayerStatusBase {
 public:
-    PlayerInfravision(player_type *player_ptr);
+    PlayerInfravision(PlayerType *player_ptr);
 
 protected:
     void set_locals() override;
index bd859e3..8cdb586 100644 (file)
@@ -30,7 +30,7 @@
 #include "system/player-type-definition.h"
 #include "util/bit-flags-calculator.h"
 
-PlayerSpeed::PlayerSpeed(player_type *player_ptr)
+PlayerSpeed::PlayerSpeed(PlayerType *player_ptr)
     : PlayerStatusBase(player_ptr)
 {
 }
index a7b1e3a..dcc50ba 100644 (file)
@@ -3,7 +3,7 @@
 
 class PlayerSpeed : public PlayerStatusBase {
 public:
-    PlayerSpeed(player_type *player_ptr);
+    PlayerSpeed(PlayerType *player_ptr);
 
 protected:
     void set_locals() override;
index 4b9bbb1..f803311 100644 (file)
@@ -12,7 +12,7 @@
  * @details
  * * コンストラクタでplayer_ptrをセット。メンバ変数を0クリア。
  */
-PlayerStatusBase::PlayerStatusBase(player_type *player_ptr)
+PlayerStatusBase::PlayerStatusBase(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
     this->set_locals(); /* 初期化。基底クラスの0クリアが呼ばれる。*/
index 677df31..f648c52 100644 (file)
@@ -2,7 +2,7 @@
 #include "system/angband.h"
 #include "player/player-status-flags.h"
 
-struct player_type;
+class PlayerType;
 class PlayerStatusBase {
 public:
     virtual ~PlayerStatusBase() = default;
@@ -12,12 +12,12 @@ public:
     virtual BIT_FLAGS get_bad_flags();
 
 protected:
-    PlayerStatusBase(player_type *player_ptr);
+    PlayerStatusBase(PlayerType *player_ptr);
 
     int16_t default_value;
     int16_t min_value;
     int16_t max_value;
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     tr_type tr_flag;
     tr_type tr_bad_flag;
     virtual void set_locals();
index 567fc72..d083f11 100644 (file)
@@ -17,7 +17,7 @@
 #include "util/bit-flags-calculator.h"
 #include "util/enum-converter.h"
 
-PlayerStealth::PlayerStealth(player_type* player_ptr)
+PlayerStealth::PlayerStealth(PlayerType* player_ptr)
     : PlayerStatusBase(player_ptr)
 {
 }
index 2b1f11c..229afc7 100644 (file)
@@ -3,7 +3,7 @@
 
 class PlayerStealth : public PlayerStatusBase {
 public:
-    PlayerStealth(player_type *player_ptr);
+    PlayerStealth(PlayerType *player_ptr);
 
     BIT_FLAGS get_bad_flags() override;
 
index b30095e..717e7c4 100644 (file)
@@ -25,7 +25,7 @@
  * @brief 10ゲームターンが進行するごとにプレイヤーの腹を減らす
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void starve_player(player_type *player_ptr)
+void starve_player(PlayerType *player_ptr)
 {
     if (player_ptr->phase_out)
         return;
@@ -95,7 +95,7 @@ void starve_player(player_type *player_ptr)
  * game turns, or 500/(100/5) = 25 player turns (if nothing else is
  * affecting the player speed).\n
  */
-bool set_food(player_type *player_ptr, TIME_EFFECT v)
+bool set_food(PlayerType *player_ptr, TIME_EFFECT v)
 {
     int old_aux, new_aux;
 
index c30e323..c59a578 100644 (file)
@@ -9,6 +9,6 @@
 #define PY_FOOD_FAINT 500 /*!< 衰弱~衰弱(赤表示/麻痺)の閾値 / Food value (Fainting) */
 #define PY_FOOD_STARVE 100 /*!< 衰弱(赤表示/麻痺)~飢餓ダメージの閾値 / Food value (Starving) */
 
-struct player_type;
-void starve_player(player_type *player_ptr);
-bool set_food(player_type *player_ptr, TIME_EFFECT v);
+class PlayerType;
+void starve_player(PlayerType *player_ptr);
+bool set_food(PlayerType *player_ptr, TIME_EFFECT v);
index a163ee2..e435684 100644 (file)
@@ -82,7 +82,7 @@ static void feel_eldritch_horror(concptr desc, monster_race *r_ptr)
  * @param m_ptr ELDRITCH_HORRORを引き起こしたモンスターの参照ポインタ。薬・罠・魔法の影響ならnullptr
  * @param necro 暗黒領域魔法の詠唱失敗によるものならばTRUEを返す
  */
-void sanity_blast(player_type *player_ptr, monster_type *m_ptr, bool necro)
+void sanity_blast(PlayerType *player_ptr, monster_type *m_ptr, bool necro)
 {
     if (player_ptr->phase_out || !w_ptr->character_dungeon)
         return;
index d5b96fd..a4d9cb8 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct monster_type;
-struct player_type;
-void sanity_blast(player_type *player_ptr, monster_type *m_ptr, bool necro);
+class PlayerType;
+void sanity_blast(PlayerType *player_ptr, monster_type *m_ptr, bool necro);
index 44abc61..c2c06c6 100644 (file)
@@ -139,7 +139,7 @@ Patron::Patron(const char *name, std::vector<patron_reward> reward_table, player
 {
 }
 
-void Patron::gain_level_reward(player_type *player_ptr_, int chosen_reward)
+void Patron::gain_level_reward(PlayerType *player_ptr_, int chosen_reward)
 {
     this->player_ptr = player_ptr_;
     char wrath_reason[32] = "";
@@ -561,7 +561,7 @@ void Patron::gain_level_reward(player_type *player_ptr_, int chosen_reward)
     }
 }
 
-void Patron::admire(player_type *player_ptr_)
+void Patron::admire(PlayerType *player_ptr_)
 {
     this->player_ptr = player_ptr_;
     if ((this->player_ptr->pclass == PlayerClassType::CHAOS_WARRIOR) || this->player_ptr->muta.has(PlayerMutationType::CHAOS_GIFT)) {
index d1ccf0c..0f75287 100644 (file)
@@ -46,7 +46,7 @@ enum patron_reward {
     REW_SER_MONS = 36, /*!< カオスパトロンからの報酬: モンスターの下僕下賜 */
 };
 
-struct player_type;
+class PlayerType;
 enum player_ability_type : int;
 
 /*!
@@ -64,11 +64,11 @@ public:
     virtual ~Patron() = default;
 
     // @note C4458 クラスメンバーの隠蔽 への対応として末尾に「_」を付ける.
-    void gain_level_reward(player_type *player_ptr_, int chosen_reward);
-    void admire(player_type *player_ptr_);
+    void gain_level_reward(PlayerType *player_ptr_, int chosen_reward);
+    void admire(PlayerType *player_ptr_);
 
 private:
-    player_type *player_ptr = nullptr; //!< プレイヤー参照ポインタ
+    PlayerType *player_ptr = nullptr; //!< プレイヤー参照ポインタ
     std::vector<patron_reward> reward_table; //!< 報酬テーブル
     player_ability_type boost_stat; //!< 強化能力値傾向
 };
index 4090fb5..774fdc2 100644 (file)
@@ -20,7 +20,7 @@
  * @param flags 耐性フラグの配列
  * @todo 最終的にplayer-status系列と統合する
  */
-static void add_mutation_flags(player_type *player_ptr, TrFlags &flags)
+static void add_mutation_flags(PlayerType *player_ptr, TrFlags &flags)
 {
     if (player_ptr->muta.none())
         return;
@@ -54,7 +54,7 @@ static void add_mutation_flags(player_type *player_ptr, TrFlags &flags)
  * @param flags 耐性フラグの配列
  * @todo 最終的にplayer-status系列と統合する
  */
-static void add_personality_flags(player_type *player_ptr, TrFlags &flags)
+static void add_personality_flags(PlayerType *player_ptr, TrFlags &flags)
 {
     if (player_ptr->ppersonality == PERSONALITY_SEXY)
         flags.set(TR_AGGRAVATE);
@@ -82,7 +82,7 @@ static void add_personality_flags(player_type *player_ptr, TrFlags &flags)
  * Obtain the "flags" for the player as if he was an item
  * @todo 最終的にplayer-status系列と統合する
  */
-void player_flags(player_type *player_ptr, TrFlags &flags)
+void player_flags(PlayerType *player_ptr, TrFlags &flags)
 {
     flags.clear();
 
@@ -93,7 +93,7 @@ void player_flags(player_type *player_ptr, TrFlags &flags)
     add_personality_flags(player_ptr, flags);
 }
 
-void riding_flags(player_type *player_ptr, TrFlags &flags, TrFlags &negative_flags)
+void riding_flags(PlayerType *player_ptr, TrFlags &flags, TrFlags &negative_flags)
 {
     flags.clear();
     negative_flags.clear();
index 2b8f26a..d223e98 100644 (file)
@@ -4,6 +4,6 @@
 
 #include "object-enchant/tr-flags.h"
 
-struct player_type;
-void player_flags(player_type *player_ptr, TrFlags &flags);
-void riding_flags(player_type *player_ptr, TrFlags &flags, TrFlags &negative_flags);
+class PlayerType;
+void player_flags(PlayerType *player_ptr, TrFlags &flags);
+void riding_flags(PlayerType *player_ptr, TrFlags &flags, TrFlags &negative_flags);
index d7bdca1..1758def 100644 (file)
@@ -70,7 +70,7 @@
 #include "view/display-messages.h"
 #include "world/world.h"
 
-using dam_func = HIT_POINT (*)(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
+using dam_func = HIT_POINT (*)(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
 
 /*!
  * @brief 酸攻撃による装備のAC劣化処理 /
@@ -82,7 +82,7 @@ using dam_func = HIT_POINT (*)(player_type *player_ptr, HIT_POINT dam, concptr k
  * Note that the "base armor" of an object never changes.
  * If any armor is damaged (or resists), the player takes less damage.
  */
-static bool acid_minus_ac(player_type *player_ptr)
+static bool acid_minus_ac(PlayerType *player_ptr)
 {
     object_type *o_ptr = nullptr;
     switch (randint1(7)) {
@@ -144,7 +144,7 @@ static bool acid_minus_ac(player_type *player_ptr)
  * @return 修正HPダメージ量
  * @details 酸オーラは存在しないが関数ポインタのために引数だけは用意している
  */
-HIT_POINT acid_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura)
+HIT_POINT acid_dam(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura)
 {
     int inv = (dam < 30) ? 1 : (dam < 60) ? 2 : 3;
     bool double_resist = is_oppose_acid(player_ptr);
@@ -177,7 +177,7 @@ HIT_POINT acid_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool
  * @param aura オーラよるダメージが原因ならばTRUE
  * @return 修正HPダメージ量
  */
-HIT_POINT elec_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura)
+HIT_POINT elec_dam(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura)
 {
     int inv = (dam < 30) ? 1 : (dam < 60) ? 2 : 3;
     bool double_resist = is_oppose_elec(player_ptr);
@@ -209,7 +209,7 @@ HIT_POINT elec_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool
  * @param aura オーラよるダメージが原因ならばTRUE
  * @return 修正HPダメージ量
  */
-HIT_POINT fire_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura)
+HIT_POINT fire_dam(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura)
 {
     int inv = (dam < 30) ? 1 : (dam < 60) ? 2 : 3;
     bool double_resist = is_oppose_fire(player_ptr);
@@ -241,7 +241,7 @@ HIT_POINT fire_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool
  * @param aura オーラよるダメージが原因ならばTRUE
  * @return 修正HPダメージ量
  */
-HIT_POINT cold_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura)
+HIT_POINT cold_dam(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura)
 {
     int inv = (dam < 30) ? 1 : (dam < 60) ? 2 : 3;
     bool double_resist = is_oppose_cold(player_ptr);
@@ -270,7 +270,7 @@ HIT_POINT cold_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool
  * the game when he dies, since the "You die." message is shown before
  * setting the player to "dead".
  */
-int take_hit(player_type *player_ptr, int damage_type, HIT_POINT damage, concptr hit_from)
+int take_hit(PlayerType *player_ptr, int damage_type, HIT_POINT damage, concptr hit_from)
 {
     int old_chp = player_ptr->chp;
 
@@ -556,7 +556,7 @@ int take_hit(player_type *player_ptr, int damage_type, HIT_POINT damage, concptr
  * @param dam_func ダメージ処理を行う関数の参照ポインタ
  * @param message オーラダメージを受けた際のメッセージ
  */
-static void process_aura_damage(monster_type *m_ptr, player_type *player_ptr, bool immune, MonsterAuraType aura_flag, dam_func dam_func, concptr message)
+static void process_aura_damage(monster_type *m_ptr, PlayerType *player_ptr, bool immune, MonsterAuraType aura_flag, dam_func dam_func, concptr message)
 {
     auto *r_ptr = &r_info[m_ptr->r_idx];
     if (r_ptr->aura_flags.has_not(aura_flag) || immune) {
@@ -580,7 +580,7 @@ static void process_aura_damage(monster_type *m_ptr, player_type *player_ptr, bo
  * @param m_ptr オーラを持つモンスターの構造体参照ポインタ
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void touch_zap_player(monster_type *m_ptr, player_type *player_ptr)
+void touch_zap_player(monster_type *m_ptr, PlayerType *player_ptr)
 {
     process_aura_damage(m_ptr, player_ptr, has_immune_fire(player_ptr) != 0, MonsterAuraType::FIRE, fire_dam, _("突然とても熱くなった!", "You are suddenly very hot!"));
     process_aura_damage(m_ptr, player_ptr, has_immune_cold(player_ptr) != 0, MonsterAuraType::COLD, cold_dam, _("突然とても寒くなった!", "You are suddenly very cold!"));
index cc25f39..16c2511 100644 (file)
 #define DAMAGE_USELIFE  6
 
 struct monster_type;
-struct player_type;
-int take_hit(player_type *player_ptr, int damage_type, HIT_POINT damage, concptr kb_str);
-HIT_POINT acid_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
-HIT_POINT elec_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
-HIT_POINT fire_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
-HIT_POINT cold_dam(player_type *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
-void touch_zap_player(monster_type *m_ptr, player_type *player_ptr);
+class PlayerType;
+int take_hit(PlayerType *player_ptr, int damage_type, HIT_POINT damage, concptr kb_str);
+HIT_POINT acid_dam(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
+HIT_POINT elec_dam(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
+HIT_POINT fire_dam(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
+HIT_POINT cold_dam(PlayerType *player_ptr, HIT_POINT dam, concptr kb_str, bool aura);
+void touch_zap_player(monster_type *m_ptr, PlayerType *player_ptr);
index 52199eb..650f767 100644 (file)
@@ -59,7 +59,7 @@ POSITION temp2_y[MAX_SHORT];
  * @param y 対象となるマスのY座標
  * @param x 対象となるマスのX座標
  */
-static void discover_hidden_things(player_type *player_ptr, POSITION y, POSITION x)
+static void discover_hidden_things(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     grid_type *g_ptr;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -95,7 +95,7 @@ static void discover_hidden_things(player_type *player_ptr, POSITION y, POSITION
  * @brief プレイヤーの探索処理判定
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void search(player_type *player_ptr)
+void search(PlayerType *player_ptr)
 {
     PERCENTAGE chance = player_ptr->skill_srh;
     if (player_ptr->blind || no_lite(player_ptr))
@@ -117,7 +117,7 @@ void search(player_type *player_ptr)
  * @param mpe_mode 移動オプションフラグ
  * @return プレイヤーが死亡やフロア離脱を行わず、実際に移動が可能ならばTRUEを返す。
  */
-bool move_player_effect(player_type *player_ptr, POSITION ny, POSITION nx, BIT_FLAGS mpe_mode)
+bool move_player_effect(PlayerType *player_ptr, POSITION ny, POSITION nx, BIT_FLAGS mpe_mode)
 {
     POSITION oy = player_ptr->y;
     POSITION ox = player_ptr->x;
@@ -271,7 +271,7 @@ bool move_player_effect(player_type *player_ptr, POSITION ny, POSITION nx, BIT_F
  * @param feat 地形ID
  * @return トラップが自動的に無効ならばTRUEを返す
  */
-bool trap_can_be_ignored(player_type *player_ptr, FEAT_IDX feat)
+bool trap_can_be_ignored(PlayerType *player_ptr, FEAT_IDX feat)
 {
     feature_type *f_ptr = &f_info[feat];
     if (f_ptr->flags.has_not(FloorFeatureType::TRAP))
index 0e5b27d..b32df4c 100644 (file)
@@ -28,7 +28,7 @@ extern int flow_tail;
 extern POSITION temp2_x[MAX_SHORT];
 extern POSITION temp2_y[MAX_SHORT];
 
-struct player_type;
-bool move_player_effect(player_type *player_ptr, POSITION ny, POSITION nx, BIT_FLAGS mpe_mode);
-bool trap_can_be_ignored(player_type *player_ptr, FEAT_IDX feat);
-void search(player_type *player_ptr);
+class PlayerType;
+bool move_player_effect(PlayerType *player_ptr, POSITION ny, POSITION nx, BIT_FLAGS mpe_mode);
+bool trap_can_be_ignored(PlayerType *player_ptr, FEAT_IDX feat);
+void search(PlayerType *player_ptr);
index 7bb3a20..cd116e3 100644 (file)
@@ -72,12 +72,12 @@ const std::vector<BIT_FLAGS> realm_choices2 = {
     (CH_NONE), /* Elementalist */
 };
 
-ItemKindType get_realm1_book(player_type *player_ptr)
+ItemKindType get_realm1_book(PlayerType *player_ptr)
 {
     return ItemKindType::LIFE_BOOK + player_ptr->realm1 - 1;
 }
 
-ItemKindType get_realm2_book(player_type *player_ptr)
+ItemKindType get_realm2_book(PlayerType *player_ptr)
 {
     return ItemKindType::LIFE_BOOK + player_ptr->realm2 - 1;
 }
index 73a262b..f9d3a40 100644 (file)
@@ -25,7 +25,7 @@ enum choosable_realm {
 extern const std::vector<BIT_FLAGS> realm_choices1;
 extern const std::vector<BIT_FLAGS> realm_choices2;
 
-struct player_type;
+class PlayerType;
 enum class ItemKindType : short;
-ItemKindType get_realm1_book(player_type *player_ptr);
-ItemKindType get_realm2_book(player_type *player_ptr);
+ItemKindType get_realm1_book(PlayerType *player_ptr);
+ItemKindType get_realm2_book(PlayerType *player_ptr);
index 8ce3761..4c9d440 100644 (file)
@@ -40,7 +40,7 @@ namespace {
 
 using GainAmountList = std::array<int, enum2i(PlayerSkillRank::MASTER)>;
 
-void gain_attack_skill_exp(player_type *player_ptr, short &exp, const GainAmountList &gain_amount_list)
+void gain_attack_skill_exp(PlayerType *player_ptr, short &exp, const GainAmountList &gain_amount_list)
 {
     auto gain_amount = 0;
     auto calc_gain_amount = [&gain_amount_list, exp](PlayerSkillRank rank, int next_rank_exp) {
@@ -61,7 +61,7 @@ void gain_attack_skill_exp(player_type *player_ptr, short &exp, const GainAmount
     set_bits(player_ptr->update, PU_BONUS);
 }
 
-void gain_spell_skill_exp_aux(player_type *player_ptr, short &exp, const GainAmountList &gain_amount_list, int spell_level)
+void gain_spell_skill_exp_aux(PlayerType *player_ptr, short &exp, const GainAmountList &gain_amount_list, int spell_level)
 {
     const auto dlev = player_ptr->current_floor_ptr->dun_level;
     const auto plev = player_ptr->lev;
@@ -93,7 +93,7 @@ void gain_spell_skill_exp_aux(player_type *player_ptr, short &exp, const GainAmo
 
 }
 
-PlayerSkill::PlayerSkill(player_type *player_ptr)
+PlayerSkill::PlayerSkill(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index b1e6466..1788816 100644 (file)
@@ -43,11 +43,11 @@ extern std::vector<skill_table> s_info;
 
 struct monster_race;
 struct object_type;
-struct player_type;
+class PlayerType;
 
 class PlayerSkill {
 public:
-    PlayerSkill(player_type *player_ptr);
+    PlayerSkill(PlayerType *player_ptr);
 
     static SUB_EXP weapon_exp_at(PlayerSkillRank rank);
     static SUB_EXP spell_exp_at(PlayerSkillRank rank);
@@ -72,5 +72,5 @@ public:
     EXP exp_of_spell(int realm, int spell_idx) const;
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index 9729ec0..f8db0b3 100644 (file)
@@ -51,7 +51,7 @@ namespace {
  * @param tr_flag 特性フラグ
  * @return tr_flag が得られる要因となるフラグの集合
  */
-BIT_FLAGS common_cause_flags(player_type *player_ptr, tr_type tr_flag)
+BIT_FLAGS common_cause_flags(PlayerType *player_ptr, tr_type tr_flag)
 {
     BIT_FLAGS result = check_equipment_flags(player_ptr, tr_flag);
 
@@ -111,7 +111,7 @@ BIT_FLAGS convert_inventory_slot_type_to_flag_cause(inventory_slot_type inventor
 /*!
  * @brief 装備による所定の特性フラグを得ているかを一括して取得する関数。
  */
-BIT_FLAGS check_equipment_flags(player_type *player_ptr, tr_type tr_flag)
+BIT_FLAGS check_equipment_flags(PlayerType *player_ptr, tr_type tr_flag)
 {
     object_type *o_ptr;
     BIT_FLAGS result = 0L;
@@ -128,7 +128,7 @@ BIT_FLAGS check_equipment_flags(player_type *player_ptr, tr_type tr_flag)
     return result;
 }
 
-BIT_FLAGS player_flags_brand_pois(player_type *player_ptr)
+BIT_FLAGS player_flags_brand_pois(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_BRAND_POIS);
 
@@ -138,7 +138,7 @@ BIT_FLAGS player_flags_brand_pois(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS player_flags_brand_acid(player_type *player_ptr)
+BIT_FLAGS player_flags_brand_acid(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_BRAND_ACID);
 
@@ -148,7 +148,7 @@ BIT_FLAGS player_flags_brand_acid(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS player_flags_brand_elec(player_type *player_ptr)
+BIT_FLAGS player_flags_brand_elec(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_BRAND_ELEC);
 
@@ -158,7 +158,7 @@ BIT_FLAGS player_flags_brand_elec(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS player_flags_brand_fire(player_type *player_ptr)
+BIT_FLAGS player_flags_brand_fire(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_BRAND_FIRE);
 
@@ -168,7 +168,7 @@ BIT_FLAGS player_flags_brand_fire(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS player_flags_brand_cold(player_type *player_ptr)
+BIT_FLAGS player_flags_brand_cold(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_BRAND_COLD);
 
@@ -183,7 +183,7 @@ BIT_FLAGS player_flags_brand_cold(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param tr_flag 要求する装備フラグ
  */
-BIT_FLAGS get_player_flags(player_type *player_ptr, tr_type tr_flag)
+BIT_FLAGS get_player_flags(PlayerType *player_ptr, tr_type tr_flag)
 {
     switch (tr_flag) {
     case TR_STR:
@@ -464,7 +464,7 @@ BIT_FLAGS get_player_flags(player_type *player_ptr, tr_type tr_flag)
 /*!
  * @brief プレイヤーが壁破壊進行を持っているかを返す。
  */
-bool has_kill_wall(player_type *player_ptr)
+bool has_kill_wall(PlayerType *player_ptr)
 {
     if (player_ptr->mimic_form == MIMIC_DEMON_LORD || music_singing(player_ptr, MUSIC_WALL)) {
         return true;
@@ -488,7 +488,7 @@ bool has_kill_wall(player_type *player_ptr)
  * * 時限で幽体化、壁抜けをもつか種族幽霊ならばひとまずTRUE。
  * * 但し騎乗中は乗騎が壁抜けを持っていなければ不能になる。
  */
-bool has_pass_wall(player_type *player_ptr)
+bool has_pass_wall(PlayerType *player_ptr)
 {
     bool pow = false;
 
@@ -511,7 +511,7 @@ bool has_pass_wall(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_xtra_might(player_type *player_ptr)
+BIT_FLAGS has_xtra_might(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_XTRA_MIGHT);
 }
@@ -521,7 +521,7 @@ BIT_FLAGS has_xtra_might(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_evil(player_type *player_ptr)
+BIT_FLAGS has_esp_evil(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_ESP_EVIL);
     if (player_ptr->realm1 == REALM_HEX) {
@@ -536,7 +536,7 @@ BIT_FLAGS has_esp_evil(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_animal(player_type *player_ptr)
+BIT_FLAGS has_esp_animal(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_ANIMAL);
 }
@@ -546,7 +546,7 @@ BIT_FLAGS has_esp_animal(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_undead(player_type *player_ptr)
+BIT_FLAGS has_esp_undead(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_UNDEAD);
 }
@@ -556,7 +556,7 @@ BIT_FLAGS has_esp_undead(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_demon(player_type *player_ptr)
+BIT_FLAGS has_esp_demon(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_DEMON);
 }
@@ -566,7 +566,7 @@ BIT_FLAGS has_esp_demon(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_orc(player_type *player_ptr)
+BIT_FLAGS has_esp_orc(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_ORC);
 }
@@ -576,7 +576,7 @@ BIT_FLAGS has_esp_orc(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_troll(player_type *player_ptr)
+BIT_FLAGS has_esp_troll(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_TROLL);
 }
@@ -586,7 +586,7 @@ BIT_FLAGS has_esp_troll(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_giant(player_type *player_ptr)
+BIT_FLAGS has_esp_giant(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_GIANT);
 }
@@ -596,7 +596,7 @@ BIT_FLAGS has_esp_giant(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_dragon(player_type *player_ptr)
+BIT_FLAGS has_esp_dragon(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_DRAGON);
 }
@@ -606,7 +606,7 @@ BIT_FLAGS has_esp_dragon(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_human(player_type *player_ptr)
+BIT_FLAGS has_esp_human(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_HUMAN);
 }
@@ -616,7 +616,7 @@ BIT_FLAGS has_esp_human(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_good(player_type *player_ptr)
+BIT_FLAGS has_esp_good(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_GOOD);
 }
@@ -626,7 +626,7 @@ BIT_FLAGS has_esp_good(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_nonliving(player_type *player_ptr)
+BIT_FLAGS has_esp_nonliving(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_NONLIVING);
 }
@@ -636,7 +636,7 @@ BIT_FLAGS has_esp_nonliving(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_unique(player_type *player_ptr)
+BIT_FLAGS has_esp_unique(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_ESP_UNIQUE);
 }
@@ -646,7 +646,7 @@ BIT_FLAGS has_esp_unique(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 持っていたら所持前提ビットフラグを返す。
  */
-BIT_FLAGS has_esp_telepathy(player_type *player_ptr)
+BIT_FLAGS has_esp_telepathy(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_TELEPATHY);
 
@@ -661,27 +661,27 @@ BIT_FLAGS has_esp_telepathy(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_bless_blade(player_type *player_ptr)
+BIT_FLAGS has_bless_blade(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_BLESSED);
 }
 
-BIT_FLAGS has_easy2_weapon(player_type *player_ptr)
+BIT_FLAGS has_easy2_weapon(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_EASY2_WEAPON);
 }
 
-BIT_FLAGS has_down_saving(player_type *player_ptr)
+BIT_FLAGS has_down_saving(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_DOWN_SAVING);
 }
 
-BIT_FLAGS has_no_ac(player_type *player_ptr)
+BIT_FLAGS has_no_ac(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_NO_AC);
 }
 
-BIT_FLAGS has_invuln_arrow(player_type *player_ptr)
+BIT_FLAGS has_invuln_arrow(PlayerType *player_ptr)
 {
     if (player_ptr->blind)
         return 0;
@@ -689,7 +689,7 @@ BIT_FLAGS has_invuln_arrow(player_type *player_ptr)
     return common_cause_flags(player_ptr, TR_INVULN_ARROW);
 }
 
-void check_no_flowed(player_type *player_ptr)
+void check_no_flowed(PlayerType *player_ptr)
 {
     object_type *o_ptr;
     bool has_sw = false, has_kabe = false;
@@ -735,17 +735,17 @@ void check_no_flowed(player_type *player_ptr)
     }
 }
 
-BIT_FLAGS has_mighty_throw(player_type *player_ptr)
+BIT_FLAGS has_mighty_throw(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_MIGHTY_THROW);
 }
 
-BIT_FLAGS has_dec_mana(player_type *player_ptr)
+BIT_FLAGS has_dec_mana(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_DEC_MANA);
 }
 
-BIT_FLAGS has_reflect(player_type *player_ptr)
+BIT_FLAGS has_reflect(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_REFLECT);
 
@@ -756,12 +756,12 @@ BIT_FLAGS has_reflect(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_see_nocto(player_type *player_ptr)
+BIT_FLAGS has_see_nocto(PlayerType *player_ptr)
 {
     return (player_ptr->pclass == PlayerClassType::NINJA) ? FLAG_CAUSE_CLASS : FLAG_CAUSE_NONE;
 }
 
-BIT_FLAGS has_warning(player_type *player_ptr)
+BIT_FLAGS has_warning(PlayerType *player_ptr)
 {
     BIT_FLAGS result = 0L;
     object_type *o_ptr;
@@ -781,17 +781,17 @@ BIT_FLAGS has_warning(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_anti_magic(player_type *player_ptr)
+BIT_FLAGS has_anti_magic(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_NO_MAGIC);
 }
 
-BIT_FLAGS has_anti_tele(player_type *player_ptr)
+BIT_FLAGS has_anti_tele(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_NO_TELE);
 }
 
-BIT_FLAGS has_sh_fire(player_type *player_ptr)
+BIT_FLAGS has_sh_fire(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SH_FIRE);
 
@@ -806,7 +806,7 @@ BIT_FLAGS has_sh_fire(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_sh_elec(player_type *player_ptr)
+BIT_FLAGS has_sh_elec(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SH_ELEC);
 
@@ -820,7 +820,7 @@ BIT_FLAGS has_sh_elec(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_sh_cold(player_type *player_ptr)
+BIT_FLAGS has_sh_cold(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SH_COLD);
 
@@ -831,17 +831,17 @@ BIT_FLAGS has_sh_cold(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_easy_spell(player_type *player_ptr)
+BIT_FLAGS has_easy_spell(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_EASY_SPELL);
 }
 
-BIT_FLAGS has_heavy_spell(player_type *player_ptr)
+BIT_FLAGS has_heavy_spell(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_HEAVY_SPELL);
 }
 
-BIT_FLAGS has_hold_exp(player_type *player_ptr)
+BIT_FLAGS has_hold_exp(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_HOLD_EXP);
 
@@ -856,7 +856,7 @@ BIT_FLAGS has_hold_exp(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_see_inv(player_type *player_ptr)
+BIT_FLAGS has_see_inv(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SEE_INVIS);
 
@@ -867,12 +867,12 @@ BIT_FLAGS has_see_inv(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_magic_mastery(player_type *player_ptr)
+BIT_FLAGS has_magic_mastery(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_MAGIC_MASTERY);
 }
 
-BIT_FLAGS has_free_act(player_type *player_ptr)
+BIT_FLAGS has_free_act(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_FREE_ACT);
 
@@ -886,7 +886,7 @@ BIT_FLAGS has_free_act(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_sustain_str(player_type *player_ptr)
+BIT_FLAGS has_sustain_str(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SUST_STR);
 
@@ -897,7 +897,7 @@ BIT_FLAGS has_sustain_str(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_sustain_int(player_type *player_ptr)
+BIT_FLAGS has_sustain_int(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SUST_INT);
 
@@ -908,7 +908,7 @@ BIT_FLAGS has_sustain_int(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_sustain_wis(player_type *player_ptr)
+BIT_FLAGS has_sustain_wis(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SUST_WIS);
 
@@ -919,7 +919,7 @@ BIT_FLAGS has_sustain_wis(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_sustain_dex(player_type *player_ptr)
+BIT_FLAGS has_sustain_dex(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SUST_DEX);
 
@@ -930,7 +930,7 @@ BIT_FLAGS has_sustain_dex(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_sustain_con(player_type *player_ptr)
+BIT_FLAGS has_sustain_con(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SUST_CON);
 
@@ -941,7 +941,7 @@ BIT_FLAGS has_sustain_con(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_sustain_chr(player_type *player_ptr)
+BIT_FLAGS has_sustain_chr(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SUST_CHR);
 
@@ -952,7 +952,7 @@ BIT_FLAGS has_sustain_chr(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_levitation(player_type *player_ptr)
+BIT_FLAGS has_levitation(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_LEVITATION);
 
@@ -978,7 +978,7 @@ BIT_FLAGS has_levitation(player_type *player_ptr)
     return result;
 }
 
-bool has_can_swim(player_type *player_ptr)
+bool has_can_swim(PlayerType *player_ptr)
 {
     bool can_swim = false;
     if (player_ptr->riding) {
@@ -991,7 +991,7 @@ bool has_can_swim(player_type *player_ptr)
     return can_swim;
 }
 
-BIT_FLAGS has_slow_digest(player_type *player_ptr)
+BIT_FLAGS has_slow_digest(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_SLOW_DIGEST);
 
@@ -1002,7 +1002,7 @@ BIT_FLAGS has_slow_digest(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_regenerate(player_type *player_ptr)
+BIT_FLAGS has_regenerate(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_REGEN);
 
@@ -1019,7 +1019,7 @@ BIT_FLAGS has_regenerate(player_type *player_ptr)
     return result;
 }
 
-void update_curses(player_type *player_ptr)
+void update_curses(PlayerType *player_ptr)
 {
     object_type *o_ptr;
     player_ptr->cursed.clear();
@@ -1095,17 +1095,17 @@ void update_curses(player_type *player_ptr)
         player_ptr->cursed_special.reset(CurseSpecialTraitType::TELEPORT_SELF);
 }
 
-BIT_FLAGS has_impact(player_type *player_ptr)
+BIT_FLAGS has_impact(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_IMPACT);
 }
 
-BIT_FLAGS has_earthquake(player_type *player_ptr)
+BIT_FLAGS has_earthquake(PlayerType *player_ptr)
 {
     return common_cause_flags(player_ptr, TR_EARTHQUAKE);
 }
 
-void update_extra_blows(player_type *player_ptr)
+void update_extra_blows(PlayerType *player_ptr)
 {
     object_type *o_ptr;
     player_ptr->extra_blows[0] = player_ptr->extra_blows[1] = 0;
@@ -1132,7 +1132,7 @@ void update_extra_blows(player_type *player_ptr)
     }
 }
 
-BIT_FLAGS has_resist_acid(player_type *player_ptr)
+BIT_FLAGS has_resist_acid(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_ACID);
 
@@ -1145,7 +1145,7 @@ BIT_FLAGS has_resist_acid(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_vuln_acid(player_type *player_ptr)
+BIT_FLAGS has_vuln_acid(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_VUL_ACID);
 
@@ -1156,7 +1156,7 @@ BIT_FLAGS has_vuln_acid(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_elec(player_type *player_ptr)
+BIT_FLAGS has_resist_elec(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_ELEC);
 
@@ -1169,7 +1169,7 @@ BIT_FLAGS has_resist_elec(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_vuln_elec(player_type *player_ptr)
+BIT_FLAGS has_vuln_elec(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_VUL_ELEC);
 
@@ -1180,7 +1180,7 @@ BIT_FLAGS has_vuln_elec(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_fire(player_type *player_ptr)
+BIT_FLAGS has_resist_fire(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_FIRE);
 
@@ -1193,7 +1193,7 @@ BIT_FLAGS has_resist_fire(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_vuln_fire(player_type *player_ptr)
+BIT_FLAGS has_vuln_fire(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_VUL_FIRE);
 
@@ -1204,7 +1204,7 @@ BIT_FLAGS has_vuln_fire(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_cold(player_type *player_ptr)
+BIT_FLAGS has_resist_cold(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_COLD);
 
@@ -1217,7 +1217,7 @@ BIT_FLAGS has_resist_cold(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_vuln_cold(player_type *player_ptr)
+BIT_FLAGS has_vuln_cold(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_VUL_COLD);
 
@@ -1228,7 +1228,7 @@ BIT_FLAGS has_vuln_cold(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_pois(player_type *player_ptr)
+BIT_FLAGS has_resist_pois(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_POIS);
 
@@ -1239,7 +1239,7 @@ BIT_FLAGS has_resist_pois(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_conf(player_type *player_ptr)
+BIT_FLAGS has_resist_conf(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_CONF);
 
@@ -1254,7 +1254,7 @@ BIT_FLAGS has_resist_conf(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_sound(player_type *player_ptr)
+BIT_FLAGS has_resist_sound(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_SOUND);
 
@@ -1265,7 +1265,7 @@ BIT_FLAGS has_resist_sound(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_lite(player_type *player_ptr)
+BIT_FLAGS has_resist_lite(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_LITE);
 
@@ -1276,7 +1276,7 @@ BIT_FLAGS has_resist_lite(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_vuln_lite(player_type *player_ptr)
+BIT_FLAGS has_vuln_lite(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_VUL_LITE);
 
@@ -1287,7 +1287,7 @@ BIT_FLAGS has_vuln_lite(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_dark(player_type *player_ptr)
+BIT_FLAGS has_resist_dark(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_DARK);
 
@@ -1298,7 +1298,7 @@ BIT_FLAGS has_resist_dark(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_chaos(player_type *player_ptr)
+BIT_FLAGS has_resist_chaos(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_CHAOS);
 
@@ -1309,7 +1309,7 @@ BIT_FLAGS has_resist_chaos(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_disen(player_type *player_ptr)
+BIT_FLAGS has_resist_disen(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_DISEN);
 
@@ -1320,7 +1320,7 @@ BIT_FLAGS has_resist_disen(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_shard(player_type *player_ptr)
+BIT_FLAGS has_resist_shard(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_SHARDS);
 
@@ -1331,7 +1331,7 @@ BIT_FLAGS has_resist_shard(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_nexus(player_type *player_ptr)
+BIT_FLAGS has_resist_nexus(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_NEXUS);
 
@@ -1342,7 +1342,7 @@ BIT_FLAGS has_resist_nexus(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_blind(player_type *player_ptr)
+BIT_FLAGS has_resist_blind(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_BLIND);
 
@@ -1357,7 +1357,7 @@ BIT_FLAGS has_resist_blind(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_neth(player_type *player_ptr)
+BIT_FLAGS has_resist_neth(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_NETHER);
 
@@ -1368,7 +1368,7 @@ BIT_FLAGS has_resist_neth(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_time(player_type *player_ptr)
+BIT_FLAGS has_resist_time(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_TIME);
 
@@ -1379,7 +1379,7 @@ BIT_FLAGS has_resist_time(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_water(player_type *player_ptr)
+BIT_FLAGS has_resist_water(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_WATER);
 
@@ -1396,7 +1396,7 @@ BIT_FLAGS has_resist_water(player_type *player_ptr)
  * @param プレイヤー情報への参照ポインタ
  * @return 呪力耐性を所持していればTRUE、なければFALSE
  */
-BIT_FLAGS has_resist_curse(player_type *player_ptr)
+BIT_FLAGS has_resist_curse(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_CURSE);
 
@@ -1407,7 +1407,7 @@ BIT_FLAGS has_resist_curse(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_resist_fear(player_type *player_ptr)
+BIT_FLAGS has_resist_fear(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_RES_FEAR);
 
@@ -1421,7 +1421,7 @@ BIT_FLAGS has_resist_fear(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_immune_acid(player_type *player_ptr)
+BIT_FLAGS has_immune_acid(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_IM_ACID);
 
@@ -1433,7 +1433,7 @@ BIT_FLAGS has_immune_acid(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_immune_elec(player_type *player_ptr)
+BIT_FLAGS has_immune_elec(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_IM_ELEC);
 
@@ -1445,7 +1445,7 @@ BIT_FLAGS has_immune_elec(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_immune_fire(player_type *player_ptr)
+BIT_FLAGS has_immune_fire(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_IM_FIRE);
 
@@ -1457,7 +1457,7 @@ BIT_FLAGS has_immune_fire(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_immune_cold(player_type *player_ptr)
+BIT_FLAGS has_immune_cold(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_IM_COLD);
 
@@ -1469,7 +1469,7 @@ BIT_FLAGS has_immune_cold(player_type *player_ptr)
     return result;
 }
 
-BIT_FLAGS has_immune_dark(player_type *player_ptr)
+BIT_FLAGS has_immune_dark(PlayerType *player_ptr)
 {
     BIT_FLAGS result = common_cause_flags(player_ptr, TR_IM_DARK);
 
@@ -1480,7 +1480,7 @@ BIT_FLAGS has_immune_dark(player_type *player_ptr)
     return result;
 }
 
-melee_type player_melee_type(player_type *player_ptr)
+melee_type player_melee_type(PlayerType *player_ptr)
 {
     if (has_two_handed_weapons(player_ptr))
         return MELEE_TYPE_WEAPON_TWOHAND;
@@ -1513,7 +1513,7 @@ melee_type player_melee_type(player_type *player_ptr)
  *        利き手が素手かつ左手も素手もしくは盾を装備している事を意味する。
  * @details Includes martial arts and hand combats as weapons.
  */
-bool can_attack_with_main_hand(player_type *player_ptr)
+bool can_attack_with_main_hand(PlayerType *player_ptr)
 {
     if (has_melee_weapon(player_ptr, INVEN_MAIN_HAND))
         return true;
@@ -1529,7 +1529,7 @@ bool can_attack_with_main_hand(player_type *player_ptr)
  *        非利き手で攻撃可能とは、非利き手に武器を持っている事に等しい
  * @details Exclude martial arts and hand combats from weapons.
  */
-bool can_attack_with_sub_hand(player_type *player_ptr)
+bool can_attack_with_sub_hand(PlayerType *player_ptr)
 {
     return has_melee_weapon(player_ptr, INVEN_SUB_HAND);
 }
@@ -1537,7 +1537,7 @@ bool can_attack_with_sub_hand(player_type *player_ptr)
 /*
  * @brief 両手持ち状態かどうかを判定する
  */
-bool has_two_handed_weapons(player_type *player_ptr)
+bool has_two_handed_weapons(PlayerType *player_ptr)
 {
     if (can_two_hands_wielding(player_ptr)) {
         if (can_attack_with_main_hand(player_ptr) && (empty_hands(player_ptr, false) == EMPTY_HAND_SUB)
@@ -1551,7 +1551,7 @@ bool has_two_handed_weapons(player_type *player_ptr)
     return false;
 }
 
-BIT_FLAGS has_lite(player_type *player_ptr)
+BIT_FLAGS has_lite(PlayerType *player_ptr)
 {
     BIT_FLAGS result = 0L;
     if (player_ptr->pclass == PlayerClassType::NINJA)
@@ -1579,7 +1579,7 @@ BIT_FLAGS has_lite(player_type *player_ptr)
  *  Only can get hit bonuses when wieids an enough light weapon which is lighter than 5 times of weight limit.
  *  If its weight is 10 times heavier or more than weight limit, gets hit penalty in calc_to_hit().
  */
-bool has_disable_two_handed_bonus(player_type *player_ptr, int i)
+bool has_disable_two_handed_bonus(PlayerType *player_ptr, int i)
 {
     if (has_melee_weapon(player_ptr, INVEN_MAIN_HAND + i) && has_two_handed_weapons(player_ptr)) {
         object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + i];
@@ -1598,7 +1598,7 @@ bool has_disable_two_handed_bonus(player_type *player_ptr, int i)
  * @brief ふさわしくない武器を持っているかどうかを返す。
  * @todo 相応しい時にFALSEで相応しくない時にTRUEという負論理は良くない、後で修正する
  */
-bool is_wielding_icky_weapon(player_type *player_ptr, int i)
+bool is_wielding_icky_weapon(PlayerType *player_ptr, int i)
 {
     auto *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + i];
     auto flgs = object_flags(o_ptr);
@@ -1624,7 +1624,7 @@ bool is_wielding_icky_weapon(player_type *player_ptr, int i)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param i 武器を持っている手。0ならば利き手、1ならば反対の手
  */
-bool is_wielding_icky_riding_weapon(player_type *player_ptr, int i)
+bool is_wielding_icky_riding_weapon(PlayerType *player_ptr, int i)
 {
     auto *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + i];
     auto flgs = object_flags(o_ptr);
@@ -1633,7 +1633,7 @@ bool is_wielding_icky_riding_weapon(player_type *player_ptr, int i)
     return (player_ptr->riding > 0) && !has_no_weapon && !is_suitable;
 }
 
-bool has_not_ninja_weapon(player_type *player_ptr, int i)
+bool has_not_ninja_weapon(PlayerType *player_ptr, int i)
 {
     if (!has_melee_weapon(player_ptr, INVEN_MAIN_HAND + i)) {
         return false;
@@ -1646,7 +1646,7 @@ bool has_not_ninja_weapon(player_type *player_ptr, int i)
                (player_ptr->inventory_list[INVEN_SUB_HAND - i].tval != ItemKindType::SHIELD));
 }
 
-bool has_not_monk_weapon(player_type *player_ptr, int i)
+bool has_not_monk_weapon(PlayerType *player_ptr, int i)
 {
     if (!has_melee_weapon(player_ptr, INVEN_MAIN_HAND + i)) {
         return false;
@@ -1657,12 +1657,12 @@ bool has_not_monk_weapon(player_type *player_ptr, int i)
     return ((player_ptr->pclass == PlayerClassType::MONK) || (player_ptr->pclass == PlayerClassType::FORCETRAINER)) && !(s_info[enum2i(player_ptr->pclass)].w_max[tval][sval]);
 }
 
-bool has_good_luck(player_type *player_ptr)
+bool has_good_luck(PlayerType *player_ptr)
 {
     return (player_ptr->ppersonality == PERSONALITY_LUCKY) || (player_ptr->muta.has(PlayerMutationType::GOOD_LUCK));
 }
 
-BIT_FLAGS player_aggravate_state(player_type *player_ptr)
+BIT_FLAGS player_aggravate_state(PlayerType *player_ptr)
 {
     if (player_ptr->cursed.has(CurseTraitType::AGGRAVATE)) {
         if ((PlayerRace(player_ptr).equals(PlayerRaceType::S_FAIRY)) && (player_ptr->ppersonality != PERSONALITY_SEXY)) {
@@ -1674,7 +1674,7 @@ BIT_FLAGS player_aggravate_state(player_type *player_ptr)
     return AGGRAVATE_NONE;
 }
 
-bool has_aggravate(player_type *player_ptr)
+bool has_aggravate(PlayerType *player_ptr)
 {
     return player_aggravate_state(player_ptr) == AGGRAVATE_NORMAL;
 }
index e753d4b..92b0416 100644 (file)
@@ -47,101 +47,101 @@ enum aggravate_state {
     AGGRAVATE_NORMAL = 0x00000002L,
 };
 
-struct player_type;
+class PlayerType;
 BIT_FLAGS convert_inventory_slot_type_to_flag_cause(inventory_slot_type inventory_slot);
-BIT_FLAGS check_equipment_flags(player_type *player_ptr, tr_type tr_flag);
-BIT_FLAGS get_player_flags(player_type *player_ptr, tr_type tr_flag);
-bool has_pass_wall(player_type *player_ptr);
-bool has_kill_wall(player_type *player_ptr);
-BIT_FLAGS has_xtra_might(player_type *player_ptr);
-BIT_FLAGS has_esp_evil(player_type *player_ptr);
-BIT_FLAGS has_esp_animal(player_type *player_ptr);
-BIT_FLAGS has_esp_undead(player_type *player_ptr);
-BIT_FLAGS has_esp_demon(player_type *player_ptr);
-BIT_FLAGS has_esp_orc(player_type *player_ptr);
-BIT_FLAGS has_esp_troll(player_type *player_ptr);
-BIT_FLAGS has_esp_giant(player_type *player_ptr);
-BIT_FLAGS has_esp_dragon(player_type *player_ptr);
-BIT_FLAGS has_esp_human(player_type *player_ptr);
-BIT_FLAGS has_esp_good(player_type *player_ptr);
-BIT_FLAGS has_esp_nonliving(player_type *player_ptr);
-BIT_FLAGS has_esp_unique(player_type *player_ptr);
-BIT_FLAGS has_esp_telepathy(player_type *player_ptr);
-BIT_FLAGS has_bless_blade(player_type *player_ptr);
-BIT_FLAGS has_easy2_weapon(player_type *player_ptr);
-BIT_FLAGS has_down_saving(player_type *player_ptr);
-BIT_FLAGS has_no_ac(player_type *player_ptr);
-BIT_FLAGS has_invuln_arrow(player_type *player_ptr);
-void check_no_flowed(player_type *player_ptr);
-BIT_FLAGS has_mighty_throw(player_type *player_ptr);
-BIT_FLAGS has_dec_mana(player_type *player_ptr);
-BIT_FLAGS has_reflect(player_type *player_ptr);
-BIT_FLAGS has_see_nocto(player_type *player_ptr);
-BIT_FLAGS has_warning(player_type *player_ptr);
-BIT_FLAGS has_anti_magic(player_type *player_ptr);
-BIT_FLAGS has_anti_tele(player_type *player_ptr);
-BIT_FLAGS has_sh_fire(player_type *player_ptr);
-BIT_FLAGS has_sh_elec(player_type *player_ptr);
-BIT_FLAGS has_sh_cold(player_type *player_ptr);
-BIT_FLAGS has_easy_spell(player_type *player_ptr);
-BIT_FLAGS has_heavy_spell(player_type *player_ptr);
-BIT_FLAGS has_hold_exp(player_type *player_ptr);
-BIT_FLAGS has_see_inv(player_type *player_ptr);
-BIT_FLAGS has_magic_mastery(player_type *player_ptr);
-BIT_FLAGS has_free_act(player_type *player_ptr);
-BIT_FLAGS has_sustain_str(player_type *player_ptr);
-BIT_FLAGS has_sustain_int(player_type *player_ptr);
-BIT_FLAGS has_sustain_wis(player_type *player_ptr);
-BIT_FLAGS has_sustain_dex(player_type *player_ptr);
-BIT_FLAGS has_sustain_con(player_type *player_ptr);
-BIT_FLAGS has_sustain_chr(player_type *player_ptr);
-BIT_FLAGS has_levitation(player_type *player_ptr);
-bool has_can_swim(player_type *player_ptr);
-BIT_FLAGS has_slow_digest(player_type *player_ptr);
-BIT_FLAGS has_regenerate(player_type *player_ptr);
-void update_curses(player_type *player_ptr);
-BIT_FLAGS has_impact(player_type *player_ptr);
-BIT_FLAGS has_earthquake(player_type *player_ptr);
-void update_extra_blows(player_type *player_ptr);
-BIT_FLAGS has_resist_acid(player_type *player_ptr);
-BIT_FLAGS has_vuln_acid(player_type *player_ptr);
-BIT_FLAGS has_resist_elec(player_type *player_ptr);
-BIT_FLAGS has_vuln_elec(player_type *player_ptr);
-BIT_FLAGS has_resist_fire(player_type *player_ptr);
-BIT_FLAGS has_vuln_fire(player_type *player_ptr);
-BIT_FLAGS has_resist_cold(player_type *player_ptr);
-BIT_FLAGS has_vuln_cold(player_type *player_ptr);
-BIT_FLAGS has_resist_pois(player_type *player_ptr);
-BIT_FLAGS has_resist_conf(player_type *player_ptr);
-BIT_FLAGS has_resist_sound(player_type *player_ptr);
-BIT_FLAGS has_resist_lite(player_type *player_ptr);
-BIT_FLAGS has_vuln_lite(player_type *player_ptr);
-BIT_FLAGS has_resist_dark(player_type *player_ptr);
-BIT_FLAGS has_resist_chaos(player_type *player_ptr);
-BIT_FLAGS has_resist_disen(player_type *player_ptr);
-BIT_FLAGS has_resist_shard(player_type *player_ptr);
-BIT_FLAGS has_resist_nexus(player_type *player_ptr);
-BIT_FLAGS has_resist_blind(player_type *player_ptr);
-BIT_FLAGS has_resist_neth(player_type *player_ptr);
-BIT_FLAGS has_resist_time(player_type *player_ptr);
-BIT_FLAGS has_resist_water(player_type *player_ptr);
-BIT_FLAGS has_resist_curse(player_type *player_ptr);
-BIT_FLAGS has_resist_fear(player_type *player_ptr);
-BIT_FLAGS has_immune_acid(player_type *player_ptr);
-BIT_FLAGS has_immune_elec(player_type *player_ptr);
-BIT_FLAGS has_immune_fire(player_type *player_ptr);
-BIT_FLAGS has_immune_cold(player_type *player_ptr);
-BIT_FLAGS has_immune_dark(player_type *player_ptr);
-bool can_attack_with_main_hand(player_type *player_ptr);
-bool can_attack_with_sub_hand(player_type *player_ptr);
-bool has_two_handed_weapons(player_type *player_ptr);
-BIT_FLAGS has_lite(player_type *player_ptr);
-bool has_disable_two_handed_bonus(player_type *player_ptr, int i);
-bool has_not_ninja_weapon(player_type *player_ptr, int i);
-bool has_not_monk_weapon(player_type *player_ptr, int i);
-bool is_wielding_icky_weapon(player_type *player_ptr, int i);
-bool is_wielding_icky_riding_weapon(player_type *player_ptr, int i);
-bool has_good_luck(player_type *player_ptr);
-BIT_FLAGS player_aggravate_state(player_type *player_ptr);
-melee_type player_melee_type(player_type *player_ptr);
-bool has_aggravate(player_type *player_ptr);
+BIT_FLAGS check_equipment_flags(PlayerType *player_ptr, tr_type tr_flag);
+BIT_FLAGS get_player_flags(PlayerType *player_ptr, tr_type tr_flag);
+bool has_pass_wall(PlayerType *player_ptr);
+bool has_kill_wall(PlayerType *player_ptr);
+BIT_FLAGS has_xtra_might(PlayerType *player_ptr);
+BIT_FLAGS has_esp_evil(PlayerType *player_ptr);
+BIT_FLAGS has_esp_animal(PlayerType *player_ptr);
+BIT_FLAGS has_esp_undead(PlayerType *player_ptr);
+BIT_FLAGS has_esp_demon(PlayerType *player_ptr);
+BIT_FLAGS has_esp_orc(PlayerType *player_ptr);
+BIT_FLAGS has_esp_troll(PlayerType *player_ptr);
+BIT_FLAGS has_esp_giant(PlayerType *player_ptr);
+BIT_FLAGS has_esp_dragon(PlayerType *player_ptr);
+BIT_FLAGS has_esp_human(PlayerType *player_ptr);
+BIT_FLAGS has_esp_good(PlayerType *player_ptr);
+BIT_FLAGS has_esp_nonliving(PlayerType *player_ptr);
+BIT_FLAGS has_esp_unique(PlayerType *player_ptr);
+BIT_FLAGS has_esp_telepathy(PlayerType *player_ptr);
+BIT_FLAGS has_bless_blade(PlayerType *player_ptr);
+BIT_FLAGS has_easy2_weapon(PlayerType *player_ptr);
+BIT_FLAGS has_down_saving(PlayerType *player_ptr);
+BIT_FLAGS has_no_ac(PlayerType *player_ptr);
+BIT_FLAGS has_invuln_arrow(PlayerType *player_ptr);
+void check_no_flowed(PlayerType *player_ptr);
+BIT_FLAGS has_mighty_throw(PlayerType *player_ptr);
+BIT_FLAGS has_dec_mana(PlayerType *player_ptr);
+BIT_FLAGS has_reflect(PlayerType *player_ptr);
+BIT_FLAGS has_see_nocto(PlayerType *player_ptr);
+BIT_FLAGS has_warning(PlayerType *player_ptr);
+BIT_FLAGS has_anti_magic(PlayerType *player_ptr);
+BIT_FLAGS has_anti_tele(PlayerType *player_ptr);
+BIT_FLAGS has_sh_fire(PlayerType *player_ptr);
+BIT_FLAGS has_sh_elec(PlayerType *player_ptr);
+BIT_FLAGS has_sh_cold(PlayerType *player_ptr);
+BIT_FLAGS has_easy_spell(PlayerType *player_ptr);
+BIT_FLAGS has_heavy_spell(PlayerType *player_ptr);
+BIT_FLAGS has_hold_exp(PlayerType *player_ptr);
+BIT_FLAGS has_see_inv(PlayerType *player_ptr);
+BIT_FLAGS has_magic_mastery(PlayerType *player_ptr);
+BIT_FLAGS has_free_act(PlayerType *player_ptr);
+BIT_FLAGS has_sustain_str(PlayerType *player_ptr);
+BIT_FLAGS has_sustain_int(PlayerType *player_ptr);
+BIT_FLAGS has_sustain_wis(PlayerType *player_ptr);
+BIT_FLAGS has_sustain_dex(PlayerType *player_ptr);
+BIT_FLAGS has_sustain_con(PlayerType *player_ptr);
+BIT_FLAGS has_sustain_chr(PlayerType *player_ptr);
+BIT_FLAGS has_levitation(PlayerType *player_ptr);
+bool has_can_swim(PlayerType *player_ptr);
+BIT_FLAGS has_slow_digest(PlayerType *player_ptr);
+BIT_FLAGS has_regenerate(PlayerType *player_ptr);
+void update_curses(PlayerType *player_ptr);
+BIT_FLAGS has_impact(PlayerType *player_ptr);
+BIT_FLAGS has_earthquake(PlayerType *player_ptr);
+void update_extra_blows(PlayerType *player_ptr);
+BIT_FLAGS has_resist_acid(PlayerType *player_ptr);
+BIT_FLAGS has_vuln_acid(PlayerType *player_ptr);
+BIT_FLAGS has_resist_elec(PlayerType *player_ptr);
+BIT_FLAGS has_vuln_elec(PlayerType *player_ptr);
+BIT_FLAGS has_resist_fire(PlayerType *player_ptr);
+BIT_FLAGS has_vuln_fire(PlayerType *player_ptr);
+BIT_FLAGS has_resist_cold(PlayerType *player_ptr);
+BIT_FLAGS has_vuln_cold(PlayerType *player_ptr);
+BIT_FLAGS has_resist_pois(PlayerType *player_ptr);
+BIT_FLAGS has_resist_conf(PlayerType *player_ptr);
+BIT_FLAGS has_resist_sound(PlayerType *player_ptr);
+BIT_FLAGS has_resist_lite(PlayerType *player_ptr);
+BIT_FLAGS has_vuln_lite(PlayerType *player_ptr);
+BIT_FLAGS has_resist_dark(PlayerType *player_ptr);
+BIT_FLAGS has_resist_chaos(PlayerType *player_ptr);
+BIT_FLAGS has_resist_disen(PlayerType *player_ptr);
+BIT_FLAGS has_resist_shard(PlayerType *player_ptr);
+BIT_FLAGS has_resist_nexus(PlayerType *player_ptr);
+BIT_FLAGS has_resist_blind(PlayerType *player_ptr);
+BIT_FLAGS has_resist_neth(PlayerType *player_ptr);
+BIT_FLAGS has_resist_time(PlayerType *player_ptr);
+BIT_FLAGS has_resist_water(PlayerType *player_ptr);
+BIT_FLAGS has_resist_curse(PlayerType *player_ptr);
+BIT_FLAGS has_resist_fear(PlayerType *player_ptr);
+BIT_FLAGS has_immune_acid(PlayerType *player_ptr);
+BIT_FLAGS has_immune_elec(PlayerType *player_ptr);
+BIT_FLAGS has_immune_fire(PlayerType *player_ptr);
+BIT_FLAGS has_immune_cold(PlayerType *player_ptr);
+BIT_FLAGS has_immune_dark(PlayerType *player_ptr);
+bool can_attack_with_main_hand(PlayerType *player_ptr);
+bool can_attack_with_sub_hand(PlayerType *player_ptr);
+bool has_two_handed_weapons(PlayerType *player_ptr);
+BIT_FLAGS has_lite(PlayerType *player_ptr);
+bool has_disable_two_handed_bonus(PlayerType *player_ptr, int i);
+bool has_not_ninja_weapon(PlayerType *player_ptr, int i);
+bool has_not_monk_weapon(PlayerType *player_ptr, int i);
+bool is_wielding_icky_weapon(PlayerType *player_ptr, int i);
+bool is_wielding_icky_riding_weapon(PlayerType *player_ptr, int i);
+bool has_good_luck(PlayerType *player_ptr);
+BIT_FLAGS player_aggravate_state(PlayerType *player_ptr);
+melee_type player_melee_type(PlayerType *player_ptr);
+bool has_aggravate(PlayerType *player_ptr);
index 0d1db63..dca1200 100644 (file)
@@ -59,7 +59,7 @@ PERCENTAGE randrate(int dice, int fix, rate_calc_type_mode mode)
 /*!
  * @brief 酸属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_acid_damage_rate(player_type *player_ptr)
+PERCENTAGE calc_acid_damage_rate(PlayerType *player_ptr)
 {
     PERCENTAGE per = 100;
 
@@ -90,7 +90,7 @@ PERCENTAGE calc_acid_damage_rate(player_type *player_ptr)
 /*!
  * @brief 電撃属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_elec_damage_rate(player_type *player_ptr)
+PERCENTAGE calc_elec_damage_rate(PlayerType *player_ptr)
 {
     PERCENTAGE per = 100;
 
@@ -120,7 +120,7 @@ PERCENTAGE calc_elec_damage_rate(player_type *player_ptr)
 /*!
  * @brief 火炎属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_fire_damage_rate(player_type *player_ptr)
+PERCENTAGE calc_fire_damage_rate(PlayerType *player_ptr)
 {
     PERCENTAGE per = 100;
     BIT_FLAGS flgs = has_vuln_fire(player_ptr);
@@ -146,7 +146,7 @@ PERCENTAGE calc_fire_damage_rate(player_type *player_ptr)
 /*!
  * @brief 冷気属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_cold_damage_rate(player_type *player_ptr)
+PERCENTAGE calc_cold_damage_rate(PlayerType *player_ptr)
 {
     PERCENTAGE per = 100;
     BIT_FLAGS flgs = has_vuln_cold(player_ptr);
@@ -171,7 +171,7 @@ PERCENTAGE calc_cold_damage_rate(player_type *player_ptr)
 /*!
  * @brief 毒属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_pois_damage_rate(player_type *player_ptr)
+PERCENTAGE calc_pois_damage_rate(PlayerType *player_ptr)
 {
     PERCENTAGE per = 100;
     if (has_resist_pois(player_ptr))
@@ -185,7 +185,7 @@ PERCENTAGE calc_pois_damage_rate(player_type *player_ptr)
 /*!
  * @brief 放射性廃棄物攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_nuke_damage_rate(player_type *player_ptr)
+PERCENTAGE calc_nuke_damage_rate(PlayerType *player_ptr)
 {
 
     PERCENTAGE per = 100;
@@ -200,7 +200,7 @@ PERCENTAGE calc_nuke_damage_rate(player_type *player_ptr)
 /*!
  * @brief 死の光線に対するダメージ倍率計算
  */
-PERCENTAGE calc_deathray_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_deathray_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     if (player_ptr->mimic_form) {
@@ -229,7 +229,7 @@ PERCENTAGE calc_deathray_damage_rate(player_type *player_ptr, rate_calc_type_mod
 /*!
  * @brief 閃光属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_lite_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_lite_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -260,7 +260,7 @@ PERCENTAGE calc_lite_damage_rate(player_type *player_ptr, rate_calc_type_mode mo
 /*!
  * @brief 暗黒属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_dark_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_dark_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -278,7 +278,7 @@ PERCENTAGE calc_dark_damage_rate(player_type *player_ptr, rate_calc_type_mode mo
 /*!
  * @brief 破片属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_shards_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_shards_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -293,7 +293,7 @@ PERCENTAGE calc_shards_damage_rate(player_type *player_ptr, rate_calc_type_mode
 /*!
  * @brief 轟音属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_sound_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_sound_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -308,7 +308,7 @@ PERCENTAGE calc_sound_damage_rate(player_type *player_ptr, rate_calc_type_mode m
 /*!
  * @brief 混乱属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_conf_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_conf_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -323,7 +323,7 @@ PERCENTAGE calc_conf_damage_rate(player_type *player_ptr, rate_calc_type_mode mo
 /*!
  * @brief 混沌属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_chaos_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_chaos_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -338,7 +338,7 @@ PERCENTAGE calc_chaos_damage_rate(player_type *player_ptr, rate_calc_type_mode m
 /*!
  * @brief 劣化属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_disenchant_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_disenchant_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -353,7 +353,7 @@ PERCENTAGE calc_disenchant_damage_rate(player_type *player_ptr, rate_calc_type_m
 /*!
  * @brief 因果混乱属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_nexus_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_nexus_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -368,7 +368,7 @@ PERCENTAGE calc_nexus_damage_rate(player_type *player_ptr, rate_calc_type_mode m
 /*!
  * @brief ロケット属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_rocket_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_rocket_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     PERCENTAGE per = 100;
@@ -383,7 +383,7 @@ PERCENTAGE calc_rocket_damage_rate(player_type *player_ptr, rate_calc_type_mode
 /*!
  * @brief 地獄属性攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_nether_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_nether_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     PERCENTAGE per = 100;
 
@@ -400,7 +400,7 @@ PERCENTAGE calc_nether_damage_rate(player_type *player_ptr, rate_calc_type_mode
 /*!
  * @brief 時間逆転攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_time_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_time_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     PERCENTAGE per = 100;
@@ -416,7 +416,7 @@ PERCENTAGE calc_time_damage_rate(player_type *player_ptr, rate_calc_type_mode mo
 /*!
  * @brief 水流攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_water_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_water_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     PERCENTAGE per = 100;
@@ -432,7 +432,7 @@ PERCENTAGE calc_water_damage_rate(player_type *player_ptr, rate_calc_type_mode m
 /*!
  * @brief 聖なる火炎攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_holy_fire_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_holy_fire_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     PERCENTAGE per = 100;
@@ -446,7 +446,7 @@ PERCENTAGE calc_holy_fire_damage_rate(player_type *player_ptr, rate_calc_type_mo
 /*!
  * @brief 地獄の火炎攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_hell_fire_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_hell_fire_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     PERCENTAGE per = 100;
@@ -458,7 +458,7 @@ PERCENTAGE calc_hell_fire_damage_rate(player_type *player_ptr, rate_calc_type_mo
 /*!
  * @brief 重力攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_gravity_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_gravity_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     PERCENTAGE per = 100;
@@ -471,7 +471,7 @@ PERCENTAGE calc_gravity_damage_rate(player_type *player_ptr, rate_calc_type_mode
 /*!
  * @brief 虚無攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_void_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_void_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     PERCENTAGE per = 100;
@@ -489,7 +489,7 @@ PERCENTAGE calc_void_damage_rate(player_type *player_ptr, rate_calc_type_mode mo
 /*!
  * @brief 深淵攻撃に対するダメージ倍率計算
  */
-PERCENTAGE calc_abyss_damage_rate(player_type *player_ptr, rate_calc_type_mode mode)
+PERCENTAGE calc_abyss_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode)
 {
     (void)mode; // unused
     PERCENTAGE per = 100;
index 80068d6..6419eb0 100644 (file)
@@ -9,28 +9,28 @@ enum rate_calc_type_mode {
     CALC_MAX = 3,
 };
 
-struct player_type;
-PERCENTAGE calc_acid_damage_rate(player_type *player_ptr);
-PERCENTAGE calc_elec_damage_rate(player_type *player_ptr);
-PERCENTAGE calc_fire_damage_rate(player_type *player_ptr);
-PERCENTAGE calc_cold_damage_rate(player_type *player_ptr);
-PERCENTAGE calc_pois_damage_rate(player_type *player_ptr);
-PERCENTAGE calc_nuke_damage_rate(player_type *player_ptr);
-PERCENTAGE calc_lite_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_dark_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_shards_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_sound_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_conf_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_chaos_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_nether_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_disenchant_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_nexus_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_time_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_water_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_rocket_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_deathray_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_holy_fire_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_hell_fire_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_gravity_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_void_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
-PERCENTAGE calc_abyss_damage_rate(player_type *player_ptr, rate_calc_type_mode mode);
+class PlayerType;
+PERCENTAGE calc_acid_damage_rate(PlayerType *player_ptr);
+PERCENTAGE calc_elec_damage_rate(PlayerType *player_ptr);
+PERCENTAGE calc_fire_damage_rate(PlayerType *player_ptr);
+PERCENTAGE calc_cold_damage_rate(PlayerType *player_ptr);
+PERCENTAGE calc_pois_damage_rate(PlayerType *player_ptr);
+PERCENTAGE calc_nuke_damage_rate(PlayerType *player_ptr);
+PERCENTAGE calc_lite_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_dark_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_shards_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_sound_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_conf_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_chaos_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_nether_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_disenchant_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_nexus_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_time_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_water_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_rocket_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_deathray_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_holy_fire_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_hell_fire_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_gravity_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_void_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
+PERCENTAGE calc_abyss_damage_rate(PlayerType *player_ptr, rate_calc_type_mode mode);
index 9345ee1..07b8c54 100644 (file)
 
 static const int extra_magic_glove_reduce_mana = 1;
 
-static bool is_martial_arts_mode(player_type *player_ptr);
-
-static ACTION_SKILL_POWER calc_disarming(player_type *player_ptr);
-static ACTION_SKILL_POWER calc_device_ability(player_type *player_ptr);
-static ACTION_SKILL_POWER calc_saving_throw(player_type *player_ptr);
-static ACTION_SKILL_POWER calc_search(player_type *player_ptr);
-static ACTION_SKILL_POWER calc_search_freq(player_type *player_ptr);
-static ACTION_SKILL_POWER calc_to_hit_melee(player_type *player_ptr);
-static ACTION_SKILL_POWER calc_to_hit_shoot(player_type *player_ptr);
-static ACTION_SKILL_POWER calc_to_hit_throw(player_type *player_ptr);
-static ACTION_SKILL_POWER calc_skill_dig(player_type *player_ptr);
-static bool is_heavy_wield(player_type *player_ptr, int i);
-static int16_t calc_num_blow(player_type *player_ptr, int i);
-static int16_t calc_to_magic_chance(player_type *player_ptr);
-static ARMOUR_CLASS calc_base_ac(player_type *player_ptr);
-static ARMOUR_CLASS calc_to_ac(player_type *player_ptr, bool is_real_value);
-static int16_t calc_double_weapon_penalty(player_type *player_ptr, INVENTORY_IDX slot);
-static bool is_riding_two_hands(player_type *player_ptr);
-static int16_t calc_riding_bow_penalty(player_type *player_ptr);
-static void put_equipment_warning(player_type *player_ptr);
-
-static short calc_to_damage(player_type *player_ptr, INVENTORY_IDX slot, bool is_real_value);
-static int16_t calc_to_hit(player_type *player_ptr, INVENTORY_IDX slot, bool is_real_value);
-
-static int16_t calc_to_hit_bow(player_type *player_ptr, bool is_real_value);
-
-static int16_t calc_to_damage_misc(player_type *player_ptr);
-static int16_t calc_to_hit_misc(player_type *player_ptr);
-
-static DICE_NUMBER calc_to_weapon_dice_num(player_type *player_ptr, INVENTORY_IDX slot);
-static player_hand main_attack_hand(player_type *player_ptr);
+static bool is_martial_arts_mode(PlayerType *player_ptr);
+
+static ACTION_SKILL_POWER calc_disarming(PlayerType *player_ptr);
+static ACTION_SKILL_POWER calc_device_ability(PlayerType *player_ptr);
+static ACTION_SKILL_POWER calc_saving_throw(PlayerType *player_ptr);
+static ACTION_SKILL_POWER calc_search(PlayerType *player_ptr);
+static ACTION_SKILL_POWER calc_search_freq(PlayerType *player_ptr);
+static ACTION_SKILL_POWER calc_to_hit_melee(PlayerType *player_ptr);
+static ACTION_SKILL_POWER calc_to_hit_shoot(PlayerType *player_ptr);
+static ACTION_SKILL_POWER calc_to_hit_throw(PlayerType *player_ptr);
+static ACTION_SKILL_POWER calc_skill_dig(PlayerType *player_ptr);
+static bool is_heavy_wield(PlayerType *player_ptr, int i);
+static int16_t calc_num_blow(PlayerType *player_ptr, int i);
+static int16_t calc_to_magic_chance(PlayerType *player_ptr);
+static ARMOUR_CLASS calc_base_ac(PlayerType *player_ptr);
+static ARMOUR_CLASS calc_to_ac(PlayerType *player_ptr, bool is_real_value);
+static int16_t calc_double_weapon_penalty(PlayerType *player_ptr, INVENTORY_IDX slot);
+static bool is_riding_two_hands(PlayerType *player_ptr);
+static int16_t calc_riding_bow_penalty(PlayerType *player_ptr);
+static void put_equipment_warning(PlayerType *player_ptr);
+
+static short calc_to_damage(PlayerType *player_ptr, INVENTORY_IDX slot, bool is_real_value);
+static int16_t calc_to_hit(PlayerType *player_ptr, INVENTORY_IDX slot, bool is_real_value);
+
+static int16_t calc_to_hit_bow(PlayerType *player_ptr, bool is_real_value);
+
+static int16_t calc_to_damage_misc(PlayerType *player_ptr);
+static int16_t calc_to_hit_misc(PlayerType *player_ptr);
+
+static DICE_NUMBER calc_to_weapon_dice_num(PlayerType *player_ptr, INVENTORY_IDX slot);
+static player_hand main_attack_hand(PlayerType *player_ptr);
 
 /*** Player information ***/
 
@@ -155,7 +155,7 @@ static player_hand main_attack_hand(player_type *player_ptr);
  * @param player_ptr 主観となるプレイヤー構造体参照ポインタ
  * @todo 将来独自インターフェース実装にはz-term系に追い出すべきか?
  */
-static void delayed_visual_update(player_type *player_ptr)
+static void delayed_visual_update(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (int i = 0; i < floor_ptr->redraw_n; i++) {
@@ -184,7 +184,7 @@ static void delayed_visual_update(player_type *player_ptr)
  * @param o_ptr 判定する射撃武器のアイテム情報参照ポインタ
  * @return 重すぎるならばTRUE
  */
-static bool is_heavy_shoot(player_type *player_ptr, object_type *o_ptr)
+static bool is_heavy_shoot(PlayerType *player_ptr, object_type *o_ptr)
 {
     return (calc_bow_weight_limit(player_ptr) < o_ptr->weight / 10);
 }
@@ -194,7 +194,7 @@ static bool is_heavy_shoot(player_type *player_ptr, object_type *o_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 総重量
  */
-WEIGHT calc_inventory_weight(player_type *player_ptr)
+WEIGHT calc_inventory_weight(PlayerType *player_ptr)
 {
     WEIGHT weight = 0;
 
@@ -208,7 +208,7 @@ WEIGHT calc_inventory_weight(player_type *player_ptr)
     return weight;
 }
 
-static void update_ability_scores(player_type *player_ptr)
+static void update_ability_scores(PlayerType *player_ptr)
 {
     PlayerStrength player_str(player_ptr);
     PlayerIntelligence player_int(player_ptr);
@@ -247,7 +247,7 @@ static void update_ability_scores(player_type *player_ptr)
  * </pre>
  * @todo ここで計算していた各値は一部の状態変化メッセージ処理を除き、今後必要な時に適示計算する形に移行するためほぼすべて削られる。
  */
-static void update_bonuses(player_type *player_ptr)
+static void update_bonuses(PlayerType *player_ptr)
 {
     auto empty_hands_status = empty_hands(player_ptr, true);
     object_type *o_ptr;
@@ -407,7 +407,7 @@ static void update_bonuses(player_type *player_ptr)
  * Adjust current hitpoints if necessary
  * @details
  */
-static void update_max_hitpoints(player_type *player_ptr)
+static void update_max_hitpoints(PlayerType *player_ptr)
 {
     int bonus = ((int)(adj_con_mhp[player_ptr->stat_index[A_CON]]) - 128) * player_ptr->lev / 4;
     int mhp = player_ptr->player_hp[player_ptr->lev - 1];
@@ -474,7 +474,7 @@ static void update_max_hitpoints(player_type *player_ptr)
  * Note that this function induces various "status" messages,
  * which must be bypasses until the character is created.
  */
-static void update_num_of_spells(player_type *player_ptr)
+static void update_num_of_spells(PlayerType *player_ptr)
 {
     if (mp_ptr->spell_book == ItemKindType::NONE)
         return;
@@ -720,7 +720,7 @@ static void update_num_of_spells(player_type *player_ptr)
  * @details
  * This function induces status messages.
  */
-static void update_max_mana(player_type *player_ptr)
+static void update_max_mana(PlayerType *player_ptr)
 {
     if ((mp_ptr->spell_book == ItemKindType::NONE) && mp_ptr->spell_first == SPELL_FIRST_NO_SPELL)
         return;
@@ -935,7 +935,7 @@ static void update_max_mana(player_type *player_ptr)
  * @param o_ptr 計算する射撃武器のアイテム情報参照ポインタ
  * @return 射撃倍率の値(100で1.00倍)
  */
-int16_t calc_num_fire(player_type *player_ptr, object_type *o_ptr)
+int16_t calc_num_fire(PlayerType *player_ptr, object_type *o_ptr)
 {
     int extra_shots = 0;
 
@@ -1004,7 +1004,7 @@ int16_t calc_num_fire(player_type *player_ptr, object_type *o_ptr)
  * * 器用さに応じたadj_dex_disテーブルによる加算
  * * 知力に応じたadj_int_disテーブルによる加算
  */
-static ACTION_SKILL_POWER calc_disarming(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_disarming(PlayerType *player_ptr)
 {
     ACTION_SKILL_POWER pow;
     const player_race_info *tmp_rp_ptr;
@@ -1034,7 +1034,7 @@ static ACTION_SKILL_POWER calc_disarming(player_type *player_ptr)
  * * 知力に応じたadj_int_devテーブルによる加算
  * * 狂戦士化による減算(-20)
  */
-static ACTION_SKILL_POWER calc_device_ability(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_device_ability(PlayerType *player_ptr)
 {
     ACTION_SKILL_POWER pow;
     const player_race_info *tmp_rp_ptr;
@@ -1084,7 +1084,7 @@ static ACTION_SKILL_POWER calc_device_ability(player_type *player_ptr)
  * * 生命の「究極の耐性」や regist_magic,magicdef持ちなら大なり上書き(95+レベル未満ならその値に上書き)
  * * 呪いのdown_savingがかかっているなら半減
  */
-static ACTION_SKILL_POWER calc_saving_throw(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_saving_throw(PlayerType *player_ptr)
 {
     ACTION_SKILL_POWER pow;
     const player_race_info *tmp_rp_ptr;
@@ -1139,7 +1139,7 @@ static ACTION_SKILL_POWER calc_saving_throw(player_type *player_ptr)
  * * 狂戦士化による減算(-15)
  * * 変異(MUT3_XTRA_EYES)による加算(+15)
  */
-static ACTION_SKILL_POWER calc_search(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_search(PlayerType *player_ptr)
 {
     ACTION_SKILL_POWER pow;
     const player_race_info *tmp_rp_ptr;
@@ -1186,7 +1186,7 @@ static ACTION_SKILL_POWER calc_search(player_type *player_ptr)
  * * 狂戦士化による減算(-15)
  * * 変異(MUT3_XTRA_EYES)による加算(+15)
  */
-static ACTION_SKILL_POWER calc_search_freq(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_search_freq(PlayerType *player_ptr)
 {
     ACTION_SKILL_POWER pow;
     const player_race_info *tmp_rp_ptr;
@@ -1229,7 +1229,7 @@ static ACTION_SKILL_POWER calc_search_freq(player_type *player_ptr)
  * @details
  * * 種族/職業/性格による加算とレベルによる追加加算
  */
-static ACTION_SKILL_POWER calc_to_hit_melee(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_to_hit_melee(PlayerType *player_ptr)
 {
     ACTION_SKILL_POWER pow;
     const player_race_info *tmp_rp_ptr;
@@ -1253,7 +1253,7 @@ static ACTION_SKILL_POWER calc_to_hit_melee(player_type *player_ptr)
  * @details
  * * 種族/職業/性格による加算とレベルによる追加加算
  */
-static ACTION_SKILL_POWER calc_to_hit_shoot(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_to_hit_shoot(PlayerType *player_ptr)
 {
     ACTION_SKILL_POWER pow;
     const player_race_info *tmp_rp_ptr;
@@ -1278,7 +1278,7 @@ static ACTION_SKILL_POWER calc_to_hit_shoot(player_type *player_ptr)
  * * 種族/職業/性格による加算とレベルによる追加加算
  * * 狂戦士による減算(-20)
  */
-static ACTION_SKILL_POWER calc_to_hit_throw(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_to_hit_throw(PlayerType *player_ptr)
 {
     ACTION_SKILL_POWER pow;
     const player_race_info *tmp_rp_ptr;
@@ -1313,7 +1313,7 @@ static ACTION_SKILL_POWER calc_to_hit_throw(player_type *player_ptr)
  * * 武器重量によるプラス修正
  * * 最終算出値に1を保証
  */
-static ACTION_SKILL_POWER calc_skill_dig(player_type *player_ptr)
+static ACTION_SKILL_POWER calc_skill_dig(PlayerType *player_ptr)
 {
     object_type *o_ptr;
 
@@ -1359,20 +1359,20 @@ static ACTION_SKILL_POWER calc_skill_dig(player_type *player_ptr)
     return pow;
 }
 
-static bool is_martial_arts_mode(player_type *player_ptr)
+static bool is_martial_arts_mode(PlayerType *player_ptr)
 {
     return ((player_ptr->pclass == PlayerClassType::MONK) || (player_ptr->pclass == PlayerClassType::FORCETRAINER) || (player_ptr->pclass == PlayerClassType::BERSERKER))
         && (any_bits(empty_hands(player_ptr, true), EMPTY_HAND_MAIN)) && !can_attack_with_sub_hand(player_ptr);
 }
 
-static bool is_heavy_wield(player_type *player_ptr, int i)
+static bool is_heavy_wield(PlayerType *player_ptr, int i)
 {
     const object_type *o_ptr = &player_ptr->inventory_list[INVEN_MAIN_HAND + i];
 
     return has_melee_weapon(player_ptr, INVEN_MAIN_HAND + i) && (calc_weapon_weight_limit(player_ptr) < o_ptr->weight / 10);
 }
 
-static int16_t calc_num_blow(player_type *player_ptr, int i)
+static int16_t calc_num_blow(PlayerType *player_ptr, int i)
 {
     object_type *o_ptr;
     int16_t num_blow = 1;
@@ -1508,7 +1508,7 @@ static int16_t calc_num_blow(player_type *player_ptr, int i)
  * * 性格チャージマンなら加算(+5)
  * * 装備品にTRC::HARD_SPELLがあるなら加算(軽い呪いなら+3/重い呪いなら+10)
  */
-static int16_t calc_to_magic_chance(player_type *player_ptr)
+static int16_t calc_to_magic_chance(PlayerType *player_ptr)
 {
     int16_t chance = 0;
 
@@ -1538,7 +1538,7 @@ static int16_t calc_to_magic_chance(player_type *player_ptr)
     return chance;
 }
 
-static ARMOUR_CLASS calc_base_ac(player_type *player_ptr)
+static ARMOUR_CLASS calc_base_ac(PlayerType *player_ptr)
 {
     ARMOUR_CLASS ac = 0;
     if (player_ptr->yoiyami)
@@ -1561,7 +1561,7 @@ static ARMOUR_CLASS calc_base_ac(player_type *player_ptr)
     return ac;
 }
 
-static ARMOUR_CLASS calc_to_ac(player_type *player_ptr, bool is_real_value)
+static ARMOUR_CLASS calc_to_ac(PlayerType *player_ptr, bool is_real_value)
 {
     ARMOUR_CLASS ac = 0;
     if (player_ptr->yoiyami)
@@ -1733,7 +1733,7 @@ static ARMOUR_CLASS calc_to_ac(player_type *player_ptr, bool is_real_value)
  * * 武蔵セットによる免除
  * * 竿状武器による増加
  */
-int16_t calc_double_weapon_penalty(player_type *player_ptr, INVENTORY_IDX slot)
+int16_t calc_double_weapon_penalty(PlayerType *player_ptr, INVENTORY_IDX slot)
 {
     int penalty = 0;
 
@@ -1765,7 +1765,7 @@ int16_t calc_double_weapon_penalty(player_type *player_ptr, INVENTORY_IDX slot)
     return (int16_t)penalty;
 }
 
-static bool is_riding_two_hands(player_type *player_ptr)
+static bool is_riding_two_hands(PlayerType *player_ptr)
 {
     if (!player_ptr->riding) {
         return false;
@@ -1790,7 +1790,7 @@ static bool is_riding_two_hands(player_type *player_ptr)
     return false;
 }
 
-static int16_t calc_riding_bow_penalty(player_type *player_ptr)
+static int16_t calc_riding_bow_penalty(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!player_ptr->riding)
@@ -1814,7 +1814,7 @@ static int16_t calc_riding_bow_penalty(player_type *player_ptr)
     return penalty;
 }
 
-void put_equipment_warning(player_type *player_ptr)
+void put_equipment_warning(PlayerType *player_ptr)
 {
     bool heavy_shoot = is_heavy_shoot(player_ptr, &player_ptr->inventory_list[INVEN_BOW]);
     if (player_ptr->old_heavy_shoot != heavy_shoot) {
@@ -1905,7 +1905,7 @@ void put_equipment_warning(player_type *player_ptr)
     }
 }
 
-static short calc_to_damage(player_type *player_ptr, INVENTORY_IDX slot, bool is_real_value)
+static short calc_to_damage(PlayerType *player_ptr, INVENTORY_IDX slot, bool is_real_value)
 {
     object_type *o_ptr = &player_ptr->inventory_list[slot];
     auto flgs = object_flags(o_ptr);
@@ -2047,7 +2047,7 @@ static short calc_to_damage(player_type *player_ptr, INVENTORY_IDX slot, bool is
  * @details
  * 'slot' MUST be INVEN_MAIN_HAND or INVEM_SUB_HAND.
  */
-static short calc_to_hit(player_type *player_ptr, INVENTORY_IDX slot, bool is_real_value)
+static short calc_to_hit(PlayerType *player_ptr, INVENTORY_IDX slot, bool is_real_value)
 {
     auto hit = 0;
 
@@ -2265,7 +2265,7 @@ static short calc_to_hit(player_type *player_ptr, INVENTORY_IDX slot, bool is_re
     return static_cast<short>(hit);
 }
 
-static int16_t calc_to_hit_bow(player_type *player_ptr, bool is_real_value)
+static int16_t calc_to_hit_bow(PlayerType *player_ptr, bool is_real_value)
 {
     int16_t pow = 0;
 
@@ -2338,7 +2338,7 @@ static int16_t calc_to_hit_bow(player_type *player_ptr, bool is_real_value)
     return pow;
 }
 
-static int16_t calc_to_damage_misc(player_type *player_ptr)
+static int16_t calc_to_damage_misc(PlayerType *player_ptr)
 {
     object_type *o_ptr;
 
@@ -2367,7 +2367,7 @@ static int16_t calc_to_damage_misc(player_type *player_ptr)
     return to_dam;
 }
 
-static int16_t calc_to_hit_misc(player_type *player_ptr)
+static int16_t calc_to_hit_misc(PlayerType *player_ptr)
 {
     object_type *o_ptr;
 
@@ -2406,7 +2406,7 @@ static int16_t calc_to_hit_misc(player_type *player_ptr)
     return to_hit;
 }
 
-static DICE_NUMBER calc_to_weapon_dice_num(player_type *player_ptr, INVENTORY_IDX slot)
+static DICE_NUMBER calc_to_weapon_dice_num(PlayerType *player_ptr, INVENTORY_IDX slot)
 {
     auto *o_ptr = &player_ptr->inventory_list[slot];
     return (player_ptr->riding > 0) && o_ptr->is_lance() ? 2 : 0;
@@ -2417,7 +2417,7 @@ static DICE_NUMBER calc_to_weapon_dice_num(player_type *player_ptr, INVENTORY_ID
  * Computes current weight limit.
  * @return 制限重量(ポンド)
  */
-WEIGHT calc_weight_limit(player_type *player_ptr)
+WEIGHT calc_weight_limit(PlayerType *player_ptr)
 {
     WEIGHT i = (WEIGHT)adj_str_wgt[player_ptr->stat_index[A_STR]] * 50;
     if (player_ptr->pclass == PlayerClassType::BERSERKER)
@@ -2429,7 +2429,7 @@ WEIGHT calc_weight_limit(player_type *player_ptr)
  * @brief update のフラグに応じた更新をまとめて行う / Handle "update"
  * @details 更新処理の対象はプレイヤーの能力修正/光源寿命/HP/MP/魔法の学習状態、他多数の外界の状態判定。
  */
-void update_creature(player_type *player_ptr)
+void update_creature(PlayerType *player_ptr)
 {
     if (!player_ptr->update)
         return;
@@ -2531,7 +2531,7 @@ void update_creature(player_type *player_ptr)
  * @brief プレイヤーが魔道書を一冊も持っていないかを判定する
  * @return 魔道書を一冊も持っていないならTRUEを返す
  */
-bool player_has_no_spellbooks(player_type *player_ptr)
+bool player_has_no_spellbooks(PlayerType *player_ptr)
 {
     object_type *o_ptr;
     for (int i = 0; i < INVEN_PACK; i++) {
@@ -2556,7 +2556,7 @@ bool player_has_no_spellbooks(player_type *player_ptr)
  * @param y 配置先Y座標
  * @return 配置に成功したらTRUE
  */
-bool player_place(player_type *player_ptr, POSITION y, POSITION x)
+bool player_place(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     if (player_ptr->current_floor_ptr->grid_array[y][x].m_idx != 0)
         return false;
@@ -2570,7 +2570,7 @@ bool player_place(player_type *player_ptr, POSITION y, POSITION x)
 /*!
  * @brief 種族アンバライトが出血時パターンの上に乗った際のペナルティ処理
  */
-void wreck_the_pattern(player_type *player_ptr)
+void wreck_the_pattern(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     int pattern_type = f_info[floor_ptr->grid_array[player_ptr->y][player_ptr->x].feat].subtype;
@@ -2600,7 +2600,7 @@ void wreck_the_pattern(player_type *player_ptr)
  * @brief プレイヤーの経験値について整合性のためのチェックと調整を行う /
  * Advance experience levels and print experience
  */
-void check_experience(player_type *player_ptr)
+void check_experience(PlayerType *player_ptr)
 {
     if (player_ptr->exp < 0)
         player_ptr->exp = 0;
@@ -2794,7 +2794,7 @@ int16_t modify_stat_value(int value, int amount)
  * Hack -- Calculates the total number of points earned                -JWT-
  * @details
  */
-long calc_score(player_type *player_ptr)
+long calc_score(PlayerType *player_ptr)
 {
     int arena_win = std::min<int>(player_ptr->arena_number, MAX_ARENA_MONS);
 
@@ -2864,31 +2864,31 @@ long calc_score(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 祝福状態ならばTRUE
  */
-bool is_blessed(player_type *player_ptr)
+bool is_blessed(PlayerType *player_ptr)
 {
     return player_ptr->blessed || music_singing(player_ptr, MUSIC_BLESS) || SpellHex(player_ptr).is_spelling_specific(HEX_BLESS);
 }
 
-bool is_tim_esp(player_type *player_ptr)
+bool is_tim_esp(PlayerType *player_ptr)
 {
     auto sniper_data = PlayerClass(player_ptr).get_specific_data<sniper_data_type>();
     auto sniper_concent = sniper_data ? sniper_data->concent : 0;
     return player_ptr->tim_esp || music_singing(player_ptr, MUSIC_MIND) || (sniper_concent >= CONCENT_TELE_THRESHOLD);
 }
 
-bool is_tim_stealth(player_type *player_ptr)
+bool is_tim_stealth(PlayerType *player_ptr)
 {
     return player_ptr->tim_stealth || music_singing(player_ptr, MUSIC_STEALTH);
 }
 
-bool is_time_limit_esp(player_type *player_ptr)
+bool is_time_limit_esp(PlayerType *player_ptr)
 {
     auto sniper_data = PlayerClass(player_ptr).get_specific_data<sniper_data_type>();
     auto sniper_concent = sniper_data ? sniper_data->concent : 0;
     return player_ptr->tim_esp || music_singing(player_ptr, MUSIC_MIND) || (sniper_concent >= CONCENT_TELE_THRESHOLD);
 }
 
-bool is_time_limit_stealth(player_type *player_ptr)
+bool is_time_limit_stealth(PlayerType *player_ptr)
 {
     return player_ptr->tim_stealth || music_singing(player_ptr, MUSIC_STEALTH);
 }
@@ -2897,7 +2897,7 @@ bool is_time_limit_stealth(player_type *player_ptr)
  * @brief 口を使う継続的な処理を中断する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void stop_mouth(player_type *player_ptr)
+void stop_mouth(PlayerType *player_ptr)
 {
     if (music_singing_any(player_ptr))
         stop_singing(player_ptr);
@@ -2907,37 +2907,37 @@ void stop_mouth(player_type *player_ptr)
     }
 }
 
-bool is_fast(player_type *player_ptr)
+bool is_fast(PlayerType *player_ptr)
 {
     return player_ptr->fast || music_singing(player_ptr, MUSIC_SPEED) || music_singing(player_ptr, MUSIC_SHERO);
 }
 
-bool is_invuln(player_type *player_ptr)
+bool is_invuln(PlayerType *player_ptr)
 {
     return player_ptr->invuln || music_singing(player_ptr, MUSIC_INVULN);
 }
 
-bool is_hero(player_type *player_ptr)
+bool is_hero(PlayerType *player_ptr)
 {
     return player_ptr->hero || music_singing(player_ptr, MUSIC_HERO) || music_singing(player_ptr, MUSIC_SHERO);
 }
 
-bool is_shero(player_type *player_ptr)
+bool is_shero(PlayerType *player_ptr)
 {
     return player_ptr->shero || player_ptr->pclass == PlayerClassType::BERSERKER;
 }
 
-bool is_echizen(player_type *player_ptr)
+bool is_echizen(PlayerType *player_ptr)
 {
     return (player_ptr->ppersonality == PERSONALITY_COMBAT) || (player_ptr->inventory_list[INVEN_BOW].name1 == ART_CRIMSON);
 }
 
-bool is_chargeman(player_type *player_ptr)
+bool is_chargeman(PlayerType *player_ptr)
 {
     return player_ptr->ppersonality == PERSONALITY_CHARGEMAN;
 }
 
-WEIGHT calc_weapon_weight_limit(player_type *player_ptr)
+WEIGHT calc_weapon_weight_limit(PlayerType *player_ptr)
 {
     WEIGHT weight = adj_str_hold[player_ptr->stat_index[A_STR]];
 
@@ -2947,14 +2947,14 @@ WEIGHT calc_weapon_weight_limit(player_type *player_ptr)
     return weight;
 }
 
-WEIGHT calc_bow_weight_limit(player_type *player_ptr)
+WEIGHT calc_bow_weight_limit(PlayerType *player_ptr)
 {
     WEIGHT weight = adj_str_hold[player_ptr->stat_index[A_STR]];
 
     return weight;
 }
 
-static player_hand main_attack_hand(player_type *player_ptr)
+static player_hand main_attack_hand(PlayerType *player_ptr)
 {
     switch (player_melee_type(player_ptr)) {
     case MELEE_TYPE_BAREHAND_TWO:
index d26d32e..cac0920 100644 (file)
@@ -8,33 +8,33 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 
-WEIGHT calc_weapon_weight_limit(player_type *player_ptr);
-WEIGHT calc_bow_weight_limit(player_type *player_ptr);
-WEIGHT calc_inventory_weight(player_type *player_ptr);
+WEIGHT calc_weapon_weight_limit(PlayerType *player_ptr);
+WEIGHT calc_bow_weight_limit(PlayerType *player_ptr);
+WEIGHT calc_inventory_weight(PlayerType *player_ptr);
 
-int16_t calc_num_fire(player_type *player_ptr, object_type *o_ptr);
-WEIGHT calc_weight_limit(player_type *player_ptr);
-void update_creature(player_type *player_ptr);
-bool player_has_no_spellbooks(player_type *player_ptr);
+int16_t calc_num_fire(PlayerType *player_ptr, object_type *o_ptr);
+WEIGHT calc_weight_limit(PlayerType *player_ptr);
+void update_creature(PlayerType *player_ptr);
+bool player_has_no_spellbooks(PlayerType *player_ptr);
 
-bool player_place(player_type *player_ptr, POSITION y, POSITION x);
+bool player_place(PlayerType *player_ptr, POSITION y, POSITION x);
 
-void check_experience(player_type *player_ptr);
-void wreck_the_pattern(player_type *player_ptr);
+void check_experience(PlayerType *player_ptr);
+void wreck_the_pattern(PlayerType *player_ptr);
 void cnv_stat(int val, char *out_val);
 int16_t modify_stat_value(int value, int amount);
-long calc_score(player_type *player_ptr);
-
-bool is_blessed(player_type *player_ptr);
-bool is_time_limit_esp(player_type *player_ptr);
-bool is_time_limit_stealth(player_type *player_ptr);
-bool is_fast(player_type *player_ptr);
-bool is_invuln(player_type *player_ptr);
-bool is_hero(player_type *player_ptr);
-bool is_shero(player_type *player_ptr);
-bool is_echizen(player_type *player_ptr);
-bool is_chargeman(player_type *player_ptr);
-
-void stop_mouth(player_type *player_ptr);
+long calc_score(PlayerType *player_ptr);
+
+bool is_blessed(PlayerType *player_ptr);
+bool is_time_limit_esp(PlayerType *player_ptr);
+bool is_time_limit_stealth(PlayerType *player_ptr);
+bool is_fast(PlayerType *player_ptr);
+bool is_invuln(PlayerType *player_ptr);
+bool is_hero(PlayerType *player_ptr);
+bool is_shero(PlayerType *player_ptr);
+bool is_echizen(PlayerType *player_ptr);
+bool is_chargeman(PlayerType *player_ptr);
+
+void stop_mouth(PlayerType *player_ptr);
index 4620f35..31b44ae 100644 (file)
@@ -27,7 +27,7 @@
  *
  * This function now returns "TRUE" if vision is "blocked" by grid (y,x).
  */
-static bool update_view_aux(player_type *player_ptr, POSITION y, POSITION x, POSITION y1, POSITION x1, POSITION y2, POSITION x2)
+static bool update_view_aux(PlayerType *player_ptr, POSITION y, POSITION x, POSITION y1, POSITION x1, POSITION y2, POSITION x2)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g1_c_ptr;
@@ -96,7 +96,7 @@ static bool update_view_aux(player_type *player_ptr, POSITION y, POSITION x, POS
  *  4c1: Each side aborts as soon as possible
  *  4c2: Each side tells the next strip how far it has to check
  */
-void update_view(player_type *player_ptr)
+void update_view(PlayerType *player_ptr)
 {
     // 前回プレイヤーから見えていた座標たちを格納する配列。
     std::vector<Pos2D> points;
index fed518f..3491ed7 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void update_view(player_type *player_ptr);
+class PlayerType;
+void update_view(PlayerType *player_ptr);
index 3b8a43a..9c103e0 100644 (file)
@@ -52,7 +52,7 @@ static void center_string(char *buf, concptr str)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param buf 墓テンプレ
  */
-static void show_basic_params(player_type *player_ptr, char *buf)
+static void show_basic_params(PlayerType *player_ptr, char *buf)
 {
     char tomb_message[160];
     (void)sprintf(tomb_message, _("レベル: %d", "Level: %d"), (int)player_ptr->lev);
@@ -76,7 +76,7 @@ static void show_basic_params(player_type *player_ptr, char *buf)
  * @param tomb_message 墓碑に刻む言葉
  * @return 追加の行数
  */
-static int show_killing_monster(player_type *player_ptr, char *buf, char *tomb_message, size_t tomb_message_size)
+static int show_killing_monster(PlayerType *player_ptr, char *buf, char *tomb_message, size_t tomb_message_size)
 {
     shape_buffer(player_ptr->died_from, GRAVE_LINE_WIDTH + 1, tomb_message, tomb_message_size);
     char *t;
@@ -121,7 +121,7 @@ static int show_killing_monster(player_type *player_ptr, char *buf, char *tomb_m
  * @param tomb_message 表示する文字列
  * @param extra_line 追加の行数
  */
-static void show_dead_place(player_type *player_ptr, char *buf, char *tomb_message, int extra_line)
+static void show_dead_place(PlayerType *player_ptr, char *buf, char *tomb_message, int extra_line)
 {
     if (streq(player_ptr->died_from, "ripe") || streq(player_ptr->died_from, "Seppuku"))
         return;
@@ -150,7 +150,7 @@ static void show_dead_place(player_type *player_ptr, char *buf, char *tomb_messa
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param buf 墓テンプレ
  */
-static void show_tomb_detail(player_type *player_ptr, char *buf)
+static void show_tomb_detail(PlayerType *player_ptr, char *buf)
 {
     char tomb_message[160];
     int extra_line = 0;
@@ -177,7 +177,7 @@ static void show_tomb_detail(player_type *player_ptr, char *buf)
  * @param buf template of the tomb
  * @return nothing
  */
-static void show_tomb_detail(player_type *player_ptr, char *buf)
+static void show_tomb_detail(PlayerType *player_ptr, char *buf)
 {
     char tomb_message[160];
     (void)sprintf(tomb_message, "Killed on Level %d", player_ptr->current_floor_ptr->dun_level);
@@ -210,7 +210,7 @@ static void show_tomb_detail(player_type *player_ptr, char *buf)
  * Display a "tomb-stone"
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_tomb(player_type *player_ptr)
+void print_tomb(PlayerType *player_ptr)
 {
     term_clear();
     char buf[1024];
@@ -248,7 +248,7 @@ void print_tomb(player_type *player_ptr)
  * @brief 死亡/引退/切腹時にインベントリ内のアイテムを*鑑定*する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void inventory_aware(player_type *player_ptr)
+static void inventory_aware(PlayerType *player_ptr)
 {
     object_type *o_ptr;
     for (int i = 0; i < INVEN_TOTAL; i++) {
@@ -265,7 +265,7 @@ static void inventory_aware(player_type *player_ptr)
  * @brief 死亡/引退/切腹時に我が家のアイテムを*鑑定*する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void home_aware(player_type *player_ptr)
+static void home_aware(PlayerType *player_ptr)
 {
     object_type *o_ptr;
     store_type *store_ptr;
@@ -287,7 +287,7 @@ static void home_aware(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return Escキーでゲームを終了する時TRUE
  */
-static bool show_dead_player_items(player_type *player_ptr)
+static bool show_dead_player_items(PlayerType *player_ptr)
 {
     if (player_ptr->equip_cnt) {
         term_clear();
@@ -313,7 +313,7 @@ static bool show_dead_player_items(player_type *player_ptr)
  * @brief 我が家にあったアイテムを表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void show_dead_home_items(player_type *player_ptr)
+static void show_dead_home_items(PlayerType *player_ptr)
 {
     for (int l = 1; l < max_towns; l++) {
         store_type *store_ptr;
@@ -346,7 +346,7 @@ static void show_dead_home_items(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param file_character ステータスダンプへのコールバック
  */
-static void export_player_info(player_type *player_ptr, display_player_pf display_player)
+static void export_player_info(PlayerType *player_ptr, display_player_pf display_player)
 {
     prt(_("キャラクターの記録をファイルに書き出すことができます。", "You may now dump a character record to one or more files."), 21, 0);
     prt(_("リターンキーでキャラクターを見ます。ESCで中断します。", "Then, hit RETURN to see the character, or ESC to abort."), 22, 0);
@@ -368,7 +368,7 @@ static void export_player_info(player_type *player_ptr, display_player_pf displa
 /*!
  * @brief 自動的にプレイヤーステータスをファイルダンプ出力する
  */
-static void file_character_auto(player_type *player_ptr, display_player_pf display_player)
+static void file_character_auto(PlayerType *player_ptr, display_player_pf display_player)
 {
     time_t now_t = time(nullptr);
     struct tm *now_tm = localtime(&now_t);
@@ -389,7 +389,7 @@ static void file_character_auto(player_type *player_ptr, display_player_pf displ
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param display_player ステータス表示へのコールバック
  */
-void show_death_info(player_type *player_ptr, display_player_pf display_player)
+void show_death_info(PlayerType *player_ptr, display_player_pf display_player)
 {
     inventory_aware(player_ptr);
     home_aware(player_ptr);
index 1d160de..8f96fbf 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "io/files-util.h"
 
-struct player_type;
-void print_tomb(player_type *player_ptr);
-void show_death_info(player_type *player_ptr, display_player_pf display_player);
+class PlayerType;
+void print_tomb(PlayerType *player_ptr);
+void show_death_info(PlayerType *player_ptr, display_player_pf display_player);
index 95789d0..385fd94 100644 (file)
@@ -20,7 +20,7 @@
  * Extract a clean "base name".
  * Build the savefile name if needed.
  */
-void process_player_name(player_type *player_ptr, bool is_new_savefile)
+void process_player_name(PlayerType *player_ptr, bool is_new_savefile)
 {
     char old_player_base[32] = "";
     if (w_ptr->character_generated)
@@ -130,7 +130,7 @@ void process_player_name(player_type *player_ptr, bool is_new_savefile)
  * What a horrible name for a global function.
  * </pre>
  */
-void get_name(player_type *player_ptr)
+void get_name(PlayerType *player_ptr)
 {
     char tmp[64];
     strcpy(tmp, player_ptr->name);
index cc7d849..6cbbf0f 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void process_player_name(player_type *player_ptr, bool is_new_savefile = false);
-void get_name(player_type *player_ptr);
+class PlayerType;
+void process_player_name(PlayerType *player_ptr, bool is_new_savefile = false);
+void get_name(PlayerType *player_ptr);
index 02ed386..16fdea2 100644 (file)
@@ -20,7 +20,7 @@
  * @todo
  * xtra1.c周りと多重実装になっているのを何とかする
  */
-void player_immunity(player_type *player_ptr, TrFlags &flags)
+void player_immunity(PlayerType *player_ptr, TrFlags &flags)
 {
     flags.clear();
 
@@ -48,7 +48,7 @@ void player_immunity(player_type *player_ptr, TrFlags &flags)
  * @todo
  * xtra1.c周りと多重実装になっているのを何とかする
  */
-void tim_player_immunity(player_type *player_ptr, TrFlags &flags)
+void tim_player_immunity(PlayerType *player_ptr, TrFlags &flags)
 {
     flags.clear();
 
@@ -71,7 +71,7 @@ void tim_player_immunity(player_type *player_ptr, TrFlags &flags)
  * @todo
  * xtra1.c周りと多重実装になっているのを何とかする
  */
-void known_obj_immunity(player_type *player_ptr, TrFlags &flags)
+void known_obj_immunity(PlayerType *player_ptr, TrFlags &flags)
 {
     flags.clear();
 
@@ -100,7 +100,7 @@ void known_obj_immunity(player_type *player_ptr, TrFlags &flags)
  * @todo
  * xtra1.c周りと多重実装になっているのを何とかする
  */
-void player_vulnerability_flags(player_type *player_ptr, TrFlags &flags)
+void player_vulnerability_flags(PlayerType *player_ptr, TrFlags &flags)
 {
     flags.clear();
 
index a30b898..a922310 100644 (file)
@@ -4,8 +4,8 @@
 
 #include "object-enchant/tr-flags.h"
 
-struct player_type;
-void player_immunity(player_type *player_ptr, TrFlags &flags);
-void tim_player_immunity(player_type *player_ptr, TrFlags &flags);
-void known_obj_immunity(player_type *player_ptr, TrFlags &flags);
-void player_vulnerability_flags(player_type *player_ptr, TrFlags &flags);
+class PlayerType;
+void player_immunity(PlayerType *player_ptr, TrFlags &flags);
+void tim_player_immunity(PlayerType *player_ptr, TrFlags &flags);
+void known_obj_immunity(PlayerType *player_ptr, TrFlags &flags);
+void player_vulnerability_flags(PlayerType *player_ptr, TrFlags &flags);
index dcffabd..d5a4ebd 100644 (file)
@@ -21,7 +21,7 @@
  * @todo
  * xtra1.c周りと多重実装になっているのを何とかする
  */
-void tim_player_flags(player_type *player_ptr, TrFlags &flags)
+void tim_player_flags(PlayerType *player_ptr, TrFlags &flags)
 {
     BIT_FLAGS tmp_effect_flag = FLAG_CAUSE_MAGIC_TIME_EFFECT;
     set_bits(tmp_effect_flag, FLAG_CAUSE_STANCE);
index 1548082..93e8b29 100644 (file)
@@ -4,5 +4,5 @@
 
 #include "object-enchant/tr-flags.h"
 
-struct player_type;
-void tim_player_flags(player_type *player_ptr, TrFlags &flags);
+class PlayerType;
+void tim_player_flags(PlayerType *player_ptr, TrFlags &flags);
index 8262886..aa71fcc 100644 (file)
@@ -6,7 +6,7 @@
 #include "realm/realm-types.h"
 #include "system/player-type-definition.h"
 
-void switch_class_racial(player_type *player_ptr, rc_type *rc_ptr)
+void switch_class_racial(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     rpi_type rpi;
     switch (player_ptr->pclass) {
index ed90c67..c53842c 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct rc_type;
-void switch_class_racial(player_type *player_ptr, rc_type *rc_ptr);
+void switch_class_racial(PlayerType *player_ptr, rc_type *rc_ptr);
index a8a20c2..90f1b44 100644 (file)
@@ -6,7 +6,7 @@
 #include "system/player-type-definition.h"
 #include "util/enum-converter.h"
 
-void select_mutation_racial(player_type *player_ptr, rc_type *rc_ptr)
+void select_mutation_racial(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     rpi_type rpi;
     if (player_ptr->muta.has(PlayerMutationType::SPIT_ACID)) {
index 711dbdf..85dbebf 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct rc_type;
-void select_mutation_racial(player_type *player_ptr, rc_type *rc_ptr);
+void select_mutation_racial(PlayerType *player_ptr, rc_type *rc_ptr);
index 45bac35..8b9761c 100644 (file)
@@ -4,7 +4,7 @@
 #include "racial/racial-util.h"
 #include "system/player-type-definition.h"
 
-void set_mimic_racial_command(player_type *player_ptr, rc_type *rc_ptr)
+void set_mimic_racial_command(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     rpi_type rpi;
     switch (player_ptr->mimic_form) {
@@ -33,7 +33,7 @@ void set_mimic_racial_command(player_type *player_ptr, rc_type *rc_ptr)
     }
 }
 
-void set_race_racial_command(player_type *player_ptr, rc_type *rc_ptr)
+void set_race_racial_command(PlayerType *player_ptr, rc_type *rc_ptr)
 {
     rpi_type rpi;
     switch (player_ptr->prace) {
index 84804d3..5262ea0 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct rc_type;
-void set_mimic_racial_command(player_type *player_ptr, rc_type *rc_ptr);
-void set_race_racial_command(player_type *player_ptr, rc_type *rc_ptr);
+void set_mimic_racial_command(PlayerType *player_ptr, rc_type *rc_ptr);
+void set_race_racial_command(PlayerType *player_ptr, rc_type *rc_ptr);
index b083bce..10c9c4d 100644 (file)
@@ -19,7 +19,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool android_inside_weapon(player_type *player_ptr)
+bool android_inside_weapon(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -54,7 +54,7 @@ bool android_inside_weapon(player_type *player_ptr)
     return true;
 }
 
-void calc_android_exp(player_type *player_ptr)
+void calc_android_exp(PlayerType *player_ptr)
 {
     uint32_t total_exp = 0;
     if (player_ptr->is_dead || (player_ptr->prace != PlayerRaceType::ANDROID))
index 1b68b0d..5db1e23 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-bool android_inside_weapon(player_type *player_ptr);
-void calc_android_exp(player_type *player_ptr);
+class PlayerType;
+bool android_inside_weapon(PlayerType *player_ptr);
+void calc_android_exp(PlayerType *player_ptr);
index 5080be1..704fb1d 100644 (file)
@@ -6,7 +6,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool demonic_breath(player_type *player_ptr)
+bool demonic_breath(PlayerType *player_ptr)
 {
     DIRECTION dir;
     AttributeType type = (one_in_(2) ? AttributeType::NETHER : AttributeType::FIRE);
index 3d45a56..7dd926b 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool demonic_breath(player_type *player_ptr);
+class PlayerType;
+bool demonic_breath(PlayerType *player_ptr);
index d1efcc2..eb77c61 100644 (file)
@@ -7,7 +7,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-static void decide_breath_kind(player_type *player_ptr, AttributeType *breath_type, concptr *breath_type_description)
+static void decide_breath_kind(PlayerType *player_ptr, AttributeType *breath_type, concptr *breath_type_description)
 {
     if (randint1(100) >= player_ptr->lev)
         return;
@@ -119,7 +119,7 @@ static void decide_breath_kind(player_type *player_ptr, AttributeType *breath_ty
     }
 }
 
-bool draconian_breath(player_type *player_ptr)
+bool draconian_breath(PlayerType *player_ptr)
 {
     AttributeType breath_type = (one_in_(3) ? AttributeType::COLD : AttributeType::FIRE);
     concptr breath_type_description = ((breath_type == AttributeType::COLD) ? _("冷気", "cold") : _("炎", "fire"));
index c91a8db..8fa35ea 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool draconian_breath(player_type *player_ptr);
+class PlayerType;
+bool draconian_breath(PlayerType *player_ptr);
index 306a4a8..c480e3a 100644 (file)
@@ -13,7 +13,7 @@
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_leveling(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_leveling(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
index b56156a..1865126 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool set_leveling(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+bool set_leveling(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
index 1bf00fd..87bdd7e 100644 (file)
@@ -84,7 +84,7 @@
 #include "util/int-char-converter.h"
 #include "view/display-messages.h"
 
-bool switch_class_racial_execution(player_type *player_ptr, const int32_t command)
+bool switch_class_racial_execution(PlayerType *player_ptr, const int32_t command)
 {
     DIRECTION dir = 0;
     switch (player_ptr->pclass) {
@@ -271,7 +271,7 @@ bool switch_class_racial_execution(player_type *player_ptr, const int32_t comman
     }
 }
 
-bool switch_mimic_racial_execution(player_type *player_ptr)
+bool switch_mimic_racial_execution(PlayerType *player_ptr)
 {
     switch (player_ptr->mimic_form) {
     case MIMIC_DEMON:
@@ -286,7 +286,7 @@ bool switch_mimic_racial_execution(player_type *player_ptr)
     }
 }
 
-bool switch_race_racial_execution(player_type *player_ptr, const int32_t command)
+bool switch_race_racial_execution(PlayerType *player_ptr, const int32_t command)
 {
     DIRECTION dir = 0;
     switch (player_ptr->prace) {
index a9c7fcb..2a1a65f 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool switch_class_racial_execution(player_type *player_ptr, const int32_t command);
-bool switch_mimic_racial_execution(player_type *player_ptr);
-bool switch_race_racial_execution(player_type *player_ptr, const int32_t command);
+class PlayerType;
+bool switch_class_racial_execution(PlayerType *player_ptr, const int32_t command);
+bool switch_mimic_racial_execution(PlayerType *player_ptr);
+bool switch_race_racial_execution(PlayerType *player_ptr, const int32_t command);
index 3216b3c..34bb0f7 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/player-type-definition.h"
 #include "util/enum-converter.h"
 
-rc_type::rc_type(player_type *player_ptr)
+rc_type::rc_type(PlayerType *player_ptr)
 {
     this->ask = true;
     this->lvl = player_ptr->lev;
index 3e9d9d7..00668db 100644 (file)
@@ -41,7 +41,7 @@ struct rpi_type {
 /*!
  * レイシャル/クラスパワー管理構造体
  */
-struct player_type;
+class PlayerType;
 struct rc_type {
     std::vector<rpi_type> power_desc{}; //!< パワー定義配列
     COMMAND_CODE command_code{}; //!< 使用しようとしているパワー番号
@@ -62,7 +62,7 @@ struct rc_type {
      * @param player_ptr プレイヤー情報への参照ポインタ
      * @return 管理構造体
      */
-    rc_type(player_type *player_ptr);
+    rc_type(PlayerType *player_ptr);
 
     /*!
      * @brief レイシャル/クラスパワー定義を追加
index 5a01cb7..53c3df0 100644 (file)
@@ -12,7 +12,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool vampirism(player_type *player_ptr)
+bool vampirism(PlayerType *player_ptr)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::NO_MELEE)) {
         msg_print(_("なぜか攻撃することができない。", "Something prevents you from attacking."));
index ad4a1c1..5083635 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool vampirism(player_type *player_ptr);
+class PlayerType;
+bool vampirism(PlayerType *player_ptr);
index 2c35a01..b342f38 100644 (file)
@@ -32,7 +32,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_arcane_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_arcane_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index eeaa852..2490486 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_arcane_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_arcane_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index aba6809..24db66c 100644 (file)
@@ -32,7 +32,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_chaos_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_chaos_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 495b954..7977676 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_chaos_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_chaos_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index cbf00f8..d73410c 100644 (file)
@@ -26,7 +26,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_craft_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_craft_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 3ffc805..e2561d9 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_craft_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_craft_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index 3d6524a..0f3124e 100644 (file)
@@ -38,7 +38,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_crusade_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_crusade_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 4b92e00..3475427 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_crusade_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_crusade_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index 964f0e6..33f2bc3 100644 (file)
@@ -35,7 +35,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_death_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_death_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 0de5103..dbdfbd0 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_death_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_death_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index 96cf226..d1c681e 100644 (file)
@@ -35,7 +35,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_daemon_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_daemon_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 30cfa27..0c502ab 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_daemon_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_daemon_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
 
index baaac62..37770a7 100644 (file)
@@ -82,7 +82,7 @@ static bool item_tester_hook_weapon_except_bow(const object_type *o_ptr)
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST / SPELL_CONT / SpellProcessType::STOP)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST / SPELL_CONT / SpellProcessType::STOP 時はnullptr文字列を返す。
  */
-concptr do_hex_spell(player_type *player_ptr, spell_hex_type spell, SpellProcessType mode)
+concptr do_hex_spell(PlayerType *player_ptr, spell_hex_type spell, SpellProcessType mode)
 {
     auto name = mode == SpellProcessType::NAME;
     auto description = mode == SpellProcessType::DESCRIPTION;
index 20f5e8a..9cb508c 100644 (file)
@@ -4,5 +4,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_hex_spell(player_type *player_ptr, spell_hex_type spell, SpellProcessType mode);
+class PlayerType;
+concptr do_hex_spell(PlayerType *player_ptr, spell_hex_type spell, SpellProcessType mode);
index 3039b7b..dbcc262 100644 (file)
@@ -65,7 +65,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_hissatsu_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_hissatsu_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 6e5e0a9..e72867c 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_hissatsu_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_hissatsu_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index a56c3f4..b05c21e 100644 (file)
@@ -30,7 +30,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_life_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_life_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 79963f2..5da1b94 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_life_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_life_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index cbf5ded..306301c 100644 (file)
@@ -48,7 +48,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_nature_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_nature_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 4b5d126..88d4b58 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_nature_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_nature_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index 5aff334..4899087 100644 (file)
@@ -33,7 +33,7 @@
  * @param spell 領域魔法としてのID
  * @param song 魔法効果のID
  */
-static void start_singing(player_type *player_ptr, SPELL_IDX spell, int32_t song)
+static void start_singing(PlayerType *player_ptr, SPELL_IDX spell, int32_t song)
 {
     /* Remember the song index */
     set_singing_song_effect(player_ptr, song);
@@ -55,7 +55,7 @@ static void start_singing(player_type *player_ptr, SPELL_IDX spell, int32_t song
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST / SpellProcessType::FAIL / SPELL_CONT / SpellProcessType::STOP)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST / SpellProcessType::FAIL / SPELL_CONT / SpellProcessType::STOP 時はnullptr文字列を返す。
  */
-concptr do_music_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_music_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index ea220f6..1e5fa48 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_music_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_music_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index 46f5330..a440450 100644 (file)
@@ -32,7 +32,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_sorcery_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_sorcery_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index d12d281..578975b 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_sorcery_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_sorcery_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index 6044350..1012861 100644 (file)
@@ -35,7 +35,7 @@
  * @param mode 処理内容 (SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO / SpellProcessType::CAST)
  * @return SpellProcessType::NAME / SPELL_DESC / SpellProcessType::INFO 時には文字列ポインタを返す。SpellProcessType::CAST時はnullptr文字列を返す。
  */
-concptr do_trump_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode)
+concptr do_trump_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode)
 {
     bool name = mode == SpellProcessType::NAME;
     bool desc = mode == SpellProcessType::DESCRIPTION;
index 953ac57..df0b08b 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr do_trump_spell(player_type *player_ptr, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr do_trump_spell(PlayerType *player_ptr, SPELL_IDX spell, SpellProcessType mode);
index a0cd213..4a3cbad 100644 (file)
@@ -177,7 +177,7 @@ void generate_hmap(floor_type *floor_ptr, POSITION y0, POSITION x0, POSITION xsi
     }
 }
 
-static bool hack_isnt_wall(player_type *player_ptr, POSITION y, POSITION x, int c1, int c2, int c3, FEAT_IDX feat1, FEAT_IDX feat2, FEAT_IDX feat3,
+static bool hack_isnt_wall(PlayerType *player_ptr, POSITION y, POSITION x, int c1, int c2, int c3, FEAT_IDX feat1, FEAT_IDX feat2, FEAT_IDX feat3,
     BIT_FLAGS info1, BIT_FLAGS info2, BIT_FLAGS info3)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -228,7 +228,7 @@ static bool hack_isnt_wall(player_type *player_ptr, POSITION y, POSITION x, int
  * Quick and nasty fill routine used to find the connected region
  * of floor in the middle of the grids
  */
-static void cave_fill(player_type *player_ptr, const POSITION y, const POSITION x)
+static void cave_fill(PlayerType *player_ptr, const POSITION y, const POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
 
@@ -264,7 +264,7 @@ static void cave_fill(player_type *player_ptr, const POSITION y, const POSITION
     }
 }
 
-bool generate_fracave(player_type *player_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int cutoff, bool light, bool room)
+bool generate_fracave(PlayerType *player_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int cutoff, bool light, bool room)
 {
     POSITION xhsize = xsize / 2;
     POSITION yhsize = ysize / 2;
@@ -387,7 +387,7 @@ bool generate_fracave(player_type *player_ptr, POSITION y0, POSITION x0, POSITIO
     return true;
 }
 
-bool generate_lake(player_type *player_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int c1, int c2, int c3, int type)
+bool generate_lake(PlayerType *player_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int c1, int c2, int c3, int type)
 {
     FEAT_IDX feat1, feat2, feat3;
     POSITION xhsize = xsize / 2;
index 517b579..6f45bc3 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 void generate_hmap(floor_type *floor_ptr, POSITION y0, POSITION x0, POSITION xsiz, POSITION ysiz, int grd, int roug, int cutoff);
-bool generate_fracave(player_type *player_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int cutoff, bool light, bool room);
-bool generate_lake(player_type *player_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int c1, int c2, int c3, int type);
+bool generate_fracave(PlayerType *player_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int cutoff, bool light, bool room);
+bool generate_lake(PlayerType *player_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int c1, int c2, int c3, int type);
index 4da05d4..f0dd256 100644 (file)
@@ -27,7 +27,7 @@
  * @note that we restrict the number of "crowded" rooms to reduce the chance of overflowing the monster list during level creation.
  * @return 部屋の生成に成功した場合 TRUE を返す。
  */
-static bool room_build(player_type *player_ptr, dun_data_type *dd_ptr, EFFECT_ID typ)
+static bool room_build(PlayerType *player_ptr, dun_data_type *dd_ptr, EFFECT_ID typ)
 {
     switch (typ) {
     case ROOM_T_NORMAL:
@@ -86,7 +86,7 @@ static void move_prob_list(room_type dst, room_type src, int *prob_list)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 部屋生成に成功した場合 TRUE を返す。
  */
-bool generate_rooms(player_type *player_ptr, dun_data_type *dd_ptr)
+bool generate_rooms(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     int crowded = 0;
index adc055b..f2eb21a 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct dun_data_type;
-struct player_type;
-bool generate_rooms(player_type *player_ptr, dun_data_type *dun_data);
+class PlayerType;
+bool generate_rooms(PlayerType *player_ptr, dun_data_type *dun_data);
index 3b6dce4..41f674d 100644 (file)
@@ -62,7 +62,7 @@
  * Note - this should be used only on allocated regions
  * within another room.
  */
-void build_small_room(player_type *player_ptr, POSITION x0, POSITION y0)
+void build_small_room(PlayerType *player_ptr, POSITION x0, POSITION y0)
 {
     for (POSITION y = y0 - 1; y <= y0 + 1; y++) {
         place_bold(player_ptr, y, x0 - 1, GB_INNER);
@@ -96,7 +96,7 @@ void build_small_room(player_type *player_ptr, POSITION x0, POSITION y0)
 /*
  * Builds a cave system in the center of the dungeon.
  */
-void build_cavern(player_type *player_ptr)
+void build_cavern(PlayerType *player_ptr)
 {
     bool light = false;
     bool done = false;
@@ -123,7 +123,7 @@ void build_cavern(player_type *player_ptr)
 /*
  * makes a lake/collapsed floor in the center of the dungeon
  */
-void build_lake(player_type *player_ptr, int type)
+void build_lake(PlayerType *player_ptr, int type)
 {
     if ((type < LAKE_T_LAVA) || (type > LAKE_T_FIRE_VAULT)) {
         msg_format("Invalid lake type (%d)", type);
@@ -155,7 +155,7 @@ void build_lake(player_type *player_ptr, int type)
  * The area inside the walls is not touched:
  * only granite is removed- normal walls stay
  */
-void build_room(player_type *player_ptr, POSITION x1, POSITION x2, POSITION y1, POSITION y2)
+void build_room(PlayerType *player_ptr, POSITION x1, POSITION x2, POSITION y1, POSITION y2)
 {
     int temp;
     if ((x1 == x2) || (y1 == y2))
@@ -211,7 +211,7 @@ void build_room(player_type *player_ptr, POSITION x1, POSITION x2, POSITION y1,
  * The power variable is a measure of how well defended a region is.
  * This alters the possible choices.
  */
-void build_recursive_room(player_type *player_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2, int power)
+void build_recursive_room(PlayerType *player_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2, int power)
 {
     POSITION xsize = x2 - x1;
     POSITION ysize = y2 - y1;
@@ -349,7 +349,7 @@ void build_recursive_room(player_type *player_ptr, POSITION x1, POSITION y1, POS
  * Note: no range checking is done so must be inside dungeon
  * This routine also stomps on doors
  */
-void add_outer_wall(player_type *player_ptr, POSITION x, POSITION y, int light, POSITION x1, POSITION y1, POSITION x2, POSITION y2)
+void add_outer_wall(PlayerType *player_ptr, POSITION x, POSITION y, int light, POSITION x1, POSITION y1, POSITION x2, POSITION y2)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!in_bounds(floor_ptr, y, x))
index 1197c45..ed6c017 100644 (file)
@@ -2,11 +2,11 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void build_lake(player_type *player_ptr, int type);
-void build_cavern(player_type *player_ptr);
-void build_small_room(player_type *player_ptr, POSITION x0, POSITION y0);
-void add_outer_wall(player_type *player_ptr, POSITION x, POSITION y, int light, POSITION x1, POSITION y1, POSITION x2, POSITION y2);
+class PlayerType;
+void build_lake(PlayerType *player_ptr, int type);
+void build_cavern(PlayerType *player_ptr);
+void build_small_room(PlayerType *player_ptr, POSITION x0, POSITION y0);
+void add_outer_wall(PlayerType *player_ptr, POSITION x, POSITION y, int light, POSITION x1, POSITION y1, POSITION x2, POSITION y2);
 POSITION dist2(POSITION x1, POSITION y1, POSITION x2, POSITION y2, POSITION h1, POSITION h2, POSITION h3, POSITION h4);
-void build_recursive_room(player_type *player_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2, int power);
-void build_room(player_type *player_ptr, POSITION x1, POSITION x2, POSITION y1, POSITION y2);
+void build_recursive_room(PlayerType *player_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2, int power);
+void build_room(PlayerType *player_ptr, POSITION x1, POSITION x2, POSITION y1, POSITION y2);
index 8b766aa..0e36171 100644 (file)
@@ -68,7 +68,7 @@ static bool precalc_ugarcade(int town_hgt, int town_wid, int n, std::vector<ugbl
 }
 
 /* Create a new floor room with optional light */
-static void generate_room_floor(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, int light)
+static void generate_room_floor(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, int light)
 {
     grid_type *g_ptr;
     for (POSITION y = y1; y <= y2; y++) {
@@ -82,7 +82,7 @@ static void generate_room_floor(player_type *player_ptr, POSITION y1, POSITION x
     }
 }
 
-static void generate_fill_perm_bold(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2)
+static void generate_fill_perm_bold(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2)
 {
     for (POSITION y = y1; y <= y2; y++)
         for (POSITION x = x1; x <= x2; x++)
@@ -99,7 +99,7 @@ static void generate_fill_perm_bold(player_type *player_ptr, POSITION y1, POSITI
  * @note
  * Note: ltcy and ltcx indicate "left top corner".
  */
-static void build_stores(player_type *player_ptr, POSITION ltcy, POSITION ltcx, StoreSaleType stores[], int n, const std::vector<ugbldg_type>& ugbldg)
+static void build_stores(PlayerType *player_ptr, POSITION ltcy, POSITION ltcx, StoreSaleType stores[], int n, const std::vector<ugbldg_type>& ugbldg)
 {
     int i;
     POSITION y, x;
@@ -165,7 +165,7 @@ static void build_stores(player_type *player_ptr, POSITION ltcy, POSITION ltcx,
  * This function does NOT do anything about the owners of the stores,\n
  * nor the contents thereof.  It only handles the physical layout.\n
  */
-bool build_type16(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type16(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     StoreSaleType stores[] = {
         StoreSaleType::GENERAL,
index 524ee5e..5ff6e6a 100644 (file)
@@ -15,5 +15,5 @@ typedef struct ugbldg_type {
 } ugbldg_type;
 
 struct dun_data_type;
-struct player_type;
-bool build_type16(player_type *player_ptr, dun_data_type *dd_ptr);
+class PlayerType;
+bool build_type16(PlayerType *player_ptr, dun_data_type *dd_ptr);
index c678198..063835c 100644 (file)
@@ -13,7 +13,7 @@
 * @brief タイプ9の部屋…フラクタルカーブによる洞窟生成 / Type 9 -- Driver routine to create fractal grid
 * @return なし
 */
-bool build_type9(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type9(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
        int grd, roug, cutoff;
        POSITION xsize, ysize, y0, x0;
index cd215e0..5edb557 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct dun_data_type;
-struct player_type;
-bool build_type9(player_type *player_ptr, dun_data_type *dd_ptr);
+class PlayerType;
+bool build_type9(PlayerType *player_ptr, dun_data_type *dd_ptr);
index 71349ec..96edb38 100644 (file)
@@ -27,7 +27,7 @@
  * is the randint0(3) below; it governs the relative density of
  * twists and turns in the labyrinth: smaller number, more twists.
  */
-void r_visit(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, int node, DIRECTION dir, int *visited)
+void r_visit(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, int node, DIRECTION dir, int *visited)
 {
     int adj[4];
     int m = (x2 - x1) / 2 + 1;
@@ -95,7 +95,7 @@ void r_visit(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POS
     }
 }
 
-void build_maze_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize, bool is_vault)
+void build_maze_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize, bool is_vault)
 {
     msg_print_wizard(player_ptr, CHEAT_DUNGEON, _("迷路ランダムVaultを生成しました。", "Maze Vault."));
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
index 1149db1..b70ab7f 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void r_visit(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, int node, DIRECTION dir, int *visited);
-void build_maze_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize, bool is_vault);
+class PlayerType;
+void r_visit(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, int node, DIRECTION dir, int *visited);
+void build_maze_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize, bool is_vault);
index b10023a..9d392aa 100644 (file)
@@ -19,7 +19,7 @@
  * @brief タイプ1の部屋…通常可変長方形の部屋を生成する / Type 1 -- normal rectangular rooms
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-bool build_type1(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type1(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, y2, x2, yval, xval;
     POSITION y1, x1, xsize, ysize;
@@ -192,7 +192,7 @@ bool build_type1(player_type *player_ptr, dun_data_type *dd_ptr)
  * @brief タイプ2の部屋…二重長方形の部屋を生成する / Type 2 -- Overlapping rectangular rooms
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-bool build_type2(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type2(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, xval, yval;
     POSITION y1a, x1a, y2a, x2a;
@@ -302,7 +302,7 @@ bool build_type2(player_type *player_ptr, dun_data_type *dd_ptr)
  * the code below will work (with "bounds checking") for 5x5, or even\n
  * for unsymetric values like 4x3 or 5x3 or 3x4 or 3x5, or even larger.\n
  */
-bool build_type3(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type3(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, dy, dx, wy, wx;
     POSITION y1a, x1a, y2a, x2a;
@@ -539,7 +539,7 @@ bool build_type3(player_type *player_ptr, dun_data_type *dd_ptr)
  *     4 - Inner room has a maze\n
  *     5 - A set of four inner rooms\n
  */
-bool build_type4(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type4(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, y1, x1;
     POSITION y2, x2, tmp, yval, xval;
@@ -871,7 +871,7 @@ bool build_type4(player_type *player_ptr, dun_data_type *dd_ptr)
  *\n
  * When done fill from the inside to find the walls,\n
  */
-bool build_type11(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type11(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION rad, x, y, x0, y0;
     int light = false;
@@ -915,7 +915,7 @@ bool build_type11(player_type *player_ptr, dun_data_type *dd_ptr)
  *\n
  * When done fill from the inside to find the walls,\n
  */
-bool build_type12(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type12(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION rad, x, y, x0, y0;
     int light = false;
index 98a8bf8..7d9d8fa 100644 (file)
@@ -1,10 +1,10 @@
 #pragma once
 
 struct dun_data_type;
-struct player_type;
-bool build_type1(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type2(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type3(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type4(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type11(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type12(player_type *player_ptr, dun_data_type *dd_ptr);
+class PlayerType;
+bool build_type1(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type2(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type3(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type4(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type11(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type12(PlayerType *player_ptr, dun_data_type *dd_ptr);
index 64a57f7..6ac54b6 100644 (file)
@@ -119,7 +119,7 @@ static concptr pit_subtype_string(int type, bool nest)
  *  @param b 比較対象参照ID2
  *  TODO: to sort.c
  */
-static bool ang_sort_comp_nest_mon_info(player_type *player_ptr, vptr u, vptr v, int a, int b)
+static bool ang_sort_comp_nest_mon_info(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -160,7 +160,7 @@ static bool ang_sort_comp_nest_mon_info(player_type *player_ptr, vptr u, vptr v,
  * @param b スワップ対象参照ID2
  * TODO: to sort.c
  */
-static void ang_sort_swap_nest_mon_info(player_type *player_ptr, vptr u, vptr v, int a, int b)
+static void ang_sort_swap_nest_mon_info(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -216,7 +216,7 @@ static void add_cave_info(grid_type *g_ptr, int cave_mask)
  *\n
  * Note that "monster nests" will never contain "unique" monsters.\n
  */
-bool build_type5(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type5(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, y1, x1, y2, x2, xval, yval;
     int i;
@@ -442,7 +442,7 @@ std::vector<nest_pit_type> pit_types = {
  *\n
  * Note that "monster pits" will never contain "unique" monsters.\n
  */
-bool build_type6(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type6(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, y1, x1, y2, x2, xval, yval;
     int i, j;
@@ -682,7 +682,7 @@ const int place_table_trapped_pit[TRAPPED_PIT_MONSTER_PLACE_MAX][3] = {
  * @detai;
  * 穴を掘るモンスター、壁を抜けるモンスターは却下
  */
-static bool vault_aux_trapped_pit(player_type *player_ptr, MONRACE_IDX r_idx)
+static bool vault_aux_trapped_pit(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     /* Unused */
     (void)player_ptr;
@@ -743,7 +743,7 @@ static bool vault_aux_trapped_pit(player_type *player_ptr, MONRACE_IDX r_idx)
  *\n
  * Note that "monster pits" will never contain "unique" monsters.\n
  */
-bool build_type13(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type13(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, y1, x1, y2, x2, xval, yval;
     int i, j;
index b72c8f6..689de99 100644 (file)
@@ -34,11 +34,11 @@ enum pit_type : int {
 };
 
 /*! pit/nest型情報の構造体定義 */
-struct player_type;
+class PlayerType;
 struct nest_pit_type {
     concptr name; //<! 部屋名
-    bool (*hook_func)(player_type *player_ptr, MONRACE_IDX r_idx); //<! モンスターフィルタ関数
-    void (*prep_func)(player_type *player_ptr); //<! 能力フィルタ関数
+    bool (*hook_func)(PlayerType *player_ptr, MONRACE_IDX r_idx); //<! モンスターフィルタ関数
+    void (*prep_func)(PlayerType *player_ptr); //<! 能力フィルタ関数
     DEPTH level; //<! 相当階
     int chance; //!< 生成確率
 };
@@ -50,6 +50,6 @@ struct nest_mon_info_type {
 };
 
 struct dun_data_type;
-bool build_type5(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type6(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type13(player_type *player_ptr, dun_data_type *dd_ptr);
+bool build_type5(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type6(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type13(PlayerType *player_ptr, dun_data_type *dd_ptr);
index b99a444..f8045b4 100644 (file)
@@ -27,7 +27,7 @@
  * @brief タイプ15の部屋…ガラス部屋の生成 / Type 15 -- glass rooms
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-bool build_type15(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type15(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, y2, x2, yval, xval;
     POSITION y1, x1, xsize, ysize;
index 8cc085f..6954f7f 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct dun_data_type;
-struct player_type;
-bool build_type15(player_type *player_ptr, dun_data_type *dd_ptr);
+class PlayerType;
+bool build_type15(PlayerType *player_ptr, dun_data_type *dd_ptr);
index 7ea8172..d526fe4 100644 (file)
@@ -18,7 +18,7 @@
  * @details
  * A special trap is placed at center of the room
  */
-bool build_type14(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type14(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y, x, y2, x2, yval, xval;
     POSITION y1, x1, xsize, ysize;
index 4bebf0e..e6100aa 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct dun_data_type;
-struct player_type;
-bool build_type14(player_type *player_ptr, dun_data_type *dd_ptr);
+class PlayerType;
+bool build_type14(PlayerType *player_ptr, dun_data_type *dd_ptr);
index ee1bb25..389f4a4 100644 (file)
@@ -52,7 +52,7 @@ std::vector<vault_type> v_info;
  * Note: If two centers are on the same point then this algorithm will create a
  *       blank bubble filled with walls. - This is prevented from happening.
  */
-static void build_bubble_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
+static void build_bubble_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
 {
 #define BUBBLENUM 10 /* number of bubbles */
 
@@ -169,7 +169,7 @@ static void build_bubble_vault(player_type *player_ptr, POSITION x0, POSITION y0
 }
 
 /* Create a random vault that looks like a collection of overlapping rooms */
-static void build_room_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
+static void build_room_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
 {
     POSITION x1, x2, y1, y2, xhsize, yhsize;
     int i;
@@ -214,7 +214,7 @@ static void build_room_vault(player_type *player_ptr, POSITION x0, POSITION y0,
 }
 
 /* Create a random vault out of a fractal grid */
-static void build_cave_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsiz, POSITION ysiz)
+static void build_cave_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsiz, POSITION ysiz)
 {
     int grd, roug, cutoff;
     bool done, light, room;
@@ -312,7 +312,7 @@ static void coord_trans(POSITION *x, POSITION *y, POSITION xoffset, POSITION yof
  * @param transno 変換ID
  */
 static void build_vault(
-    player_type *player_ptr, POSITION yval, POSITION xval, POSITION ymax, POSITION xmax, concptr data, POSITION xoffset, POSITION yoffset, int transno)
+    PlayerType *player_ptr, POSITION yval, POSITION xval, POSITION ymax, POSITION xmax, concptr data, POSITION xoffset, POSITION yoffset, int transno)
 {
     POSITION dx, dy, x, y, i, j;
     concptr t;
@@ -601,7 +601,7 @@ static void build_vault(
 /*!
  * @brief タイプ7の部屋…v_info.txtより小型vaultを生成する / Type 7 -- simple vaults (see "v_info.txt")
  */
-bool build_type7(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type7(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     vault_type *v_ptr = nullptr;
     int dummy;
@@ -669,7 +669,7 @@ bool build_type7(player_type *player_ptr, dun_data_type *dd_ptr)
 /*!
  * @brief タイプ8の部屋…v_info.txtより大型vaultを生成する / Type 8 -- greater vaults (see "v_info.txt")
  */
-bool build_type8(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type8(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     vault_type *v_ptr;
     int dummy;
@@ -745,7 +745,7 @@ bool build_type8(player_type *player_ptr, dun_data_type *dd_ptr)
  * This is made by two concentric "crypts" with perpendicular
  * walls creating the cross-hairs.
  */
-static void build_target_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
+static void build_target_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
 {
     POSITION rad, x, y;
 
@@ -849,7 +849,7 @@ static void build_target_vault(player_type *player_ptr, POSITION x0, POSITION y0
  *
  * Miniture rooms are then scattered across the vault.
  */
-static void build_elemental_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsiz, POSITION ysiz)
+static void build_elemental_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsiz, POSITION ysiz)
 {
     int grd, roug;
     int c1, c2, c3;
@@ -928,7 +928,7 @@ static void build_elemental_vault(player_type *player_ptr, POSITION x0, POSITION
  * The vault has two entrances on opposite sides to guarantee
  * a way to get in even if the vault abuts a side of the dungeon.
  */
-static void build_mini_c_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
+static void build_mini_c_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
 {
     POSITION dy, dx;
     POSITION y1, x1, y2, x2, y, x, total;
@@ -1039,7 +1039,7 @@ static void build_mini_c_vault(player_type *player_ptr, POSITION x0, POSITION y0
  *
  *This makes a vault that looks like a castle/ city in the dungeon.
  */
-static void build_castle_vault(player_type *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
+static void build_castle_vault(PlayerType *player_ptr, POSITION x0, POSITION y0, POSITION xsize, POSITION ysize)
 {
     POSITION dy, dx;
     POSITION y1, x1, y2, x2;
@@ -1077,7 +1077,7 @@ static void build_castle_vault(player_type *player_ptr, POSITION x0, POSITION y0
  * @brief タイプ10の部屋…ランダム生成vault / Type 10 -- Random vaults
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-bool build_type10(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type10(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     POSITION y0, x0, xsize, ysize, vtype;
 
@@ -1139,7 +1139,7 @@ bool build_type10(player_type *player_ptr, dun_data_type *dd_ptr)
 /*!
  * @brief タイプ17の部屋…v_info.txtより固定特殊部屋を生成する / Type 17 -- fixed special room (see "v_info.txt")
  */
-bool build_type17(player_type *player_ptr, dun_data_type *dd_ptr)
+bool build_type17(PlayerType *player_ptr, dun_data_type *dd_ptr)
 {
     vault_type *v_ptr = nullptr;
     int dummy;
index 77265fb..c34b66b 100644 (file)
@@ -19,8 +19,8 @@ typedef struct vault_type {
 extern std::vector<vault_type> v_info;
 
 struct dun_data_type;
-struct player_type;
-bool build_type7(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type8(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type10(player_type *player_ptr, dun_data_type *dd_ptr);
-bool build_type17(player_type *player_ptr, dun_data_type *dd_ptr);
+class PlayerType;
+bool build_type7(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type8(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type10(PlayerType *player_ptr, dun_data_type *dd_ptr);
+bool build_type17(PlayerType *player_ptr, dun_data_type *dd_ptr);
index e955c4e..75153af 100644 (file)
@@ -32,7 +32,7 @@ static bool get_is_floor(floor_type *floor_ptr, POSITION x, POSITION y)
  * @param x 地形を変えたいマスのX座標
  * @param y 地形を変えたいマスのY座標
  */
-static void set_floor(player_type *player_ptr, POSITION x, POSITION y)
+static void set_floor(PlayerType *player_ptr, POSITION x, POSITION y)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!in_bounds(floor_ptr, y, x))
@@ -56,7 +56,7 @@ static void set_floor(player_type *player_ptr, POSITION x, POSITION y)
  * @param x2 範囲の右端
  * @param y2 範囲の下端
  */
-static void check_room_boundary(player_type *player_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2)
+static void check_room_boundary(PlayerType *player_ptr, POSITION x1, POSITION y1, POSITION x2, POSITION y2)
 {
     bool old_is_floor;
     bool new_is_floor;
@@ -173,7 +173,7 @@ static bool find_space_aux(dun_data_type *dd_ptr, POSITION blocks_high, POSITION
  * Return TRUE and values for the center of the room if all went well.\n
  * Otherwise, return FALSE.\n
  */
-bool find_space(player_type *player_ptr, dun_data_type *dd_ptr, POSITION *y, POSITION *x, POSITION height, POSITION width)
+bool find_space(PlayerType *player_ptr, dun_data_type *dd_ptr, POSITION *y, POSITION *x, POSITION height, POSITION width)
 {
     int pick;
     POSITION block_y = 0;
index 475ce18..1234590 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 struct dun_data_type;
-struct player_type;
-bool find_space(player_type *player_ptr, dun_data_type *dd_ptr, POSITION *y, POSITION *x, POSITION height, POSITION width);
+class PlayerType;
+bool find_space(PlayerType *player_ptr, dun_data_type *dd_ptr, POSITION *y, POSITION *x, POSITION height, POSITION width);
index a736b0f..e0ee5d9 100644 (file)
@@ -20,7 +20,7 @@
 /*
  * Routine that fills the empty areas of a room with treasure and monsters.
  */
-void fill_treasure(player_type *player_ptr, POSITION x1, POSITION x2, POSITION y1, POSITION y2, int difficulty)
+void fill_treasure(PlayerType *player_ptr, POSITION x1, POSITION x2, POSITION y1, POSITION y2, int difficulty)
 {
     POSITION cx = (x1 + x2) / 2;
     POSITION cy = (y1 + y2) / 2;
index 82a5897..7e7968d 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void fill_treasure(player_type *player_ptr, POSITION x1, POSITION x2, POSITION y1, POSITION y2, int difficulty);
+class PlayerType;
+void fill_treasure(PlayerType *player_ptr, POSITION x1, POSITION x2, POSITION y1, POSITION y2, int difficulty);
index eb69dbb..391f2e8 100644 (file)
 /*
  * Grid based version of "creature_bold()"
  */
-static bool player_grid(player_type *player_ptr, grid_type *g_ptr) { return g_ptr == &player_ptr->current_floor_ptr->grid_array[player_ptr->y][player_ptr->x]; }
+static bool player_grid(PlayerType *player_ptr, grid_type *g_ptr) { return g_ptr == &player_ptr->current_floor_ptr->grid_array[player_ptr->y][player_ptr->x]; }
 
 /*
  * Grid based version of "cave_empty_bold()"
  */
-static bool is_cave_empty_grid(player_type *player_ptr, grid_type *g_ptr)
+static bool is_cave_empty_grid(PlayerType *player_ptr, grid_type *g_ptr)
 {
     bool is_empty_grid = g_ptr->cave_has_flag(FloorFeatureType::PLACE);
     is_empty_grid &= g_ptr->m_idx == 0;
@@ -38,7 +38,7 @@ static bool is_cave_empty_grid(player_type *player_ptr, grid_type *g_ptr)
  * @details
  * Only really called by some of the "vault" routines.
  */
-void vault_monsters(player_type *player_ptr, POSITION y1, POSITION x1, int num)
+void vault_monsters(PlayerType *player_ptr, POSITION y1, POSITION x1, int num)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (int k = 0; k < num; k++) {
@@ -67,7 +67,7 @@ void vault_monsters(player_type *player_ptr, POSITION y1, POSITION x1, int num)
  * @details
  * Only really called by some of the "vault" routines.
  */
-void vault_objects(player_type *player_ptr, POSITION y, POSITION x, int num)
+void vault_objects(PlayerType *player_ptr, POSITION y, POSITION x, int num)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     for (; num > 0; --num) {
@@ -112,7 +112,7 @@ void vault_objects(player_type *player_ptr, POSITION y, POSITION x, int num)
  * @details
  * Only really called by some of the "vault" routines.
  */
-static void vault_trap_aux(player_type *player_ptr, POSITION y, POSITION x, POSITION yd, POSITION xd)
+static void vault_trap_aux(PlayerType *player_ptr, POSITION y, POSITION x, POSITION yd, POSITION xd)
 {
     grid_type *g_ptr;
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
@@ -153,7 +153,7 @@ static void vault_trap_aux(player_type *player_ptr, POSITION y, POSITION x, POSI
  * Only really called by some of the "vault" routines.
  * @todo rooms-normal からしか呼ばれていない、要調整
  */
-void vault_traps(player_type *player_ptr, POSITION y, POSITION x, POSITION yd, POSITION xd, int num)
+void vault_traps(PlayerType *player_ptr, POSITION y, POSITION x, POSITION yd, POSITION xd, int num)
 {
     for (int i = 0; i < num; i++)
         vault_trap_aux(player_ptr, y, x, yd, xd);
index 464bf35..3d8ff83 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void vault_monsters(player_type *player_ptr, POSITION y1, POSITION x1, int num);
-void vault_objects(player_type *player_ptr, POSITION y, POSITION x, int num);
-void vault_traps(player_type *player_ptr, POSITION y, POSITION x, POSITION yd, POSITION xd, int num);
+class PlayerType;
+void vault_monsters(PlayerType *player_ptr, POSITION y1, POSITION x1, int num);
+void vault_objects(PlayerType *player_ptr, POSITION y, POSITION x, int num);
+void vault_traps(PlayerType *player_ptr, POSITION y, POSITION x, POSITION yd, POSITION xd, int num);
index ad87a4f..a9fc05f 100644 (file)
@@ -23,7 +23,7 @@
  * @brief 保存フロアの書き込み / Actually write a saved floor data using effectively compressed format.
  * @param sf_ptr 保存したいフロアの参照ポインタ
  */
-void wr_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr)
+void wr_saved_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!sf_ptr) {
@@ -150,7 +150,7 @@ void wr_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr)
  * @player_ptr プレイヤーへの参照ポインタ
  * @return 保存に成功したらTRUE
  */
-bool wr_dungeon(player_type *player_ptr)
+bool wr_dungeon(PlayerType *player_ptr)
 {
     forget_lite(player_ptr->current_floor_ptr);
     forget_view(player_ptr->current_floor_ptr);
@@ -205,7 +205,7 @@ bool wr_dungeon(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param sf_ptr 保存フロア参照ポインタ
  */
-static bool save_floor_aux(player_type *player_ptr, saved_floor_type *sf_ptr)
+static bool save_floor_aux(PlayerType *player_ptr, saved_floor_type *sf_ptr)
 {
     compact_objects(player_ptr, 0);
     compact_monsters(player_ptr, 0);
@@ -230,7 +230,7 @@ static bool save_floor_aux(player_type *player_ptr, saved_floor_type *sf_ptr)
  * @param sf_ptr 保存フロア参照ポインタ
  * @param mode 保存オプション
  */
-bool save_floor(player_type *player_ptr, saved_floor_type *sf_ptr, BIT_FLAGS mode)
+bool save_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr, BIT_FLAGS mode)
 {
     FILE *old_fff = nullptr;
     byte old_xor_byte = 0;
index e53ce40..b94f986 100644 (file)
@@ -6,8 +6,8 @@
 #define SLF_SECOND 0x0001 /* Called from another save/load function */
 #define SLF_NO_KILL 0x0002 /* Don't kill temporary files */
 
-struct player_type;
+class PlayerType;
 struct saved_floor_type;
-void wr_saved_floor(player_type *player_ptr, saved_floor_type *sf_ptr);
-bool wr_dungeon(player_type *player_ptr);
-bool save_floor(player_type *player_ptr, saved_floor_type *sf_ptr, BIT_FLAGS mode);
+void wr_saved_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr);
+bool wr_dungeon(PlayerType *player_ptr);
+bool save_floor(PlayerType *player_ptr, saved_floor_type *sf_ptr, BIT_FLAGS mode);
index 03ab8fc..938a619 100644 (file)
@@ -20,7 +20,7 @@
  * @brief セーブデータに領域情報を書き込む / Write player realms
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void wr_relams(player_type *player_ptr)
+static void wr_relams(PlayerType *player_ptr)
 {
     if (player_ptr->pclass == PlayerClassType::ELEMENTALIST)
         wr_byte((byte)player_ptr->element);
@@ -33,7 +33,7 @@ static void wr_relams(player_type *player_ptr)
  * @brief セーブデータにプレイヤー情報を書き込む / Write some "player" info
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void wr_player(player_type *player_ptr)
+void wr_player(PlayerType *player_ptr)
 {
     wr_string(player_ptr->name);
     wr_string(player_ptr->died_from);
index 31ebdb5..5722002 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void wr_player(player_type *player_ptr);
+class PlayerType;
+void wr_player(PlayerType *player_ptr);
index c5a8d8d..ce9042e 100644 (file)
@@ -48,7 +48,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 成功すればtrue
  */
-static bool wr_savefile_new(player_type *player_ptr, save_type type)
+static bool wr_savefile_new(PlayerType *player_ptr, save_type type)
 {
     compact_objects(player_ptr, 0);
     compact_monsters(player_ptr, 0);
@@ -231,7 +231,7 @@ static bool wr_savefile_new(player_type *player_ptr, save_type type)
  * @details
  * Angband 2.8.0 will use "fd" instead of "fff" if possible
  */
-static bool save_player_aux(player_type *player_ptr, char *name, save_type type)
+static bool save_player_aux(PlayerType *player_ptr, char *name, save_type type)
 {
     safe_setuid_grab(player_ptr);
     int file_permission = 0644;
@@ -274,7 +274,7 @@ static bool save_player_aux(player_type *player_ptr, char *name, save_type type)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 成功すればtrue
  */
-bool save_player(player_type *player_ptr, save_type type)
+bool save_player(PlayerType *player_ptr, save_type type)
 {
     char safe[1024];
     strcpy(safe, savefile);
index f5aba69..015380b 100644 (file)
@@ -6,5 +6,5 @@ enum save_type {
        SAVE_TYPE_DEBUG = 2
 };
 
-struct player_type;
-bool save_player(player_type *player_ptr, save_type type);
+class PlayerType;
+bool save_player(PlayerType *player_ptr, save_type type);
index e176f83..a2bef43 100644 (file)
@@ -9,7 +9,7 @@
 #include "target/target-getter.h"
 #include "view/display-messages.h"
 
-bool activate_bladeturner(player_type *player_ptr)
+bool activate_bladeturner(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
index dd37cc2..eb254b6 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool activate_bladeturner(player_type *player_ptr);
+class PlayerType;
+bool activate_bladeturner(PlayerType *player_ptr);
index b5f59ca..4694ad2 100644 (file)
@@ -51,7 +51,7 @@ void get_bloody_moon_flags(object_type *o_ptr)
  * @param o_ptr ブラッディ・ムーンへの参照ポインタ
  * @return オブジェクト情報に異常がない限りTRUE
  */
-bool activate_bloody_moon(player_type *player_ptr, object_type *o_ptr)
+bool activate_bloody_moon(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (o_ptr->name1 != ART_BLOOD)
         return false;
index 6f18f55..dd5007f 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
 struct object_type;
-struct player_type;
+class PlayerType;
 void get_bloody_moon_flags(object_type *o_ptr);
-bool activate_bloody_moon(player_type *player_ptr, object_type *o_ptr);
+bool activate_bloody_moon(PlayerType *player_ptr, object_type *o_ptr);
index a4e0c46..389f636 100644 (file)
@@ -30,7 +30,7 @@
 /*!< この値以降の小項目IDを持った箱は大型の箱としてドロップ数を増やす / Special "sval" limit -- first "large" chest */
 #define SV_CHEST_MIN_LARGE 4
 
-Chest::Chest(player_type *player_ptr)
+Chest::Chest(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index 0b46408..87b40d6 100644 (file)
@@ -2,14 +2,14 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class Chest {
 public:
-    Chest(player_type *player_ptr);
+    Chest(PlayerType *player_ptr);
     virtual ~Chest() = default;
     void chest_death(bool scatter, POSITION y, POSITION x, OBJECT_IDX o_idx);
     void chest_trap(POSITION y, POSITION x, OBJECT_IDX o_idx);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 };
index 8f6068d..b037d45 100644 (file)
@@ -18,7 +18,7 @@
  * Need to analyze size of the window.
  * Need more color coding.
  */
-static bool fire_crimson(player_type *player_ptr)
+static bool fire_crimson(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -50,7 +50,7 @@ static bool fire_crimson(player_type *player_ptr)
     return true;
 }
 
-bool activate_crimson(player_type *player_ptr, object_type *o_ptr)
+bool activate_crimson(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (o_ptr->name1 != ART_CRIMSON)
         return false;
index 98c1749..f62bdfd 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool activate_crimson(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool activate_crimson(PlayerType *player_ptr, object_type *o_ptr);
index d9b7284..d980ad7 100644 (file)
@@ -29,7 +29,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 倍率 (実際は1/10になる)
  */
-static int calc_death_scythe_reflection_magnification_mimic_none(player_type *player_ptr)
+static int calc_death_scythe_reflection_magnification_mimic_none(PlayerType *player_ptr)
 {
     switch (player_ptr->prace) {
     case PlayerRaceType::YEEK:
@@ -64,7 +64,7 @@ static int calc_death_scythe_reflection_magnification_mimic_none(player_type *pl
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 倍率 (実際は1/10になる)
  */
-static int calc_death_scythe_reflection_magnification(player_type *player_ptr)
+static int calc_death_scythe_reflection_magnification(PlayerType *player_ptr)
 {
     switch (player_ptr->mimic_form) {
     case MIMIC_NONE:
@@ -84,7 +84,7 @@ static int calc_death_scythe_reflection_magnification(player_type *player_ptr)
  * @param magnification ダメージ倍率
  * @param death_scythe_flags 死の大鎌に関するオブジェクトフラグ配列
  */
-static void compensate_death_scythe_reflection_magnification(player_type *player_ptr, int *magnification, const TrFlags &death_scythe_flags)
+static void compensate_death_scythe_reflection_magnification(PlayerType *player_ptr, int *magnification, const TrFlags &death_scythe_flags)
 {
     if ((player_ptr->alignment < 0) && (*magnification < 20))
         *magnification = 20;
@@ -133,7 +133,7 @@ static void death_scythe_reflection_critial_hit(player_attack_type *pa_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pa_ptr 直接攻撃構造体への参照ポインタ
  */
-void process_death_scythe_reflection(player_type *player_ptr, player_attack_type *pa_ptr)
+void process_death_scythe_reflection(PlayerType *player_ptr, player_attack_type *pa_ptr)
 {
     sound(SOUND_HIT);
     msg_format(_("ミス! %sにかわされた。", "You miss %s."), pa_ptr->m_name);
index 13259d5..f8fda9a 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct player_attack_type;
-struct player_type;
-void process_death_scythe_reflection(player_type *player_ptr, player_attack_type *pa_ptr);
+class PlayerType;
+void process_death_scythe_reflection(PlayerType *player_ptr, player_attack_type *pa_ptr);
index c642514..9e8f97d 100644 (file)
@@ -61,7 +61,7 @@ static void inscribe_nickname(ae_type *ae_ptr)
     ae_ptr->o_ptr->inscription = quark_add(buf);
 }
 
-static bool set_activation_target(player_type *player_ptr, ae_type *ae_ptr)
+static bool set_activation_target(PlayerType *player_ptr, ae_type *ae_ptr)
 {
     bool old_target_pet = target_pet;
     target_pet = true;
@@ -82,7 +82,7 @@ static bool set_activation_target(player_type *player_ptr, ae_type *ae_ptr)
     return true;
 }
 
-static void add_quark_to_inscription(player_type *player_ptr, ae_type *ae_ptr, concptr t, char *buf)
+static void add_quark_to_inscription(PlayerType *player_ptr, ae_type *ae_ptr, concptr t, char *buf)
 {
     if (!*t)
         return;
@@ -124,7 +124,7 @@ static void add_quark_to_inscription(player_type *player_ptr, ae_type *ae_ptr, c
     ae_ptr->o_ptr->inscription = quark_add(buf);
 }
 
-static void check_inscription_value(player_type *player_ptr, ae_type *ae_ptr)
+static void check_inscription_value(PlayerType *player_ptr, ae_type *ae_ptr)
 {
     if (ae_ptr->o_ptr->inscription == 0)
         return;
@@ -141,7 +141,7 @@ static void check_inscription_value(player_type *player_ptr, ae_type *ae_ptr)
     add_quark_to_inscription(player_ptr, ae_ptr, t, buf);
 }
 
-static void check_monster_ball_use(player_type *player_ptr, ae_type *ae_ptr)
+static void check_monster_ball_use(PlayerType *player_ptr, ae_type *ae_ptr)
 {
     if (!monster_can_enter(player_ptr, player_ptr->y + ddy[ae_ptr->dir], player_ptr->x + ddx[ae_ptr->dir], &r_info[ae_ptr->o_ptr->pval], 0))
         return;
@@ -168,7 +168,7 @@ static void check_monster_ball_use(player_type *player_ptr, ae_type *ae_ptr)
     ae_ptr->success = true;
 }
 
-bool exe_monster_capture(player_type *player_ptr, ae_type *ae_ptr)
+bool exe_monster_capture(PlayerType *player_ptr, ae_type *ae_ptr)
 {
     if (ae_ptr->o_ptr->tval != ItemKindType::CAPTURE)
         return false;
index 9f4d8ed..b9d001a 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 typedef struct ae_type ae_type;
-struct player_type;
-bool exe_monster_capture(player_type *player_ptr, ae_type *ae_ptr);
+class PlayerType;
+bool exe_monster_capture(PlayerType *player_ptr, ae_type *ae_ptr);
index a5b641a..2a1aff4 100644 (file)
@@ -7,7 +7,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-bool activate_muramasa(player_type *player_ptr, object_type *o_ptr)
+bool activate_muramasa(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (o_ptr->name1 != ART_MURAMASA)
         return false;
index 6ffab1f..8f3ba5e 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool activate_muramasa(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool activate_muramasa(PlayerType *player_ptr, object_type *o_ptr);
index 1db583f..eecc05c 100644 (file)
@@ -16,7 +16,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param dir 発動の方向ID
  */
-static void exe_ring_of_power(player_type *player_ptr, DIRECTION dir)
+static void exe_ring_of_power(PlayerType *player_ptr, DIRECTION dir)
 {
     switch (randint1(10)) {
     case 1:
@@ -53,7 +53,7 @@ static void exe_ring_of_power(player_type *player_ptr, DIRECTION dir)
     }
 }
 
-bool activate_ring_of_power(player_type *player_ptr, concptr name)
+bool activate_ring_of_power(PlayerType *player_ptr, concptr name)
 {
     DIRECTION dir;
     msg_format(_("%sは漆黒に輝いた...", "The %s glows intensely black..."), name);
index 27c7f6c..fec840e 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool activate_ring_of_power(player_type *player_ptr, concptr name);
+class PlayerType;
+bool activate_ring_of_power(PlayerType *player_ptr, concptr name);
index d81d19d..d0960e1 100644 (file)
@@ -13,7 +13,7 @@
 #include "util/bit-flags-calculator.h"
 #include "view/display-messages.h"
 
-StoneOfLore::StoneOfLore(player_type *player_ptr)
+StoneOfLore::StoneOfLore(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index 92f8fbb..bda09c8 100644 (file)
@@ -1,14 +1,14 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 class StoneOfLore {
 public:
-    StoneOfLore(player_type *player_ptr);
+    StoneOfLore(PlayerType *player_ptr);
     virtual ~StoneOfLore() = default;
     bool perilous_secrets();
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 
     void consume_mp();
 };
index 2fa00bf..0007939 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-bool activate_toragoroshi(player_type *player_ptr)
+bool activate_toragoroshi(PlayerType *player_ptr)
 {
     msg_print(_("あなたは妖刀に魅入られた…", "You are fascinated by the cursed blade..."));
     msg_print(_("「狂ほしく 血のごとき 月はのぼれり 秘めおきし 魔剣 いずこぞや」", "'Behold the blade arts.'"));
index 3fb9016..28021ff 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool activate_toragoroshi(player_type *player_ptr);
+class PlayerType;
+bool activate_toragoroshi(PlayerType *player_ptr);
index 4cf6544..c524af3 100644 (file)
@@ -81,7 +81,7 @@ void torch_lost_fuel(object_type *o_ptr)
  * @details
  * SWD: Experimental modification: multiple light sources have additive effect.
  */
-void update_lite_radius(player_type *player_ptr)
+void update_lite_radius(PlayerType *player_ptr)
 {
     player_ptr->cur_lite = 0;
     for (int i = INVEN_MAIN_HAND; i < INVEN_TOTAL; i++) {
@@ -174,7 +174,7 @@ void update_lite_radius(player_type *player_ptr)
  *                 ***         *****
  *                              ***
  */
-void update_lite(player_type *player_ptr)
+void update_lite(PlayerType *player_ptr)
 {
     // 前回照らされていた座標たちを格納する配列。
     std::vector<Pos2D> points;
index 756add8..f4d1b0a 100644 (file)
@@ -5,10 +5,10 @@
 #include "object-enchant/tr-flags.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 bool is_active_torch(object_type *o_ptr);
 void torch_flags(object_type *o_ptr, TrFlags &flgs);
 void torch_dice(object_type *o_ptr, DICE_NUMBER *dd, DICE_SID *ds);
 void torch_lost_fuel(object_type *o_ptr);
-void update_lite_radius(player_type *player_ptr);
-void update_lite(player_type *player_ptr);
+void update_lite_radius(PlayerType *player_ptr);
+void update_lite(PlayerType *player_ptr);
index 3070651..44d8bea 100644 (file)
@@ -17,7 +17,7 @@
 #include "system/player-type-definition.h"
 #include "view/display-messages.h"
 
-void blood_curse_to_enemy(player_type *player_ptr, MONSTER_IDX m_idx)
+void blood_curse_to_enemy(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     grid_type *g_ptr = &player_ptr->current_floor_ptr->grid_array[m_ptr->fy][m_ptr->fx];
index edd1afb..711ecc6 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void blood_curse_to_enemy(player_type *player_ptr, MONSTER_IDX m_idx);
+class PlayerType;
+void blood_curse_to_enemy(PlayerType *player_ptr, MONSTER_IDX m_idx);
index c36a5b8..b2df1ea 100644 (file)
@@ -49,7 +49,7 @@
  * @param m_idx 地震を起こしたモンスターID(0ならばプレイヤー)
  * @return 効力があった場合TRUEを返す
  */
-bool earthquake(player_type *player_ptr, POSITION cy, POSITION cx, POSITION r, MONSTER_IDX m_idx)
+bool earthquake(PlayerType *player_ptr, POSITION cy, POSITION cx, POSITION r, MONSTER_IDX m_idx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if ((floor_ptr->inside_quest && quest_type::is_fixed(floor_ptr->inside_quest)) || !floor_ptr->dun_level) {
index 3edc638..6503e02 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool earthquake(player_type *player_ptr, POSITION cy, POSITION cx, POSITION r, MONSTER_IDX m_idx);
+class PlayerType;
+bool earthquake(PlayerType *player_ptr, POSITION cy, POSITION cx, POSITION r, MONSTER_IDX m_idx);
index 207546d..8dcb7b1 100644 (file)
@@ -47,7 +47,7 @@
  *
  * Beware of "sliding index errors".
  */
-bool recharge(player_type *player_ptr, int power)
+bool recharge(PlayerType *player_ptr, int power)
 {
     concptr q = _("どのアイテムに魔力を充填しますか? ", "Recharge which item? ");
     concptr s = _("魔力を充填すべきアイテムがない。", "You have nothing to recharge.");
index cc9ceb9..14001e4 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool recharge(player_type *player_ptr, int power);
+class PlayerType;
+bool recharge(PlayerType *player_ptr, int power);
index 083a75c..4acb4a8 100644 (file)
@@ -11,7 +11,7 @@
  * @param dam 威力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool wall_to_mud(player_type *player_ptr, DIRECTION dir, HIT_POINT dam)
+bool wall_to_mud(PlayerType *player_ptr, DIRECTION dir, HIT_POINT dam)
 {
     BIT_FLAGS flg = PROJECT_BEAM | PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL;
     return (project_hook(player_ptr, AttributeType::KILL_WALL, dir, dam, flg));
@@ -23,7 +23,7 @@ bool wall_to_mud(player_type *player_ptr, DIRECTION dir, HIT_POINT dam)
  * @param dir 方向(5ならばグローバル変数 target_col/target_row の座標を目標にする)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool wizard_lock(player_type *player_ptr, DIRECTION dir)
+bool wizard_lock(PlayerType *player_ptr, DIRECTION dir)
 {
     BIT_FLAGS flg = PROJECT_BEAM | PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL;
     return (project_hook(player_ptr, AttributeType::JAM_DOOR, dir, 20 + randint1(30), flg));
@@ -35,7 +35,7 @@ bool wizard_lock(player_type *player_ptr, DIRECTION dir)
  * @param dir 方向(5ならばグローバル変数 target_col/target_row の座標を目標にする)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool destroy_door(player_type *player_ptr, DIRECTION dir)
+bool destroy_door(PlayerType *player_ptr, DIRECTION dir)
 {
     BIT_FLAGS flg = PROJECT_BEAM | PROJECT_GRID | PROJECT_ITEM;
     return (project_hook(player_ptr, AttributeType::KILL_DOOR, dir, 0, flg));
@@ -47,7 +47,7 @@ bool destroy_door(player_type *player_ptr, DIRECTION dir)
  * @param dir 方向(5ならばグローバル変数 target_col/target_row の座標を目標にする)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool disarm_trap(player_type *player_ptr, DIRECTION dir)
+bool disarm_trap(PlayerType *player_ptr, DIRECTION dir)
 {
     BIT_FLAGS flg = PROJECT_BEAM | PROJECT_GRID | PROJECT_ITEM;
     return (project_hook(player_ptr, AttributeType::KILL_TRAP, dir, 0, flg));
index 194046d..f83f7b0 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool wall_to_mud(player_type *player_ptr, DIRECTION dir, HIT_POINT dam);
-bool wizard_lock(player_type *player_ptr, DIRECTION dir);
-bool destroy_door(player_type *player_ptr, DIRECTION dir);
-bool disarm_trap(player_type *player_ptr, DIRECTION dir);
+class PlayerType;
+bool wall_to_mud(PlayerType *player_ptr, DIRECTION dir, HIT_POINT dam);
+bool wizard_lock(PlayerType *player_ptr, DIRECTION dir);
+bool destroy_door(PlayerType *player_ptr, DIRECTION dir);
+bool disarm_trap(PlayerType *player_ptr, DIRECTION dir);
index 0e793e2..633325e 100644 (file)
@@ -11,7 +11,7 @@
  * @param plev パワー
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool charm_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
+bool charm_monster(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL;
     return (project_hook(player_ptr, AttributeType::CHARM, dir, plev, flg));
@@ -24,7 +24,7 @@ bool charm_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
  * @param plev パワー
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool control_one_undead(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
+bool control_one_undead(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL;
     return (project_hook(player_ptr, AttributeType::CONTROL_UNDEAD, dir, plev, flg));
@@ -37,7 +37,7 @@ bool control_one_undead(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL ple
  * @param plev パワー
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool control_one_demon(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
+bool control_one_demon(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL;
     return (project_hook(player_ptr, AttributeType::CONTROL_DEMON, dir, plev, flg));
@@ -50,7 +50,7 @@ bool control_one_demon(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev
  * @param plev パワー
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool charm_animal(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
+bool charm_animal(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL;
     return (project_hook(player_ptr, AttributeType::CONTROL_ANIMAL, dir, plev, flg));
index 31f2b6c..44cf12d 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool charm_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
-bool control_one_undead(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
-bool control_one_demon(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
-bool charm_animal(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
+class PlayerType;
+bool charm_monster(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
+bool control_one_undead(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
+bool control_one_demon(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
+bool charm_animal(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
index 2a76820..1756930 100644 (file)
@@ -16,7 +16,7 @@
  * @return 解呪されたアイテムの数
  * @details 永遠の呪いは解呪できない
  */
-static int exe_curse_removal(player_type *player_ptr, int all)
+static int exe_curse_removal(PlayerType *player_ptr, int all)
 {
     int cnt = 0;
     for (int i = INVEN_MAIN_HAND; i < INVEN_TOTAL; i++) {
@@ -53,11 +53,11 @@ static int exe_curse_removal(player_type *player_ptr, int all)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 解呪に成功した装備数
  */
-int remove_curse(player_type *player_ptr) { return exe_curse_removal(player_ptr, false); }
+int remove_curse(PlayerType *player_ptr) { return exe_curse_removal(player_ptr, false); }
 
 /*!
  * @brief 装備の重い呪い解呪処理 /
  * Remove all curses
  * @return 解呪に成功した装備数
  */
-int remove_all_curse(player_type *player_ptr) { return exe_curse_removal(player_ptr, true); }
+int remove_all_curse(PlayerType *player_ptr) { return exe_curse_removal(player_ptr, true); }
index c90c8ae..152bb05 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-int remove_curse(player_type *player_ptr);
-int remove_all_curse(player_type *player_ptr);
+class PlayerType;
+int remove_curse(PlayerType *player_ptr);
+int remove_all_curse(PlayerType *player_ptr);
index dddc76d..13fd85b 100644 (file)
@@ -37,7 +37,7 @@
  * @param known 地形から危険フラグを外すならTRUE
  * @return 効力があった場合TRUEを返す
  */
-static bool detect_feat_flag(player_type *player_ptr, POSITION range, FloorFeatureType flag, bool known)
+static bool detect_feat_flag(PlayerType *player_ptr, POSITION range, FloorFeatureType flag, bool known)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -83,7 +83,7 @@ static bool detect_feat_flag(player_type *player_ptr, POSITION range, FloorFeatu
  * @details
  * 吟遊詩人による感知についてはFALSEを返す
  */
-bool detect_traps(player_type *player_ptr, POSITION range, bool known)
+bool detect_traps(PlayerType *player_ptr, POSITION range, bool known)
 {
     bool detect = detect_feat_flag(player_ptr, range, FloorFeatureType::TRAP, known);
     if (!known && detect)
@@ -107,7 +107,7 @@ bool detect_traps(player_type *player_ptr, POSITION range, bool known)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_doors(player_type *player_ptr, POSITION range)
+bool detect_doors(PlayerType *player_ptr, POSITION range)
 {
     bool detect = detect_feat_flag(player_ptr, range, FloorFeatureType::DOOR, true);
 
@@ -126,7 +126,7 @@ bool detect_doors(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_stairs(player_type *player_ptr, POSITION range)
+bool detect_stairs(PlayerType *player_ptr, POSITION range)
 {
     bool detect = detect_feat_flag(player_ptr, range, FloorFeatureType::STAIRS, true);
 
@@ -145,7 +145,7 @@ bool detect_stairs(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_treasure(player_type *player_ptr, POSITION range)
+bool detect_treasure(PlayerType *player_ptr, POSITION range)
 {
     bool detect = detect_feat_flag(player_ptr, range, FloorFeatureType::HAS_GOLD, true);
 
@@ -163,7 +163,7 @@ bool detect_treasure(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_objects_gold(player_type *player_ptr, POSITION range)
+bool detect_objects_gold(PlayerType *player_ptr, POSITION range)
 {
     POSITION range2 = range;
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
@@ -211,7 +211,7 @@ bool detect_objects_gold(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_objects_normal(player_type *player_ptr, POSITION range)
+bool detect_objects_normal(PlayerType *player_ptr, POSITION range)
 {
     POSITION range2 = range;
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
@@ -266,7 +266,7 @@ bool detect_objects_normal(player_type *player_ptr, POSITION range)
  * It can probably be argued that this function is now too powerful.
  * </pre>
  */
-bool detect_objects_magic(player_type *player_ptr, POSITION range)
+bool detect_objects_magic(PlayerType *player_ptr, POSITION range)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -312,7 +312,7 @@ bool detect_objects_magic(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_monsters_normal(player_type *player_ptr, POSITION range)
+bool detect_monsters_normal(PlayerType *player_ptr, POSITION range)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -351,7 +351,7 @@ bool detect_monsters_normal(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_monsters_invis(player_type *player_ptr, POSITION range)
+bool detect_monsters_invis(PlayerType *player_ptr, POSITION range)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -396,7 +396,7 @@ bool detect_monsters_invis(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_monsters_evil(player_type *player_ptr, POSITION range)
+bool detect_monsters_evil(PlayerType *player_ptr, POSITION range)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -441,7 +441,7 @@ bool detect_monsters_evil(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_monsters_nonliving(player_type *player_ptr, POSITION range)
+bool detect_monsters_nonliving(PlayerType *player_ptr, POSITION range)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -481,7 +481,7 @@ bool detect_monsters_nonliving(player_type *player_ptr, POSITION range)
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_monsters_mind(player_type *player_ptr, POSITION range)
+bool detect_monsters_mind(PlayerType *player_ptr, POSITION range)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -524,7 +524,7 @@ bool detect_monsters_mind(player_type *player_ptr, POSITION range)
  * @param Match 対応シンボルの混じったモンスター文字列(複数指定化)
  * @return 効力があった場合TRUEを返す
  */
-bool detect_monsters_string(player_type *player_ptr, POSITION range, concptr Match)
+bool detect_monsters_string(PlayerType *player_ptr, POSITION range, concptr Match)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -569,7 +569,7 @@ bool detect_monsters_string(player_type *player_ptr, POSITION range, concptr Mat
  * @param match_flag 感知フラグ
  * @return 効力があった場合TRUEを返す
  */
-bool detect_monsters_xxx(player_type *player_ptr, POSITION range, uint32_t match_flag)
+bool detect_monsters_xxx(PlayerType *player_ptr, POSITION range, uint32_t match_flag)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -625,7 +625,7 @@ bool detect_monsters_xxx(player_type *player_ptr, POSITION range, uint32_t match
  * @param range 効果範囲
  * @return 効力があった場合TRUEを返す
  */
-bool detect_all(player_type *player_ptr, POSITION range)
+bool detect_all(PlayerType *player_ptr, POSITION range)
 {
     bool detect = false;
     if (detect_traps(player_ptr, range, true))
index 5e2d5eb..a0ee344 100644 (file)
@@ -2,19 +2,19 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool detect_traps(player_type *player_ptr, POSITION range, bool known);
-bool detect_doors(player_type* player_ptr, POSITION range);
-bool detect_stairs(player_type* player_ptr, POSITION range);
-bool detect_treasure(player_type* player_ptr, POSITION range);
-bool detect_objects_gold(player_type* player_ptr, POSITION range);
-bool detect_objects_normal(player_type* player_ptr, POSITION range);
-bool detect_objects_magic(player_type* player_ptr, POSITION range);
-bool detect_monsters_normal(player_type* player_ptr, POSITION range);
-bool detect_monsters_invis(player_type* player_ptr, POSITION range);
-bool detect_monsters_evil(player_type* player_ptr, POSITION range);
-bool detect_monsters_xxx(player_type* player_ptr, POSITION range, uint32_t match_flag);
-bool detect_monsters_string(player_type* player_ptr, POSITION range, concptr);
-bool detect_monsters_nonliving(player_type* player_ptr, POSITION range);
-bool detect_monsters_mind(player_type* player_ptr, POSITION range);
-bool detect_all(player_type* player_ptr, POSITION range);
+class PlayerType;
+bool detect_traps(PlayerType *player_ptr, POSITION range, bool known);
+bool detect_doors(PlayerType* player_ptr, POSITION range);
+bool detect_stairs(PlayerType* player_ptr, POSITION range);
+bool detect_treasure(PlayerType* player_ptr, POSITION range);
+bool detect_objects_gold(PlayerType* player_ptr, POSITION range);
+bool detect_objects_normal(PlayerType* player_ptr, POSITION range);
+bool detect_objects_magic(PlayerType* player_ptr, POSITION range);
+bool detect_monsters_normal(PlayerType* player_ptr, POSITION range);
+bool detect_monsters_invis(PlayerType* player_ptr, POSITION range);
+bool detect_monsters_evil(PlayerType* player_ptr, POSITION range);
+bool detect_monsters_xxx(PlayerType* player_ptr, POSITION range, uint32_t match_flag);
+bool detect_monsters_string(PlayerType* player_ptr, POSITION range, concptr);
+bool detect_monsters_nonliving(PlayerType* player_ptr, POSITION range);
+bool detect_monsters_mind(PlayerType* player_ptr, POSITION range);
+bool detect_all(PlayerType* player_ptr, POSITION range);
index d2f5788..249dcf4 100644 (file)
@@ -25,7 +25,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 生成が実際に試みられたらTRUEを返す
  */
-bool artifact_scroll(player_type *player_ptr)
+bool artifact_scroll(PlayerType *player_ptr)
 {
     concptr q = _("どのアイテムを強化しますか? ", "Enchant which item? ");
     concptr s = _("強化できるアイテムがない。", "You have nothing to enchant.");
@@ -118,7 +118,7 @@ bool artifact_scroll(player_type *player_ptr)
  * Returns TRUE if something was mundanified, else FALSE.
  * </pre>
  */
-bool mundane_spell(player_type *player_ptr, bool only_equip)
+bool mundane_spell(PlayerType *player_ptr, bool only_equip)
 {
     std::unique_ptr<ItemTester> item_tester = std::make_unique<AllMatchItemTester>();
     if (only_equip)
index 1a138be..209eca1 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-bool artifact_scroll(player_type *player_ptr);
-bool mundane_spell(player_type *player_ptr, bool only_equip);
+class PlayerType;
+bool artifact_scroll(PlayerType *player_ptr);
+bool mundane_spell(PlayerType *player_ptr, bool only_equip);
index 0d34e88..370d516 100644 (file)
@@ -20,7 +20,7 @@
  * @return 劣化処理に関するメッセージが発せられた場合はTRUEを返す /
  * Return "TRUE" if the player notices anything
  */
-bool apply_disenchant(player_type *player_ptr, BIT_FLAGS mode)
+bool apply_disenchant(PlayerType *player_ptr, BIT_FLAGS mode)
 {
     int t = 0;
     switch (randint1(8)) {
index 3e9428d..5595c30 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool apply_disenchant(player_type *player_ptr, BIT_FLAGS mode);
+class PlayerType;
+bool apply_disenchant(PlayerType *player_ptr, BIT_FLAGS mode);
index 3d49f61..42c0f82 100644 (file)
@@ -34,7 +34,7 @@
  * @param wgt 許容重量
  * @param require_los 射線の通りを要求するならばTRUE
  */
-void fetch_item(player_type *player_ptr, DIRECTION dir, WEIGHT wgt, bool require_los)
+void fetch_item(PlayerType *player_ptr, DIRECTION dir, WEIGHT wgt, bool require_los)
 {
     grid_type *g_ptr;
     object_type *o_ptr;
@@ -112,7 +112,7 @@ void fetch_item(player_type *player_ptr, DIRECTION dir, WEIGHT wgt, bool require
     player_ptr->redraw |= PR_MAP;
 }
 
-bool fetch_monster(player_type *player_ptr)
+bool fetch_monster(PlayerType *player_ptr)
 {
     monster_type *m_ptr;
     MONSTER_IDX m_idx;
index 422423e..58de752 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void fetch_item(player_type *player_ptr, DIRECTION dir, WEIGHT wgt, bool require_los);
-bool fetch_monster(player_type *player_ptr);
+class PlayerType;
+void fetch_item(PlayerType *player_ptr, DIRECTION dir, WEIGHT wgt, bool require_los);
+bool fetch_monster(PlayerType *player_ptr);
index 0e889f3..911008c 100644 (file)
@@ -59,7 +59,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param ninja 忍者かどうか
  */
-void wiz_lite(player_type *player_ptr, bool ninja)
+void wiz_lite(PlayerType *player_ptr, bool ninja)
 {
     /* Memorize objects */
     for (OBJECT_IDX i = 1; i < player_ptr->current_floor_ptr->o_max; i++) {
@@ -129,7 +129,7 @@ void wiz_lite(player_type *player_ptr, bool ninja)
 /*
  * Forget the dungeon map (ala "Thinking of Maud...").
  */
-void wiz_dark(player_type *player_ptr)
+void wiz_dark(PlayerType *player_ptr)
 {
     /* Forget every grid */
     for (POSITION y = 1; y < player_ptr->current_floor_ptr->height - 1; y++) {
@@ -180,7 +180,7 @@ void wiz_dark(player_type *player_ptr)
 /*
  * Hack -- map the current panel (plus some) ala "magic mapping"
  */
-void map_area(player_type *player_ptr, POSITION range)
+void map_area(PlayerType *player_ptr, POSITION range)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS))
         range /= 3;
@@ -244,7 +244,7 @@ void map_area(player_type *player_ptr, POSITION range)
  * "earthquake" by using the "full" to select "destruction".
  * </pre>
  */
-bool destroy_area(player_type *player_ptr, POSITION y1, POSITION x1, POSITION r, bool in_generate)
+bool destroy_area(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION r, bool in_generate)
 {
     /* Prevent destruction of quest levels and town */
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
index 3ab4eb1..1a65d9a 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void wiz_lite(player_type *player_ptr, bool ninja);
-void wiz_dark(player_type *player_ptr);
-void map_area(player_type *player_ptr, POSITION range);
-bool destroy_area(player_type *player_ptr, POSITION y1, POSITION x1, POSITION r, bool in_generate);
+class PlayerType;
+void wiz_lite(PlayerType *player_ptr, bool ninja);
+void wiz_dark(PlayerType *player_ptr);
+void map_area(PlayerType *player_ptr, POSITION range);
+bool destroy_area(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION r, bool in_generate);
index d554911..8e516c8 100644 (file)
@@ -39,7 +39,7 @@
  * @param spell_name 抹殺効果を起こした魔法の名前
  * @return 効力があった場合TRUEを返す
  */
-bool genocide_aux(player_type *player_ptr, MONSTER_IDX m_idx, int power, bool player_cast, int dam_side, concptr spell_name)
+bool genocide_aux(PlayerType *player_ptr, MONSTER_IDX m_idx, int power, bool player_cast, int dam_side, concptr spell_name)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
@@ -118,7 +118,7 @@ bool genocide_aux(player_type *player_ptr, MONSTER_IDX m_idx, int power, bool pl
  * @param player_cast プレイヤーの魔法によるものならば TRUE
  * @return 効力があった場合TRUEを返す
  */
-bool symbol_genocide(player_type *player_ptr, int power, bool player_cast)
+bool symbol_genocide(PlayerType *player_ptr, int power, bool player_cast)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     bool is_special_floor = floor_ptr->inside_quest && !random_quest_number(player_ptr, floor_ptr->dun_level);
@@ -158,7 +158,7 @@ bool symbol_genocide(player_type *player_ptr, int power, bool player_cast)
  * @param player_cast プレイヤーの魔法によるものならば TRUE
  * @return 効力があった場合TRUEを返す
  */
-bool mass_genocide(player_type *player_ptr, int power, bool player_cast)
+bool mass_genocide(PlayerType *player_ptr, int power, bool player_cast)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     bool is_special_floor = floor_ptr->inside_quest && !random_quest_number(player_ptr, floor_ptr->dun_level);
@@ -193,7 +193,7 @@ bool mass_genocide(player_type *player_ptr, int power, bool player_cast)
  * @param player_cast プレイヤーの魔法によるものならば TRUE
  * @return 効力があった場合TRUEを返す
  */
-bool mass_genocide_undead(player_type *player_ptr, int power, bool player_cast)
+bool mass_genocide_undead(PlayerType *player_ptr, int power, bool player_cast)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     bool is_special_floor = floor_ptr->inside_quest && !random_quest_number(player_ptr, floor_ptr->dun_level);
index 7d13c31..744b271 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool genocide_aux(player_type *player_ptr, MONSTER_IDX m_idx, int power, bool player_cast, int dam_side, concptr spell_name);
-bool symbol_genocide(player_type *player_ptr, int power, bool player_cast);
-bool mass_genocide(player_type *player_ptr, int power, bool player_cast);
-bool mass_genocide_undead(player_type *player_ptr, int power, bool player_cast);
+class PlayerType;
+bool genocide_aux(PlayerType *player_ptr, MONSTER_IDX m_idx, int power, bool player_cast, int dam_side, concptr spell_name);
+bool symbol_genocide(PlayerType *player_ptr, int power, bool player_cast);
+bool mass_genocide(PlayerType *player_ptr, int power, bool player_cast);
+bool mass_genocide_undead(PlayerType *player_ptr, int power, bool player_cast);
index ba26c55..9b268c9 100644 (file)
@@ -20,7 +20,7 @@
  * Leave a "rune of protection" which prevents monster movement
  * @return 実際に設置が行われた場合TRUEを返す
  */
-bool create_rune_protection_one(player_type *player_ptr)
+bool create_rune_protection_one(PlayerType *player_ptr)
 {
     if (!cave_clean_bold(player_ptr->current_floor_ptr, player_ptr->y, player_ptr->x)) {
         msg_print(_("床上のアイテムが呪文を跳ね返した。", "The object resists the spell."));
@@ -42,7 +42,7 @@ bool create_rune_protection_one(player_type *player_ptr)
  * @param x 設置場所
  * @return 実際に設置が行われた場合TRUEを返す
  */
-bool create_rune_explosion(player_type *player_ptr, POSITION y, POSITION x)
+bool create_rune_explosion(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!cave_clean_bold(floor_ptr, y, x)) {
@@ -61,7 +61,7 @@ bool create_rune_explosion(player_type *player_ptr, POSITION y, POSITION x)
  * @brief プレイヤーの手による能動的な階段生成処理 /
  * Create stairs at or move previously created stairs into the player location.
  */
-void stair_creation(player_type *player_ptr)
+void stair_creation(PlayerType *player_ptr)
 {
     bool up = true;
     if (ironman_downward)
index 5443b60..b3471a3 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool create_rune_protection_one(player_type *player_ptr);
-bool create_rune_explosion(player_type *player_ptr, POSITION y, POSITION x);
-void stair_creation(player_type *player_ptr);
+class PlayerType;
+bool create_rune_protection_one(PlayerType *player_ptr);
+bool create_rune_explosion(PlayerType *player_ptr, POSITION y, POSITION x);
+void stair_creation(PlayerType *player_ptr);
index 0da6f70..be71fc4 100644 (file)
@@ -20,7 +20,7 @@
  * Affect grids, objects, and monsters
  * </pre>
  */
-bool fire_ball(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad)
+bool fire_ball(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL;
     if (typ == AttributeType::CHARM_LIVING)
@@ -53,7 +53,7 @@ bool fire_ball(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_PO
  * Affect grids, objects, and monsters
  * </pre>
  */
-bool fire_breath(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad)
+bool fire_breath(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad)
 {
     return fire_ball(player_ptr, typ, dir, dam, -rad);
 }
@@ -73,7 +73,7 @@ bool fire_breath(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_
  * Affect grids, objects, and monsters
  * </pre>
  */
-bool fire_rocket(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad)
+bool fire_rocket(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad)
 {
     POSITION tx = player_ptr->x + 99 * ddx[dir];
     POSITION ty = player_ptr->y + 99 * ddy[dir];
@@ -101,7 +101,7 @@ bool fire_rocket(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_
  * Affect grids, objects, and monsters
  * </pre>
  */
-bool fire_ball_hide(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad)
+bool fire_ball_hide(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad)
 {
     POSITION tx = player_ptr->x + 99 * ddx[dir];
     POSITION ty = player_ptr->y + 99 * ddy[dir];
@@ -134,7 +134,7 @@ bool fire_ball_hide(player_type *player_ptr, AttributeType typ, DIRECTION dir, H
  * Option to hurt the player.
  * </pre>
  */
-bool fire_meteor(player_type *player_ptr, MONSTER_IDX who, AttributeType typ, POSITION y, POSITION x, HIT_POINT dam, POSITION rad)
+bool fire_meteor(PlayerType *player_ptr, MONSTER_IDX who, AttributeType typ, POSITION y, POSITION x, HIT_POINT dam, POSITION rad)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL;
     return project(player_ptr, who, rad, y, x, dam, typ, flg).notice;
@@ -151,7 +151,7 @@ bool fire_meteor(player_type *player_ptr, MONSTER_IDX who, AttributeType typ, PO
  * @param dev 回数分散
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool fire_blast(player_type *player_ptr, AttributeType typ, DIRECTION dir, DICE_NUMBER dd, DICE_SID ds, int num, int dev)
+bool fire_blast(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, DICE_NUMBER dd, DICE_SID ds, int num, int dev)
 {
     POSITION ty, tx, y, x;
     POSITION ly, lx;
@@ -201,7 +201,7 @@ bool fire_blast(player_type *player_ptr, AttributeType typ, DIRECTION dir, DICE_
  * Affect monsters and grids (not objects).
  * </pre>
  */
-bool fire_bolt(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam)
+bool fire_bolt(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_GRID;
     if (typ != AttributeType::ARROW)
@@ -222,7 +222,7 @@ bool fire_bolt(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_PO
  * Affect monsters, grids and objects.
  * </pre>
  */
-bool fire_beam(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam)
+bool fire_beam(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam)
 {
     BIT_FLAGS flg = PROJECT_BEAM | PROJECT_KILL | PROJECT_GRID | PROJECT_ITEM;
     return (project_hook(player_ptr, typ, dir, dam, flg));
@@ -242,7 +242,7 @@ bool fire_beam(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_PO
  * Affect monsters, grids and objects.
  * </pre>
  */
-bool fire_bolt_or_beam(player_type *player_ptr, PERCENTAGE prob, AttributeType typ, DIRECTION dir, HIT_POINT dam)
+bool fire_bolt_or_beam(PlayerType *player_ptr, PERCENTAGE prob, AttributeType typ, DIRECTION dir, HIT_POINT dam)
 {
     if (randint0(100) < prob) {
         return (fire_beam(player_ptr, typ, dir, dam));
@@ -260,7 +260,7 @@ bool fire_bolt_or_beam(player_type *player_ptr, PERCENTAGE prob, AttributeType t
  * @param flg フラグ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool project_hook(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, BIT_FLAGS flg)
+bool project_hook(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, BIT_FLAGS flg)
 {
     flg |= (PROJECT_THRU);
     POSITION tx = player_ptr->x + ddx[dir];
index bf73d3c..a488cfa 100644 (file)
@@ -3,14 +3,14 @@
 #include "system/angband.h"
 #include "effect/attribute-types.h"
 
-struct player_type;
-bool fire_ball(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad);
-bool fire_breath(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad);
-bool fire_rocket(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad);
-bool fire_ball_hide(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad);
-bool fire_meteor(player_type *player_ptr, MONSTER_IDX who, AttributeType typ, POSITION x, POSITION y, HIT_POINT dam, POSITION rad);
-bool fire_bolt(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam);
-bool fire_blast(player_type *player_ptr, AttributeType typ, DIRECTION dir, DICE_NUMBER dd, DICE_SID ds, int num, int dev);
-bool fire_beam(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam);
-bool fire_bolt_or_beam(player_type *player_ptr, PERCENTAGE prob, AttributeType typ, DIRECTION dir, HIT_POINT dam);
-bool project_hook(player_type *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, BIT_FLAGS flg);
+class PlayerType;
+bool fire_ball(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad);
+bool fire_breath(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad);
+bool fire_rocket(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad);
+bool fire_ball_hide(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, POSITION rad);
+bool fire_meteor(PlayerType *player_ptr, MONSTER_IDX who, AttributeType typ, POSITION x, POSITION y, HIT_POINT dam, POSITION rad);
+bool fire_bolt(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam);
+bool fire_blast(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, DICE_NUMBER dd, DICE_SID ds, int num, int dev);
+bool fire_beam(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam);
+bool fire_bolt_or_beam(PlayerType *player_ptr, PERCENTAGE prob, AttributeType typ, DIRECTION dir, HIT_POINT dam);
+bool project_hook(PlayerType *player_ptr, AttributeType typ, DIRECTION dir, HIT_POINT dam, BIT_FLAGS flg);
index 2f68bfe..ea70543 100644 (file)
@@ -51,7 +51,7 @@ using PassBoldFunc = bool (*)(floor_type *, POSITION, POSITION);
  * </pre>
  * @todo この辺、xとyが引数になっているが、player_ptr->xとplayer_ptr->yで全て置き換えが効くはず……
  */
-static void cave_temp_room_lite(player_type *player_ptr, const std::vector<Pos2D> &points)
+static void cave_temp_room_lite(PlayerType *player_ptr, const std::vector<Pos2D> &points)
 {
     for (const auto &point : points) {
         const POSITION y = point.y;
@@ -100,7 +100,7 @@ static void cave_temp_room_lite(player_type *player_ptr, const std::vector<Pos2D
  * </pre>
  * @todo この辺、xとyが引数になっているが、player_ptr->xとplayer_ptr->yで全て置き換えが効くはず……
  */
-static void cave_temp_room_unlite(player_type *player_ptr, const std::vector<Pos2D> &points)
+static void cave_temp_room_unlite(PlayerType *player_ptr, const std::vector<Pos2D> &points)
 {
     for (const auto &point : points) {
         const POSITION y = point.y;
@@ -209,7 +209,7 @@ static int next_to_walls_adj(floor_type *floor_ptr, const POSITION cy, const POS
  * @param pass_bold 地形条件を返す関数ポインタ
  */
 static void cave_temp_room_aux(
-    player_type *player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x, const bool only_room, const PassBoldFunc pass_bold)
+    PlayerType *player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x, const bool only_room, const PassBoldFunc pass_bold)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
@@ -252,7 +252,7 @@ static void cave_temp_room_aux(
  * @param y 指定Y座標
  * @param x 指定X座標
  */
-static void cave_temp_lite_room_aux(player_type *player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x)
+static void cave_temp_lite_room_aux(PlayerType *player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x)
 {
     cave_temp_room_aux(player_ptr, points, y, x, false, cave_los_bold);
 }
@@ -272,7 +272,7 @@ static bool cave_pass_dark_bold(floor_type *floor_ptr, POSITION y, POSITION x) {
  * @param y 指定Y座標
  * @param x 指定X座標
  */
-static void cave_temp_unlite_room_aux(player_type *player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x)
+static void cave_temp_unlite_room_aux(PlayerType *player_ptr, std::vector<Pos2D> &points, const POSITION y, const POSITION x)
 {
     cave_temp_room_aux(player_ptr, points, y, x, true, cave_pass_dark_bold);
 }
@@ -285,7 +285,7 @@ static void cave_temp_unlite_room_aux(player_type *player_ptr, std::vector<Pos2D
  *
  * NOTE: 部屋に限らないかも?
  */
-void lite_room(player_type *player_ptr, const POSITION y1, const POSITION x1)
+void lite_room(PlayerType *player_ptr, const POSITION y1, const POSITION x1)
 {
     // 明るくするマスを記録する配列。
     std::vector<Pos2D> points;
@@ -329,7 +329,7 @@ void lite_room(player_type *player_ptr, const POSITION y1, const POSITION x1)
  * @param y1 指定Y座標
  * @param x1 指定X座標
  */
-void unlite_room(player_type *player_ptr, const POSITION y1, const POSITION x1)
+void unlite_room(PlayerType *player_ptr, const POSITION y1, const POSITION x1)
 {
     // 暗くするマスを記録する配列。
     std::vector<Pos2D> points;
@@ -368,7 +368,7 @@ void unlite_room(player_type *player_ptr, const POSITION y1, const POSITION x1)
  * @param magic 魔法による効果であればTRUE、スターライトの杖による効果であればFALSE
  * @return 常にTRUE
  */
-bool starlight(player_type *player_ptr, bool magic)
+bool starlight(PlayerType *player_ptr, bool magic)
 {
     if (!player_ptr->blind && !magic) {
         msg_print(_("杖の先が明るく輝いた...", "The end of the staff glows brightly..."));
@@ -402,7 +402,7 @@ bool starlight(player_type *player_ptr, bool magic)
  * @param rad 効果半径
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool lite_area(player_type *player_ptr, HIT_POINT dam, POSITION rad)
+bool lite_area(PlayerType *player_ptr, HIT_POINT dam, POSITION rad)
 {
     if (d_info[player_ptr->dungeon_idx].flags.has(DungeonFeatureType::DARKNESS)) {
         msg_print(_("ダンジョンが光を吸収した。", "The darkness of this dungeon absorbs your light."));
@@ -428,7 +428,7 @@ bool lite_area(player_type *player_ptr, HIT_POINT dam, POSITION rad)
  * @param rad 効果半径
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool unlite_area(player_type *player_ptr, HIT_POINT dam, POSITION rad)
+bool unlite_area(PlayerType *player_ptr, HIT_POINT dam, POSITION rad)
 {
     if (!player_ptr->blind) {
         msg_print(_("暗闇が辺りを覆った。", "Darkness surrounds you."));
@@ -449,7 +449,7 @@ bool unlite_area(player_type *player_ptr, HIT_POINT dam, POSITION rad)
  * @param dam 威力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool lite_line(player_type *player_ptr, DIRECTION dir, HIT_POINT dam)
+bool lite_line(PlayerType *player_ptr, DIRECTION dir, HIT_POINT dam)
 {
     BIT_FLAGS flg = PROJECT_BEAM | PROJECT_GRID | PROJECT_KILL;
     return (project_hook(player_ptr, AttributeType::LITE_WEAK, dir, dam, flg));
index 09fdcc4..6748f63 100644 (file)
@@ -2,10 +2,10 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void lite_room(player_type *player_ptr, POSITION y1, POSITION x1);
-bool starlight(player_type *player_ptr, bool magic);
-void unlite_room(player_type *player_ptr, POSITION y1, POSITION x1);
-bool lite_area(player_type *player_ptr, HIT_POINT dam, POSITION rad);
-bool unlite_area(player_type *player_ptr, HIT_POINT dam, POSITION rad);
-bool lite_line(player_type *player_ptr, DIRECTION dir, HIT_POINT dam);
+class PlayerType;
+void lite_room(PlayerType *player_ptr, POSITION y1, POSITION x1);
+bool starlight(PlayerType *player_ptr, bool magic);
+void unlite_room(PlayerType *player_ptr, POSITION y1, POSITION x1);
+bool lite_area(PlayerType *player_ptr, HIT_POINT dam, POSITION rad);
+bool unlite_area(PlayerType *player_ptr, HIT_POINT dam, POSITION rad);
+bool lite_line(PlayerType *player_ptr, DIRECTION dir, HIT_POINT dam);
index 424df60..1a81249 100644 (file)
@@ -17,7 +17,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool door_creation(player_type *player_ptr, POSITION y, POSITION x)
+bool door_creation(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     BIT_FLAGS flg = PROJECT_GRID | PROJECT_ITEM | PROJECT_HIDE;
     return project(player_ptr, 0, 1, y, x, 0, AttributeType::MAKE_DOOR, flg).notice;
@@ -30,7 +30,7 @@ bool door_creation(player_type *player_ptr, POSITION y, POSITION x)
  * @param x 起点X座標
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool trap_creation(player_type *player_ptr, POSITION y, POSITION x)
+bool trap_creation(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     BIT_FLAGS flg = PROJECT_GRID | PROJECT_ITEM | PROJECT_HIDE;
     return project(player_ptr, 0, 1, y, x, 0, AttributeType::MAKE_TRAP, flg).notice;
@@ -41,7 +41,7 @@ bool trap_creation(player_type *player_ptr, POSITION y, POSITION x)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool tree_creation(player_type *player_ptr, POSITION y, POSITION x)
+bool tree_creation(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     BIT_FLAGS flg = PROJECT_GRID | PROJECT_ITEM | PROJECT_HIDE;
     return project(player_ptr, 0, 1, y, x, 0, AttributeType::MAKE_TREE, flg).notice;
@@ -52,7 +52,7 @@ bool tree_creation(player_type *player_ptr, POSITION y, POSITION x)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool create_rune_protection_area(player_type *player_ptr, POSITION y, POSITION x)
+bool create_rune_protection_area(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     BIT_FLAGS flg = PROJECT_GRID | PROJECT_ITEM;
     return project(player_ptr, 0, 1, y, x, 0, AttributeType::MAKE_RUNE_PROTECTION, flg).notice;
@@ -63,7 +63,7 @@ bool create_rune_protection_area(player_type *player_ptr, POSITION y, POSITION x
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool wall_stone(player_type *player_ptr)
+bool wall_stone(PlayerType *player_ptr)
 {
     BIT_FLAGS flg = PROJECT_GRID | PROJECT_ITEM | PROJECT_HIDE;
     bool dummy = project(player_ptr, 0, 1, player_ptr->y, player_ptr->x, 0, AttributeType::STONE_WALL, flg).notice;
@@ -77,7 +77,7 @@ bool wall_stone(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool destroy_doors_touch(player_type *player_ptr)
+bool destroy_doors_touch(PlayerType *player_ptr)
 {
     BIT_FLAGS flg = PROJECT_GRID | PROJECT_ITEM | PROJECT_HIDE;
     return project(player_ptr, 0, 1, player_ptr->y, player_ptr->x, 0, AttributeType::KILL_DOOR, flg).notice;
@@ -88,7 +88,7 @@ bool destroy_doors_touch(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool disarm_traps_touch(player_type *player_ptr)
+bool disarm_traps_touch(PlayerType *player_ptr)
 {
     BIT_FLAGS flg = PROJECT_GRID | PROJECT_ITEM | PROJECT_HIDE;
     return project(player_ptr, 0, 1, player_ptr->y, player_ptr->x, 0, AttributeType::KILL_TRAP, flg).notice;
@@ -99,7 +99,7 @@ bool disarm_traps_touch(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool sleep_monsters_touch(player_type *player_ptr)
+bool sleep_monsters_touch(PlayerType *player_ptr)
 {
     BIT_FLAGS flg = PROJECT_KILL | PROJECT_HIDE;
     return project(player_ptr, 0, 1, player_ptr->y, player_ptr->x, player_ptr->lev, AttributeType::OLD_SLEEP, flg).notice;
@@ -113,7 +113,7 @@ bool sleep_monsters_touch(player_type *player_ptr)
  * @param x 起点X座標
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool animate_dead(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x)
+bool animate_dead(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x)
 {
     BIT_FLAGS flg = PROJECT_ITEM | PROJECT_HIDE;
     return project(player_ptr, who, 5, y, x, 0, AttributeType::ANIM_DEAD, flg).notice;
@@ -123,7 +123,7 @@ bool animate_dead(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION
  * @brief 周辺破壊効果(プレイヤー中心)
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void wall_breaker(player_type *player_ptr)
+void wall_breaker(PlayerType *player_ptr)
 {
     POSITION y = 0, x = 0;
     int attempts = 1000;
index 7ab5a14..4db70ac 100644 (file)
@@ -2,14 +2,14 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool door_creation(player_type *player_ptr, POSITION y, POSITION x);
-bool trap_creation(player_type *player_ptr, POSITION y, POSITION x);
-bool tree_creation(player_type *player_ptr, POSITION y, POSITION x);
-bool create_rune_protection_area(player_type *player_ptr, POSITION y, POSITION x);
-bool wall_stone(player_type *player_ptr);
-bool destroy_doors_touch(player_type *player_ptr);
-bool disarm_traps_touch(player_type *player_ptr);
-bool sleep_monsters_touch(player_type *player_ptr);
-bool animate_dead(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x);
-void wall_breaker(player_type *player_ptr);
+class PlayerType;
+bool door_creation(PlayerType *player_ptr, POSITION y, POSITION x);
+bool trap_creation(PlayerType *player_ptr, POSITION y, POSITION x);
+bool tree_creation(PlayerType *player_ptr, POSITION y, POSITION x);
+bool create_rune_protection_area(PlayerType *player_ptr, POSITION y, POSITION x);
+bool wall_stone(PlayerType *player_ptr);
+bool destroy_doors_touch(PlayerType *player_ptr);
+bool disarm_traps_touch(PlayerType *player_ptr);
+bool sleep_monsters_touch(PlayerType *player_ptr);
+bool animate_dead(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x);
+void wall_breaker(PlayerType *player_ptr);
index 43f08a7..f15ae33 100644 (file)
@@ -36,7 +36,7 @@
  * Done by a potion of "self knowledge".
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void identify_pack(player_type *player_ptr)
+void identify_pack(PlayerType *player_ptr)
 {
     for (INVENTORY_IDX i = 0; i < INVEN_TOTAL; i++) {
         object_type *o_ptr = &player_ptr->inventory_list[i];
@@ -55,7 +55,7 @@ void identify_pack(player_type *player_ptr)
  * @param o_ptr 鑑定されるアイテムの情報参照ポインタ
  * @return 実際に鑑定できたらTRUEを返す
  */
-bool identify_item(player_type *player_ptr, object_type *o_ptr)
+bool identify_item(PlayerType *player_ptr, object_type *o_ptr)
 {
     GAME_TEXT o_name[MAX_NLEN];
     describe_flavor(player_ptr, o_name, o_ptr, 0);
@@ -99,7 +99,7 @@ bool identify_item(player_type *player_ptr, object_type *o_ptr)
  * This routine does *not* automatically combine objects.
  * Returns TRUE if something was identified, else FALSE.
  */
-bool ident_spell(player_type *player_ptr, bool only_equip)
+bool ident_spell(PlayerType *player_ptr, bool only_equip)
 {
     std::unique_ptr<ItemTester> item_tester = std::make_unique<FuncItemTester>(only_equip ? object_is_not_identified_weapon_armor : object_is_not_identified);
 
@@ -148,7 +148,7 @@ bool ident_spell(player_type *player_ptr, bool only_equip)
  * Fully "identify" an object in the inventory -BEN-
  * This routine returns TRUE if an item was identified.
  */
-bool identify_fully(player_type *player_ptr, bool only_equip)
+bool identify_fully(PlayerType *player_ptr, bool only_equip)
 {
     std::unique_ptr<ItemTester> item_tester
         = std::make_unique<FuncItemTester>(only_equip ? object_is_not_fully_identified_weapon_armour : object_is_not_fully_identified);
index 211f678..88c7ba9 100644 (file)
@@ -3,8 +3,8 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-void identify_pack(player_type *player_ptr);
-bool identify_item(player_type *player_ptr, object_type *o_ptr);
-bool ident_spell(player_type *player_ptr, bool only_equip);
-bool identify_fully(player_type *player_ptr, bool only_equip);
+class PlayerType;
+void identify_pack(PlayerType *player_ptr);
+bool identify_item(PlayerType *player_ptr, object_type *o_ptr);
+bool ident_spell(PlayerType *player_ptr, bool only_equip);
+bool identify_fully(PlayerType *player_ptr, bool only_equip);
index ced1209..29d3229 100644 (file)
@@ -21,7 +21,7 @@
 /*!
  * @brief ペット爆破処理 /
  */
-void discharge_minion(player_type *player_ptr)
+void discharge_minion(PlayerType *player_ptr)
 {
     bool okay = true;
     for (MONSTER_IDX i = 1; i < player_ptr->current_floor_ptr->m_max; i++) {
index d3be69d..4c3cfc6 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void discharge_minion(player_type *player_ptr);
+class PlayerType;
+void discharge_minion(PlayerType *player_ptr);
index 9e117c4..dd7cdd4 100644 (file)
@@ -28,7 +28,7 @@
  * @details
  * Note that this function is one of the more "dangerous" ones...
  */
-static MONRACE_IDX poly_r_idx(player_type *player_ptr, MONRACE_IDX r_idx)
+static MONRACE_IDX poly_r_idx(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     monster_race *r_ptr = &r_info[r_idx];
     if ((r_ptr->flags1 & RF1_UNIQUE) || (r_ptr->flags1 & RF1_QUESTOR))
@@ -63,7 +63,7 @@ static MONRACE_IDX poly_r_idx(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param x 指定のX座標
  * @return 実際に変身したらTRUEを返す
  */
-bool polymorph_monster(player_type *player_ptr, POSITION y, POSITION x)
+bool polymorph_monster(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
index e4e047d..0d457ba 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool polymorph_monster(player_type *player_ptr, POSITION y, POSITION x);
+class PlayerType;
+bool polymorph_monster(PlayerType *player_ptr, POSITION y, POSITION x);
index 522e342..466681a 100644 (file)
@@ -40,7 +40,7 @@
  * @brief 混沌招来処理
  * @return 作用が実際にあった場合TRUEを返す
  */
-void call_chaos(player_type *player_ptr)
+void call_chaos(PlayerType *player_ptr)
 {
     AttributeType hurt_types[31] = { AttributeType::ELEC, AttributeType::POIS, AttributeType::ACID, AttributeType::COLD, AttributeType::FIRE, 
         AttributeType::MISSILE, AttributeType::ARROW, AttributeType::PLASMA, AttributeType::HOLY_FIRE, AttributeType::WATER, AttributeType::LITE, 
@@ -93,7 +93,7 @@ void call_chaos(player_type *player_ptr)
  * or the player gets paralyzed.
  * </pre>
  */
-bool activate_ty_curse(player_type *player_ptr, bool stop_ty, int *count)
+bool activate_ty_curse(PlayerType *player_ptr, bool stop_ty, int *count)
 {
     BIT_FLAGS flg = (PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL | PROJECT_JUMP);
     bool is_first_curse = true;
@@ -236,7 +236,7 @@ bool activate_ty_curse(player_type *player_ptr, bool stop_ty, int *count)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param spell ランダムな効果を選択するための基準ID
  */
-void wild_magic(player_type *player_ptr, int spell)
+void wild_magic(PlayerType *player_ptr, int spell)
 {
     int type = SUMMON_MOLD + randint0(6);
     if (type < SUMMON_MOLD)
@@ -347,7 +347,7 @@ void wild_magic(player_type *player_ptr, int spell)
  * while keeping the results quite random.  It also allows some potent\n
  * effects only at high level.
  */
-void cast_wonder(player_type *player_ptr, DIRECTION dir)
+void cast_wonder(PlayerType *player_ptr, DIRECTION dir)
 {
     PLAYER_LEVEL plev = player_ptr->lev;
     int die = randint1(100) + plev / 5;
index 3df73e2..fc23170 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void wild_magic(player_type *player_ptr, int spell);
-void call_chaos(player_type *player_ptr);
-bool activate_ty_curse(player_type *player_ptr, bool stop_ty, int *count);
-void cast_wonder(player_type *player_ptr, DIRECTION dir);
+class PlayerType;
+void wild_magic(PlayerType *player_ptr, int spell);
+void call_chaos(PlayerType *player_ptr);
+bool activate_ty_curse(PlayerType *player_ptr, bool stop_ty, int *count);
+void cast_wonder(PlayerType *player_ptr, DIRECTION dir);
index 39bdd19..f6dc640 100644 (file)
@@ -44,7 +44,7 @@
  * this is done in two passes. -- JDL
  * </pre>
  */
-bool project_all_los(player_type *player_ptr, AttributeType typ, HIT_POINT dam)
+bool project_all_los(PlayerType *player_ptr, AttributeType typ, HIT_POINT dam)
 {
     for (MONSTER_IDX i = 1; i < player_ptr->current_floor_ptr->m_max; i++) {
         monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[i];
@@ -82,7 +82,7 @@ bool project_all_los(player_type *player_ptr, AttributeType typ, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool speed_monsters(player_type *player_ptr)
+bool speed_monsters(PlayerType *player_ptr)
 {
     return (project_all_los(player_ptr, AttributeType::OLD_SPEED, player_ptr->lev));
 }
@@ -92,7 +92,7 @@ bool speed_monsters(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool slow_monsters(player_type *player_ptr, int power)
+bool slow_monsters(PlayerType *player_ptr, int power)
 {
     return (project_all_los(player_ptr, AttributeType::OLD_SLOW, power));
 }
@@ -102,7 +102,7 @@ bool slow_monsters(player_type *player_ptr, int power)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool sleep_monsters(player_type *player_ptr, int power)
+bool sleep_monsters(PlayerType *player_ptr, int power)
 {
     return (project_all_los(player_ptr, AttributeType::OLD_SLEEP, power));
 }
@@ -112,7 +112,7 @@ bool sleep_monsters(player_type *player_ptr, int power)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool banish_evil(player_type *player_ptr, int dist)
+bool banish_evil(PlayerType *player_ptr, int dist)
 {
     return (project_all_los(player_ptr, AttributeType::AWAY_EVIL, dist));
 }
@@ -121,7 +121,7 @@ bool banish_evil(player_type *player_ptr, int dist)
  * @brief 視界内のアンデッド・モンスターを恐怖させる処理 / Turn undead
  * @return 効力があった場合TRUEを返す
  */
-bool turn_undead(player_type *player_ptr)
+bool turn_undead(PlayerType *player_ptr)
 {
     bool tester = (project_all_los(player_ptr, AttributeType::TURN_UNDEAD, player_ptr->lev));
     if (tester)
@@ -134,7 +134,7 @@ bool turn_undead(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool dispel_undead(player_type *player_ptr, HIT_POINT dam)
+bool dispel_undead(PlayerType *player_ptr, HIT_POINT dam)
 {
     bool tester = (project_all_los(player_ptr, AttributeType::DISP_UNDEAD, dam));
     if (tester)
@@ -147,7 +147,7 @@ bool dispel_undead(player_type *player_ptr, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool dispel_evil(player_type *player_ptr, HIT_POINT dam)
+bool dispel_evil(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::DISP_EVIL, dam));
 }
@@ -157,7 +157,7 @@ bool dispel_evil(player_type *player_ptr, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool dispel_good(player_type *player_ptr, HIT_POINT dam)
+bool dispel_good(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::DISP_GOOD, dam));
 }
@@ -167,7 +167,7 @@ bool dispel_good(player_type *player_ptr, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool dispel_monsters(player_type *player_ptr, HIT_POINT dam)
+bool dispel_monsters(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::DISP_ALL, dam));
 }
@@ -177,7 +177,7 @@ bool dispel_monsters(player_type *player_ptr, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool dispel_living(player_type *player_ptr, HIT_POINT dam)
+bool dispel_living(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::DISP_LIVING, dam));
 }
@@ -187,7 +187,7 @@ bool dispel_living(player_type *player_ptr, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool dispel_demons(player_type *player_ptr, HIT_POINT dam)
+bool dispel_demons(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::DISP_DEMON, dam));
 }
@@ -197,7 +197,7 @@ bool dispel_demons(player_type *player_ptr, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 効力があった場合TRUEを返す
  */
-bool crusade(player_type *player_ptr)
+bool crusade(PlayerType *player_ptr)
 {
     return (project_all_los(player_ptr, AttributeType::CRUSADE, player_ptr->lev * 4));
 }
@@ -207,7 +207,7 @@ bool crusade(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param who 怒らせる原因を起こしたモンスター(0ならばプレイヤー)
  */
-void aggravate_monsters(player_type *player_ptr, MONSTER_IDX who)
+void aggravate_monsters(PlayerType *player_ptr, MONSTER_IDX who)
 {
     bool sleep = false;
     bool speed = false;
@@ -250,7 +250,7 @@ void aggravate_monsters(player_type *player_ptr, MONSTER_IDX who)
  * @param dam 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool confuse_monsters(player_type *player_ptr, HIT_POINT dam)
+bool confuse_monsters(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::OLD_CONF, dam));
 }
@@ -261,7 +261,7 @@ bool confuse_monsters(player_type *player_ptr, HIT_POINT dam)
  * @param dam 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool charm_monsters(player_type *player_ptr, HIT_POINT dam)
+bool charm_monsters(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::CHARM, dam));
 }
@@ -272,7 +272,7 @@ bool charm_monsters(player_type *player_ptr, HIT_POINT dam)
  * @param dam 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool charm_animals(player_type *player_ptr, HIT_POINT dam)
+bool charm_animals(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::CONTROL_ANIMAL, dam));
 }
@@ -283,7 +283,7 @@ bool charm_animals(player_type *player_ptr, HIT_POINT dam)
  * @param dam 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool stun_monsters(player_type *player_ptr, HIT_POINT dam)
+bool stun_monsters(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::STUN, dam));
 }
@@ -294,7 +294,7 @@ bool stun_monsters(player_type *player_ptr, HIT_POINT dam)
  * @param dam 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool stasis_monsters(player_type *player_ptr, HIT_POINT dam)
+bool stasis_monsters(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::STASIS, dam));
 }
@@ -305,7 +305,7 @@ bool stasis_monsters(player_type *player_ptr, HIT_POINT dam)
  * @param dam 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool mindblast_monsters(player_type *player_ptr, HIT_POINT dam)
+bool mindblast_monsters(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::PSI, dam));
 }
@@ -316,7 +316,7 @@ bool mindblast_monsters(player_type *player_ptr, HIT_POINT dam)
  * @param dist 効力(距離)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool banish_monsters(player_type *player_ptr, int dist)
+bool banish_monsters(PlayerType *player_ptr, int dist)
 {
     return (project_all_los(player_ptr, AttributeType::AWAY_ALL, dist));
 }
@@ -327,7 +327,7 @@ bool banish_monsters(player_type *player_ptr, int dist)
  * @param dam 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool turn_evil(player_type *player_ptr, HIT_POINT dam)
+bool turn_evil(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::TURN_EVIL, dam));
 }
@@ -338,7 +338,7 @@ bool turn_evil(player_type *player_ptr, HIT_POINT dam)
  * @param dam 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool turn_monsters(player_type *player_ptr, HIT_POINT dam)
+bool turn_monsters(PlayerType *player_ptr, HIT_POINT dam)
 {
     return (project_all_los(player_ptr, AttributeType::TURN_ALL, dam));
 }
@@ -348,7 +348,7 @@ bool turn_monsters(player_type *player_ptr, HIT_POINT dam)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool deathray_monsters(player_type *player_ptr)
+bool deathray_monsters(PlayerType *player_ptr)
 {
     return (project_all_los(player_ptr, AttributeType::DEATH_RAY, player_ptr->lev * 200));
 }
@@ -359,7 +359,7 @@ bool deathray_monsters(player_type *player_ptr)
  * @param m_ptr モンスター情報への参照ポインタ
  * @param r_ptr モンスター種族への参照ポインタ
  */
-void probed_monster_info(char *buf, player_type *player_ptr, monster_type *m_ptr, monster_race *r_ptr)
+void probed_monster_info(char *buf, PlayerType *player_ptr, monster_type *m_ptr, monster_race *r_ptr)
 {
     if (!is_original_ap(m_ptr)) {
         if (m_ptr->mflag2.has(MonsterConstantFlagType::KAGE))
@@ -422,7 +422,7 @@ void probed_monster_info(char *buf, player_type *player_ptr, monster_type *m_ptr
  * @brief 周辺モンスターを調査する / Probe nearby monsters
  * @return 効力があった場合TRUEを返す
  */
-bool probing(player_type *player_ptr)
+bool probing(PlayerType *player_ptr)
 {
     bool cu = Term->scr->cu;
     bool cv = Term->scr->cv;
index 5f55e05..2415f95 100644 (file)
@@ -5,30 +5,30 @@
 
 struct monster_race;
 struct monster_type;
-struct player_type;
-bool project_all_los(player_type *player_ptr, AttributeType typ, HIT_POINT dam);
-bool speed_monsters(player_type *player_ptr);
-bool slow_monsters(player_type *player_ptr, int power);
-bool sleep_monsters(player_type *player_ptr, int power);
-void aggravate_monsters(player_type *player_ptr, MONSTER_IDX who);
-bool banish_evil(player_type *player_ptr, int dist);
-bool turn_undead(player_type *player_ptr);
-bool dispel_evil(player_type *player_ptr, HIT_POINT dam);
-bool dispel_good(player_type *player_ptr, HIT_POINT dam);
-bool dispel_undead(player_type *player_ptr, HIT_POINT dam);
-bool dispel_monsters(player_type *player_ptr, HIT_POINT dam);
-bool dispel_living(player_type *player_ptr, HIT_POINT dam);
-bool dispel_demons(player_type *player_ptr, HIT_POINT dam);
-bool crusade(player_type *player_ptr);
-bool confuse_monsters(player_type *player_ptr, HIT_POINT dam);
-bool charm_monsters(player_type *player_ptr, HIT_POINT dam);
-bool charm_animals(player_type *player_ptr, HIT_POINT dam);
-bool stun_monsters(player_type *player_ptr, HIT_POINT dam);
-bool stasis_monsters(player_type *player_ptr, HIT_POINT dam);
-bool mindblast_monsters(player_type *player_ptr, HIT_POINT dam);
-bool banish_monsters(player_type *player_ptr, int dist);
-bool turn_evil(player_type *player_ptr, HIT_POINT dam);
-bool turn_monsters(player_type *player_ptr, HIT_POINT dam);
-bool deathray_monsters(player_type *player_ptr);
-void probed_monster_info(char *buf, player_type *player_ptr, monster_type *m_ptr, monster_race *r_ptr);
-bool probing(player_type *player_ptr);
+class PlayerType;
+bool project_all_los(PlayerType *player_ptr, AttributeType typ, HIT_POINT dam);
+bool speed_monsters(PlayerType *player_ptr);
+bool slow_monsters(PlayerType *player_ptr, int power);
+bool sleep_monsters(PlayerType *player_ptr, int power);
+void aggravate_monsters(PlayerType *player_ptr, MONSTER_IDX who);
+bool banish_evil(PlayerType *player_ptr, int dist);
+bool turn_undead(PlayerType *player_ptr);
+bool dispel_evil(PlayerType *player_ptr, HIT_POINT dam);
+bool dispel_good(PlayerType *player_ptr, HIT_POINT dam);
+bool dispel_undead(PlayerType *player_ptr, HIT_POINT dam);
+bool dispel_monsters(PlayerType *player_ptr, HIT_POINT dam);
+bool dispel_living(PlayerType *player_ptr, HIT_POINT dam);
+bool dispel_demons(PlayerType *player_ptr, HIT_POINT dam);
+bool crusade(PlayerType *player_ptr);
+bool confuse_monsters(PlayerType *player_ptr, HIT_POINT dam);
+bool charm_monsters(PlayerType *player_ptr, HIT_POINT dam);
+bool charm_animals(PlayerType *player_ptr, HIT_POINT dam);
+bool stun_monsters(PlayerType *player_ptr, HIT_POINT dam);
+bool stasis_monsters(PlayerType *player_ptr, HIT_POINT dam);
+bool mindblast_monsters(PlayerType *player_ptr, HIT_POINT dam);
+bool banish_monsters(PlayerType *player_ptr, int dist);
+bool turn_evil(PlayerType *player_ptr, HIT_POINT dam);
+bool turn_monsters(PlayerType *player_ptr, HIT_POINT dam);
+bool deathray_monsters(PlayerType *player_ptr);
+void probed_monster_info(char *buf, PlayerType *player_ptr, monster_type *m_ptr, monster_race *r_ptr);
+bool probing(PlayerType *player_ptr);
index 8bcc89b..0bda0c4 100644 (file)
@@ -11,7 +11,7 @@
  * @param dam 威力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool hypodynamic_bolt(player_type *player_ptr, DIRECTION dir, HIT_POINT dam)
+bool hypodynamic_bolt(PlayerType *player_ptr, DIRECTION dir, HIT_POINT dam)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::HYPODYNAMIA, dir, dam, flg));
@@ -24,7 +24,7 @@ bool hypodynamic_bolt(player_type *player_ptr, DIRECTION dir, HIT_POINT dam)
  * @param plev プレイヤーレベル(効力はplev*200)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool death_ray(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
+bool death_ray(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::DEATH_RAY, dir, plev * 200, flg));
index f55756b..11bcf69 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool hypodynamic_bolt(player_type *player_ptr, DIRECTION dir, HIT_POINT dam);
-bool death_ray(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
+class PlayerType;
+bool hypodynamic_bolt(PlayerType *player_ptr, DIRECTION dir, HIT_POINT dam);
+bool death_ray(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
index 1ac6ddf..73e9259 100644 (file)
@@ -51,7 +51,7 @@
  * @param dir 方向(5ならばグローバル変数 target_col/target_row の座標を目標にする)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool teleport_swap(player_type *player_ptr, DIRECTION dir)
+bool teleport_swap(PlayerType *player_ptr, DIRECTION dir)
 {
     POSITION tx, ty;
     if ((dir == 5) && target_okay(player_ptr)) {
@@ -105,7 +105,7 @@ bool teleport_swap(player_type *player_ptr, DIRECTION dir)
  * @param distance 移動距離
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool teleport_monster(player_type *player_ptr, DIRECTION dir, int distance)
+bool teleport_monster(PlayerType *player_ptr, DIRECTION dir, int distance)
 {
     BIT_FLAGS flg = PROJECT_BEAM | PROJECT_KILL;
     return (project_hook(player_ptr, AttributeType::AWAY_ALL, dir, distance, flg));
@@ -123,7 +123,7 @@ bool teleport_monster(player_type *player_ptr, DIRECTION dir, int distance)
  * Attempt to move the monster at least "dis/2" grids away.
  * But allow variation to prevent infinite loops.
  */
-bool teleport_away(player_type *player_ptr, MONSTER_IDX m_idx, POSITION dis, teleport_flags mode)
+bool teleport_away(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION dis, teleport_flags mode)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     if (!monster_is_valid(m_ptr))
@@ -200,7 +200,7 @@ bool teleport_away(player_type *player_ptr, MONSTER_IDX m_idx, POSITION dis, tel
  * @param power テレポート成功確率
  * @param mode オプション
  */
-void teleport_monster_to(player_type *player_ptr, MONSTER_IDX m_idx, POSITION ty, POSITION tx, int power, teleport_flags mode)
+void teleport_monster_to(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION ty, POSITION tx, int power, teleport_flags mode)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     if (!m_ptr->r_idx)
@@ -285,7 +285,7 @@ void teleport_monster_to(player_type *player_ptr, MONSTER_IDX m_idx, POSITION ty
  * of candidates has equal possibility to be choosen as a destination.
  * </pre>
  */
-bool teleport_player_aux(player_type *player_ptr, POSITION dis, bool is_quantum_effect, teleport_flags mode)
+bool teleport_player_aux(PlayerType *player_ptr, POSITION dis, bool is_quantum_effect, teleport_flags mode)
 {
     if (player_ptr->wild_mode)
         return false;
@@ -373,7 +373,7 @@ bool teleport_player_aux(player_type *player_ptr, POSITION dis, bool is_quantum_
  * @param dis 基本移動距離
  * @param mode オプション
  */
-void teleport_player(player_type *player_ptr, POSITION dis, BIT_FLAGS mode)
+void teleport_player(PlayerType *player_ptr, POSITION dis, BIT_FLAGS mode)
 {
     const POSITION oy = player_ptr->y;
     const POSITION ox = player_ptr->x;
@@ -407,7 +407,7 @@ void teleport_player(player_type *player_ptr, POSITION dis, BIT_FLAGS mode)
  * @param dis テレポート距離
  * @param is_quantum_effect 量子的効果によるテレポートアウェイならばTRUE
  */
-void teleport_player_away(MONSTER_IDX m_idx, player_type *player_ptr, POSITION dis, bool is_quantum_effect)
+void teleport_player_away(MONSTER_IDX m_idx, PlayerType *player_ptr, POSITION dis, bool is_quantum_effect)
 {
     if (player_ptr->phase_out)
         return;
@@ -455,7 +455,7 @@ void teleport_player_away(MONSTER_IDX m_idx, player_type *player_ptr, POSITION d
  * This function allows teleporting into vaults (!)
  * </pre>
  */
-void teleport_player_to(player_type *player_ptr, POSITION ny, POSITION nx, teleport_flags mode)
+void teleport_player_to(PlayerType *player_ptr, POSITION ny, POSITION nx, teleport_flags mode)
 {
     if (player_ptr->anti_tele && !(mode & TELEPORT_NONMAGICAL)) {
         msg_print(_("不思議な力がテレポートを防いだ!", "A mysterious force prevents you from teleporting!"));
@@ -493,7 +493,7 @@ void teleport_player_to(player_type *player_ptr, POSITION ny, POSITION nx, telep
     (void)move_player_effect(player_ptr, y, x, MPE_FORGET_FLOW | MPE_HANDLE_STUFF | MPE_DONT_PICKUP);
 }
 
-void teleport_away_followable(player_type *player_ptr, MONSTER_IDX m_idx)
+void teleport_away_followable(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[m_idx];
     POSITION oldfy = m_ptr->fy;
@@ -553,7 +553,7 @@ void teleport_away_followable(player_type *player_ptr, MONSTER_IDX m_idx)
  * @param y テレポート先のY座標
  * @return 目標に指定通りテレポートできたならばTRUEを返す
  */
-bool exe_dimension_door(player_type *player_ptr, POSITION x, POSITION y)
+bool exe_dimension_door(PlayerType *player_ptr, POSITION x, POSITION y)
 {
     PLAYER_LEVEL plev = player_ptr->lev;
 
@@ -576,7 +576,7 @@ bool exe_dimension_door(player_type *player_ptr, POSITION x, POSITION y)
  * Dimension Door
  * @return ターンを消費した場合TRUEを返す
  */
-bool dimension_door(player_type *player_ptr)
+bool dimension_door(PlayerType *player_ptr)
 {
     DEPTH x = 0, y = 0;
     if (!tgt_pt(player_ptr, &x, &y))
index c226ecf..7cee38c 100644 (file)
@@ -3,15 +3,15 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-bool teleport_monster(player_type *player_ptr, DIRECTION dir, int distance);
-bool teleport_swap(player_type *player_ptr, DIRECTION dir);
-bool teleport_away(player_type *player_ptr, MONSTER_IDX m_idx, POSITION dis, teleport_flags mode);
-void teleport_monster_to(player_type *player_ptr, MONSTER_IDX m_idx, POSITION ty, POSITION tx, int power, teleport_flags mode);
-bool teleport_player_aux(player_type *player_ptr, POSITION dis, bool is_quantum_effect, teleport_flags mode);
-void teleport_player(player_type *player_ptr, POSITION dis, BIT_FLAGS mode);
-void teleport_player_away(MONSTER_IDX m_idx, player_type *player_ptr, POSITION dis, bool is_quantum_effect);
-void teleport_player_to(player_type *player_ptr, POSITION ny, POSITION nx, teleport_flags mode);
-void teleport_away_followable(player_type *player_ptr, MONSTER_IDX m_idx);
-bool dimension_door(player_type *player_ptr);
-bool exe_dimension_door(player_type *player_ptr, POSITION x, POSITION y);
+class PlayerType;
+bool teleport_monster(PlayerType *player_ptr, DIRECTION dir, int distance);
+bool teleport_swap(PlayerType *player_ptr, DIRECTION dir);
+bool teleport_away(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION dis, teleport_flags mode);
+void teleport_monster_to(PlayerType *player_ptr, MONSTER_IDX m_idx, POSITION ty, POSITION tx, int power, teleport_flags mode);
+bool teleport_player_aux(PlayerType *player_ptr, POSITION dis, bool is_quantum_effect, teleport_flags mode);
+void teleport_player(PlayerType *player_ptr, POSITION dis, BIT_FLAGS mode);
+void teleport_player_away(MONSTER_IDX m_idx, PlayerType *player_ptr, POSITION dis, bool is_quantum_effect);
+void teleport_player_to(PlayerType *player_ptr, POSITION ny, POSITION nx, teleport_flags mode);
+void teleport_away_followable(PlayerType *player_ptr, MONSTER_IDX m_idx);
+bool dimension_door(PlayerType *player_ptr);
+bool exe_dimension_door(PlayerType *player_ptr, POSITION x, POSITION y);
index 435a575..dc98529 100644 (file)
@@ -47,7 +47,7 @@
  * @param idx テレポート・レベル対象のモンスター
  * @todo 変数名が実態と合っているかどうかは要確認
  */
-bool is_teleport_level_ineffective(player_type *player_ptr, MONSTER_IDX idx)
+bool is_teleport_level_ineffective(PlayerType *player_ptr, MONSTER_IDX idx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     bool is_special_floor
@@ -66,7 +66,7 @@ bool is_teleport_level_ineffective(player_type *player_ptr, MONSTER_IDX idx)
  * @param m_idx テレポートの対象となるモンスターID(0ならばプレイヤー) / If m_idx <= 0, target is player.
  * @todo cmd-save.h への依存あり。コールバックで何とかしたい
  */
-void teleport_level(player_type *player_ptr, MONSTER_IDX m_idx)
+void teleport_level(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     GAME_TEXT m_name[160];
     bool see_m = true;
@@ -213,7 +213,7 @@ void teleport_level(player_type *player_ptr, MONSTER_IDX m_idx)
         sound(SOUND_TPLEVEL);
 }
 
-bool teleport_level_other(player_type *player_ptr)
+bool teleport_level_other(PlayerType *player_ptr)
 {
     if (!target_set(player_ptr, TARGET_KILL))
         return false;
@@ -248,7 +248,7 @@ bool teleport_level_other(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return テレポート処理を決定したか否か
  */
-bool tele_town(player_type *player_ptr)
+bool tele_town(PlayerType *player_ptr)
 {
     if (player_ptr->current_floor_ptr->dun_level) {
         msg_print(_("この魔法は地上でしか使えない!", "This spell can only be used on the surface!"));
@@ -320,7 +320,7 @@ bool tele_town(player_type *player_ptr)
  * @brief 現実変容処理
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void reserve_alter_reality(player_type *player_ptr, TIME_EFFECT turns)
+void reserve_alter_reality(PlayerType *player_ptr, TIME_EFFECT turns)
 {
     if (player_ptr->current_floor_ptr->inside_arena || ironman_downward) {
         msg_print(_("何も起こらなかった。", "Nothing happens."));
@@ -346,7 +346,7 @@ void reserve_alter_reality(player_type *player_ptr, TIME_EFFECT turns)
  * @param turns 発動までのターン数
  * @return 常にTRUEを返す
  */
-bool recall_player(player_type *player_ptr, TIME_EFFECT turns)
+bool recall_player(PlayerType *player_ptr, TIME_EFFECT turns)
 {
     /*
      * TODO: Recall the player to the last
@@ -390,7 +390,7 @@ bool recall_player(player_type *player_ptr, TIME_EFFECT turns)
     return true;
 }
 
-bool free_level_recall(player_type *player_ptr)
+bool free_level_recall(PlayerType *player_ptr)
 {
     DUNGEON_IDX select_dungeon = choose_dungeon(_("にテレポート", "teleport"), 4, 0);
     if (!select_dungeon)
@@ -429,7 +429,7 @@ bool free_level_recall(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return リセット処理が実際に行われたらTRUEを返す
  */
-bool reset_recall(player_type *player_ptr)
+bool reset_recall(PlayerType *player_ptr)
 {
     int select_dungeon, dummy = 0;
     char ppp[80];
index 5a73113..588ab01 100644 (file)
@@ -2,12 +2,12 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void teleport_level(player_type *player_ptr, MONSTER_IDX m_idx);
-bool teleport_level_other(player_type *player_ptr);
-bool tele_town(player_type *player_ptr);
-void reserve_alter_reality(player_type *player_ptr, TIME_EFFECT turns);
-bool is_teleport_level_ineffective(player_type *player_ptr, MONSTER_IDX idx);
-bool recall_player(player_type *player_ptr, TIME_EFFECT turns);
-bool free_level_recall(player_type *player_ptr);
-bool reset_recall(player_type *player_ptr);
+class PlayerType;
+void teleport_level(PlayerType *player_ptr, MONSTER_IDX m_idx);
+bool teleport_level_other(PlayerType *player_ptr);
+bool tele_town(PlayerType *player_ptr);
+void reserve_alter_reality(PlayerType *player_ptr, TIME_EFFECT turns);
+bool is_teleport_level_ineffective(PlayerType *player_ptr, MONSTER_IDX idx);
+bool recall_player(PlayerType *player_ptr, TIME_EFFECT turns);
+bool free_level_recall(PlayerType *player_ptr);
+bool reset_recall(PlayerType *player_ptr);
index 72ae782..9bb449a 100644 (file)
@@ -10,7 +10,7 @@
  * @brief 寿命つき光源の燃素追加処理 /
  * Charge a lite (torch or latern)
  */
-void phlogiston(player_type *player_ptr)
+void phlogiston(PlayerType *player_ptr)
 {
     GAME_TURN max_flog = 0;
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_LITE];
index a4a35ff..a4af0dd 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void phlogiston(player_type *player_ptr);
+class PlayerType;
+void phlogiston(PlayerType *player_ptr);
index 4fdad5e..a21f082 100644 (file)
@@ -31,7 +31,7 @@
  * @details
  * Sorry, it becomes not (void)...
  */
-void call_the_void(player_type *player_ptr)
+void call_the_void(PlayerType *player_ptr)
 {
     bool do_call = true;
     auto *floor_ptr = player_ptr->current_floor_ptr;
@@ -101,7 +101,7 @@ void call_the_void(player_type *player_ptr)
  * @param player_ptr 術者の参照ポインタ
  * @return 実際に処理が反映された場合TRUE
  */
-bool vanish_dungeon(player_type *player_ptr)
+bool vanish_dungeon(PlayerType *player_ptr)
 {
     auto *floor_ptr = player_ptr->current_floor_ptr;
     bool is_special_floor = floor_ptr->inside_quest && quest_type::is_fixed(floor_ptr->inside_quest);
@@ -189,7 +189,7 @@ bool vanish_dungeon(player_type *player_ptr)
  * @param rad 効力の半径
  * @details このファイルにいるのは、spells-trump.c と比べて行数が少なかったため。それ以上の意図はない
  */
-void cast_meteor(player_type *player_ptr, HIT_POINT dam, POSITION rad)
+void cast_meteor(PlayerType *player_ptr, HIT_POINT dam, POSITION rad)
 {
     int b = 10 + randint1(10);
     for (int i = 0; i < b; i++) {
index c72754f..bf1130b 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void call_the_void(player_type *player_ptr);
-bool vanish_dungeon(player_type *player_ptr);
-void cast_meteor(player_type *player_ptr, HIT_POINT dam, POSITION rad);
+class PlayerType;
+void call_the_void(PlayerType *player_ptr);
+bool vanish_dungeon(PlayerType *player_ptr);
+void cast_meteor(PlayerType *player_ptr, HIT_POINT dam, POSITION rad);
index 34caf22..28d18d4 100644 (file)
@@ -31,7 +31,7 @@
  * @param v 継続時間
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_ele_attack(player_type *player_ptr, uint32_t attack_type, TIME_EFFECT v)
+bool set_ele_attack(PlayerType *player_ptr, uint32_t attack_type, TIME_EFFECT v)
 {
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
 
@@ -99,7 +99,7 @@ bool set_ele_attack(player_type *player_ptr, uint32_t attack_type, TIME_EFFECT v
  * @param v 継続時間
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_ele_immune(player_type *player_ptr, uint32_t immune_type, TIME_EFFECT v)
+bool set_ele_immune(PlayerType *player_ptr, uint32_t immune_type, TIME_EFFECT v)
 {
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
 
@@ -155,7 +155,7 @@ bool set_ele_immune(player_type *player_ptr, uint32_t immune_type, TIME_EFFECT v
 /*
  * Choose a warrior-mage elemental attack. -LM-
  */
-bool choose_ele_attack(player_type *player_ptr)
+bool choose_ele_attack(PlayerType *player_ptr)
 {
     if (!has_melee_weapon(player_ptr, INVEN_MAIN_HAND) && !has_melee_weapon(player_ptr, INVEN_SUB_HAND)) {
         msg_format(_("武器を持たないと魔法剣は使えない。", "You cannot use temporary branding with no weapon."));
@@ -217,7 +217,7 @@ bool choose_ele_attack(player_type *player_ptr)
 /*
  * Choose a elemental immune. -LM-
  */
-bool choose_ele_immune(player_type *player_ptr, TIME_EFFECT immune_turn)
+bool choose_ele_immune(PlayerType *player_ptr, TIME_EFFECT immune_turn)
 {
     screen_save();
 
@@ -259,7 +259,7 @@ bool choose_ele_immune(player_type *player_ptr, TIME_EFFECT immune_turn)
  * pulish shield
  * @return ターン消費を要する処理を行ったならばTRUEを返す
  */
-bool pulish_shield(player_type *player_ptr)
+bool pulish_shield(PlayerType *player_ptr)
 {
     concptr q = _("どの盾を磨きますか?", "Polish which shield? ");
     concptr s = _("磨く盾がありません。", "You have no shield to polish.");
index e6d12e3..cbd2d09 100644 (file)
@@ -2,9 +2,9 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool set_ele_attack(player_type *player_ptr, uint32_t attack_type, TIME_EFFECT v);
-bool set_ele_immune(player_type *player_ptr, uint32_t immune_type, TIME_EFFECT v);
-bool choose_ele_attack(player_type *player_ptr);
-bool choose_ele_immune(player_type *player_ptr, TIME_EFFECT turn);
-bool pulish_shield(player_type *player_ptr);
+class PlayerType;
+bool set_ele_attack(PlayerType *player_ptr, uint32_t attack_type, TIME_EFFECT v);
+bool set_ele_immune(PlayerType *player_ptr, uint32_t immune_type, TIME_EFFECT v);
+bool choose_ele_attack(PlayerType *player_ptr);
+bool choose_ele_immune(PlayerType *player_ptr, TIME_EFFECT turn);
+bool pulish_shield(PlayerType *player_ptr);
index de6b5e1..7d9b86c 100644 (file)
@@ -34,7 +34,7 @@
  * @param rad 効力の半径
  * @return ターゲットを指定し、実行したならばTRUEを返す。
  */
-bool cast_wrath_of_the_god(player_type *player_ptr, HIT_POINT dam, POSITION rad)
+bool cast_wrath_of_the_god(PlayerType *player_ptr, HIT_POINT dam, POSITION rad)
 {
     DIRECTION dir;
     if (!get_aim_dir(player_ptr, &dir))
@@ -108,7 +108,7 @@ bool cast_wrath_of_the_god(player_type *player_ptr, HIT_POINT dam, POSITION rad)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_sh_holy(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_sh_holy(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -151,7 +151,7 @@ bool set_tim_sh_holy(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す
  * @details 呪術領域でも使えるが、汎用性と行数の兼ね合いを考えて破邪側に入れた
  */
-bool set_tim_eyeeye(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_eyeeye(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
index 8d608bc..9078002 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool cast_wrath_of_the_god(player_type *player_ptr, HIT_POINT dam, POSITION rad);
-bool set_tim_sh_holy(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tim_eyeeye(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+bool cast_wrath_of_the_god(PlayerType *player_ptr, HIT_POINT dam, POSITION rad);
+bool set_tim_sh_holy(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tim_eyeeye(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
index b83b483..0977f77 100644 (file)
@@ -13,7 +13,7 @@
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_sh_fire(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_sh_fire(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
index 53ca491..06e2bbf 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool set_tim_sh_fire(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+bool set_tim_sh_fire(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
index 62d9d39..d97c727 100644 (file)
@@ -40,7 +40,7 @@
 /*!< 呪術の最大詠唱数 */
 constexpr int MAX_KEEP = 4;
 
-SpellHex::SpellHex(player_type *player_ptr)
+SpellHex::SpellHex(PlayerType *player_ptr)
     : player_ptr(player_ptr)
     , spell_hex_data(PlayerClass(player_ptr).get_specific_data<spell_hex_data_type>())
 {
@@ -55,7 +55,7 @@ SpellHex::SpellHex(player_type *player_ptr)
     }
 }
 
-SpellHex::SpellHex(player_type *player_ptr, monap_type *monap_ptr)
+SpellHex::SpellHex(PlayerType *player_ptr, monap_type *monap_ptr)
     : player_ptr(player_ptr)
     , monap_ptr(monap_ptr)
 {
index a525398..e0c7785 100644 (file)
@@ -11,12 +11,12 @@ enum class SpellHexRevengeType : byte {
 };
 
 struct monap_type;
-struct player_type;
+class PlayerType;
 struct spell_hex_data_type;
 class SpellHex {
 public:
-    SpellHex(player_type *player_ptr);
-    SpellHex(player_type *player_ptr, monap_type *monap_ptr);
+    SpellHex(PlayerType *player_ptr);
+    SpellHex(PlayerType *player_ptr, monap_type *monap_ptr);
     virtual ~SpellHex() = default;
 
     bool stop_spells_with_selection();
@@ -42,7 +42,7 @@ public:
     void set_revenge_type(SpellHexRevengeType type);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     std::vector<int> casting_spells;
     monap_type *monap_ptr = nullptr;
     std::shared_ptr<spell_hex_data_type> spell_hex_data;
index f791daa..5fe900d 100644 (file)
@@ -17,7 +17,7 @@
  * @param player_ptr 錆止め実行者の参照ポインタ
  * @return ターン消費を要する処理を行ったならばTRUEを返す
  */
-bool rustproof(player_type *player_ptr)
+bool rustproof(PlayerType *player_ptr)
 {
     concptr q = _("どの防具に錆止めをしますか?", "Rustproof which piece of armour? ");
     concptr s = _("錆止めできるものがありません。", "You have nothing to rustproof.");
index e495ea4..b2c88d0 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool rustproof(player_type *player_ptr);
+class PlayerType;
+bool rustproof(PlayerType *player_ptr);
index dc3181b..9d8f1ef 100644 (file)
@@ -23,7 +23,7 @@
 /*!
  * @brief プレイヤーの歌に関する継続処理
  */
-void check_music(player_type *player_ptr)
+void check_music(PlayerType *player_ptr)
 {
     if (player_ptr->pclass != PlayerClassType::BARD)
         return;
@@ -74,7 +74,7 @@ void check_music(player_type *player_ptr)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_stealth(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_stealth(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -113,7 +113,7 @@ bool set_tim_stealth(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
 /*!
  * @brief 歌の停止を処理する / Stop singing if the player is a Bard
  */
-void stop_singing(player_type *player_ptr)
+void stop_singing(PlayerType *player_ptr)
 {
     if (player_ptr->pclass != PlayerClassType::BARD)
         return;
@@ -136,19 +136,19 @@ void stop_singing(player_type *player_ptr)
     set_bits(player_ptr->redraw, PR_STATUS);
 }
 
-bool music_singing(player_type *player_ptr, int music_songs)
+bool music_singing(PlayerType *player_ptr, int music_songs)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     return bird_data && (bird_data->singing_song == music_songs);
 }
 
-bool music_singing_any(player_type *player_ptr)
+bool music_singing_any(PlayerType *player_ptr)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     return bird_data && (bird_data->singing_song != MUSIC_NONE);
 }
 
-int32_t get_singing_song_effect(player_type *player_ptr)
+int32_t get_singing_song_effect(PlayerType *player_ptr)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     if (!bird_data) {
@@ -158,7 +158,7 @@ int32_t get_singing_song_effect(player_type *player_ptr)
     return bird_data->singing_song;
 }
 
-void set_singing_song_effect(player_type *player_ptr, const int32_t magic_num)
+void set_singing_song_effect(PlayerType *player_ptr, const int32_t magic_num)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     if (!bird_data) {
@@ -168,7 +168,7 @@ void set_singing_song_effect(player_type *player_ptr, const int32_t magic_num)
     bird_data->singing_song = i2enum<realm_song_type>(magic_num);
 }
 
-int32_t get_interrupting_song_effect(player_type *player_ptr)
+int32_t get_interrupting_song_effect(PlayerType *player_ptr)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     if (!bird_data) {
@@ -178,7 +178,7 @@ int32_t get_interrupting_song_effect(player_type *player_ptr)
     return bird_data->interrputing_song;
 }
 
-void set_interrupting_song_effect(player_type *player_ptr, const int32_t magic_num)
+void set_interrupting_song_effect(PlayerType *player_ptr, const int32_t magic_num)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     if (!bird_data) {
@@ -188,7 +188,7 @@ void set_interrupting_song_effect(player_type *player_ptr, const int32_t magic_n
     bird_data->interrputing_song = i2enum<realm_song_type>(magic_num);
 }
 
-int32_t get_singing_count(player_type *player_ptr)
+int32_t get_singing_count(PlayerType *player_ptr)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     if (!bird_data) {
@@ -198,7 +198,7 @@ int32_t get_singing_count(player_type *player_ptr)
     return bird_data->singing_duration;
 }
 
-void set_singing_count(player_type *player_ptr, const int32_t magic_num)
+void set_singing_count(PlayerType *player_ptr, const int32_t magic_num)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     if (!bird_data) {
@@ -208,7 +208,7 @@ void set_singing_count(player_type *player_ptr, const int32_t magic_num)
     bird_data->singing_duration = magic_num;
 }
 
-byte get_singing_song_id(player_type *player_ptr)
+byte get_singing_song_id(PlayerType *player_ptr)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     if (!bird_data) {
@@ -218,7 +218,7 @@ byte get_singing_song_id(player_type *player_ptr)
     return bird_data->singing_song_spell_idx;
 }
 
-void set_singing_song_id(player_type *player_ptr, const byte magic_num)
+void set_singing_song_id(PlayerType *player_ptr, const byte magic_num)
 {
     auto bird_data = PlayerClass(player_ptr).get_specific_data<bard_data_type>();
     if (!bird_data) {
index d2a9dbc..9053367 100644 (file)
@@ -2,17 +2,17 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void check_music(player_type *player_ptr);
-bool set_tim_stealth(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-void stop_singing(player_type *player_ptr);
-bool music_singing(player_type *player_ptr, int music_songs);
-bool music_singing_any(player_type *player_ptr);
-int32_t get_singing_song_effect(player_type *player_ptr);
-void set_singing_song_effect(player_type *player_ptr, const int32_t magic_num);
-int32_t get_interrupting_song_effect(player_type *player_ptr);
-void set_interrupting_song_effect(player_type *player_ptr, const int32_t magic_num);
-int32_t get_singing_count(player_type *player_ptr);
-void set_singing_count(player_type *player_ptr, const int32_t magic_num);
-byte get_singing_song_id(player_type *player_ptr);
-void set_singing_song_id(player_type *player_ptr, const byte magic_num);
+class PlayerType;
+void check_music(PlayerType *player_ptr);
+bool set_tim_stealth(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+void stop_singing(PlayerType *player_ptr);
+bool music_singing(PlayerType *player_ptr, int music_songs);
+bool music_singing_any(PlayerType *player_ptr);
+int32_t get_singing_song_effect(PlayerType *player_ptr);
+void set_singing_song_effect(PlayerType *player_ptr, const int32_t magic_num);
+int32_t get_interrupting_song_effect(PlayerType *player_ptr);
+void set_interrupting_song_effect(PlayerType *player_ptr, const int32_t magic_num);
+int32_t get_singing_count(PlayerType *player_ptr);
+void set_singing_count(PlayerType *player_ptr, const int32_t magic_num);
+byte get_singing_song_id(PlayerType *player_ptr);
+void set_singing_song_id(PlayerType *player_ptr, const byte magic_num);
index ef90ce4..8ad666d 100644 (file)
@@ -20,7 +20,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 処理が実際に行われたらTRUEを返す
  */
-bool alchemy(player_type *player_ptr)
+bool alchemy(PlayerType *player_ptr)
 {
     bool force = false;
     if (command_arg > 0)
index ab0dca4..f5ee7ea 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-bool alchemy(player_type *player_ptr);
+class PlayerType;
+bool alchemy(PlayerType *player_ptr);
index c32810c..4f28038 100644 (file)
@@ -26,7 +26,7 @@
  * @brief トランプ領域の「シャッフル」の効果をランダムに決めて処理する。
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void cast_shuffle(player_type *player_ptr)
+void cast_shuffle(PlayerType *player_ptr)
 {
     PLAYER_LEVEL plev = player_ptr->lev;
     DIRECTION dir;
@@ -220,7 +220,7 @@ void cast_shuffle(player_type *player_ptr)
     gain_exp(player_ptr, ee);
 }
 
-void become_living_trump(player_type *player_ptr)
+void become_living_trump(PlayerType *player_ptr)
 {
     /* 1/7 Teleport control and 6/7 Random teleportation (uncontrolled) */
     MUTATION_IDX mutation = one_in_(7) ? 12 : 77;
index 67f51dd..6505f2c 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-void cast_shuffle(player_type *player_ptr);
-void become_living_trump(player_type *player_ptr);
+class PlayerType;
+void cast_shuffle(PlayerType *player_ptr);
+void become_living_trump(PlayerType *player_ptr);
index 36ba247..48b158f 100644 (file)
@@ -186,7 +186,7 @@ bool in_disintegration_range(floor_type *floor_ptr, POSITION y1, POSITION x1, PO
 /*
  * breath shape
  */
-void breath_shape(player_type *player_ptr, uint16_t *path_g, int dist, int *pgrids, POSITION *gx, POSITION *gy, POSITION *gm, POSITION *pgm_rad, POSITION rad, POSITION y1, POSITION x1, POSITION y2, POSITION x2, AttributeType typ)
+void breath_shape(PlayerType *player_ptr, uint16_t *path_g, int dist, int *pgrids, POSITION *gx, POSITION *gy, POSITION *gm, POSITION *pgm_rad, POSITION rad, POSITION y1, POSITION x1, POSITION y2, POSITION x2, AttributeType typ)
 {
     POSITION by = y1;
     POSITION bx = x1;
index 77b5394..a2e5b2c 100644 (file)
@@ -4,7 +4,7 @@
 #include "effect/attribute-types.h"
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 bool in_disintegration_range(floor_type *floor_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2);
-void breath_shape(player_type *player_ptr, uint16_t *path_g, int dist, int *pgrids, POSITION *gx, POSITION *gy, POSITION *gm, POSITION *pgm_rad, POSITION rad, POSITION y1, POSITION x1, POSITION y2, POSITION x2, AttributeType typ);
+void breath_shape(PlayerType *player_ptr, uint16_t *path_g, int dist, int *pgrids, POSITION *gx, POSITION *gy, POSITION *gm, POSITION *pgm_rad, POSITION rad, POSITION y1, POSITION x1, POSITION y2, POSITION x2, AttributeType typ);
 POSITION dist_to_line(POSITION y, POSITION x, POSITION y1, POSITION x1, POSITION y2, POSITION x2);
index 4f11415..c4a3fdc 100644 (file)
@@ -33,7 +33,7 @@ static const int extra_min_magic_fail_rate = 2;
  * @param realm 魔法領域
  * @return 消費MP
  */
-MANA_POINT mod_need_mana(player_type *player_ptr, MANA_POINT need_mana, SPELL_IDX spell, int16_t realm)
+MANA_POINT mod_need_mana(PlayerType *player_ptr, MANA_POINT need_mana, SPELL_IDX spell, int16_t realm)
 {
 #define MANA_CONST 2400
 #define MANA_DIV 4
@@ -65,7 +65,7 @@ MANA_POINT mod_need_mana(player_type *player_ptr, MANA_POINT need_mana, SPELL_ID
  * @return 失敗率(%)
  * @todo 統合を検討
  */
-PERCENTAGE mod_spell_chance_1(player_type *player_ptr, PERCENTAGE chance)
+PERCENTAGE mod_spell_chance_1(PlayerType *player_ptr, PERCENTAGE chance)
 {
     chance += player_ptr->to_m_chance;
 
@@ -94,7 +94,7 @@ PERCENTAGE mod_spell_chance_1(player_type *player_ptr, PERCENTAGE chance)
  * Note: variable "chance" cannot be negative.
  * @todo 統合を検討
  */
-PERCENTAGE mod_spell_chance_2(player_type *player_ptr, PERCENTAGE chance)
+PERCENTAGE mod_spell_chance_2(PlayerType *player_ptr, PERCENTAGE chance)
 {
     if (player_ptr->dec_mana)
         chance--;
@@ -111,7 +111,7 @@ PERCENTAGE mod_spell_chance_2(player_type *player_ptr, PERCENTAGE chance)
  * @param use_realm 魔法領域ID
  * @return 失敗率(%)
  */
-PERCENTAGE spell_chance(player_type *player_ptr, SPELL_IDX spell, int16_t use_realm)
+PERCENTAGE spell_chance(PlayerType *player_ptr, SPELL_IDX spell, int16_t use_realm)
 {
     if (mp_ptr->spell_book == ItemKindType::NONE)
         return 100;
@@ -202,7 +202,7 @@ PERCENTAGE spell_chance(player_type *player_ptr, SPELL_IDX spell, int16_t use_re
  * @param x 表示メッセージ左上X座標
  * @param use_realm 魔法領域ID
  */
-void print_spells(player_type *player_ptr, SPELL_IDX target_spell, SPELL_IDX *spells, int num, TERM_LEN y, TERM_LEN x, int16_t use_realm)
+void print_spells(PlayerType *player_ptr, SPELL_IDX target_spell, SPELL_IDX *spells, int num, TERM_LEN y, TERM_LEN x, int16_t use_realm)
 {
     if (((use_realm <= REALM_NONE) || (use_realm > MAX_REALM)) && allow_debug_options)
         msg_print(_("警告! print_spell が領域なしに呼ばれた", "Warning! print_spells called with null realm"));
index f6eea7e..8322799 100644 (file)
@@ -2,9 +2,9 @@
 
 #include "system/angband.h"
 
-struct player_type;
-MANA_POINT mod_need_mana(player_type *player_ptr, MANA_POINT need_mana, SPELL_IDX spell, int16_t realm);
-PERCENTAGE mod_spell_chance_1(player_type *player_ptr, PERCENTAGE chance);
-PERCENTAGE mod_spell_chance_2(player_type *player_ptr, PERCENTAGE chance);
-PERCENTAGE spell_chance(player_type *player_ptr, SPELL_IDX spell, int16_t realm);
-void print_spells(player_type *player_ptr, SPELL_IDX target_spell, SPELL_IDX *spells, int num, TERM_LEN y, TERM_LEN x, int16_t realm);
+class PlayerType;
+MANA_POINT mod_need_mana(PlayerType *player_ptr, MANA_POINT need_mana, SPELL_IDX spell, int16_t realm);
+PERCENTAGE mod_spell_chance_1(PlayerType *player_ptr, PERCENTAGE chance);
+PERCENTAGE mod_spell_chance_2(PlayerType *player_ptr, PERCENTAGE chance);
+PERCENTAGE spell_chance(PlayerType *player_ptr, SPELL_IDX spell, int16_t realm);
+void print_spells(PlayerType *player_ptr, SPELL_IDX target_spell, SPELL_IDX *spells, int num, TERM_LEN y, TERM_LEN x, int16_t realm);
index 2b5042e..51e0aa9 100644 (file)
@@ -21,7 +21,7 @@
  * @param m_ptr 対象モンスター
  * @return 魅了に抵抗したらTRUE
  */
-bool common_saving_throw_charm(player_type *player_ptr, HIT_POINT pow, monster_type *m_ptr)
+bool common_saving_throw_charm(PlayerType *player_ptr, HIT_POINT pow, monster_type *m_ptr)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
 
@@ -56,7 +56,7 @@ bool common_saving_throw_charm(player_type *player_ptr, HIT_POINT pow, monster_t
  * @param m_ptr 対象モンスター
  * @return 服従に抵抗したらTRUE
  */
-bool common_saving_throw_control(player_type *player_ptr, HIT_POINT pow, monster_type *m_ptr)
+bool common_saving_throw_control(PlayerType *player_ptr, HIT_POINT pow, monster_type *m_ptr)
 {
     monster_race *r_ptr = &r_info[m_ptr->r_idx];
 
@@ -86,7 +86,7 @@ bool common_saving_throw_control(player_type *player_ptr, HIT_POINT pow, monster
  * ハードコーティングによる実装が行われている。
  * メイジは(レベル)%、ハイメイジ、スペルマスターは(レベル)%、それ以外の職業は(レベル/2)%
  */
-PERCENTAGE beam_chance(player_type *player_ptr)
+PERCENTAGE beam_chance(PlayerType *player_ptr)
 {
     if (player_ptr->pclass == PlayerClassType::MAGE)
         return (PERCENTAGE)(player_ptr->lev);
index dc81389..7950a05 100644 (file)
@@ -3,7 +3,7 @@
 #include "system/angband.h"
 
 struct monster_type;
-struct player_type;
-bool common_saving_throw_control(player_type *player_ptr, HIT_POINT pow, monster_type *m_ptr);
-bool common_saving_throw_charm(player_type *player_ptr, HIT_POINT pow, monster_type *m_ptr);
-PERCENTAGE beam_chance(player_type *player_ptr);
+class PlayerType;
+bool common_saving_throw_control(PlayerType *player_ptr, HIT_POINT pow, monster_type *m_ptr);
+bool common_saving_throw_charm(PlayerType *player_ptr, HIT_POINT pow, monster_type *m_ptr);
+PERCENTAGE beam_chance(PlayerType *player_ptr);
index 0269ded..ea298eb 100644 (file)
@@ -22,7 +22,7 @@
  * @param mode 求める処理
  * @return 各領域魔法に各種テキストを求めた場合は文字列参照ポインタ、そうでない場合はnullptrを返す。
  */
-concptr exe_spell(player_type *player_ptr, int16_t realm, SPELL_IDX spell, SpellProcessType mode)
+concptr exe_spell(PlayerType *player_ptr, int16_t realm, SPELL_IDX spell, SpellProcessType mode)
 {
        switch (realm)
        {
index 8dc85f5..7a02419 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 #include "spell/spells-util.h"
 
-struct player_type;
-concptr exe_spell(player_type *player_ptr, int16_t realm, SPELL_IDX spell, SpellProcessType mode);
+class PlayerType;
+concptr exe_spell(PlayerType *player_ptr, int16_t realm, SPELL_IDX spell, SpellProcessType mode);
index 419790a..2c5e505 100644 (file)
@@ -85,7 +85,7 @@ static amuse_type amuse_info[]
  * @param num 誰得の処理回数
  * @param known TRUEならばオブジェクトが必ず*鑑定*済になる
  */
-void amusement(player_type *player_ptr, POSITION y1, POSITION x1, int num, bool known)
+void amusement(PlayerType *player_ptr, POSITION y1, POSITION x1, int num, bool known)
 {
     int t = 0;
     for (int n = 0; amuse_info[n].tval != ItemKindType::NONE; n++) {
@@ -180,7 +180,7 @@ void amusement(player_type *player_ptr, POSITION y1, POSITION x1, int num, bool
  * @param special TRUEならば必ず特別品を落とす
  * @param known TRUEならばオブジェクトが必ず*鑑定*済になる
  */
-void acquirement(player_type *player_ptr, POSITION y1, POSITION x1, int num, bool great, bool special, bool known)
+void acquirement(PlayerType *player_ptr, POSITION y1, POSITION x1, int num, bool great, bool special, bool known)
 {
     object_type *i_ptr;
     object_type object_type_body;
@@ -210,7 +210,7 @@ void acquirement(player_type *player_ptr, POSITION y1, POSITION x1, int num, boo
  * @return 何も持っていない場合を除き、常にTRUEを返す
  * @todo 元のreturnは間違っているが、修正後の↓文がどれくらい正しいかは要チェック
  */
-bool curse_armor(player_type *player_ptr)
+bool curse_armor(PlayerType *player_ptr)
 {
     /* Curse the body armor */
     object_type *o_ptr;
@@ -268,7 +268,7 @@ bool curse_armor(player_type *player_ptr)
  * @return 何も持っていない場合を除き、常にTRUEを返す
  * @todo 元のreturnは間違っているが、修正後の↓文がどれくらい正しいかは要チェック
  */
-bool curse_weapon_object(player_type *player_ptr, bool force, object_type *o_ptr)
+bool curse_weapon_object(PlayerType *player_ptr, bool force, object_type *o_ptr)
 {
     if (!o_ptr->k_idx)
         return false;
@@ -318,7 +318,7 @@ bool curse_weapon_object(player_type *player_ptr, bool force, object_type *o_ptr
  * Enchant some bolts
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void brand_bolts(player_type *player_ptr)
+void brand_bolts(PlayerType *player_ptr)
 {
     /* Use the first acceptable bolts */
     for (int i = 0; i < INVEN_PACK; i++) {
@@ -396,7 +396,7 @@ static void break_curse(object_type *o_ptr)
  * the larger the pile, the lower the chance of success.
  * </pre>
  */
-bool enchant_equipment(player_type *player_ptr, object_type *o_ptr, int n, int eflag)
+bool enchant_equipment(PlayerType *player_ptr, object_type *o_ptr, int n, int eflag)
 {
     /* Large piles resist enchantment */
     int prob = o_ptr->number * 100;
@@ -498,7 +498,7 @@ bool enchant_equipment(player_type *player_ptr, object_type *o_ptr, int n, int e
  * Note that "num_ac" requires armour, else weapon
  * Returns TRUE if attempted, FALSE if cancelled
  */
-bool enchant_spell(player_type *player_ptr, HIT_PROB num_hit, HIT_POINT num_dam, ARMOUR_CLASS num_ac)
+bool enchant_spell(PlayerType *player_ptr, HIT_PROB num_hit, HIT_POINT num_dam, ARMOUR_CLASS num_ac)
 {
     /* Assume enchant weapon */
     FuncItemTester item_tester(&object_type::allow_enchant_weapon);
@@ -554,7 +554,7 @@ bool enchant_spell(player_type *player_ptr, HIT_PROB num_hit, HIT_POINT num_dam,
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param brand_type エゴ化ID(e_info.txtとは連動していない)
  */
-void brand_weapon(player_type *player_ptr, int brand_type)
+void brand_weapon(PlayerType *player_ptr, int brand_type)
 {
     concptr q = _("どの武器を強化しますか? ", "Enchant which weapon? ");
     concptr s = _("強化できる武器がない。", "You have nothing to enchant.");
index c54fb98..41d65b9 100644 (file)
@@ -3,12 +3,12 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-void amusement(player_type *player_ptr, POSITION y1, POSITION x1, int num, bool known);
-void acquirement(player_type *player_ptr, POSITION y1, POSITION x1, int num, bool great, bool special, bool known);
-bool curse_armor(player_type *player_ptr);
-bool curse_weapon_object(player_type *player_ptr, bool force, object_type *o_ptr);
-void brand_bolts(player_type *player_ptr);
+class PlayerType;
+void amusement(PlayerType *player_ptr, POSITION y1, POSITION x1, int num, bool known);
+void acquirement(PlayerType *player_ptr, POSITION y1, POSITION x1, int num, bool great, bool special, bool known);
+bool curse_armor(PlayerType *player_ptr);
+bool curse_weapon_object(PlayerType *player_ptr, bool force, object_type *o_ptr);
+void brand_bolts(PlayerType *player_ptr);
 
 /*
  * Bit flags for the "enchant()" function
@@ -17,6 +17,6 @@ void brand_bolts(player_type *player_ptr);
 #define ENCH_TODAM      0x02 /*!< 装備強化処理: ダメージ強化 / Enchant to damage */
 #define ENCH_TOAC       0x04 /*!< 装備強化処理: AC強化 / Enchant to AC */
 #define ENCH_FORCE      0x08 /*!< 装備強化処理: 無条件に成功させる / Force enchantment */
-bool enchant_equipment(player_type *player_ptr, object_type *o_ptr, int n, int eflag);
-bool enchant_spell(player_type *player_ptr, HIT_PROB num_hit, HIT_POINT num_dam, ARMOUR_CLASS num_ac);
-void brand_weapon(player_type *player_ptr, int brand_type);
+bool enchant_equipment(PlayerType *player_ptr, object_type *o_ptr, int n, int eflag);
+bool enchant_spell(PlayerType *player_ptr, HIT_PROB num_hit, HIT_POINT num_dam, ARMOUR_CLASS num_ac);
+void brand_weapon(PlayerType *player_ptr, int brand_type);
index 68b7e31..a9b8aa5 100644 (file)
@@ -16,7 +16,7 @@
  * @magic 魔法の効果である場合TRUE (杖と同じ効果の呪文はあったか? 要調査)
  * @powerful 効果が増強される時TRUE (TRUEになるタイミングはあるか? 要調査)
  */
-bool cleansing_nova(player_type *player_ptr, bool magic, bool powerful)
+bool cleansing_nova(PlayerType *player_ptr, bool magic, bool powerful)
 {
     bool ident = false;
     if (dispel_evil(player_ptr, powerful ? 225 : 150)) {
@@ -57,7 +57,7 @@ bool cleansing_nova(player_type *player_ptr, bool magic, bool powerful)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @powerful 効果が増強される時TRUE (TRUEになるタイミングはあるか? 要調査)
  */
-bool unleash_mana_storm(player_type *player_ptr, bool powerful)
+bool unleash_mana_storm(PlayerType *player_ptr, bool powerful)
 {
     msg_print(_("強力な魔力が敵を引き裂いた!", "Mighty magics rend your enemies!"));
     project(player_ptr, 0, (powerful ? 7 : 5), player_ptr->y, player_ptr->x, (randint1(200) + (powerful ? 500 : 300)) * 2, AttributeType::MANA,
index c1fc46e..5a78f1a 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
-struct player_type;
-bool cleansing_nova(player_type *player_ptr, bool magic, bool powerful);
-bool unleash_mana_storm(player_type *player_ptr, bool powerful);
+class PlayerType;
+bool cleansing_nova(PlayerType *player_ptr, bool magic, bool powerful);
+bool unleash_mana_storm(PlayerType *player_ptr, bool powerful);
index e1fed5f..3710f72 100644 (file)
@@ -63,7 +63,7 @@
  * @param dam 威力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool heal_monster(player_type *player_ptr, DIRECTION dir, HIT_POINT dam)
+bool heal_monster(PlayerType *player_ptr, DIRECTION dir, HIT_POINT dam)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::OLD_HEAL, dir, dam, flg));
@@ -76,7 +76,7 @@ bool heal_monster(player_type *player_ptr, DIRECTION dir, HIT_POINT dam)
  * @param power 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool speed_monster(player_type *player_ptr, DIRECTION dir, int power)
+bool speed_monster(PlayerType *player_ptr, DIRECTION dir, int power)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::OLD_SPEED, dir, power, flg));
@@ -89,7 +89,7 @@ bool speed_monster(player_type *player_ptr, DIRECTION dir, int power)
  * @param power 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool slow_monster(player_type *player_ptr, DIRECTION dir, int power)
+bool slow_monster(PlayerType *player_ptr, DIRECTION dir, int power)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::OLD_SLOW, dir, power, flg));
@@ -102,7 +102,7 @@ bool slow_monster(player_type *player_ptr, DIRECTION dir, int power)
  * @param power 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool sleep_monster(player_type *player_ptr, DIRECTION dir, int power)
+bool sleep_monster(PlayerType *player_ptr, DIRECTION dir, int power)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::OLD_SLEEP, dir, power, flg));
@@ -115,7 +115,7 @@ bool sleep_monster(player_type *player_ptr, DIRECTION dir, int power)
  * @return 作用が実際にあった場合TRUEを返す
  * @details 威力はプレイヤーレベル*2に固定
  */
-bool stasis_monster(player_type *player_ptr, DIRECTION dir)
+bool stasis_monster(PlayerType *player_ptr, DIRECTION dir)
 {
     return (fire_ball_hide(player_ptr, AttributeType::STASIS, dir, player_ptr->lev * 2, 0));
 }
@@ -127,7 +127,7 @@ bool stasis_monster(player_type *player_ptr, DIRECTION dir)
  * @return 作用が実際にあった場合TRUEを返す
  * @details 威力はプレイヤーレベル*2に固定
  */
-bool stasis_evil(player_type *player_ptr, DIRECTION dir)
+bool stasis_evil(PlayerType *player_ptr, DIRECTION dir)
 {
     return (fire_ball_hide(player_ptr, AttributeType::STASIS_EVIL, dir, player_ptr->lev * 2, 0));
 }
@@ -139,7 +139,7 @@ bool stasis_evil(player_type *player_ptr, DIRECTION dir)
  * @param plev プレイヤーレベル(=効力)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool confuse_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
+bool confuse_monster(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::OLD_CONF, dir, plev, flg));
@@ -152,7 +152,7 @@ bool confuse_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
  * @param plev プレイヤーレベル(=効力)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool stun_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
+bool stun_monster(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::STUN, dir, plev, flg));
@@ -165,7 +165,7 @@ bool stun_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
  * @param power 効力
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool poly_monster(player_type *player_ptr, DIRECTION dir, int power)
+bool poly_monster(PlayerType *player_ptr, DIRECTION dir, int power)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     bool tester = (project_hook(player_ptr, AttributeType::OLD_POLY, dir, power, flg));
@@ -180,7 +180,7 @@ bool poly_monster(player_type *player_ptr, DIRECTION dir, int power)
  * @param dir 方向(5ならばグローバル変数 target_col/target_row の座標を目標にする)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool clone_monster(player_type *player_ptr, DIRECTION dir)
+bool clone_monster(PlayerType *player_ptr, DIRECTION dir)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::OLD_CLONE, dir, 0, flg));
@@ -193,13 +193,13 @@ bool clone_monster(player_type *player_ptr, DIRECTION dir)
  * @param plev プレイヤーレベル(=効力)
  * @return 作用が実際にあった場合TRUEを返す
  */
-bool fear_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
+bool fear_monster(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev)
 {
     BIT_FLAGS flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
     return (project_hook(player_ptr, AttributeType::TURN_ALL, dir, plev, flg));
 }
 
-bool time_walk(player_type *player_ptr)
+bool time_walk(PlayerType *player_ptr)
 {
     if (player_ptr->timewalk) {
         msg_print(_("既に時は止まっている。", "Time is already stopped."));
@@ -224,7 +224,7 @@ bool time_walk(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param options スペル共通オプション
  */
-void roll_hitdice(player_type *player_ptr, spell_operation options)
+void roll_hitdice(PlayerType *player_ptr, spell_operation options)
 {
     HIT_POINT min_value = player_ptr->hitdie + ((PY_MAX_LEVEL + 2) * (player_ptr->hitdie + 1)) * 3 / 8;
     HIT_POINT max_value = player_ptr->hitdie + ((PY_MAX_LEVEL + 2) * (player_ptr->hitdie + 1)) * 5 / 8;
@@ -273,7 +273,7 @@ void roll_hitdice(player_type *player_ptr, spell_operation options)
     msg_print(_("体力ランクが変わった。", "Life rate has changed."));
 }
 
-bool life_stream(player_type *player_ptr, bool message, bool virtue_change)
+bool life_stream(PlayerType *player_ptr, bool message, bool virtue_change)
 {
     if (virtue_change) {
         chg_virtue(player_ptr, V_VITALITY, 1);
@@ -301,7 +301,7 @@ bool life_stream(player_type *player_ptr, bool message, bool virtue_change)
     return true;
 }
 
-bool heroism(player_type *player_ptr, int base)
+bool heroism(PlayerType *player_ptr, int base)
 {
     auto ident = false;
     if (BadStatusSetter(player_ptr).afraidness(0)) {
@@ -319,7 +319,7 @@ bool heroism(player_type *player_ptr, int base)
     return ident;
 }
 
-bool berserk(player_type *player_ptr, int base)
+bool berserk(PlayerType *player_ptr, int base)
 {
     auto ident = false;
     if (BadStatusSetter(player_ptr).afraidness(0)) {
@@ -337,7 +337,7 @@ bool berserk(player_type *player_ptr, int base)
     return ident;
 }
 
-bool cure_light_wounds(player_type *player_ptr, DICE_NUMBER dice, DICE_SID sides)
+bool cure_light_wounds(PlayerType *player_ptr, DICE_NUMBER dice, DICE_SID sides)
 {
     auto ident = false;
     if (hp_player(player_ptr, damroll(dice, sides))) {
@@ -360,7 +360,7 @@ bool cure_light_wounds(player_type *player_ptr, DICE_NUMBER dice, DICE_SID sides
     return ident;
 }
 
-bool cure_serious_wounds(player_type *player_ptr, DICE_NUMBER dice, DICE_SID sides)
+bool cure_serious_wounds(PlayerType *player_ptr, DICE_NUMBER dice, DICE_SID sides)
 {
     auto ident = false;
     if (hp_player(player_ptr, damroll(dice, sides))) {
@@ -387,7 +387,7 @@ bool cure_serious_wounds(player_type *player_ptr, DICE_NUMBER dice, DICE_SID sid
     return ident;
 }
 
-bool cure_critical_wounds(player_type *player_ptr, HIT_POINT pow)
+bool cure_critical_wounds(PlayerType *player_ptr, HIT_POINT pow)
 {
     auto ident = false;
     if (hp_player(player_ptr, pow)) {
@@ -422,7 +422,7 @@ bool cure_critical_wounds(player_type *player_ptr, HIT_POINT pow)
     return ident;
 }
 
-bool true_healing(player_type *player_ptr, HIT_POINT pow)
+bool true_healing(PlayerType *player_ptr, HIT_POINT pow)
 {
     auto ident = false;
     if (hp_player(player_ptr, pow)) {
@@ -457,7 +457,7 @@ bool true_healing(player_type *player_ptr, HIT_POINT pow)
     return ident;
 }
 
-bool restore_mana(player_type *player_ptr, bool magic_eater)
+bool restore_mana(PlayerType *player_ptr, bool magic_eater)
 {
     if (player_ptr->pclass == PlayerClassType::MAGIC_EATER && magic_eater) {
         // 魔力復活による、魔道具術師の取り込んだ魔法の回復量
@@ -496,7 +496,7 @@ bool restore_mana(player_type *player_ptr, bool magic_eater)
     return true;
 }
 
-bool restore_all_status(player_type *player_ptr)
+bool restore_all_status(PlayerType *player_ptr)
 {
     bool ident = false;
     if (do_res_stat(player_ptr, A_STR))
@@ -514,7 +514,7 @@ bool restore_all_status(player_type *player_ptr)
     return ident;
 }
 
-bool fishing(player_type *player_ptr)
+bool fishing(PlayerType *player_ptr)
 {
     DIRECTION dir;
     if (!get_direction(player_ptr, &dir, false, false))
@@ -548,7 +548,7 @@ bool fishing(player_type *player_ptr)
  * @details
  * 脱いで落とした装備にtimeoutを設定するために装備品のアドレスを返す。
  */
-bool cosmic_cast_off(player_type *player_ptr, object_type **o_ptr_ptr)
+bool cosmic_cast_off(PlayerType *player_ptr, object_type **o_ptr_ptr)
 {
     object_type *o_ptr = (*o_ptr_ptr);
 
@@ -599,7 +599,7 @@ bool cosmic_cast_off(player_type *player_ptr, object_type **o_ptr_ptr)
  * @brief プレイヤーの因果混乱処理 / Apply Nexus
  * @param m_ptr 因果混乱をプレイヤーに与えたモンスターの情報参照ポインタ
  */
-void apply_nexus(monster_type *m_ptr, player_type *player_ptr)
+void apply_nexus(monster_type *m_ptr, PlayerType *player_ptr)
 {
     switch (randint1(7)) {
     case 1:
@@ -642,7 +642,7 @@ void apply_nexus(monster_type *m_ptr, player_type *player_ptr)
  * @brief プレイヤーのステータスシャッフル処理
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void status_shuffle(player_type *player_ptr)
+void status_shuffle(PlayerType *player_ptr)
 {
     /* Pick a pair of stats */
     int i = randint0(A_MAX);
index 75f162a..60a7846 100644 (file)
@@ -4,32 +4,32 @@
 #include "spell/spells-util.h"
 
 struct object_type;
-struct player_type;
+class PlayerType;
 struct monster_type;
-bool heal_monster(player_type *player_ptr, DIRECTION dir, HIT_POINT dam);
-bool speed_monster(player_type *player_ptr, DIRECTION dir, int power);
-bool slow_monster(player_type *player_ptr, DIRECTION dir, int power);
-bool sleep_monster(player_type *player_ptr, DIRECTION dir, int power);
-bool stasis_monster(player_type *player_ptr, DIRECTION dir);    /* Like sleep, affects undead as well */
-bool stasis_evil(player_type *player_ptr, DIRECTION dir);    /* Like sleep, affects undead as well */
-bool confuse_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
-bool stun_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
-bool fear_monster(player_type *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
-bool poly_monster(player_type *player_ptr, DIRECTION dir, int power);
-bool clone_monster(player_type *player_ptr, DIRECTION dir);
-bool time_walk(player_type *player_ptr);
-void roll_hitdice(player_type *player_ptr, spell_operation options);
-bool life_stream(player_type *player_ptr, bool message, bool virtue_change);
-bool heroism(player_type *player_ptr, int base);
-bool berserk(player_type *player_ptr, int base);
-bool cure_light_wounds(player_type *player_ptr, DICE_NUMBER dice, DICE_SID sides);
-bool cure_serious_wounds(player_type *player_ptr, DICE_NUMBER dice, DICE_SID sides);
-bool cure_critical_wounds(player_type *player_ptr, HIT_POINT pow);
-bool true_healing(player_type *player_ptr, HIT_POINT pow);
-bool restore_mana(player_type *player_ptr, bool magic_eater);
-bool restore_all_status(player_type *player_ptr);
+bool heal_monster(PlayerType *player_ptr, DIRECTION dir, HIT_POINT dam);
+bool speed_monster(PlayerType *player_ptr, DIRECTION dir, int power);
+bool slow_monster(PlayerType *player_ptr, DIRECTION dir, int power);
+bool sleep_monster(PlayerType *player_ptr, DIRECTION dir, int power);
+bool stasis_monster(PlayerType *player_ptr, DIRECTION dir);    /* Like sleep, affects undead as well */
+bool stasis_evil(PlayerType *player_ptr, DIRECTION dir);    /* Like sleep, affects undead as well */
+bool confuse_monster(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
+bool stun_monster(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
+bool fear_monster(PlayerType *player_ptr, DIRECTION dir, PLAYER_LEVEL plev);
+bool poly_monster(PlayerType *player_ptr, DIRECTION dir, int power);
+bool clone_monster(PlayerType *player_ptr, DIRECTION dir);
+bool time_walk(PlayerType *player_ptr);
+void roll_hitdice(PlayerType *player_ptr, spell_operation options);
+bool life_stream(PlayerType *player_ptr, bool message, bool virtue_change);
+bool heroism(PlayerType *player_ptr, int base);
+bool berserk(PlayerType *player_ptr, int base);
+bool cure_light_wounds(PlayerType *player_ptr, DICE_NUMBER dice, DICE_SID sides);
+bool cure_serious_wounds(PlayerType *player_ptr, DICE_NUMBER dice, DICE_SID sides);
+bool cure_critical_wounds(PlayerType *player_ptr, HIT_POINT pow);
+bool true_healing(PlayerType *player_ptr, HIT_POINT pow);
+bool restore_mana(PlayerType *player_ptr, bool magic_eater);
+bool restore_all_status(PlayerType *player_ptr);
 
-bool fishing(player_type *player_ptr);
-bool cosmic_cast_off(player_type *player_ptr, object_type **o_ptr_ptr);
-void apply_nexus(monster_type *m_ptr, player_type *player_ptr);
-void status_shuffle(player_type *player_ptr);
+bool fishing(PlayerType *player_ptr);
+bool cosmic_cast_off(PlayerType *player_ptr, object_type **o_ptr_ptr);
+void apply_nexus(monster_type *m_ptr, PlayerType *player_ptr);
+void status_shuffle(PlayerType *player_ptr);
index dd26420..e73a41b 100644 (file)
@@ -48,7 +48,7 @@
  * @param mode モンスター生成条件フラグ
  * @return モンスターが(敵対も含めて)召還されたならばTRUEを返す。
  */
-bool trump_summoning(player_type *player_ptr, int num, bool pet, POSITION y, POSITION x, DEPTH lev, summon_type type, BIT_FLAGS mode)
+bool trump_summoning(PlayerType *player_ptr, int num, bool pet, POSITION y, POSITION x, DEPTH lev, summon_type type, BIT_FLAGS mode)
 {
     /* Default level */
     PLAYER_LEVEL plev = player_ptr->lev;
@@ -90,7 +90,7 @@ bool trump_summoning(player_type *player_ptr, int num, bool pet, POSITION y, POS
     return success;
 }
 
-bool cast_summon_demon(player_type *player_ptr, int power)
+bool cast_summon_demon(PlayerType *player_ptr, int power)
 {
     uint32_t flg = 0L;
     bool pet = !one_in_(3);
@@ -114,7 +114,7 @@ bool cast_summon_demon(player_type *player_ptr, int power)
     return true;
 }
 
-bool cast_summon_undead(player_type *player_ptr, int power)
+bool cast_summon_undead(PlayerType *player_ptr, int power)
 {
     bool pet = one_in_(3);
     summon_type type = (player_ptr->lev > 47 ? SUMMON_HI_UNDEAD : SUMMON_UNDEAD);
@@ -138,7 +138,7 @@ bool cast_summon_undead(player_type *player_ptr, int power)
     return true;
 }
 
-bool cast_summon_hound(player_type *player_ptr, int power)
+bool cast_summon_hound(PlayerType *player_ptr, int power)
 {
     BIT_FLAGS mode = PM_ALLOW_GROUP;
     bool pet = !one_in_(5);
@@ -157,7 +157,7 @@ bool cast_summon_hound(player_type *player_ptr, int power)
     return true;
 }
 
-bool cast_summon_elemental(player_type *player_ptr, int power)
+bool cast_summon_elemental(PlayerType *player_ptr, int power)
 {
     bool pet = one_in_(3);
     BIT_FLAGS mode = 0L;
@@ -179,7 +179,7 @@ bool cast_summon_elemental(player_type *player_ptr, int power)
     return true;
 }
 
-bool cast_summon_octopus(player_type *player_ptr)
+bool cast_summon_octopus(PlayerType *player_ptr)
 {
     BIT_FLAGS mode = PM_ALLOW_GROUP;
     bool pet = !one_in_(5);
@@ -199,7 +199,7 @@ bool cast_summon_octopus(player_type *player_ptr)
  * @brief 悪魔領域のグレーターデーモン召喚を処理する / Daemon spell Summon Greater Demon
  * @return 処理を実行したならばTRUEを返す。
  */
-bool cast_summon_greater_demon(player_type *player_ptr)
+bool cast_summon_greater_demon(PlayerType *player_ptr)
 {
     concptr q = _("どの死体を捧げますか? ", "Sacrifice which corpse? ");
     concptr s = _("捧げられる死体を持っていない。", "You have nothing to scrifice.");
@@ -232,7 +232,7 @@ bool cast_summon_greater_demon(player_type *player_ptr)
  * @param mode 召喚オプション
  * @return ターンを消費した場合TRUEを返す
  */
-bool summon_kin_player(player_type *player_ptr, DEPTH level, POSITION y, POSITION x, BIT_FLAGS mode)
+bool summon_kin_player(PlayerType *player_ptr, DEPTH level, POSITION y, POSITION x, BIT_FLAGS mode)
 {
     bool pet = (bool)(mode & PM_FORCE_PET);
     if (!pet)
@@ -248,7 +248,7 @@ bool summon_kin_player(player_type *player_ptr, DEPTH level, POSITION y, POSITIO
  * @param x 召喚位置X座標
  * @return 作用が実際にあった場合TRUEを返す
  */
-int summon_cyber(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x)
+int summon_cyber(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x)
 {
     /* Summoned by a monster */
     BIT_FLAGS mode = PM_ALLOW_GROUP;
@@ -271,7 +271,7 @@ int summon_cyber(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION
     return count;
 }
 
-void mitokohmon(player_type *player_ptr)
+void mitokohmon(PlayerType *player_ptr)
 {
     int count = 0;
     concptr sukekakusan = "";
@@ -329,7 +329,7 @@ void mitokohmon(player_type *player_ptr)
  * @return 作用が実際にあった場合TRUEを返す
  * @todo 引数にPOSITION x/yは必要か? 要調査
  */
-int activate_hi_summon(player_type *player_ptr, POSITION y, POSITION x, bool can_pet)
+int activate_hi_summon(PlayerType *player_ptr, POSITION y, POSITION x, bool can_pet)
 {
     BIT_FLAGS mode = PM_ALLOW_GROUP;
     bool pet = false;
@@ -423,7 +423,7 @@ int activate_hi_summon(player_type *player_ptr, POSITION y, POSITION x, bool can
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param dir 方向ID
  */
-void cast_invoke_spirits(player_type *player_ptr, DIRECTION dir)
+void cast_invoke_spirits(PlayerType *player_ptr, DIRECTION dir)
 {
     PLAYER_LEVEL plev = player_ptr->lev;
     int die = randint1(100) + plev / 5;
index 12fd33c..72bd842 100644 (file)
@@ -5,16 +5,16 @@
 enum summon_type : int;
 
 struct object_type;
-struct player_type;
-bool trump_summoning(player_type *player_ptr, int num, bool pet, POSITION y, POSITION x, DEPTH lev, summon_type type, BIT_FLAGS mode);
-bool cast_summon_demon(player_type *player_ptr, int power);
-bool cast_summon_undead(player_type *player_ptr, int power);
-bool cast_summon_hound(player_type *player_ptr, int power);
-bool cast_summon_elemental(player_type *player_ptr, int power);
-bool cast_summon_octopus(player_type *player_ptr);
-bool cast_summon_greater_demon(player_type *player_ptr);
-bool summon_kin_player(player_type *player_ptr, DEPTH level, POSITION y, POSITION x, BIT_FLAGS mode);
-void mitokohmon(player_type *player_ptr);
-int summon_cyber(player_type *player_ptr, MONSTER_IDX who, POSITION y, POSITION x);
-int activate_hi_summon(player_type *player_ptr, POSITION y, POSITION x, bool can_pet);
-void cast_invoke_spirits(player_type *player_ptr, DIRECTION dir);
+class PlayerType;
+bool trump_summoning(PlayerType *player_ptr, int num, bool pet, POSITION y, POSITION x, DEPTH lev, summon_type type, BIT_FLAGS mode);
+bool cast_summon_demon(PlayerType *player_ptr, int power);
+bool cast_summon_undead(PlayerType *player_ptr, int power);
+bool cast_summon_hound(PlayerType *player_ptr, int power);
+bool cast_summon_elemental(PlayerType *player_ptr, int power);
+bool cast_summon_octopus(PlayerType *player_ptr);
+bool cast_summon_greater_demon(PlayerType *player_ptr);
+bool summon_kin_player(PlayerType *player_ptr, DEPTH level, POSITION y, POSITION x, BIT_FLAGS mode);
+void mitokohmon(PlayerType *player_ptr);
+int summon_cyber(PlayerType *player_ptr, MONSTER_IDX who, POSITION y, POSITION x);
+int activate_hi_summon(PlayerType *player_ptr, POSITION y, POSITION x, bool can_pet);
+void cast_invoke_spirits(PlayerType *player_ptr, DIRECTION dir);
index 4b5b899..2023d56 100644 (file)
@@ -32,7 +32,7 @@
  * #ACTION_NONE / #ACTION_SEARCH / #ACTION_REST / #ACTION_LEARN / #ACTION_FISH / #ACTION_MONK_STANCE / #ACTION_SAMURAI_STANCE / #ACTION_SING / #ACTION_HAYAGAKE / #ACTION_SPELL
  * から選択。
  */
-void set_action(player_type *player_ptr, uint8_t typ)
+void set_action(PlayerType *player_ptr, uint8_t typ)
 {
     int prev_typ = player_ptr->action;
     if (typ == prev_typ) {
index 09fe3f5..1b5ae6b 100644 (file)
@@ -2,5 +2,5 @@
 
 #include <stdint.h>
 
-struct player_type;
-void set_action(player_type *player_ptr, uint8_t typ);
+class PlayerType;
+void set_action(PlayerType *player_ptr, uint8_t typ);
index 342c8da..8bd1017 100644 (file)
@@ -25,7 +25,7 @@
 #include "view/display-messages.h"
 #include <algorithm>
 
-BadStatusSetter::BadStatusSetter(player_type *player_ptr)
+BadStatusSetter::BadStatusSetter(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index 80e4a89..2130c63 100644 (file)
@@ -4,14 +4,14 @@
 
 /*!
  * @details 仮引数がtmpなのは、全て範囲外の値を範囲内に収める処理が含まれるため
- * @todo TIME_EFFECT型の引数はplayer_typeの時限ステータスをTimedEffectsクラスへ入れる時にshortへ差し替えること.
+ * @todo TIME_EFFECT型の引数はPlayerTypeの時限ステータスをTimedEffectsクラスへ入れる時にshortへ差し替えること.
  */
 enum class PlayerCutRank;
 enum class PlayerStunRank;
-struct player_type;
+class PlayerType;
 class BadStatusSetter {
 public:
-    BadStatusSetter(player_type *player_ptr);
+    BadStatusSetter(PlayerType *player_ptr);
     virtual ~BadStatusSetter() = default;
     
     bool blindness(const TIME_EFFECT tmp_v);
@@ -34,7 +34,7 @@ public:
     bool mod_cut(const TIME_EFFECT tmp_v);
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
 
     bool process_stun_effect(const short v);
     void process_stun_status(const PlayerStunRank new_rank, const short v);
index deb7f35..5848610 100644 (file)
@@ -31,7 +31,7 @@ static concptr desc_stat_neg[]
  * Note that this function (used by stat potions) now restores\n
  * the stat BEFORE increasing it.\n
  */
-bool inc_stat(player_type *player_ptr, int stat)
+bool inc_stat(PlayerType *player_ptr, int stat)
 {
     BASE_STATUS gain;
     BASE_STATUS value = player_ptr->stat_cur[stat];
@@ -79,7 +79,7 @@ bool inc_stat(player_type *player_ptr, int stat)
  * if your stat is already drained, the "max" value will not drop all\n
  * the way down to the "cur" value.\n
  */
-bool dec_stat(player_type *player_ptr, int stat, int amount, int permanent)
+bool dec_stat(PlayerType *player_ptr, int stat, int amount, int permanent)
 {
     bool res = false;
     BASE_STATUS cur = player_ptr->stat_cur[stat];
@@ -161,7 +161,7 @@ bool dec_stat(player_type *player_ptr, int stat, int amount, int permanent)
  * @param stat 回復ステータスID
  * @return 実際に回復した場合TRUEを返す。
  */
-bool res_stat(player_type *player_ptr, int stat)
+bool res_stat(PlayerType *player_ptr, int stat)
 {
     if (player_ptr->stat_cur[stat] != player_ptr->stat_max[stat]) {
         player_ptr->stat_cur[stat] = player_ptr->stat_max[stat];
@@ -176,7 +176,7 @@ bool res_stat(player_type *player_ptr, int stat)
 /*
  * Lose a "point"
  */
-bool do_dec_stat(player_type *player_ptr, int stat)
+bool do_dec_stat(PlayerType *player_ptr, int stat)
 {
     bool sust = false;
     switch (stat) {
@@ -222,7 +222,7 @@ bool do_dec_stat(player_type *player_ptr, int stat)
 /*
  * Restore lost "points" in a stat
  */
-bool do_res_stat(player_type *player_ptr, int stat)
+bool do_res_stat(PlayerType *player_ptr, int stat)
 {
     if (res_stat(player_ptr, stat)) {
         msg_format(_("元通りに%sなった気がする。", "You feel %s."), desc_stat_pos[stat]);
@@ -235,7 +235,7 @@ bool do_res_stat(player_type *player_ptr, int stat)
 /*
  * Gain a "point" in a stat
  */
-bool do_inc_stat(player_type *player_ptr, int stat)
+bool do_inc_stat(PlayerType *player_ptr, int stat)
 {
     bool res = res_stat(player_ptr, stat);
     if (inc_stat(player_ptr, stat)) {
@@ -263,7 +263,7 @@ bool do_inc_stat(player_type *player_ptr, int stat)
 /*
  * Forget everything
  */
-bool lose_all_info(player_type *player_ptr)
+bool lose_all_info(PlayerType *player_ptr)
 {
     chg_virtue(player_ptr, V_KNOWLEDGE, -5);
     chg_virtue(player_ptr, V_ENLIGHTEN, -5);
index 7711aba..ea31c06 100644 (file)
@@ -1,10 +1,10 @@
 #pragma once
 
-struct player_type;
-bool inc_stat(player_type *player_ptr, int stat);
-bool dec_stat(player_type *player_ptr, int stat, int amount, int permanent);
-bool res_stat(player_type *player_ptr, int stat);
-bool do_dec_stat(player_type *player_ptr, int stat);
-bool do_res_stat(player_type *player_ptr, int stat);
-bool do_inc_stat(player_type *player_ptr, int stat);
-bool lose_all_info(player_type *player_ptr);
+class PlayerType;
+bool inc_stat(PlayerType *player_ptr, int stat);
+bool dec_stat(PlayerType *player_ptr, int stat, int amount, int permanent);
+bool res_stat(PlayerType *player_ptr, int stat);
+bool do_dec_stat(PlayerType *player_ptr, int stat);
+bool do_res_stat(PlayerType *player_ptr, int stat);
+bool do_inc_stat(PlayerType *player_ptr, int stat);
+bool lose_all_info(PlayerType *player_ptr);
index 6186497..4a4f371 100644 (file)
@@ -19,7 +19,7 @@
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_protevil(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_protevil(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -61,7 +61,7 @@ bool set_protevil(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_invuln(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_invuln(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -121,7 +121,7 @@ bool set_invuln(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_regen(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_regen(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -164,7 +164,7 @@ bool set_tim_regen(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_reflect(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_reflect(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -207,7 +207,7 @@ bool set_tim_reflect(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_pass_wall(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_pass_wall(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
index 8cda63c..67114a7 100644 (file)
@@ -2,9 +2,9 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool set_protevil(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_invuln(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tim_regen(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tim_reflect(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_pass_wall(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+bool set_protevil(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_invuln(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tim_regen(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tim_reflect(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_pass_wall(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
index e6b569a..6038105 100644 (file)
@@ -26,7 +26,7 @@
 /*!
  * @brief プレイヤーの全ての時限効果をリセットする。 / reset timed flags
  */
-void reset_tim_flags(player_type *player_ptr)
+void reset_tim_flags(PlayerType *player_ptr)
 {
     auto effects = player_ptr->effects();
     player_ptr->fast = 0; /* Timed -- Fast */
@@ -110,7 +110,7 @@ void reset_tim_flags(player_type *player_ptr)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_fast(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_fast(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -152,7 +152,7 @@ bool set_fast(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_shield(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_shield(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -194,7 +194,7 @@ bool set_shield(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_magicdef(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_magicdef(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -236,7 +236,7 @@ bool set_magicdef(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_blessed(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_blessed(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -278,7 +278,7 @@ bool set_blessed(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_hero(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_hero(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -322,7 +322,7 @@ bool set_hero(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_mimic(player_type *player_ptr, TIME_EFFECT v, int16_t mimic_race_idx, bool do_dec)
+bool set_mimic(PlayerType *player_ptr, TIME_EFFECT v, int16_t mimic_race_idx, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -372,7 +372,7 @@ bool set_mimic(player_type *player_ptr, TIME_EFFECT v, int16_t mimic_race_idx, b
  * @param do_dec FALSEの場合現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_shero(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_shero(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -420,7 +420,7 @@ bool set_shero(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_wraith_form(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_wraith_form(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -476,7 +476,7 @@ bool set_wraith_form(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tsuyoshi(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tsuyoshi(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
index 71029da..bb3a98b 100644 (file)
@@ -2,14 +2,14 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void reset_tim_flags(player_type *player_ptr);
-bool set_fast(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_shield(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_magicdef(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_blessed(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_hero(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_mimic(player_type *player_ptr, TIME_EFFECT v, int16_t mimic_race_idx, bool do_dec);
-bool set_shero(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_wraith_form(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tsuyoshi(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+void reset_tim_flags(PlayerType *player_ptr);
+bool set_fast(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_shield(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_magicdef(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_blessed(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_hero(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_mimic(PlayerType *player_ptr, TIME_EFFECT v, int16_t mimic_race_idx, bool do_dec);
+bool set_shero(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_wraith_form(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tsuyoshi(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
index f5754b6..ddd4891 100644 (file)
@@ -19,7 +19,7 @@
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_oppose_acid(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_oppose_acid(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -60,7 +60,7 @@ bool set_oppose_acid(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_oppose_elec(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_oppose_elec(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -102,7 +102,7 @@ bool set_oppose_elec(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_oppose_fire(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_oppose_fire(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -145,7 +145,7 @@ bool set_oppose_fire(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_oppose_cold(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_oppose_cold(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -186,7 +186,7 @@ bool set_oppose_cold(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_oppose_pois(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_oppose_pois(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -222,29 +222,29 @@ bool set_oppose_pois(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
     return true;
 }
 
-bool is_oppose_acid(player_type *player_ptr)
+bool is_oppose_acid(PlayerType *player_ptr)
 {
     return player_ptr->oppose_acid || music_singing(player_ptr, MUSIC_RESIST) || PlayerClass(player_ptr).samurai_stance_is(SamuraiStanceType::MUSOU);
 }
 
-bool is_oppose_elec(player_type *player_ptr)
+bool is_oppose_elec(PlayerType *player_ptr)
 {
     return player_ptr->oppose_elec || music_singing(player_ptr, MUSIC_RESIST) || PlayerClass(player_ptr).samurai_stance_is(SamuraiStanceType::MUSOU);
 }
 
-bool is_oppose_fire(player_type *player_ptr)
+bool is_oppose_fire(PlayerType *player_ptr)
 {
     return player_ptr->oppose_fire || music_singing(player_ptr, MUSIC_RESIST)
         || (PlayerClass(player_ptr).samurai_stance_is(SamuraiStanceType::MUSOU) || (player_ptr->mimic_form == MIMIC_DEMON)
             || (PlayerRace(player_ptr).equals(PlayerRaceType::BALROG) && player_ptr->lev > 44));
 }
 
-bool is_oppose_cold(player_type *player_ptr)
+bool is_oppose_cold(PlayerType *player_ptr)
 {
     return player_ptr->oppose_cold || music_singing(player_ptr, MUSIC_RESIST) || PlayerClass(player_ptr).samurai_stance_is(SamuraiStanceType::MUSOU);
 }
 
-bool is_oppose_pois(player_type *player_ptr)
+bool is_oppose_pois(PlayerType *player_ptr)
 {
     return player_ptr->oppose_pois || music_singing(player_ptr, MUSIC_RESIST)
         || (PlayerClass(player_ptr).samurai_stance_is(SamuraiStanceType::MUSOU) || (player_ptr->pclass == PlayerClassType::NINJA && player_ptr->lev > 44));
index 2868817..af8f57d 100644 (file)
@@ -2,14 +2,14 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool set_oppose_acid(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_oppose_elec(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_oppose_fire(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_oppose_cold(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_oppose_pois(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool is_oppose_acid(player_type *player_ptr);
-bool is_oppose_elec(player_type *player_ptr);
-bool is_oppose_fire(player_type *player_ptr);
-bool is_oppose_cold(player_type *player_ptr);
-bool is_oppose_pois(player_type *player_ptr);
+class PlayerType;
+bool set_oppose_acid(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_oppose_elec(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_oppose_fire(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_oppose_cold(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_oppose_pois(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool is_oppose_acid(PlayerType *player_ptr);
+bool is_oppose_elec(PlayerType *player_ptr);
+bool is_oppose_fire(PlayerType *player_ptr);
+bool is_oppose_cold(PlayerType *player_ptr);
+bool is_oppose_pois(PlayerType *player_ptr);
index 7bcac15..e41c8d6 100644 (file)
@@ -6,7 +6,7 @@
 /*
  * Gain experience
  */
-void gain_exp_64(player_type *player_ptr, int32_t amount, uint32_t amount_frac)
+void gain_exp_64(PlayerType *player_ptr, int32_t amount, uint32_t amount_frac)
 {
     if (player_ptr->is_dead)
         return;
@@ -25,12 +25,12 @@ void gain_exp_64(player_type *player_ptr, int32_t amount, uint32_t amount_frac)
 /*
  * Gain experience
  */
-void gain_exp(player_type *player_ptr, int32_t amount) { gain_exp_64(player_ptr, amount, 0L); }
+void gain_exp(PlayerType *player_ptr, int32_t amount) { gain_exp_64(player_ptr, amount, 0L); }
 
 /*
  * Lose experience
  */
-void lose_exp(player_type *player_ptr, int32_t amount)
+void lose_exp(PlayerType *player_ptr, int32_t amount)
 {
     if (player_ptr->prace == PlayerRaceType::ANDROID)
         return;
@@ -45,7 +45,7 @@ void lose_exp(player_type *player_ptr, int32_t amount)
 /*
  * Restores any drained experience
  */
-bool restore_level(player_type *player_ptr)
+bool restore_level(PlayerType *player_ptr)
 {
     if (player_ptr->exp < player_ptr->max_exp) {
         msg_print(_("経験値が戻ってきた気がする。", "You feel your experience returning."));
@@ -61,7 +61,7 @@ bool restore_level(player_type *player_ptr)
  * Drain experience
  * If resisted to draining, return FALSE
  */
-bool drain_exp(player_type *player_ptr, int32_t drain, int32_t slip, int hold_exp_prob)
+bool drain_exp(PlayerType *player_ptr, int32_t drain, int32_t slip, int hold_exp_prob)
 {
     if (player_ptr->prace == PlayerRaceType::ANDROID)
         return false;
index 7549aae..978a7f2 100644 (file)
@@ -2,9 +2,9 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void gain_exp_64(player_type *player_ptr, int32_t amount, uint32_t amount_frac);
-void gain_exp(player_type *player_ptr, int32_t amount);
-bool restore_level(player_type *player_ptr);
-void lose_exp(player_type *player_ptr, int32_t amount);
-bool drain_exp(player_type *player_ptr, int32_t drain, int32_t slip, int hold_exp_prob);
+class PlayerType;
+void gain_exp_64(PlayerType *player_ptr, int32_t amount, uint32_t amount_frac);
+void gain_exp(PlayerType *player_ptr, int32_t amount);
+bool restore_level(PlayerType *player_ptr);
+void lose_exp(PlayerType *player_ptr, int32_t amount);
+bool drain_exp(PlayerType *player_ptr, int32_t drain, int32_t slip, int hold_exp_prob);
index cbcc964..8cd91f1 100644 (file)
@@ -27,7 +27,7 @@
 #include "util/enum-converter.h"
 #include "view/display-messages.h"
 
-void do_poly_wounds(player_type *player_ptr)
+void do_poly_wounds(PlayerType *player_ptr)
 {
     int16_t hit_p = (player_ptr->mhp - player_ptr->chp);
     int16_t change = damroll(player_ptr->lev, 5);
@@ -52,7 +52,7 @@ void do_poly_wounds(player_type *player_ptr)
 /*
  * Change player race
  */
-void change_race(player_type *player_ptr, PlayerRaceType new_race, concptr effect_msg)
+void change_race(PlayerType *player_ptr, PlayerRaceType new_race, concptr effect_msg)
 {
     concptr title = race_info[enum2i(new_race)].title;
     PlayerRaceType old_race = player_ptr->prace;
@@ -100,7 +100,7 @@ void change_race(player_type *player_ptr, PlayerRaceType new_race, concptr effec
     lite_spot(player_ptr, player_ptr->y, player_ptr->x);
 }
 
-void do_poly_self(player_type *player_ptr)
+void do_poly_self(PlayerType *player_ptr)
 {
     int power = player_ptr->lev;
 
index da3c580..2c16077 100644 (file)
@@ -3,7 +3,7 @@
 #include "player-info/race-types.h"
 #include "system/angband.h"
 
-struct player_type;
-void do_poly_self(player_type *player_ptr);
-void do_poly_wounds(player_type *player_ptr);
-void change_race(player_type *player_ptr, PlayerRaceType new_race, concptr effect_msg);
+class PlayerType;
+void do_poly_self(PlayerType *player_ptr);
+void do_poly_wounds(PlayerType *player_ptr);
+void change_race(PlayerType *player_ptr, PlayerRaceType new_race, concptr effect_msg);
index a2ae6e4..646a5e6 100644 (file)
@@ -16,7 +16,7 @@
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_esp(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_esp(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -59,7 +59,7 @@ bool set_tim_esp(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_invis(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_invis(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -102,7 +102,7 @@ bool set_tim_invis(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_infra(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_infra(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
index 9159d9b..1bb7180 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool set_tim_esp(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tim_invis(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tim_infra(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+bool set_tim_esp(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tim_invis(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tim_infra(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
index cbe5984..4cc61c9 100644 (file)
@@ -13,7 +13,7 @@
  * @param do_dec 現在の継続時間より長い値のみ上書きする
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  */
-bool set_tim_levitation(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_levitation(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -49,7 +49,7 @@ bool set_tim_levitation(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
     return true;
 }
 
-bool set_ultimate_res(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_ultimate_res(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -88,7 +88,7 @@ bool set_ultimate_res(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
     return true;
 }
 
-bool set_tim_res_nether(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_res_nether(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -126,7 +126,7 @@ bool set_tim_res_nether(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
     return true;
 }
 
-bool set_tim_res_time(player_type *player_ptr, TIME_EFFECT v, bool do_dec)
+bool set_tim_res_time(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
index c341d9b..416f8a8 100644 (file)
@@ -2,8 +2,8 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool set_tim_levitation(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_ultimate_res(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tim_res_nether(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
-bool set_tim_res_time(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
+class PlayerType;
+bool set_tim_levitation(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_ultimate_res(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tim_res_nether(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
+bool set_tim_res_time(PlayerType *player_ptr, TIME_EFFECT v, bool do_dec);
index 066b0c2..ce3e7fc 100644 (file)
@@ -17,7 +17,7 @@
  * Based on a suggestion by "Lee Vogt" <lvogt@cig.mcel.mot.com>
  * </pre>
  */
-bool black_market_crap(player_type *player_ptr, object_type *o_ptr)
+bool black_market_crap(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (o_ptr->is_ego())
         return false;
index 772815c..36d8673 100644 (file)
@@ -1,5 +1,5 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool black_market_crap(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool black_market_crap(PlayerType *player_ptr, object_type *o_ptr);
index 2a71e6d..57bed12 100644 (file)
@@ -51,7 +51,7 @@
  * (cast magic) into "g" (get), and "s" (search) into "d" (drop).
  * </pre>
  */
-void do_cmd_store(player_type *player_ptr)
+void do_cmd_store(PlayerType *player_ptr)
 {
     if (player_ptr->wild_mode)
         return;
index 925bbf2..42d3721 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_store(player_type *player_ptr);
+class PlayerType;
+void do_cmd_store(PlayerType *player_ptr);
index 2cdd957..cbc3137 100644 (file)
@@ -23,7 +23,7 @@
  * known, the player may have to pick stuff up and drop it again.
  * </pre>
  */
-int home_carry(player_type *player_ptr, object_type *o_ptr)
+int home_carry(PlayerType *player_ptr, object_type *o_ptr)
 {
     bool old_stack_force_notes = stack_force_notes;
     bool old_stack_force_costs = stack_force_costs;
@@ -129,7 +129,7 @@ static void sweep_reorder_store_item(object_type *o_ptr, const int i, bool *comb
     }
 }
 
-static void exe_reorder_store_item(player_type *player_ptr, bool *flag)
+static void exe_reorder_store_item(PlayerType *player_ptr, bool *flag)
 {
     for (int i = 0; i < st_ptr->stock_num; i++) {
         object_type *o_ptr;
@@ -164,7 +164,7 @@ static void exe_reorder_store_item(player_type *player_ptr, bool *flag)
  * @param store_num 店舗ID
  * @return 実際に整理が行われたならばTRUEを返す。
  */
-bool combine_and_reorder_home(player_type *player_ptr, const StoreSaleType store_num)
+bool combine_and_reorder_home(PlayerType *player_ptr, const StoreSaleType store_num)
 {
     bool old_stack_force_notes = stack_force_notes;
     bool old_stack_force_costs = stack_force_costs;
index 90ab1d7..710d292 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 struct object_type;
-struct player_type;
+class PlayerType;
 enum class StoreSaleType;
-int home_carry(player_type *player_ptr, object_type *o_ptr);
-bool combine_and_reorder_home(player_type *player_ptr, const StoreSaleType store_num);
+int home_carry(PlayerType *player_ptr, object_type *o_ptr);
+bool combine_and_reorder_home(PlayerType *player_ptr, const StoreSaleType store_num);
index 3608dbd..4840a09 100644 (file)
@@ -13,7 +13,7 @@
  * Remove an item from museum (Originally from TOband)
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void museum_remove_object(player_type *player_ptr)
+void museum_remove_object(PlayerType *player_ptr)
 {
     if (st_ptr->stock_num <= 0) {
         msg_print(_("博物館には何も置いてありません。", "The Museum is empty."));
index 2e490a1..e6a8db0 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void museum_remove_object(player_type *player_ptr);
+class PlayerType;
+void museum_remove_object(PlayerType *player_ptr);
index 8908ae6..f009d94 100644 (file)
@@ -31,7 +31,7 @@
  * "greed" value is always something (?).
  * </pre>
  */
-PRICE price_item(player_type *player_ptr, object_type *o_ptr, int greed, bool flip)
+PRICE price_item(PlayerType *player_ptr, object_type *o_ptr, int greed, bool flip)
 {
     PRICE price = object_value(o_ptr);
     if (price <= 0)
index ed8372f..4d6725d 100644 (file)
@@ -5,5 +5,5 @@
 #define LOW_PRICE_THRESHOLD 10L
 
 struct object_type;
-struct player_type;
-PRICE price_item(player_type *player_ptr, object_type *o_ptr, int greed, bool flip);
+class PlayerType;
+PRICE price_item(PlayerType *player_ptr, object_type *o_ptr, int greed, bool flip);
index 8505f3f..ca585aa 100644 (file)
@@ -46,7 +46,7 @@
  * @return プレイヤーの価格に対して店主が不服ならばTRUEを返す /
  * Return TRUE if purchase is NOT successful
  */
-static std::optional<PRICE> prompt_to_buy(player_type *player_ptr, object_type *o_ptr)
+static std::optional<PRICE> prompt_to_buy(PlayerType *player_ptr, object_type *o_ptr)
 {
     auto price_ask = price_item(player_ptr, o_ptr, ot_ptr->inflate, false);
 
@@ -97,7 +97,7 @@ static bool show_store_select_item(COMMAND_CODE *item, const int i)
  * @param i お店のストック数(アドレス渡し)
  * @param 取得元インベントリ番号
  */
-static void take_item_from_home(player_type *player_ptr, object_type *o_ptr, object_type *j_ptr, const COMMAND_CODE item)
+static void take_item_from_home(PlayerType *player_ptr, object_type *o_ptr, object_type *j_ptr, const COMMAND_CODE item)
 {
     const int amt = j_ptr->number;
     distribute_charges(o_ptr, j_ptr, amt);
@@ -131,7 +131,7 @@ static void take_item_from_home(player_type *player_ptr, object_type *o_ptr, obj
     chg_virtue(player_ptr, V_SACRIFICE, 1);
 }
 
-static void shuffle_store(player_type *player_ptr)
+static void shuffle_store(PlayerType *player_ptr)
 {
     if (!one_in_(STORE_SHUFFLE)) {
         msg_print(_("店主は新たな在庫を取り出した。", "The shopkeeper brings out some new stock."));
@@ -148,7 +148,7 @@ static void shuffle_store(player_type *player_ptr)
     prt(buf, 3, 50);
 }
 
-static void switch_store_stock(player_type *player_ptr, const int i, const COMMAND_CODE item)
+static void switch_store_stock(PlayerType *player_ptr, const int i, const COMMAND_CODE item)
 {
     if (st_ptr->stock_num == 0) {
         shuffle_store(player_ptr);
@@ -175,7 +175,7 @@ static void switch_store_stock(player_type *player_ptr, const int i, const COMMA
  * Buy an item from a store                    -RAK-
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void store_purchase(player_type *player_ptr)
+void store_purchase(PlayerType *player_ptr)
 {
     if (cur_store_num == StoreSaleType::MUSEUM) {
         msg_print(_("博物館から取り出すことはできません。", "Items cannot be taken out of the Museum."));
index 282163a..5681af1 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void store_purchase(player_type *player_ptr);
+class PlayerType;
+void store_purchase(PlayerType *player_ptr);
index f2bbf1e..054ea18 100644 (file)
@@ -41,7 +41,7 @@ concptr rumor_bind_name(char *base, concptr fullname)
     return v;
 }
 
-void display_rumor(player_type *player_ptr, bool ex)
+void display_rumor(PlayerType *player_ptr, bool ex)
 {
     char rumor[1024];
     int section = (ex && (randint0(3) == 0)) ? 1 : 0;
index 5430c6b..1b81fc7 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void display_rumor(player_type *player_ptr, bool ex);
+class PlayerType;
+void display_rumor(PlayerType *player_ptr, bool ex);
index 80d6c5d..7a7c178 100644 (file)
@@ -15,7 +15,7 @@
  * Successful haggle.
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void store_owner_says_comment(player_type *player_ptr)
+void store_owner_says_comment(PlayerType *player_ptr)
 {
     if (cur_store_num == StoreSaleType::BLACK)
         msg_print(comment_1_B[randint0(MAX_COMMENT_1)]);
@@ -37,7 +37,7 @@ void store_owner_says_comment(player_type *player_ptr)
  * @details
  * We paid "price", it was worth "value", and we thought it was worth "guess"
  */
-void purchase_analyze(player_type *player_ptr, PRICE price, PRICE value, PRICE guess)
+void purchase_analyze(PlayerType *player_ptr, PRICE price, PRICE value, PRICE guess)
 {
     /* Item was worthless, but we bought it */
     if ((value <= 0) && (price > value)) {
index 733ff6d..63c0f26 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void store_owner_says_comment(player_type *player_ptr);
-void purchase_analyze(player_type *player_ptr, PRICE price, PRICE value, PRICE guess);
+class PlayerType;
+void store_owner_says_comment(PlayerType *player_ptr);
+void purchase_analyze(PlayerType *player_ptr, PRICE price, PRICE value, PRICE guess);
index d5e50c0..d7ab538 100644 (file)
@@ -48,7 +48,7 @@
  * @param o_ptr オブジェクトの構造体参照ポインタ
  * @return 売るなら(true,売値)、売らないなら(false,0)のタプル
  */
-static std::optional<PRICE> prompt_to_sell(player_type *player_ptr, object_type *o_ptr)
+static std::optional<PRICE> prompt_to_sell(PlayerType *player_ptr, object_type *o_ptr)
 {
     auto price_ask = price_item(player_ptr, o_ptr, ot_ptr->inflate, true);
 
@@ -67,7 +67,7 @@ static std::optional<PRICE> prompt_to_sell(player_type *player_ptr, object_type
  * Sell an item to the store (or home)
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void store_sell(player_type *player_ptr)
+void store_sell(PlayerType *player_ptr)
 {
     concptr q; //!< @note プロンプトメッセージ
     concptr s_none; //!< @note 売る/置くものがない場合のメッセージ
index c39cb7d..0615dc3 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void store_sell(player_type *player_ptr);
+class PlayerType;
+void store_sell(PlayerType *player_ptr);
index 97aa227..0f613b2 100644 (file)
@@ -210,7 +210,7 @@ static bool switch_store_check(const object_type *o_ptr)
  * @note
  * Note that a shop-keeper must refuse to buy "worthless" items
  */
-bool store_will_buy(player_type *, const object_type *o_ptr)
+bool store_will_buy(PlayerType *, const object_type *o_ptr)
 {
     if ((cur_store_num == StoreSaleType::HOME) || (cur_store_num == StoreSaleType::MUSEUM))
         return true;
@@ -409,7 +409,7 @@ static byte decide_discount_rate(const PRICE cost)
  * Some objects can be sold at a "discount" (in small piles)
  * </pre>
  */
-void mass_produce(player_type *, object_type *o_ptr)
+void mass_produce(PlayerType *, object_type *o_ptr)
 {
     const PRICE cost = object_value(o_ptr);
     int size = switch_mass_production(o_ptr, cost);
index 577d5c9..e0a93ca 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
 struct object_type;
-struct player_type;
-bool store_will_buy(player_type *player_ptr, const object_type *o_ptr);
-void mass_produce(player_type *player_ptr, object_type *o_ptr);
+class PlayerType;
+bool store_will_buy(PlayerType *player_ptr, const object_type *o_ptr);
+void mass_produce(PlayerType *player_ptr, object_type *o_ptr);
index 007ad7b..d7bf88f 100644 (file)
@@ -50,7 +50,7 @@ bool leave_store = false;
  * but not in the stores, to prevent chaos.
  * </pre>
  */
-void store_process_command(player_type *player_ptr)
+void store_process_command(PlayerType *player_ptr)
 {
     repeat_check();
     if (rogue_like_commands && (command_cmd == 'l'))
index abc37b0..e4c8ee4 100644 (file)
@@ -2,5 +2,5 @@
 
 extern bool leave_store;
 
-struct player_type;
-void store_process_command(player_type *player_ptr);
+class PlayerType;
+void store_process_command(PlayerType *player_ptr);
index 0cecbbe..be0bd41 100644 (file)
@@ -127,7 +127,7 @@ static std::vector<PARAMETER_VALUE> store_same_magic_device_pvals(object_type *j
  * </pre>
  */
 void store_create(
-    player_type *player_ptr, KIND_OBJECT_IDX fix_k_idx, black_market_crap_pf black_market_crap, store_will_buy_pf store_will_buy, mass_produce_pf mass_produce)
+    PlayerType *player_ptr, KIND_OBJECT_IDX fix_k_idx, black_market_crap_pf black_market_crap, store_will_buy_pf store_will_buy, mass_produce_pf mass_produce)
 {
     if (st_ptr->stock_num >= st_ptr->stock_size)
         return;
index f5dbab5..261ca9a 100644 (file)
@@ -54,12 +54,12 @@ struct store_type {
 extern StoreSaleType cur_store_num;
 extern store_type *st_ptr;
 
-struct player_type;
-typedef bool (*black_market_crap_pf)(player_type *, object_type *);
-typedef bool (*store_will_buy_pf)(player_type *, const object_type *);
-typedef void (*mass_produce_pf)(player_type *, object_type *);
+class PlayerType;
+typedef bool (*black_market_crap_pf)(PlayerType *, object_type *);
+typedef bool (*store_will_buy_pf)(PlayerType *, const object_type *);
+typedef void (*mass_produce_pf)(PlayerType *, object_type *);
 void store_delete(void);
-void store_create(player_type *player_ptr, KIND_OBJECT_IDX k_idx, black_market_crap_pf black_market_crap, store_will_buy_pf store_will_buy, mass_produce_pf mass_produce);
+void store_create(PlayerType *player_ptr, KIND_OBJECT_IDX k_idx, black_market_crap_pf black_market_crap, store_will_buy_pf store_will_buy, mass_produce_pf mass_produce);
 void store_item_increase(INVENTORY_IDX item, ITEM_NUMBER num);
 void store_item_optimize(INVENTORY_IDX item);
 int store_carry(object_type *o_ptr);
index b4d3e38..ce95130 100644 (file)
@@ -195,7 +195,7 @@ int get_stock(COMMAND_CODE *com_val, concptr pmt, int i, int j)
  * @brief 店のアイテムを調べるコマンドのメインルーチン /
  * Examine an item in a store                     -JDL-
  */
-void store_examine(player_type *player_ptr)
+void store_examine(PlayerType *player_ptr)
 {
     if (st_ptr->stock_num <= 0) {
         if (cur_store_num == StoreSaleType::HOME)
@@ -237,7 +237,7 @@ void store_examine(player_type *player_ptr)
  * Shuffle one of the stores.
  * @param which 店舗種類のID
  */
-void store_shuffle(player_type *player_ptr, StoreSaleType which)
+void store_shuffle(PlayerType *player_ptr, StoreSaleType which)
 {
     if ((which == StoreSaleType::HOME) || (which == StoreSaleType::MUSEUM))
         return;
@@ -287,7 +287,7 @@ void store_shuffle(player_type *player_ptr, StoreSaleType which)
  * @param store_num 店舗種類のID
  * @param chance 更新商品数
  */
-void store_maintenance(player_type *player_ptr, int town_num, StoreSaleType store_num, int chance)
+void store_maintenance(PlayerType *player_ptr, int town_num, StoreSaleType store_num, int chance)
 {
     cur_store_num = store_num;
     if ((store_num == StoreSaleType::HOME) || (store_num == StoreSaleType::MUSEUM))
index fcaf50b..1cbfe9b 100644 (file)
@@ -22,11 +22,11 @@ extern int16_t inner_town_num;
 extern int cur_store_feat;
 extern bool allow_inc;
 
-struct player_type;
+class PlayerType;
 int16_t store_get_stock_max(StoreSaleType sst, bool powerup = true);
-void store_shuffle(player_type *player_ptr, StoreSaleType which);
-void store_maintenance(player_type *player_ptr, int town_num, StoreSaleType store_num, int chance);
+void store_shuffle(PlayerType *player_ptr, StoreSaleType which);
+void store_maintenance(PlayerType *player_ptr, int town_num, StoreSaleType store_num, int chance);
 void store_init(int town_num, StoreSaleType store_num);
-void store_examine(player_type *player_ptr);
+void store_examine(PlayerType *player_ptr);
 int store_check_num(object_type *o_ptr);
 int get_stock(COMMAND_CODE *com_val, concptr pmt, int i, int j);
index daa7b36..b0acd16 100644 (file)
@@ -20,7 +20,7 @@ enum class ItemKindType : short;
 enum class SmithEffectType : int16_t;
 enum class RandomArtActType : short;
 
-struct player_type;
+class PlayerType;
 typedef struct object_type {
     KIND_OBJECT_IDX k_idx{}; /*!< Kind index (zero if "dead") */
     POSITION iy{}; /*!< Y-position on map, or zero */
index 6c30be7..2d1593c 100644 (file)
@@ -5,19 +5,19 @@
 /*!
  * @brief プレイヤー構造体実体 / Static player info record
  */
-player_type p_body;
+PlayerType p_body;
 
 /*!
  * @brief プレイヤー構造体へのグローバル参照ポインタ / Pointer to the player info
  */
-player_type *p_ptr = &p_body;
+PlayerType *p_ptr = &p_body;
 
-player_type::player_type()
+PlayerType::PlayerType()
     : timed_effects(std::make_shared<TimedEffects>())
 {
 }
 
-std::shared_ptr<TimedEffects> player_type::effects() const
+std::shared_ptr<TimedEffects> PlayerType::effects() const
 {
     return this->timed_effects;
 }
index 80c79fc..31f7f38 100644 (file)
@@ -22,9 +22,9 @@ enum class MonsterAbilityType;
 struct floor_type;
 struct object_type;
 class TimedEffects;
-struct player_type {
+class PlayerType {
 public:
-    player_type();
+    PlayerType();
     int player_uid{};
     int player_euid{};
     int player_egid{};
@@ -418,4 +418,4 @@ private:
     std::shared_ptr<TimedEffects> timed_effects;
 };
 
-extern player_type *p_ptr;
+extern PlayerType *p_ptr;
index 8ceeefa..c988a58 100644 (file)
@@ -28,7 +28,7 @@
  * XAngband: determine if a given location is "interesting"
  * based on target_set_accept function.
  */
-static bool tgt_pt_accept(player_type *player_ptr, POSITION y, POSITION x)
+static bool tgt_pt_accept(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!(in_bounds(floor_ptr, y, x)))
@@ -59,7 +59,7 @@ static bool tgt_pt_accept(player_type *player_ptr, POSITION y, POSITION x)
  * XAngband: Prepare the "temp" array for "tget_pt"
  * based on target_set_prepare funciton.
  */
-static void tgt_pt_prepare(player_type *player_ptr, std::vector<POSITION> &ys, std::vector<POSITION> &xs)
+static void tgt_pt_prepare(PlayerType *player_ptr, std::vector<POSITION> &ys, std::vector<POSITION> &xs)
 {
     if (!expand_list)
         return;
@@ -114,7 +114,7 @@ struct tgt_pt_info {
     char prev_ch; //<! 前回入力キー
     std::function<bool(grid_type *)> callback; //<! 条件判定コールバック
 
-    void move_to_symbol(player_type *player_ptr);
+    void move_to_symbol(PlayerType *player_ptr);
 };
 
 /*!
@@ -123,7 +123,7 @@ struct tgt_pt_info {
  * @details 自分 (@)の位置に戻ってくるような処理に見える.
  * コールバックにも依る?
  */
-void tgt_pt_info::move_to_symbol(player_type *player_ptr)
+void tgt_pt_info::move_to_symbol(PlayerType *player_ptr)
 {
     if (!expand_list || this->ys.empty())
         return;
@@ -170,7 +170,7 @@ void tgt_pt_info::move_to_symbol(player_type *player_ptr)
  * @param y_ptr y座標への参照ポインタ
  * @return 指定したらTRUE、キャンセルしたらFALSE
  */
-bool tgt_pt(player_type *player_ptr, POSITION *x_ptr, POSITION *y_ptr)
+bool tgt_pt(PlayerType *player_ptr, POSITION *x_ptr, POSITION *y_ptr)
 {
     tgt_pt_info info;
     get_screen_size(&info.wid, &info.hgt);
index 4f152fa..fe879bb 100644 (file)
@@ -2,5 +2,5 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool tgt_pt(player_type *player_ptr, POSITION *x, POSITION *y);
+class PlayerType;
+bool tgt_pt(PlayerType *player_ptr, POSITION *x, POSITION *y);
index c969c28..05bd286 100644 (file)
@@ -87,7 +87,7 @@ static void calc_frac(projection_path_type *pp_ptr, bool is_vertical)
     pp_ptr->k++;
 }
 
-static void calc_projection_to_target(player_type *player_ptr, projection_path_type *pp_ptr, bool is_vertical)
+static void calc_projection_to_target(PlayerType *player_ptr, projection_path_type *pp_ptr, bool is_vertical)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     while (true) {
@@ -127,7 +127,7 @@ static void calc_projection_to_target(player_type *player_ptr, projection_path_t
     }
 }
 
-static bool calc_vertical_projection(player_type *player_ptr, projection_path_type *pp_ptr)
+static bool calc_vertical_projection(PlayerType *player_ptr, projection_path_type *pp_ptr)
 {
     if (pp_ptr->ay <= pp_ptr->ax)
         return false;
@@ -146,7 +146,7 @@ static bool calc_vertical_projection(player_type *player_ptr, projection_path_ty
     return true;
 }
 
-static bool calc_horizontal_projection(player_type *player_ptr, projection_path_type *pp_ptr)
+static bool calc_horizontal_projection(PlayerType *player_ptr, projection_path_type *pp_ptr)
 {
     if (pp_ptr->ax <= pp_ptr->ay)
         return false;
@@ -165,7 +165,7 @@ static bool calc_horizontal_projection(player_type *player_ptr, projection_path_
     return true;
 }
 
-static void calc_projection_others(player_type *player_ptr, projection_path_type *pp_ptr)
+static void calc_projection_others(PlayerType *player_ptr, projection_path_type *pp_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     while (true) {
@@ -212,7 +212,7 @@ static void calc_projection_others(player_type *player_ptr, projection_path_type
  * @param flag フラグID
  * @return リストの長さ
  */
-int projection_path(player_type *player_ptr, uint16_t *gp, POSITION range, POSITION y1, POSITION x1, POSITION y2, POSITION x2, BIT_FLAGS flag)
+int projection_path(PlayerType *player_ptr, uint16_t *gp, POSITION range, POSITION y1, POSITION x1, POSITION y2, POSITION x2, BIT_FLAGS flag)
 {
     if ((x1 == x2) && (y1 == y2))
         return 0;
@@ -243,7 +243,7 @@ int projection_path(player_type *player_ptr, uint16_t *gp, POSITION range, POSIT
  *
  * This is slightly (but significantly) different from "los(y1,x1,y2,x2)".
  */
-bool projectable(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2)
+bool projectable(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2)
 {
     uint16_t grid_g[512];
     int grid_n = projection_path(player_ptr, grid_g, (project_length ? project_length : get_max_range(player_ptr)), y1, x1, y2, x2, 0);
@@ -263,7 +263,7 @@ bool projectable(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2,
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return 射程
  */
-int get_max_range(player_type *player_ptr) { return player_ptr->phase_out ? 36 : 18; }
+int get_max_range(PlayerType *player_ptr) { return player_ptr->phase_out ? 36 : 18; }
 
 /*
  * Convert a "grid" (G) into a "location" (Y)
index 33d3d2b..b499baa 100644 (file)
@@ -2,9 +2,9 @@
 
 #include "system/angband.h"
 
-struct player_type;
-int projection_path(player_type *player_ptr, uint16_t *gp, POSITION range, POSITION y1, POSITION x1, POSITION y2, POSITION x2, BIT_FLAGS flg);
-bool projectable(player_type *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2);
-int get_max_range(player_type *player_ptr);
+class PlayerType;
+int projection_path(PlayerType *player_ptr, uint16_t *gp, POSITION range, POSITION y1, POSITION x1, POSITION y2, POSITION x2, BIT_FLAGS flg);
+bool projectable(PlayerType *player_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2);
+int get_max_range(PlayerType *player_ptr);
 POSITION get_grid_y(uint16_t grid);
 POSITION get_grid_x(uint16_t grid);
index ef5b866..0534650 100644 (file)
@@ -40,7 +40,7 @@ POSITION target_row;
  * The map is reprinted if necessary, and "TRUE" is returned.
  * @return 実際に再描画が必要だった場合TRUEを返す
  */
-void verify_panel(player_type *player_ptr)
+void verify_panel(PlayerType *player_ptr)
 {
     POSITION y = player_ptr->y;
     POSITION x = player_ptr->x;
@@ -117,7 +117,7 @@ void verify_panel(player_type *player_ptr)
  * Update (if necessary) and verify (if possible) the target.
  * We return TRUE if the target is "okay" and FALSE otherwise.
  */
-bool target_okay(player_type *player_ptr)
+bool target_okay(PlayerType *player_ptr)
 {
     if (target_who < 0)
         return true;
index cdda401..d0d63b4 100644 (file)
@@ -6,6 +6,6 @@ extern MONSTER_IDX target_who;
 extern POSITION target_col;
 extern POSITION target_row;
 
-struct player_type;
-void verify_panel(player_type *player_ptr);
-bool target_okay(player_type *player_ptr);
+class PlayerType;
+void verify_panel(PlayerType *player_ptr);
+bool target_okay(PlayerType *player_ptr);
index 4950afc..ddd2d44 100644 (file)
@@ -70,7 +70,7 @@ typedef struct eg_type {
     concptr name;
 } eg_type;
 
-static eg_type *initialize_eg_type(player_type *player_ptr, eg_type *eg_ptr, POSITION y, POSITION x, target_type mode, concptr info)
+static eg_type *initialize_eg_type(PlayerType *player_ptr, eg_type *eg_ptr, POSITION y, POSITION x, target_type mode, concptr info)
 {
     eg_ptr->y = y;
     eg_ptr->x = x;
@@ -94,7 +94,7 @@ static eg_type *initialize_eg_type(player_type *player_ptr, eg_type *eg_ptr, POS
 /*
  * Evaluate number of kill needed to gain level
  */
-static void evaluate_monster_exp(player_type *player_ptr, char *buf, monster_type *m_ptr)
+static void evaluate_monster_exp(PlayerType *player_ptr, char *buf, monster_type *m_ptr)
 {
     monster_race *ap_r_ptr = &r_info[m_ptr->ap_r_idx];
     if ((player_ptr->lev >= PY_MAX_LEVEL) || (player_ptr->prace == PlayerRaceType::ANDROID)) {
@@ -128,7 +128,7 @@ static void evaluate_monster_exp(player_type *player_ptr, char *buf, monster_typ
     sprintf(buf, "%03ld", (long int)num);
 }
 
-static void describe_scan_result(player_type *player_ptr, eg_type *eg_ptr)
+static void describe_scan_result(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     if (!easy_floor)
         return;
@@ -138,7 +138,7 @@ static void describe_scan_result(player_type *player_ptr, eg_type *eg_ptr)
         eg_ptr->x_info = _("x物 ", "x,");
 }
 
-static void describe_target(player_type *player_ptr, eg_type *eg_ptr)
+static void describe_target(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     if (!player_bold(player_ptr, eg_ptr->y, eg_ptr->x)) {
         eg_ptr->s1 = _("ターゲット:", "Target:");
@@ -155,7 +155,7 @@ static void describe_target(player_type *player_ptr, eg_type *eg_ptr)
 #endif
 }
 
-static process_result describe_hallucinated_target(player_type *player_ptr, eg_type *eg_ptr)
+static process_result describe_hallucinated_target(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     if (!player_ptr->hallucinated)
         return PROCESS_CONTINUE;
@@ -175,7 +175,7 @@ static process_result describe_hallucinated_target(player_type *player_ptr, eg_t
     return PROCESS_FALSE;
 }
 
-static bool describe_grid_lore(player_type *player_ptr, eg_type *eg_ptr)
+static bool describe_grid_lore(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     screen_save();
     screen_roff(player_ptr, eg_ptr->m_ptr->ap_r_idx, MONSTER_LORE_NORMAL);
@@ -185,7 +185,7 @@ static bool describe_grid_lore(player_type *player_ptr, eg_type *eg_ptr)
     return eg_ptr->query != 'r';
 }
 
-static void describe_grid_monster(player_type *player_ptr, eg_type *eg_ptr)
+static void describe_grid_monster(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     bool recall = false;
     GAME_TEXT m_name[MAX_NLEN];
@@ -235,7 +235,7 @@ static void describe_monster_person(eg_type *eg_ptr)
 #endif
 }
 
-static uint16_t describe_monster_item(player_type *player_ptr, eg_type *eg_ptr)
+static uint16_t describe_monster_item(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     for (const auto this_o_idx : eg_ptr->m_ptr->hold_o_idx_list) {
         GAME_TEXT o_name[MAX_NLEN];
@@ -267,7 +267,7 @@ static bool within_char_util(int16_t input)
     return (input > -127) && (input < 128);
 }
 
-static int16_t describe_grid(player_type *player_ptr, eg_type *eg_ptr)
+static int16_t describe_grid(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     if ((eg_ptr->g_ptr->m_idx == 0) || !player_ptr->current_floor_ptr->m_list[eg_ptr->g_ptr->m_idx].ml)
         return CONTINUOUS_DESCRIPTION;
@@ -297,7 +297,7 @@ static int16_t describe_grid(player_type *player_ptr, eg_type *eg_ptr)
     return CONTINUOUS_DESCRIPTION;
 }
 
-static int16_t describe_footing(player_type *player_ptr, eg_type *eg_ptr)
+static int16_t describe_footing(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     if (eg_ptr->floor_num != 1)
         return CONTINUOUS_DESCRIPTION;
@@ -336,7 +336,7 @@ static int16_t describe_footing_items(eg_type *eg_ptr)
     return CONTINUOUS_DESCRIPTION;
 }
 
-static char describe_footing_many_items(player_type *player_ptr, eg_type *eg_ptr, int *min_width)
+static char describe_footing_many_items(PlayerType *player_ptr, eg_type *eg_ptr, int *min_width)
 {
     while (true) {
         screen_save();
@@ -364,7 +364,7 @@ static char describe_footing_many_items(player_type *player_ptr, eg_type *eg_ptr
     }
 }
 
-static int16_t loop_describing_grid(player_type *player_ptr, eg_type *eg_ptr)
+static int16_t loop_describing_grid(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     if (eg_ptr->floor_num == 0)
         return CONTINUOUS_DESCRIPTION;
@@ -383,7 +383,7 @@ static int16_t loop_describing_grid(player_type *player_ptr, eg_type *eg_ptr)
     }
 }
 
-static int16_t describe_footing_sight(player_type *player_ptr, eg_type *eg_ptr, object_type *o_ptr)
+static int16_t describe_footing_sight(PlayerType *player_ptr, eg_type *eg_ptr, object_type *o_ptr)
 {
     if ((o_ptr->marked & OM_FOUND) == 0)
         return CONTINUOUS_DESCRIPTION;
@@ -418,7 +418,7 @@ static int16_t describe_footing_sight(player_type *player_ptr, eg_type *eg_ptr,
     return CONTINUOUS_DESCRIPTION;
 }
 
-static int16_t sweep_footing_items(player_type *player_ptr, eg_type *eg_ptr)
+static int16_t sweep_footing_items(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     for (const auto this_o_idx : eg_ptr->g_ptr->o_idx_list) {
         object_type *o_ptr;
@@ -431,7 +431,7 @@ static int16_t sweep_footing_items(player_type *player_ptr, eg_type *eg_ptr)
     return CONTINUOUS_DESCRIPTION;
 }
 
-static concptr decide_target_floor(player_type *player_ptr, eg_type *eg_ptr)
+static concptr decide_target_floor(PlayerType *player_ptr, eg_type *eg_ptr)
 {
     if (eg_ptr->f_ptr->flags.has(FloorFeatureType::QUEST_ENTER)) {
         QUEST_IDX old_quest = player_ptr->current_floor_ptr->inside_quest;
@@ -499,7 +499,7 @@ static void describe_grid_monster_all(eg_type *eg_ptr)
  * @return 入力キー
  * @todo xとlで処理を分ける?
  */
-char examine_grid(player_type *player_ptr, const POSITION y, const POSITION x, target_type mode, concptr info)
+char examine_grid(PlayerType *player_ptr, const POSITION y, const POSITION x, target_type mode, concptr info)
 {
     eg_type tmp_eg;
     eg_type *eg_ptr = initialize_eg_type(player_ptr, &tmp_eg, y, x, mode, info);
index 68d26fb..ceaecd4 100644 (file)
@@ -5,5 +5,5 @@
 extern bool show_gold_on_floor;
 
 enum target_type : uint32_t;
-struct player_type;
-char examine_grid(player_type *player_ptr, const POSITION y, const POSITION x, target_type mode, concptr info);
+class PlayerType;
+char examine_grid(PlayerType *player_ptr, const POSITION y, const POSITION x, target_type mode, concptr info);
index 7066c50..bae71a5 100644 (file)
@@ -30,7 +30,7 @@
  *
  * Note that confusion over-rides any (explicit?) user choice.
  */
-bool get_aim_dir(player_type *player_ptr, DIRECTION *dp)
+bool get_aim_dir(PlayerType *player_ptr, DIRECTION *dp)
 {
     DIRECTION dir = command_dir;
     if (use_old_target && target_okay(player_ptr))
@@ -100,7 +100,7 @@ bool get_aim_dir(player_type *player_ptr, DIRECTION *dp)
     return true;
 }
 
-bool get_direction(player_type *player_ptr, DIRECTION *dp, bool allow_under, bool with_steed)
+bool get_direction(PlayerType *player_ptr, DIRECTION *dp, bool allow_under, bool with_steed)
 {
     DIRECTION dir = command_dir;
     COMMAND_CODE code;
@@ -186,7 +186,7 @@ bool get_direction(player_type *player_ptr, DIRECTION *dp, bool allow_under, boo
  * This function tracks and uses the "global direction", and uses
  * that as the "desired direction", to which "confusion" is applied.
  */
-bool get_rep_dir(player_type *player_ptr, DIRECTION *dp, bool under)
+bool get_rep_dir(PlayerType *player_ptr, DIRECTION *dp, bool under)
 {
     DIRECTION dir = command_dir;
     COMMAND_CODE code;
index ed691b9..0024ca8 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool get_aim_dir(player_type *player_ptr, DIRECTION *dp);
-bool get_direction(player_type *player_ptr, DIRECTION *dp, bool allow_under, bool with_steed);
-bool get_rep_dir(player_type *player_ptr, DIRECTION *dp, bool under);
+class PlayerType;
+bool get_aim_dir(PlayerType *player_ptr, DIRECTION *dp);
+bool get_direction(PlayerType *player_ptr, DIRECTION *dp, bool allow_under, bool with_steed);
+bool get_rep_dir(PlayerType *player_ptr, DIRECTION *dp, bool under);
index 8e93aa2..f01b9c2 100644 (file)
@@ -38,7 +38,7 @@
  * Future versions may restrict the ability to target "trappers"
  * and "mimics", but the semantics is a little bit weird.
  */
-bool target_able(player_type *player_ptr, MONSTER_IDX m_idx)
+bool target_able(PlayerType *player_ptr, MONSTER_IDX m_idx)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     monster_type *m_ptr = &floor_ptr->m_list[m_idx];
@@ -63,7 +63,7 @@ bool target_able(player_type *player_ptr, MONSTER_IDX m_idx)
 /*
  * Determine if a given location is "interesting"
  */
-static bool target_set_accept(player_type *player_ptr, POSITION y, POSITION x)
+static bool target_set_accept(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!(in_bounds(floor_ptr, y, x)))
@@ -110,7 +110,7 @@ static bool target_set_accept(player_type *player_ptr, POSITION y, POSITION x)
  *
  * ys, xs は処理開始時にクリアされる。
  */
-void target_set_prepare(player_type *player_ptr, std::vector<POSITION> &ys, std::vector<POSITION> &xs, const BIT_FLAGS mode)
+void target_set_prepare(PlayerType *player_ptr, std::vector<POSITION> &ys, std::vector<POSITION> &xs, const BIT_FLAGS mode)
 {
     POSITION min_hgt, max_hgt, min_wid, max_wid;
     if (mode & TARGET_KILL) {
@@ -162,7 +162,7 @@ void target_set_prepare(player_type *player_ptr, std::vector<POSITION> &ys, std:
     std::swap(xs[0], xs[1]);
 }
 
-void target_sensing_monsters_prepare(player_type *player_ptr, std::vector<MONSTER_IDX> &monster_list)
+void target_sensing_monsters_prepare(PlayerType *player_ptr, std::vector<MONSTER_IDX> &monster_list)
 {
     monster_list.clear();
 
index 68757f1..90f5a7e 100644 (file)
@@ -4,7 +4,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-bool target_able(player_type *player_ptr, MONSTER_IDX m_idx);
-void target_set_prepare(player_type *player_ptr, std::vector<POSITION> &ys, std::vector<POSITION> &xs, BIT_FLAGS mode);
-void target_sensing_monsters_prepare(player_type *player_ptr, std::vector<MONSTER_IDX> &monster_list);
+class PlayerType;
+bool target_able(PlayerType *player_ptr, MONSTER_IDX m_idx);
+void target_set_prepare(PlayerType *player_ptr, std::vector<POSITION> &ys, std::vector<POSITION> &xs, BIT_FLAGS mode);
+void target_sensing_monsters_prepare(PlayerType *player_ptr, std::vector<MONSTER_IDX> &monster_list);
index 5bd7037..a6a2c2d 100644 (file)
@@ -51,7 +51,7 @@ typedef struct ts_type {
     bool move_fast; // カーソル移動を粗くする(1マスずつ移動しない)
 } ts_type;
 
-static ts_type *initialize_target_set_type(player_type *player_ptr, ts_type *ts_ptr, target_type mode)
+static ts_type *initialize_target_set_type(PlayerType *player_ptr, ts_type *ts_ptr, target_type mode)
 {
     ts_ptr->mode = mode;
     ts_ptr->y = player_ptr->y;
@@ -74,7 +74,7 @@ static ts_type *initialize_target_set_type(player_type *player_ptr, ts_type *ts_
  * Also used in do_cmd_locate
  * @return 実際に再描画が必要だった場合TRUEを返す
  */
-static bool change_panel_xy(player_type *player_ptr, POSITION y, POSITION x)
+static bool change_panel_xy(PlayerType *player_ptr, POSITION y, POSITION x)
 {
     POSITION dy = 0, dx = 0;
     TERM_LEN wid, hgt;
@@ -154,7 +154,7 @@ static POSITION_IDX target_pick(const POSITION y1, const POSITION x1, const POSI
     return b_i;
 }
 
-static void describe_projectablity(player_type *player_ptr, ts_type *ts_ptr)
+static void describe_projectablity(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     ts_ptr->y = ys_interest[ts_ptr->m];
     ts_ptr->x = xs_interest[ts_ptr->m];
@@ -186,7 +186,7 @@ static void menu_target(ts_type *ts_ptr)
         ts_ptr->query = 't';
 }
 
-static void switch_target_input(player_type *player_ptr, ts_type *ts_ptr)
+static void switch_target_input(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     ts_ptr->distance = 0;
     switch (ts_ptr->query) {
@@ -271,7 +271,7 @@ static void switch_target_input(player_type *player_ptr, ts_type *ts_ptr)
  * @brief カーソル移動に伴い、描画範囲、"interesting" 座標リスト、現在のターゲットを更新する。
  * @return カーソル移動によって描画範囲が変化したかどうか
  */
-static bool check_panel_changed(player_type *player_ptr, ts_type *ts_ptr)
+static bool check_panel_changed(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     // カーソル移動によって描画範囲が変化しないなら何もせずその旨を返す。
     if (!change_panel(player_ptr, ddy[ts_ptr->distance], ddx[ts_ptr->distance]))
@@ -308,7 +308,7 @@ static bool check_panel_changed(player_type *player_ptr, ts_type *ts_ptr)
  *
  * 既に "interesting" な座標を発見している場合、この関数は何もしない。
  */
-static void sweep_targets(player_type *player_ptr, ts_type *ts_ptr)
+static void sweep_targets(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     while (ts_ptr->flag && (ts_ptr->target_num < 0)) {
@@ -354,7 +354,7 @@ static void sweep_targets(player_type *player_ptr, ts_type *ts_ptr)
     }
 }
 
-static bool set_target_grid(player_type *player_ptr, ts_type *ts_ptr)
+static bool set_target_grid(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     if (!ts_ptr->flag || ys_interest.empty())
         return false;
@@ -385,7 +385,7 @@ static bool set_target_grid(player_type *player_ptr, ts_type *ts_ptr)
     return true;
 }
 
-static void describe_grid_wizard(player_type *player_ptr, ts_type *ts_ptr)
+static void describe_grid_wizard(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     if (!cheat_sight)
         return;
@@ -396,7 +396,7 @@ static void describe_grid_wizard(player_type *player_ptr, ts_type *ts_ptr)
     strcat(ts_ptr->info, cheatinfo);
 }
 
-static void switch_next_grid_command(player_type *player_ptr, ts_type *ts_ptr)
+static void switch_next_grid_command(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     switch (ts_ptr->query) {
     case ESCAPE:
@@ -459,7 +459,7 @@ static void switch_next_grid_command(player_type *player_ptr, ts_type *ts_ptr)
     }
 }
 
-static void decide_change_panel(player_type *player_ptr, ts_type *ts_ptr)
+static void decide_change_panel(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     if (ts_ptr->distance == 0)
         return;
@@ -499,7 +499,7 @@ static void decide_change_panel(player_type *player_ptr, ts_type *ts_ptr)
         ts_ptr->y = 1;
 }
 
-static void sweep_target_grids(player_type *player_ptr, ts_type *ts_ptr)
+static void sweep_target_grids(PlayerType *player_ptr, ts_type *ts_ptr)
 {
     while (!ts_ptr->done) {
         if (set_target_grid(player_ptr, ts_ptr))
@@ -530,7 +530,7 @@ static void sweep_target_grids(player_type *player_ptr, ts_type *ts_ptr)
 /*
  * Handle "target" and "look".
  */
-bool target_set(player_type *player_ptr, target_type mode)
+bool target_set(PlayerType *player_ptr, target_type mode)
 {
     ts_type tmp_ts;
     ts_type *ts_ptr = initialize_target_set_type(player_ptr, &tmp_ts, mode);
index d9c1194..aa1ed54 100644 (file)
@@ -3,5 +3,5 @@
 #include<stdint.h>
 
 enum target_type : uint32_t;
-struct player_type;
-bool target_set(player_type *player_ptr, target_type mode);
+class PlayerType;
+bool target_set(PlayerType *player_ptr, target_type mode);
index a69c8bd..cc7d52e 100644 (file)
@@ -21,7 +21,7 @@
  * @param j_ptr 比較対象オブジェクトの構造体参照ポインタ2
  * @return o_ptrの方が上位ならばTRUEを返す。
  */
-bool object_sort_comp(player_type *player_ptr, object_type *o_ptr, int32_t o_value, object_type *j_ptr)
+bool object_sort_comp(PlayerType *player_ptr, object_type *o_ptr, int32_t o_value, object_type *j_ptr)
 {
     int o_type, j_type;
     if (!j_ptr->k_idx)
index 7525290..13d32cb 100644 (file)
@@ -3,5 +3,5 @@
 #include "system/angband.h"
 
 struct object_type;
-struct player_type;
-bool object_sort_comp(player_type *player_ptr, object_type *o_ptr, int32_t o_value, object_type *j_ptr);
+class PlayerType;
+bool object_sort_comp(PlayerType *player_ptr, object_type *o_ptr, int32_t o_value, object_type *j_ptr);
index d140325..b5cfe42 100644 (file)
@@ -21,8 +21,8 @@
  * @param ang_sort_comp 比較用の関数ポインタ
  * @param ang_sort_swap スワップ用の関数ポインタ
  */
-static void exe_ang_sort(player_type *player_ptr, vptr u, vptr v, int p, int q, bool (*ang_sort_comp)(player_type *, vptr, vptr, int, int),
-    void (*ang_sort_swap)(player_type *, vptr, vptr, int, int))
+static void exe_ang_sort(PlayerType *player_ptr, vptr u, vptr v, int p, int q, bool (*ang_sort_comp)(PlayerType *, vptr, vptr, int, int),
+    void (*ang_sort_swap)(PlayerType *, vptr, vptr, int, int))
 {
     if (p >= q)
         return;
@@ -63,8 +63,8 @@ static void exe_ang_sort(player_type *player_ptr, vptr u, vptr v, int p, int q,
  * @param ang_sort_comp 比較用の関数ポインタ
  * @param ang_sort_swap スワップ用の関数ポインタ
  */
-void ang_sort(player_type *player_ptr, vptr u, vptr v, int n, bool (*ang_sort_comp)(player_type *, vptr, vptr, int, int),
-    void (*ang_sort_swap)(player_type *, vptr, vptr, int, int))
+void ang_sort(PlayerType *player_ptr, vptr u, vptr v, int n, bool (*ang_sort_comp)(PlayerType *, vptr, vptr, int, int),
+    void (*ang_sort_swap)(PlayerType *, vptr, vptr, int, int))
 {
     exe_ang_sort(player_ptr, u, v, 0, n - 1, ang_sort_comp, ang_sort_swap);
 }
@@ -75,7 +75,7 @@ void ang_sort(player_type *player_ptr, vptr u, vptr v, int n, bool (*ang_sort_co
  * We use "u" and "v" to point to arrays of "x" and "y" positions,
  * and sort the arrays by double-distance to the player.
  */
-bool ang_sort_comp_distance(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_comp_distance(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     POSITION *x = (POSITION *)(u);
     POSITION *y = (POSITION *)(v);
@@ -112,7 +112,7 @@ bool ang_sort_comp_distance(player_type *player_ptr, vptr u, vptr v, int a, int
  * We use "u" and "v" to point to arrays of "x" and "y" positions,
  * and sort the arrays by level of monster
  */
-bool ang_sort_comp_importance(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_comp_importance(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     POSITION *x = (POSITION *)(u);
     POSITION *y = (POSITION *)(v);
@@ -205,7 +205,7 @@ bool ang_sort_comp_importance(player_type *player_ptr, vptr u, vptr v, int a, in
  * We use "u" and "v" to point to arrays of "x" and "y" positions,
  * and sort the arrays by distance to the player.
  */
-void ang_sort_swap_position(player_type *player_ptr, vptr u, vptr v, int a, int b)
+void ang_sort_swap_position(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -228,7 +228,7 @@ void ang_sort_swap_position(player_type *player_ptr, vptr u, vptr v, int a, int
  * We use "u" to point to array of monster indexes,
  * and "v" to select the type of sorting to perform on "u".
  */
-bool ang_sort_art_comp(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_art_comp(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -293,7 +293,7 @@ bool ang_sort_art_comp(player_type *player_ptr, vptr u, vptr v, int a, int b)
  * We use "u" to point to array of monster indexes,
  * and "v" to select the type of sorting to perform.
  */
-void ang_sort_art_swap(player_type *player_ptr, vptr u, vptr v, int a, int b)
+void ang_sort_art_swap(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -305,7 +305,7 @@ void ang_sort_art_swap(player_type *player_ptr, vptr u, vptr v, int a, int b)
     who[b] = holder;
 }
 
-bool ang_sort_comp_quest_num(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_comp_quest_num(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -317,7 +317,7 @@ bool ang_sort_comp_quest_num(player_type *player_ptr, vptr u, vptr v, int a, int
     return (qa->comptime != qb->comptime) ? (qa->comptime < qb->comptime) : (qa->level <= qb->level);
 }
 
-void ang_sort_swap_quest_num(player_type *player_ptr, vptr u, vptr v, int a, int b)
+void ang_sort_swap_quest_num(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -337,7 +337,7 @@ void ang_sort_swap_quest_num(player_type *player_ptr, vptr u, vptr v, int a, int
  * @param b 所持品ID2
  * @return 1の方が大であればTRUE
  */
-bool ang_sort_comp_pet(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_comp_pet(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)v;
@@ -390,7 +390,7 @@ bool ang_sort_comp_pet(player_type *player_ptr, vptr u, vptr v, int a, int b)
  * We use "u" to point to array of monster indexes,
  * and "v" to select the type of sorting to perform on "u".
  */
-bool ang_sort_comp_hook(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_comp_hook(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -470,7 +470,7 @@ bool ang_sort_comp_hook(player_type *player_ptr, vptr u, vptr v, int a, int b)
  * We use "u" to point to array of monster indexes,
  * and "v" to select the type of sorting to perform.
  */
-void ang_sort_swap_hook(player_type *player_ptr, vptr u, vptr v, int a, int b)
+void ang_sort_swap_hook(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -487,7 +487,7 @@ void ang_sort_swap_hook(player_type *player_ptr, vptr u, vptr v, int a, int b)
 /*
  * hook function to sort monsters by level
  */
-bool ang_sort_comp_monster_level(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_comp_monster_level(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -524,7 +524,7 @@ bool ang_sort_comp_monster_level(player_type *player_ptr, vptr u, vptr v, int a,
  * @param b 比較対象のモンスターID2
  * @return 2番目が大ならばTRUEを返す
  */
-bool ang_sort_comp_pet_dismiss(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_comp_pet_dismiss(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)v;
@@ -586,7 +586,7 @@ bool ang_sort_comp_pet_dismiss(player_type *player_ptr, vptr u, vptr v, int a, i
  * @param b スワップするモンスター種族のID2
  * @return aの方が大きければtrue
  */
-bool ang_sort_comp_cave_temp(player_type *player_ptr, vptr u, vptr v, int a, int b)
+bool ang_sort_comp_cave_temp(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
@@ -607,7 +607,7 @@ bool ang_sort_comp_cave_temp(player_type *player_ptr, vptr u, vptr v, int a, int
  * @param a スワップするモンスター種族のID1
  * @param b スワップするモンスター種族のID2
  */
-void ang_sort_swap_cave_temp(player_type *player_ptr, vptr u, vptr v, int a, int b)
+void ang_sort_swap_cave_temp(PlayerType *player_ptr, vptr u, vptr v, int a, int b)
 {
     /* Unused */
     (void)player_ptr;
index 3a5acc1..24de67b 100644 (file)
@@ -3,26 +3,26 @@
 #include "system/angband.h"
 
 #include "system/player-type-definition.h"
-void ang_sort(player_type *player_ptr, vptr u, vptr v, int n, bool (*ang_sort_comp)(player_type *, vptr, vptr, int, int),
-    void (*ang_sort_swap)(player_type *, vptr, vptr, int, int));
+void ang_sort(PlayerType *player_ptr, vptr u, vptr v, int n, bool (*ang_sort_comp)(PlayerType *, vptr, vptr, int, int),
+    void (*ang_sort_swap)(PlayerType *, vptr, vptr, int, int));
 
-bool ang_sort_comp_distance(player_type *player_ptr, vptr u, vptr v, int a, int b);
-bool ang_sort_comp_importance(player_type *player_ptr, vptr u, vptr v, int a, int b);
-void ang_sort_swap_position(player_type *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_comp_distance(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_comp_importance(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
+void ang_sort_swap_position(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
 
-bool ang_sort_art_comp(player_type *player_ptr, vptr u, vptr v, int a, int b);
-void ang_sort_art_swap(player_type *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_art_comp(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
+void ang_sort_art_swap(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
 
-bool ang_sort_comp_quest_num(player_type *player_ptr, vptr u, vptr v, int a, int b);
-void ang_sort_swap_quest_num(player_type *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_comp_quest_num(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
+void ang_sort_swap_quest_num(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
 
-bool ang_sort_comp_pet(player_type *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_comp_pet(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
 
-bool ang_sort_comp_hook(player_type *player_ptr, vptr u, vptr v, int a, int b);
-void ang_sort_swap_hook(player_type *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_comp_hook(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
+void ang_sort_swap_hook(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
 
-bool ang_sort_comp_monster_level(player_type *player_ptr, vptr u, vptr v, int a, int b);
-bool ang_sort_comp_pet_dismiss(player_type *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_comp_monster_level(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_comp_pet_dismiss(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
 
-bool ang_sort_comp_cave_temp(player_type *player_ptr, vptr u, vptr v, int a, int b);
-void ang_sort_swap_cave_temp(player_type *player_ptr, vptr u, vptr v, int a, int b);
+bool ang_sort_comp_cave_temp(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
+void ang_sort_swap_cave_temp(PlayerType *player_ptr, vptr u, vptr v, int a, int b);
index 18fd81e..243a5c0 100644 (file)
@@ -14,7 +14,7 @@
  * @brief オートロール中のステータスを表示する / Display stat values, subset of "put_stats()"
  * @details See 'display_player(p_ptr, )' for screen layout constraints.
  */
-void birth_put_stats(player_type *player_ptr)
+void birth_put_stats(PlayerType *player_ptr)
 {
     if (!autoroller)
         return;
index fdad547..b038c6d 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void birth_put_stats(player_type *player_ptr);
+class PlayerType;
+void birth_put_stats(PlayerType *player_ptr);
index 68fb960..fb93a90 100644 (file)
@@ -102,7 +102,7 @@ static std::array<tr_type, 6> lite_flags = {
  * @param char_stat その行の特性の状況(参照渡し)
  * その行の表示色用の判定も行う
  */
-static void process_cursed_equipment_characteristics(player_type *player_ptr, uint16_t mode, char_stat &char_stat)
+static void process_cursed_equipment_characteristics(PlayerType *player_ptr, uint16_t mode, char_stat &char_stat)
 {
     int max_i = (mode & DP_WP) ? INVEN_BOW + 1 : INVEN_TOTAL;
     for (int i = INVEN_MAIN_HAND; i < max_i; i++) {
@@ -151,7 +151,7 @@ static void process_cursed_equipment_characteristics(player_type *player_ptr, ui
  * @details
  * その行の表示色用の判定も行う
  */
-static void process_light_equipment_characteristics(player_type *player_ptr, all_player_flags *f, uint16_t mode, char_stat &char_stat)
+static void process_light_equipment_characteristics(PlayerType *player_ptr, all_player_flags *f, uint16_t mode, char_stat &char_stat)
 {
     int max_i = (mode & DP_WP) ? INVEN_BOW + 1 : INVEN_TOTAL;
     for (int i = INVEN_MAIN_HAND; i < max_i; i++) {
@@ -200,7 +200,7 @@ static void process_light_equipment_characteristics(player_type *player_ptr, all
  * @details
  * その行の表示色用の判定も行う
  */
-static void process_inventory_characteristic(player_type *player_ptr, tr_type flag, all_player_flags *f, uint16_t mode, char_stat &char_stat)
+static void process_inventory_characteristic(PlayerType *player_ptr, tr_type flag, all_player_flags *f, uint16_t mode, char_stat &char_stat)
 {
     int max_i = (mode & DP_WP) ? INVEN_BOW + 1 : INVEN_TOTAL;
     for (int i = INVEN_MAIN_HAND; i < max_i; i++) {
@@ -263,7 +263,7 @@ static void process_inventory_characteristic(player_type *player_ptr, tr_type fl
  * @param f プレイヤーの特性情報構造体
  * @param mode 表示オプション
  */
-static void process_one_characteristic(player_type *player_ptr, TERM_LEN row, TERM_LEN col, std::string_view header, tr_type flag, all_player_flags *f, uint16_t mode)
+static void process_one_characteristic(PlayerType *player_ptr, TERM_LEN row, TERM_LEN col, std::string_view header, tr_type flag, all_player_flags *f, uint16_t mode)
 {
     char_stat char_stat;
 
@@ -318,7 +318,7 @@ static void process_one_characteristic(player_type *player_ptr, TERM_LEN row, TE
  * @param f 特性フラグへの参照ポインタ
  */
 static void display_basic_resistance_info(
-    player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+    PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 12;
     TERM_LEN col = 1;
@@ -344,7 +344,7 @@ static void display_basic_resistance_info(
  * @param f 特性フラグへの参照ポインタ
  */
 static void display_advanced_resistance_info(
-    player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+    PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 12;
     TERM_LEN col = 26;
@@ -369,7 +369,7 @@ static void display_advanced_resistance_info(
  * @param f 特性フラグへの参照ポインタ
  */
 static void display_other_resistance_info(
-    player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+    PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 12;
     TERM_LEN col = 51;
@@ -393,7 +393,7 @@ static void display_other_resistance_info(
  * @param player_ptr プレイヤーへの参照ポインタ
  * @todo 将来的には装備系とまとめたいが、乗馬による特性変化や一時能力変化等の扱いがあるので据え置き。
  */
- all_player_flags get_player_state_flags(player_type *player_ptr)
+ all_player_flags get_player_state_flags(PlayerType *player_ptr)
 {
     all_player_flags f;
     player_flags(player_ptr, f.player_flags);
@@ -412,7 +412,7 @@ static void display_other_resistance_info(
  * @param display_player_equippy 表示へのコールバック
  * Special display, part 1
  */
-void display_player_flag_info_1(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16))
+void display_player_flag_info_1(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16))
 {
     all_player_flags f = get_player_state_flags(player_ptr);
 
@@ -427,7 +427,7 @@ void display_player_flag_info_1(player_type *player_ptr, void (*display_player_e
  * @param display_player_equippy 表示へのコールバック
  * @param f 特性フラグへの参照ポインタ
  */
-static void display_slay_info(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+static void display_slay_info(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 3;
     TERM_LEN col = 1;
@@ -452,7 +452,7 @@ static void display_slay_info(player_type *player_ptr, void (*display_player_equ
  * @param display_player_equippy 表示へのコールバック
  * @param f 特性フラグへの参照ポインタ
  */
-static void display_brand_info(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+static void display_brand_info(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 3;
     TERM_LEN col = 1;
@@ -481,7 +481,7 @@ static void display_brand_info(player_type *player_ptr, void (*display_player_eq
  * @param f 特性フラグへの参照ポインタ
  */
 static void display_tval_misc_info(
-    player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+    PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 3;
     TERM_LEN col = 49;
@@ -511,7 +511,7 @@ static void display_tval_misc_info(
  * @param display_player_equippy 表示へのコールバック
  * @param f 特性フラグへの参照ポインタ
  */
-static void display_esc_info(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+static void display_esc_info(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 3;
     TERM_LEN col = 21;
@@ -540,7 +540,7 @@ static void display_esc_info(player_type *player_ptr, void (*display_player_equi
  * @param f 特性フラグへの参照ポインタ
  */
 static void display_stustain_aura_info(
-    player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+    PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 3;
     TERM_LEN col = 21;
@@ -570,7 +570,7 @@ static void display_stustain_aura_info(
  * @param display_player_equippy 表示へのコールバック
  * @param f 特性フラグへの参照ポインタ
  */
-static void display_curse_info(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
+static void display_curse_info(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16), all_player_flags *f)
 {
     TERM_LEN row = 3;
     TERM_LEN col = 49;
@@ -600,7 +600,7 @@ static void display_curse_info(player_type *player_ptr, void (*display_player_eq
  * @param player_ptr プレイヤーへの参照ポインタ
  * Special display, part 2
  */
-void display_player_flag_info_2(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16))
+void display_player_flag_info_2(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16))
 {
     /* Extract flags and store */
     all_player_flags f = get_player_state_flags(player_ptr);
@@ -615,7 +615,7 @@ void display_player_flag_info_2(player_type *player_ptr, void (*display_player_e
  * @param player_ptr プレイヤーへの参照ポインタ
  * Special display, part 3
  */
-void display_player_flag_info_3(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16))
+void display_player_flag_info_3(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16))
 {
     /* Extract flags and store */
     all_player_flags f = get_player_state_flags(player_ptr);
index e1704e7..33deeab 100644 (file)
@@ -7,7 +7,7 @@
 #define DP_CURSE 1<<1L
 #define DP_LITE 1<<2L
 
-struct player_type;
-void display_player_flag_info_1(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16));
-void display_player_flag_info_2(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16));
-void display_player_flag_info_3(player_type *player_ptr, void (*display_player_equippy)(player_type *, TERM_LEN, TERM_LEN, BIT_FLAGS16));
+class PlayerType;
+void display_player_flag_info_1(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16));
+void display_player_flag_info_2(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16));
+void display_player_flag_info_3(PlayerType *player_ptr, void (*display_player_equippy)(PlayerType *, TERM_LEN, TERM_LEN, BIT_FLAGS16));
index acf51e1..d310751 100644 (file)
@@ -24,7 +24,7 @@
  * @details
  * Hack -- do not display "trailing" empty slots
  */
-COMMAND_CODE show_inventory(player_type *player_ptr, int target_item, BIT_FLAGS mode, const ItemTester &item_tester)
+COMMAND_CODE show_inventory(PlayerType *player_ptr, int target_item, BIT_FLAGS mode, const ItemTester &item_tester)
 {
     COMMAND_CODE i;
     int k, l, z = 0;
@@ -127,7 +127,7 @@ COMMAND_CODE show_inventory(player_type *player_ptr, int target_item, BIT_FLAGS
  * @brief 所持アイテム一覧を表示する /
  * Choice window "shadow" of the "show_inven()" function
  */
-void display_inventory(player_type *player_ptr, const ItemTester &item_tester)
+void display_inventory(PlayerType *player_ptr, const ItemTester &item_tester)
 {
     int i, n, z = 0;
     TERM_COLOR attr = TERM_WHITE;
index 831ad05..62596a3 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
+class PlayerType;
 class ItemTester;
-COMMAND_CODE show_inventory(player_type *player_ptr, int target_item, BIT_FLAGS mode, const ItemTester& item_tester);
-COMMAND_CODE show_equipment(player_type *player_ptr, int target_item, BIT_FLAGS mode, const ItemTester& item_tester);
+COMMAND_CODE show_inventory(PlayerType *player_ptr, int target_item, BIT_FLAGS mode, const ItemTester& item_tester);
+COMMAND_CODE show_equipment(PlayerType *player_ptr, int target_item, BIT_FLAGS mode, const ItemTester& item_tester);
index ec6958e..424e575 100644 (file)
@@ -80,7 +80,7 @@ void roff_top(MONRACE_IDX r_idx)
  * @param r_idx モンスターの種族ID
  * @param mode 表示オプション
  */
-void screen_roff(player_type *player_ptr, MONRACE_IDX r_idx, monster_lore_mode mode)
+void screen_roff(PlayerType *player_ptr, MONRACE_IDX r_idx, monster_lore_mode mode)
 {
     msg_erase();
     term_erase(0, 1, 255);
@@ -94,7 +94,7 @@ void screen_roff(player_type *player_ptr, MONRACE_IDX r_idx, monster_lore_mode m
  * Hack -- describe the given monster race in the current "term" window
  * @param r_idx モンスターの種族ID
  */
-void display_roff(player_type *player_ptr)
+void display_roff(PlayerType *player_ptr)
 {
     for (int y = 0; y < Term->hgt; y++) {
         term_erase(0, y, 255);
@@ -117,7 +117,7 @@ void display_roff(player_type *player_ptr)
 void output_monster_spoiler(MONRACE_IDX r_idx, void (*roff_func)(TERM_COLOR attr, concptr str))
 {
     hook_c_roff = roff_func;
-    player_type dummy;
+    PlayerType dummy;
 
     dummy.lev = 1;
     dummy.max_plv = 1;
@@ -400,7 +400,7 @@ void display_monster_alignment(lore_type *lore_ptr)
  * @param player_ptr プレイヤーの情報へのポインター
  * @param lore_ptr モンスターの思い出の情報へのポインター
  */
-void display_monster_exp(player_type *player_ptr, lore_type *lore_ptr)
+void display_monster_exp(PlayerType *player_ptr, lore_type *lore_ptr)
 {
 #ifdef JP
     hooked_roff("を倒すことは");
@@ -471,7 +471,7 @@ void display_monster_aura(lore_type *lore_ptr)
         hook_c_roff(TERM_L_BLUE, format(_("%^sはスパークに包まれている。", "%^s is surrounded by electricity.  "), Who::who(lore_ptr->msex)));
 }
 
-void display_lore_this(player_type *player_ptr, lore_type *lore_ptr)
+void display_lore_this(PlayerType *player_ptr, lore_type *lore_ptr)
 {
     if ((lore_ptr->r_ptr->r_tkills == 0) && !lore_ptr->know_everything)
         return;
@@ -554,7 +554,7 @@ void display_monster_collective(lore_type *lore_ptr)
  * a monster.
  * @todo max_blows はゲームの中核的なパラメータの1つなのでどこかのヘッダに定数宣言しておきたい
  */
-void display_monster_launching(player_type *player_ptr, lore_type *lore_ptr)
+void display_monster_launching(PlayerType *player_ptr, lore_type *lore_ptr)
 {
     if (lore_ptr->ability_flags.has(MonsterAbilityType::ROCKET)) {
         set_damage(player_ptr, lore_ptr, MonsterAbilityType::ROCKET, _("ロケット%sを発射する", "shoot a rocket%s"));
index 1580018..d36019a 100644 (file)
@@ -4,10 +4,10 @@
 #include "system/angband.h"
 
 struct lore_type;
-struct player_type;
+class PlayerType;
 void roff_top(MONRACE_IDX r_idx);
-void screen_roff(player_type *player_ptr, MONRACE_IDX r_idx, monster_lore_mode mode);
-void display_roff(player_type *player_ptr);
+void screen_roff(PlayerType *player_ptr, MONRACE_IDX r_idx, monster_lore_mode mode);
+void display_roff(PlayerType *player_ptr);
 void output_monster_spoiler(MONRACE_IDX r_idx, void (*roff_func)(TERM_COLOR attr, concptr str));
 void display_kill_numbers(lore_type *lore_ptr);
 bool display_where_to_appear(lore_type *lore_ptr);
@@ -16,10 +16,10 @@ void display_monster_move(lore_type *lore_ptr);
 void display_monster_never_move(lore_type *lore_ptr);
 void display_monster_kind(lore_type *lore_ptr);
 void display_monster_alignment(lore_type *lore_ptr);
-void display_monster_exp(player_type *player_ptr, lore_type *lore_ptr);
+void display_monster_exp(PlayerType *player_ptr, lore_type *lore_ptr);
 void display_monster_aura(lore_type *lore_ptr);
-void display_lore_this(player_type *player_ptr, lore_type *lore_ptr);
+void display_lore_this(PlayerType *player_ptr, lore_type *lore_ptr);
 void display_monster_collective(lore_type *lore_ptr);
-void display_monster_launching(player_type *player_ptr, lore_type *lore_ptr);
+void display_monster_launching(PlayerType *player_ptr, lore_type *lore_ptr);
 void display_monster_sometimes(lore_type *lore_ptr);
 void display_monster_guardian(lore_type *lore_ptr);
index 469ca89..1af8a73 100644 (file)
@@ -138,7 +138,7 @@ static bool is_revealed_wall(floor_type *floor_ptr, feature_type *f_ptr, POSITIO
  * @param tap 文字色属性(タイル)
  * @param tcp 文字種属性(タイル)
  */
-void map_info(player_type *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, SYMBOL_CODE *cp, TERM_COLOR *tap, SYMBOL_CODE *tcp)
+void map_info(PlayerType *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, SYMBOL_CODE *cp, TERM_COLOR *tap, SYMBOL_CODE *tcp)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     grid_type *g_ptr = &floor_ptr->grid_array[y][x];
index 793533f..be6ba84 100644 (file)
@@ -9,5 +9,5 @@ extern byte display_autopick;
 extern char image_object_hack[MAX_IMAGE_OBJECT_HACK];
 extern char image_monster_hack[MAX_IMAGE_MONSTER_HACK];
 
-struct player_type;
-void map_info(player_type *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, SYMBOL_CODE *cp, TERM_COLOR *tap, SYMBOL_CODE *tcp);
+class PlayerType;
+void map_info(PlayerType *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, SYMBOL_CODE *cp, TERM_COLOR *tap, SYMBOL_CODE *tcp);
index 362224c..cd3275d 100644 (file)
@@ -197,7 +197,7 @@ bool is_msg_window_flowed(void)
 /*
  * Hack -- flush
  */
-static void msg_flush(player_type *player_ptr, int x)
+static void msg_flush(PlayerType *player_ptr, int x)
 {
     byte a = TERM_L_BLUE;
     bool show_more = (num_more >= 0);
index 998d9b4..9f80dec 100644 (file)
@@ -33,7 +33,7 @@
  * @param hand 武器の装備部位ID
  * @param hand_entry 項目ID
  */
-static void display_player_melee_bonus(player_type *player_ptr, int hand, int hand_entry)
+static void display_player_melee_bonus(PlayerType *player_ptr, int hand, int hand_entry)
 {
     HIT_PROB show_tohit = player_ptr->dis_to_h[hand];
     HIT_POINT show_todam = player_ptr->dis_to_d[hand];
@@ -61,7 +61,7 @@ static void display_player_melee_bonus(player_type *player_ptr, int hand, int ha
  * @brief 右手に比べて左手の表示ルーチンが複雑なので分離
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_sub_hand(player_type *player_ptr)
+static void display_sub_hand(PlayerType *player_ptr)
 {
     if (can_attack_with_sub_hand(player_ptr)) {
         display_player_melee_bonus(player_ptr, 1, left_hander ? ENTRY_RIGHT_HAND2 : ENTRY_LEFT_HAND2);
@@ -88,7 +88,7 @@ static void display_sub_hand(player_type *player_ptr)
  * @brief 武器による命中率とダメージの補正を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_hit_damage(player_type *player_ptr)
+static void display_hit_damage(PlayerType *player_ptr)
 {
     object_type *o_ptr = &player_ptr->inventory_list[INVEN_BOW];
     HIT_PROB show_tohit = player_ptr->dis_to_h_b;
@@ -112,7 +112,7 @@ static void display_hit_damage(player_type *player_ptr)
  * @brief 射撃武器倍率を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_shoot_magnification(player_type *player_ptr)
+static void display_shoot_magnification(PlayerType *player_ptr)
 {
     int tmul = 0;
     if (player_ptr->inventory_list[INVEN_BOW].k_idx) {
@@ -131,7 +131,7 @@ static void display_shoot_magnification(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param base_speed プレイヤーの速度
  */
-static TERM_COLOR decide_speed_color(player_type *player_ptr, const int base_speed)
+static TERM_COLOR decide_speed_color(PlayerType *player_ptr, const int base_speed)
 {
     TERM_COLOR attr;
     if (base_speed > 0) {
@@ -159,7 +159,7 @@ static TERM_COLOR decide_speed_color(player_type *player_ptr, const int base_spe
  * @param player_ptr プレイヤーへの参照ポインタ
  * @return プレイヤーの速度
  */
-static int calc_temporary_speed(player_type *player_ptr)
+static int calc_temporary_speed(PlayerType *player_ptr)
 {
     int tmp_speed = 0;
     if (!player_ptr->riding) {
@@ -186,7 +186,7 @@ static int calc_temporary_speed(player_type *player_ptr)
  * @param base_speed プレイヤーの素の速度
  * @param tmp_speed アイテム等で一時的に変化した速度量
  */
-static void display_player_speed(player_type *player_ptr, TERM_COLOR attr, int base_speed, int tmp_speed)
+static void display_player_speed(PlayerType *player_ptr, TERM_COLOR attr, int base_speed, int tmp_speed)
 {
     char buf[160];
     if (tmp_speed) {
@@ -218,7 +218,7 @@ static void display_player_speed(player_type *player_ptr, TERM_COLOR attr, int b
  * @brief プレイヤーの現在経験値・最大経験値・次のレベルまでに必要な経験値を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_player_exp(player_type *player_ptr)
+static void display_player_exp(PlayerType *player_ptr)
 {
     int e = (player_ptr->prace == PlayerRaceType::ANDROID) ? ENTRY_EXP_ANDR : ENTRY_CUR_EXP;
     if (player_ptr->exp >= player_ptr->max_exp)
@@ -243,7 +243,7 @@ static void display_player_exp(player_type *player_ptr)
  * @brief ゲーム内の経過時間を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_playtime_in_game(player_type *player_ptr)
+static void display_playtime_in_game(PlayerType *player_ptr)
 {
     int day, hour, min;
     extract_day_hour_min(player_ptr, &day, &hour, &min);
@@ -289,7 +289,7 @@ static void display_real_playtime(void)
  * @param player_ptr プレイヤーへの参照ポインタ
  * Prints the following information on the screen.
  */
-void display_player_middle(player_type *player_ptr)
+void display_player_middle(PlayerType *player_ptr)
 {
     if (can_attack_with_main_hand(player_ptr))
         display_player_melee_bonus(player_ptr, 0, left_hander ? ENTRY_LEFT_HAND1 : ENTRY_RIGHT_HAND1);
index 80b0a2f..d41e8d8 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void display_player_middle(player_type *player_ptr);
+class PlayerType;
+void display_player_middle(PlayerType *player_ptr);
index 62ca8d5..3a7f08d 100644 (file)
@@ -12,7 +12,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * Special display, part 2a
  */
-void display_player_misc_info(player_type *player_ptr)
+void display_player_misc_info(PlayerType *player_ptr)
 {
     put_str(_("名前  :", "Name  :"), 1, 26);
     put_str(_("性別  :", "Sex   :"), 3, 1);
index 10fe6ba..3014f6a 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void display_player_misc_info(player_type *player_ptr);
+class PlayerType;
+void display_player_misc_info(PlayerType *player_ptr);
index 607e1ad..43829da 100644 (file)
@@ -31,7 +31,7 @@
  * @return 基礎値
  * @details 最大が18になるのはD&D由来
  */
-static int calc_basic_stat(player_type *player_ptr, int stat_num)
+static int calc_basic_stat(PlayerType *player_ptr, int stat_num)
 {
     int e_adj = 0;
     if ((player_ptr->stat_max[stat_num] > 18) && (player_ptr->stat_top[stat_num] > 18))
@@ -55,7 +55,7 @@ static int calc_basic_stat(player_type *player_ptr, int stat_num)
  * @param stat_num 能力値番号
  * @return 補正後の基礎パラメータ
  */
-static int compensate_special_race(player_type *player_ptr, int stat_num)
+static int compensate_special_race(PlayerType *player_ptr, int stat_num)
 {
     if (!PlayerRace(player_ptr).equals(PlayerRaceType::ENT))
         return 0;
@@ -91,7 +91,7 @@ static int compensate_special_race(player_type *player_ptr, int stat_num)
  * @param row 行数
  * @param stat_col 列数
  */
-static void display_basic_stat_name(player_type *player_ptr, int stat_num, int row, int stat_col)
+static void display_basic_stat_name(PlayerType *player_ptr, int stat_num, int row, int stat_col)
 {
     if (player_ptr->stat_cur[stat_num] < player_ptr->stat_max[stat_num])
         c_put_str(TERM_WHITE, stat_names_reduced[stat_num], row + stat_num + 1, stat_col + 1);
@@ -109,7 +109,7 @@ static void display_basic_stat_name(player_type *player_ptr, int stat_num, int r
  * @param stat_col 列数
  * @param buf 能力値の数値
  */
-static void display_basic_stat_value(player_type *player_ptr, int stat_num, int r_adj, int e_adj, int row, int stat_col, char *buf)
+static void display_basic_stat_value(PlayerType *player_ptr, int stat_num, int r_adj, int e_adj, int row, int stat_col, char *buf)
 {
     (void)sprintf(buf, "%3d", r_adj);
     c_put_str(TERM_L_BLUE, buf, row + stat_num + 1, stat_col + 13);
@@ -138,7 +138,7 @@ static void display_basic_stat_value(player_type *player_ptr, int stat_num, int
  * @param row 行数
  * @param stat_col 列数
  */
-static void process_stats(player_type *player_ptr, int row, int stat_col)
+static void process_stats(PlayerType *player_ptr, int row, int stat_col)
 {
     char buf[80];
     for (int i = 0; i < A_MAX; i++) {
@@ -196,7 +196,7 @@ static void compensate_stat_by_weapon(char *c, TERM_COLOR *a, object_type *o_ptr
  * @param row 行数
  * @param col 列数
  */
-static void display_equipments_compensation(player_type *player_ptr, int row, int *col)
+static void display_equipments_compensation(PlayerType *player_ptr, int row, int *col)
 {
     for (int i = INVEN_MAIN_HAND; i < INVEN_TOTAL; i++) {
         object_type *o_ptr;
@@ -224,7 +224,7 @@ static void display_equipments_compensation(player_type *player_ptr, int row, in
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param stat 能力値番号
  */
-static int compensation_stat_by_mutation(player_type *player_ptr, int stat)
+static int compensation_stat_by_mutation(PlayerType *player_ptr, int stat)
 {
     int compensation = 0;
     if (stat == A_STR) {
@@ -295,7 +295,7 @@ static int compensation_stat_by_mutation(player_type *player_ptr, int stat)
  * @param c 補正後の表示記号
  * @param a 表示色
  */
-static void change_display_by_mutation(player_type *player_ptr, int stat, char *c, TERM_COLOR *a)
+static void change_display_by_mutation(PlayerType *player_ptr, int stat, char *c, TERM_COLOR *a)
 {
     int compensation = compensation_stat_by_mutation(player_ptr, stat);
     if (compensation == 0)
@@ -321,7 +321,7 @@ static void change_display_by_mutation(player_type *player_ptr, int stat, char *
  * @param col 列数
  * @param row 行数
  */
-static void display_mutation_compensation(player_type *player_ptr, int row, int col)
+static void display_mutation_compensation(PlayerType *player_ptr, int row, int col)
 {
     TrFlags flags;
     player_flags(player_ptr, flags);
@@ -355,7 +355,7 @@ static void display_mutation_compensation(player_type *player_ptr, int row, int
  * No mod, no sustain, will be a slate '.'
  * </pre>
  */
-void display_player_stat_info(player_type *player_ptr)
+void display_player_stat_info(PlayerType *player_ptr)
 {
     int stat_col = 22;
     int row = 3;
index ed9def1..6103578 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void display_player_stat_info(player_type *player_ptr);
+class PlayerType;
+void display_player_stat_info(PlayerType *player_ptr);
index e0e6af3..170f875 100644 (file)
@@ -48,7 +48,7 @@
  * @param mode ステータス表示モード
  * @return どれかの処理をこなしたらTRUE、何もしなかったらFALSE
  */
-static bool display_player_info(player_type *player_ptr, int mode)
+static bool display_player_info(PlayerType *player_ptr, int mode)
 {
     if (mode == 2) {
         display_player_misc_info(player_ptr);
@@ -79,7 +79,7 @@ static bool display_player_info(player_type *player_ptr, int mode)
  * @brief 名前、性別、種族、職業を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_player_basic_info(player_type *player_ptr)
+static void display_player_basic_info(PlayerType *player_ptr)
 {
     char tmp[64];
 #ifdef JP
@@ -98,7 +98,7 @@ static void display_player_basic_info(player_type *player_ptr)
  * @brief 魔法領域を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_magic_realms(player_type *player_ptr)
+static void display_magic_realms(PlayerType *player_ptr)
 {
     if (player_ptr->realm1 == REALM_NONE && player_ptr->element == REALM_NONE)
         return;
@@ -120,7 +120,7 @@ static void display_magic_realms(player_type *player_ptr)
  * @details
  * 日本語版では、身長はcmに、体重はkgに変更してある
  */
-static void display_phisique(player_type *player_ptr)
+static void display_phisique(PlayerType *player_ptr)
 {
 #ifdef JP
     display_player_one_line(ENTRY_AGE, format("%d才", (int)player_ptr->age), TERM_L_BLUE);
@@ -141,7 +141,7 @@ static void display_phisique(player_type *player_ptr)
  * @brief 能力値を (減少していたら色を変えて)表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-static void display_player_stats(player_type *player_ptr)
+static void display_player_stats(PlayerType *player_ptr)
 {
     char buf[80];
     for (int i = 0; i < A_MAX; i++) {
@@ -170,7 +170,7 @@ static void display_player_stats(player_type *player_ptr)
  * @param statmsg メッセージバッファ
  * @return 生きていたらFALSE、死んでいたらTRUE
  */
-static bool search_death_cause(player_type *player_ptr, char *statmsg)
+static bool search_death_cause(PlayerType *player_ptr, char *statmsg)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!player_ptr->is_dead)
@@ -220,7 +220,7 @@ static bool search_death_cause(player_type *player_ptr, char *statmsg)
  * @param statmsg メッセージバッファ
  * @return クエスト内であればTRUE、いなければFALSE
  */
-static bool decide_death_in_quest(player_type *player_ptr, char *statmsg)
+static bool decide_death_in_quest(PlayerType *player_ptr, char *statmsg)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (!floor_ptr->inside_quest || !quest_type::is_fixed(floor_ptr->inside_quest))
@@ -241,7 +241,7 @@ static bool decide_death_in_quest(player_type *player_ptr, char *statmsg)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param statmsg メッセージバッファ
  */
-static void decide_current_floor(player_type *player_ptr, char *statmsg)
+static void decide_current_floor(PlayerType *player_ptr, char *statmsg)
 {
     if (search_death_cause(player_ptr, statmsg))
         return;
@@ -298,7 +298,7 @@ static void display_current_floor(char *statmsg)
  * Mode 4 = mutations
  * </pre>
  */
-void display_player(player_type *player_ptr, int mode)
+void display_player(PlayerType *player_ptr, int mode)
 {
     if ((player_ptr->muta.any() || has_good_luck(player_ptr)) && display_mutations)
         mode = (mode % 6);
@@ -346,7 +346,7 @@ void display_player(player_type *player_ptr, int mode)
  * @param mode オプション
  * @todo y = 6、x = 0、mode = 0で固定。何とかする
  */
-void display_player_equippy(player_type *player_ptr, TERM_LEN y, TERM_LEN x, BIT_FLAGS16 mode)
+void display_player_equippy(PlayerType *player_ptr, TERM_LEN y, TERM_LEN x, BIT_FLAGS16 mode)
 {
     int max_i = (mode & DP_WP) ? INVEN_BOW + 1 : INVEN_TOTAL;
     for (int i = INVEN_MAIN_HAND; i < max_i; i++) {
index da913c6..61ba053 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void display_player(player_type *player_ptr, int mode);
-void display_player_equippy(player_type *player_ptr, TERM_LEN y, TERM_LEN x, BIT_FLAGS16 mode);
+class PlayerType;
+void display_player(PlayerType *player_ptr, int mode);
+void display_player_equippy(PlayerType *player_ptr, TERM_LEN y, TERM_LEN x, BIT_FLAGS16 mode);
index 630eb75..238e79d 100644 (file)
@@ -9,7 +9,7 @@
 #include "term/screen-processor.h"
 #include <string>
 
-void display_life_rating(player_type *player_ptr, self_info_type *self_ptr)
+void display_life_rating(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     player_ptr->knowledge |= KNOW_STAT | KNOW_HPRATE;
     strcpy(self_ptr->plev_buf, "");
@@ -21,7 +21,7 @@ void display_life_rating(player_type *player_ptr, self_info_type *self_ptr)
     self_ptr->info[self_ptr->line++] = "";
 }
 
-void display_max_base_status(player_type *player_ptr, self_info_type *self_ptr)
+void display_max_base_status(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     self_ptr->info[self_ptr->line++] = _("能力の最大値", "Limits of maximum stats");
     for (int v_nr = 0; v_nr < A_MAX; v_nr++) {
@@ -32,7 +32,7 @@ void display_max_base_status(player_type *player_ptr, self_info_type *self_ptr)
     }
 }
 
-void display_virtue(player_type *player_ptr, self_info_type *self_ptr)
+void display_virtue(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     self_ptr->info[self_ptr->line++] = "";
     std::string alg = PlayerAlignment(player_ptr).get_alignment_description(true);
@@ -77,7 +77,7 @@ void display_virtue(player_type *player_ptr, self_info_type *self_ptr)
     }
 }
 
-void display_mimic_race_ability(player_type *player_ptr, self_info_type *self_ptr)
+void display_mimic_race_ability(PlayerType *player_ptr, self_info_type *self_ptr)
 {
     switch (player_ptr->mimic_form) {
     case MIMIC_DEMON:
index 8679eee..c54c2de 100644 (file)
@@ -1,9 +1,9 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 struct self_info_type;
-void display_life_rating(player_type *player_ptr, self_info_type *self_ptr);
-void display_max_base_status(player_type *player_ptr, self_info_type *self_ptr);
-void display_virtue(player_type *player_ptr, self_info_type *self_ptr);
-void display_mimic_race_ability(player_type *player_ptr, self_info_type *self_ptr);
+void display_life_rating(PlayerType *player_ptr, self_info_type *self_ptr);
+void display_max_base_status(PlayerType *player_ptr, self_info_type *self_ptr);
+void display_virtue(PlayerType *player_ptr, self_info_type *self_ptr);
+void display_mimic_race_ability(PlayerType *player_ptr, self_info_type *self_ptr);
 void display_self_info(self_info_type *self_ptr);
index 12b321d..2ec0780 100644 (file)
@@ -26,7 +26,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details
  */
-void store_prt_gold(player_type *player_ptr)
+void store_prt_gold(PlayerType *player_ptr)
 {
     prt(_("手持ちのお金: ", "Gold Remaining: "), 19 + xtra_stock, 53);
     char out_val[64];
@@ -40,7 +40,7 @@ void store_prt_gold(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param pos 表示行
  */
-void display_entry(player_type *player_ptr, int pos)
+void display_entry(PlayerType *player_ptr, int pos)
 {
     object_type *o_ptr;
     o_ptr = &st_ptr->stock[pos];
@@ -111,7 +111,7 @@ void display_entry(player_type *player_ptr, int pos)
  * @details
  * All prices are listed as "per individual object".  -BEN-
  */
-void display_store_inventory(player_type *player_ptr)
+void display_store_inventory(PlayerType *player_ptr)
 {
     int k;
     for (k = 0; k < store_bottom; k++) {
@@ -145,7 +145,7 @@ void display_store_inventory(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details
  */
-void display_store(player_type *player_ptr)
+void display_store(PlayerType *player_ptr)
 {
     term_clear();
     if (cur_store_num == StoreSaleType::HOME) {
index cc42654..564abd9 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
-struct player_type;
-void store_prt_gold(player_type *player_ptr);
-void display_entry(player_type *player_ptr, int pos);
-void display_store_inventory(player_type *player_ptr);
-void display_store(player_type *player_ptr);
+class PlayerType;
+void store_prt_gold(PlayerType *player_ptr);
+void display_entry(PlayerType *player_ptr, int pos);
+void display_store_inventory(PlayerType *player_ptr);
+void display_store(PlayerType *player_ptr);
index a548deb..0af5708 100644 (file)
@@ -17,7 +17,7 @@
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param item 残量を表示したいプレイヤーのアイテム所持スロット
  */
-void inven_item_charges(player_type *player_ptr, INVENTORY_IDX item)
+void inven_item_charges(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     object_type *o_ptr = &player_ptr->inventory_list[item];
     if ((o_ptr->tval != ItemKindType::STAFF) && (o_ptr->tval != ItemKindType::WAND))
@@ -48,7 +48,7 @@ void inven_item_charges(player_type *player_ptr, INVENTORY_IDX item)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param item 残量を表示したいプレイヤーのアイテム所持スロット
  */
-void inven_item_describe(player_type *player_ptr, INVENTORY_IDX item)
+void inven_item_describe(PlayerType *player_ptr, INVENTORY_IDX item)
 {
     object_type *o_ptr = &player_ptr->inventory_list[item];
     GAME_TEXT o_name[MAX_NLEN];
@@ -72,7 +72,7 @@ void inven_item_describe(player_type *player_ptr, INVENTORY_IDX item)
  * @details
  * Include list of usable spells for readible books
  */
-void display_koff(player_type *player_ptr, KIND_OBJECT_IDX k_idx)
+void display_koff(PlayerType *player_ptr, KIND_OBJECT_IDX k_idx)
 {
     object_type forge;
     object_type *q_ptr;
index c8c2208..097b089 100644 (file)
@@ -2,7 +2,7 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void inven_item_charges(player_type *player_ptr, INVENTORY_IDX item);
-void inven_item_describe(player_type *player_ptr, INVENTORY_IDX item);
-void display_koff(player_type *player_ptr, KIND_OBJECT_IDX k_idx);
+class PlayerType;
+void inven_item_charges(PlayerType *player_ptr, INVENTORY_IDX item);
+void inven_item_describe(PlayerType *player_ptr, INVENTORY_IDX item);
+void display_koff(PlayerType *player_ptr, KIND_OBJECT_IDX k_idx);
index 832690f..2052f41 100644 (file)
@@ -38,7 +38,7 @@ static TERM_COLOR likert_color = TERM_WHITE;
  * @param shots 射撃回数
  * @param shot_frac 射撃速度
  */
-static void calc_shot_params(player_type *player_ptr, object_type *o_ptr, int *shots, int *shot_frac)
+static void calc_shot_params(PlayerType *player_ptr, object_type *o_ptr, int *shots, int *shot_frac)
 {
     if (o_ptr->k_idx == 0)
         return;
@@ -72,7 +72,7 @@ static void calc_shot_params(player_type *player_ptr, object_type *o_ptr, int *s
  * @param o_ptr 装備中の武器への参照ポインタ
  * @return 利き手ならTRUE、反対の手ならFALSE
  */
-static bool calc_weapon_damage_limit(player_type *player_ptr, int hand, int *damage, int *basedam, object_type *o_ptr)
+static bool calc_weapon_damage_limit(PlayerType *player_ptr, int hand, int *damage, int *basedam, object_type *o_ptr)
 {
     PLAYER_LEVEL level = player_ptr->lev;
     if (hand > 0) {
@@ -131,7 +131,7 @@ static bool calc_weapon_one_hand(object_type *o_ptr, int hand, int *damage, int
  * @param flgs オブジェクトフラグ群
  * @return 強化後の素手ダメージ
  */
-static int strengthen_basedam(player_type *player_ptr, object_type *o_ptr, int basedam, const TrFlags &flgs)
+static int strengthen_basedam(PlayerType *player_ptr, object_type *o_ptr, int basedam, const TrFlags &flgs)
 {
     if (o_ptr->is_fully_known() && ((o_ptr->name1 == ART_VORPAL_BLADE) || (o_ptr->name1 == ART_CHAINSWORD))) {
         /* vorpal blade */
@@ -244,7 +244,7 @@ static concptr likert(int x, int y)
  * @param damage 直接攻撃のダメージ
  * @param to_h 命中補正
  */
-static void calc_two_hands(player_type *player_ptr, int *damage, int *to_h)
+static void calc_two_hands(PlayerType *player_ptr, int *damage, int *to_h)
 {
     object_type *o_ptr;
     o_ptr = &player_ptr->inventory_list[INVEN_BOW];
@@ -295,7 +295,7 @@ static void calc_two_hands(player_type *player_ptr, int *damage, int *to_h)
  * @param shot_frac 射撃速度
  * @param display_player_one_line 1行表示用のコールバック関数
  */
-static void display_first_page(player_type *player_ptr, int xthb, int *damage, int shots, int shot_frac)
+static void display_first_page(PlayerType *player_ptr, int xthb, int *damage, int shots, int shot_frac)
 {
     int xthn = player_ptr->skill_thn + (player_ptr->to_h_m * BTH_PLUS_ADJ);
 
@@ -375,7 +375,7 @@ static void display_first_page(player_type *player_ptr, int xthb, int *damage, i
  * @details
  * This code is "imitated" elsewhere to "dump" a character sheet.
  */
-void display_player_various(player_type *player_ptr)
+void display_player_various(PlayerType *player_ptr)
 {
     object_type *o_ptr;
     o_ptr = &player_ptr->inventory_list[INVEN_BOW];
index ae0cd32..89b7ebb 100644 (file)
@@ -50,5 +50,5 @@
 #define ENTRY_EXP_ANDR 43
 #define ENTRY_EXP_TO_ADV_ANDR 44
 
-struct player_type;
-void display_player_various(player_type *player_ptr);
+class PlayerType;
+void display_player_various(PlayerType *player_ptr);
index 886f487..f132661 100644 (file)
@@ -26,7 +26,7 @@
  * Need to analyze size of the window.
  * Need more color coding.
  */
-static void display_spell_list(player_type *player_ptr)
+static void display_spell_list(PlayerType *player_ptr)
 {
     TERM_LEN y, x;
     int m[9];
@@ -173,7 +173,7 @@ static void display_spell_list(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * Hack -- display spells in sub-windows
  */
-void fix_spell(player_type *player_ptr)
+void fix_spell(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         term_type *old = Term;
index d2279cb..8740fb1 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void fix_spell(player_type *player_ptr);
+class PlayerType;
+void fix_spell(PlayerType *player_ptr);
index 36ef3ac..493c531 100644 (file)
@@ -66,7 +66,7 @@ FixItemTesterSetter::~FixItemTesterSetter()
  * @brief サブウィンドウに所持品一覧を表示する / Hack -- display inventory in sub-windows
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void fix_inventory(player_type *player_ptr)
+void fix_inventory(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         term_type *old = Term;
@@ -198,7 +198,7 @@ void print_monster_list(floor_type *floor_ptr, const std::vector<MONSTER_IDX> &m
  * @brief 出現中モンスターのリストをサブウィンドウに表示する / Hack -- display monster list in sub-windows
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void fix_monster_list(player_type *player_ptr)
+void fix_monster_list(PlayerType *player_ptr)
 {
     static std::vector<MONSTER_IDX> monster_list;
     std::once_flag once;
@@ -231,7 +231,7 @@ void fix_monster_list(player_type *player_ptr)
  * @brief 装備アイテム一覧を表示する /
  * Choice window "shadow" of the "show_equip()" function
  */
-static void display_equipment(player_type *player_ptr, const ItemTester &item_tester)
+static void display_equipment(PlayerType *player_ptr, const ItemTester &item_tester)
 {
     if (!player_ptr || !player_ptr->inventory_list)
         return;
@@ -304,7 +304,7 @@ static void display_equipment(player_type *player_ptr, const ItemTester &item_te
  * Hack -- display equipment in sub-windows
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void fix_equip(player_type *player_ptr)
+void fix_equip(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         term_type *old = Term;
@@ -325,7 +325,7 @@ void fix_equip(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * Hack -- display character in sub-windows
  */
-void fix_player(player_type *player_ptr)
+void fix_player(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         term_type *old = Term;
@@ -381,7 +381,7 @@ void fix_message(void)
  * @details
  * Note that the "player" symbol does NOT appear on the map.
  */
-void fix_overhead(player_type *player_ptr)
+void fix_overhead(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         term_type *old = Term;
@@ -408,7 +408,7 @@ void fix_overhead(player_type *player_ptr)
  * @brief 自分の周辺の地形をTermに表示する
  * @param プレイヤー情報への参照ポインタ
  */
-static void display_dungeon(player_type *player_ptr)
+static void display_dungeon(PlayerType *player_ptr)
 {
     TERM_COLOR ta = 0;
     SYMBOL_CODE tc = '\0';
@@ -445,7 +445,7 @@ static void display_dungeon(player_type *player_ptr)
  * @brief 自分の周辺のダンジョンの地形をサブウィンドウに表示する / display dungeon view around player in a sub window
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void fix_dungeon(player_type *player_ptr)
+void fix_dungeon(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         term_type *old = Term;
@@ -467,7 +467,7 @@ void fix_dungeon(player_type *player_ptr)
  * Hack -- display dungeon view in sub-windows
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void fix_monster(player_type *player_ptr)
+void fix_monster(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         term_type *old = Term;
@@ -491,7 +491,7 @@ void fix_monster(player_type *player_ptr)
  * Hack -- display object recall in sub-windows
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void fix_object(player_type *player_ptr)
+void fix_object(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         term_type *old = Term;
@@ -536,7 +536,7 @@ static const monster_type *monster_on_floor_items(floor_type *floor_ptr, const g
  * @param y 参照する座標グリッドのy座標
  * @param x 参照する座標グリッドのx座標
  */
-static void display_floor_item_list(player_type *player_ptr, const int y, const int x)
+static void display_floor_item_list(PlayerType *player_ptr, const int y, const int x)
 {
     // Term の行数を取得。
     TERM_LEN term_h;
@@ -612,7 +612,7 @@ static void display_floor_item_list(player_type *player_ptr, const int y, const
 /*!
  * @brief (y,x) のアイテム一覧をサブウィンドウに表示する / display item at (y,x) in sub-windows
  */
-void fix_floor_item_list(player_type *player_ptr, const int y, const int x)
+void fix_floor_item_list(PlayerType *player_ptr, const int y, const int x)
 {
     for (int j = 0; j < 8; j++) {
         if (!angband_term[j])
@@ -636,7 +636,7 @@ void fix_floor_item_list(player_type *player_ptr, const int y, const int x)
  * @brief サブウィンドウに所持品、装備品リストの表示を行う /
  * Flip "inven" and "equip" in any sub-windows
  */
-void toggle_inventory_equipment(player_type *player_ptr)
+void toggle_inventory_equipment(PlayerType *player_ptr)
 {
     for (int j = 0; j < 8; j++) {
         if (!angband_term[j])
index ce06990..64068f2 100644 (file)
@@ -5,20 +5,20 @@
 #include <vector>
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 class ItemTester;
-void fix_inventory(player_type *player_ptr);
+void fix_inventory(PlayerType *player_ptr);
 void print_monster_list(floor_type *floor_ptr, const std::vector<MONSTER_IDX> &monster_list, TERM_LEN x, TERM_LEN y, TERM_LEN max_lines);
-void fix_monster_list(player_type *player_ptr);
-void fix_equip(player_type *player_ptr);
-void fix_player(player_type *player_ptr);
+void fix_monster_list(PlayerType *player_ptr);
+void fix_equip(PlayerType *player_ptr);
+void fix_player(PlayerType *player_ptr);
 void fix_message(void);
-void fix_overhead(player_type *player_ptr);
-void fix_dungeon(player_type *player_ptr);
-void fix_monster(player_type *player_ptr);
-void fix_object(player_type *player_ptr);
-void fix_floor_item_list(player_type *player_ptr, const int y, const int x);
-void toggle_inventory_equipment(player_type *player_ptr);
+void fix_overhead(PlayerType *player_ptr);
+void fix_dungeon(PlayerType *player_ptr);
+void fix_monster(PlayerType *player_ptr);
+void fix_object(PlayerType *player_ptr);
+void fix_floor_item_list(PlayerType *player_ptr, const int y, const int x);
+void toggle_inventory_equipment(PlayerType *player_ptr);
 
 /*!
  * @brief サブウィンドウ表示用の ItemTester オブジェクトを設定するクラス
index 7aceedc..ae6d0f8 100644 (file)
@@ -24,7 +24,7 @@
  * @param target_item アイテムの選択処理を行うか否か。
  * @return 選択したアイテムのタグ
  */
-COMMAND_CODE show_equipment(player_type *player_ptr, int target_item, BIT_FLAGS mode, const ItemTester &item_tester)
+COMMAND_CODE show_equipment(PlayerType *player_ptr, int target_item, BIT_FLAGS mode, const ItemTester &item_tester)
 {
     COMMAND_CODE i;
     int j, k, l;
index 02f1289..f91add2 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "object/tval-types.h"
 
-struct player_type;
+class PlayerType;
 class ItemTester;
-void display_inventory(player_type *player_ptr, const ItemTester& item_tester);
+void display_inventory(PlayerType *player_ptr, const ItemTester& item_tester);
index 19f62e8..bc8c4bd 100644 (file)
@@ -22,7 +22,7 @@
 /*!
  * @brief プレイヤーの称号を表示する / Prints "title", including "wizard" or "winner" as needed.
  */
-void print_title(player_type *player_ptr)
+void print_title(PlayerType *player_ptr)
 {
     GAME_TEXT str[14];
     concptr p = "";
@@ -43,7 +43,7 @@ void print_title(player_type *player_ptr)
 /*!
  * @brief プレイヤーのレベルを表示する / Prints level
  */
-void print_level(player_type *player_ptr)
+void print_level(PlayerType *player_ptr)
 {
     char tmp[32];
     sprintf(tmp, "%5d", player_ptr->lev);
@@ -59,7 +59,7 @@ void print_level(player_type *player_ptr)
 /*!
  * @brief プレイヤーの経験値を表示する / Display the experience
  */
-void print_exp(player_type *player_ptr)
+void print_exp(PlayerType *player_ptr)
 {
     char out_val[32];
 
@@ -88,7 +88,7 @@ void print_exp(player_type *player_ptr)
 /*!
  * @brief プレイヤーのACを表示する / Prints current AC
  */
-void print_ac(player_type *player_ptr)
+void print_ac(PlayerType *player_ptr)
 {
     char tmp[32];
 
@@ -107,7 +107,7 @@ void print_ac(player_type *player_ptr)
 /*!
  * @brief プレイヤーのHPを表示する / Prints Cur/Max hit points
  */
-void print_hp(player_type *player_ptr)
+void print_hp(PlayerType *player_ptr)
 {
     char tmp[32];
     put_str("HP", ROW_CURHP, COL_CURHP);
@@ -131,7 +131,7 @@ void print_hp(player_type *player_ptr)
 /*!
  * @brief プレイヤーのMPを表示する / Prints players max/cur spell points
  */
-void print_sp(player_type *player_ptr)
+void print_sp(PlayerType *player_ptr)
 {
     char tmp[32];
     byte color;
@@ -159,7 +159,7 @@ void print_sp(player_type *player_ptr)
  * @brief プレイヤーの所持金を表示する / Prints current gold
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_gold(player_type *player_ptr)
+void print_gold(PlayerType *player_ptr)
 {
     char tmp[32];
     put_str(_("$ ", "AU "), ROW_GOLD, COL_GOLD);
@@ -171,7 +171,7 @@ void print_gold(player_type *player_ptr)
  * @brief 現在のフロアの深さを表示する / Prints depth in stat area
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_depth(player_type *player_ptr)
+void print_depth(PlayerType *player_ptr)
 {
     char depths[32];
     TERM_COLOR attr = TERM_WHITE;
@@ -242,7 +242,7 @@ void print_depth(player_type *player_ptr)
  * @brief プレイヤーのステータスを一括表示する(左側部分) / Display basic info (mostly left of map)
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_frame_basic(player_type *player_ptr)
+void print_frame_basic(PlayerType *player_ptr)
 {
     if (player_ptr->mimic_form) {
         print_field(mimic_info[player_ptr->mimic_form].title, ROW_RACE, COL_RACE);
@@ -286,7 +286,7 @@ void print_frame_basic(player_type *player_ptr)
  * health-bar stops tracking any monster that "disappears".
  * </pre>
  */
-void health_redraw(player_type *player_ptr, bool riding)
+void health_redraw(PlayerType *player_ptr, bool riding)
 {
     int16_t health_who;
     int row, col;
index c965f73..32c8784 100644 (file)
@@ -1,13 +1,13 @@
 #pragma once
 
-struct player_type;
-void print_title(player_type *player_ptr);
-void print_level(player_type *player_ptr);
-void print_exp(player_type *player_ptr);
-void print_ac(player_type *player_ptr);
-void print_hp(player_type *player_ptr);
-void print_sp(player_type *player_ptr);
-void print_gold(player_type *player_ptr);
-void print_depth(player_type *player_ptr);
-void print_frame_basic(player_type *player_ptr);
-void health_redraw(player_type *player_ptr, bool riding);
+class PlayerType;
+void print_title(PlayerType *player_ptr);
+void print_level(PlayerType *player_ptr);
+void print_exp(PlayerType *player_ptr);
+void print_ac(PlayerType *player_ptr);
+void print_hp(PlayerType *player_ptr);
+void print_sp(PlayerType *player_ptr);
+void print_gold(PlayerType *player_ptr);
+void print_depth(PlayerType *player_ptr);
+void print_frame_basic(PlayerType *player_ptr);
+void health_redraw(PlayerType *player_ptr, bool riding);
index e5d14a6..80dab88 100644 (file)
@@ -46,7 +46,7 @@
  * @brief プレイヤー能力値を描画する / Print character stat in given row, column
  * @param stat 描画するステータスのID
  */
-void print_stat(player_type *player_ptr, int stat)
+void print_stat(PlayerType *player_ptr, int stat)
 {
     GAME_TEXT tmp[32];
     if (player_ptr->stat_cur[stat] < player_ptr->stat_max[stat]) {
@@ -73,7 +73,7 @@ void print_stat(player_type *player_ptr, int stat)
 /*!
  * @brief プレイヤーの負傷状態を表示する
  */
-void print_cut(player_type *player_ptr)
+void print_cut(PlayerType *player_ptr)
 {
     auto player_cut = player_ptr->effects()->cut();
     if (!player_cut->is_cut()) {
@@ -89,7 +89,7 @@ void print_cut(player_type *player_ptr)
  * @brief プレイヤーの朦朧状態を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_stun(player_type *player_ptr)
+void print_stun(PlayerType *player_ptr)
 {
     auto player_stun = player_ptr->effects()->stun();
     if (!player_stun->is_stunned()) {
@@ -105,7 +105,7 @@ void print_stun(player_type *player_ptr)
  * @brief プレイヤーの空腹状態を表示する / Prints status of hunger
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_hunger(player_type *player_ptr)
+void print_hunger(PlayerType *player_ptr)
 {
     if (allow_debug_options && player_ptr->current_floor_ptr->inside_arena)
         return;
@@ -146,7 +146,7 @@ void print_hunger(player_type *player_ptr)
  * This function was a major bottleneck when resting, so a lot of
  * the text formatting code was optimized in place below.
  */
-void print_state(player_type *player_ptr)
+void print_state(PlayerType *player_ptr)
 {
     TERM_COLOR attr = TERM_WHITE;
     GAME_TEXT text[16];
@@ -244,7 +244,7 @@ void print_state(player_type *player_ptr)
  * @brief プレイヤーの行動速度を表示する / Prints the speed_value of a character.                       -CJS-
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_speed(player_type *player_ptr)
+void print_speed(PlayerType *player_ptr)
 {
     TERM_LEN wid, hgt;
     term_get_size(&wid, &hgt);
@@ -301,7 +301,7 @@ void print_speed(player_type *player_ptr)
  * @brief プレイヤーの呪文学習可能状態を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_study(player_type *player_ptr)
+void print_study(PlayerType *player_ptr)
 {
     TERM_LEN wid, hgt;
     term_get_size(&wid, &hgt);
@@ -319,7 +319,7 @@ void print_study(player_type *player_ptr)
  * @brief プレイヤーのものまね可能状態を表示する
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_imitation(player_type *player_ptr)
+void print_imitation(PlayerType *player_ptr)
 {
     TERM_LEN wid, hgt;
     term_get_size(&wid, &hgt);
@@ -345,7 +345,7 @@ void print_imitation(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @bar_flags 表示可否を決めるためのフラグ群
  */
-static void add_hex_status_flags(player_type *player_ptr, BIT_FLAGS *bar_flags)
+static void add_hex_status_flags(PlayerType *player_ptr, BIT_FLAGS *bar_flags)
 {
     if (player_ptr->realm1 != REALM_HEX) {
         return;
@@ -433,7 +433,7 @@ static void add_hex_status_flags(player_type *player_ptr, BIT_FLAGS *bar_flags)
 /*!
  * @brief 下部に状態表示を行う / Show status bar
  */
-void print_status(player_type *player_ptr)
+void print_status(PlayerType *player_ptr)
 {
     TERM_LEN wid, hgt;
     term_get_size(&wid, &hgt);
@@ -652,7 +652,7 @@ void print_status(player_type *player_ptr)
  * @brief プレイヤーのステータスを一括表示する(下部分) / Display extra info (mostly below map)
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void print_frame_extra(player_type *player_ptr)
+void print_frame_extra(PlayerType *player_ptr)
 {
     print_cut(player_ptr);
     print_stun(player_ptr);
index a08f195..13bab0f 100644 (file)
@@ -1,13 +1,13 @@
 #pragma once
 
-struct player_type;
-void print_stat(player_type *player_ptr, int stat);
-void print_cut(player_type *player_ptr);
-void print_stun(player_type *player_ptr);
-void print_hunger(player_type *player_ptr);
-void print_state(player_type *player_ptr);
-void print_speed(player_type *player_ptr);
-void print_study(player_type *player_ptr);
-void print_imitation(player_type *player_ptr);
-void print_status(player_type *player_ptr);
-void print_frame_extra(player_type *player_ptr);
+class PlayerType;
+void print_stat(PlayerType *player_ptr, int stat);
+void print_cut(PlayerType *player_ptr);
+void print_stun(PlayerType *player_ptr);
+void print_hunger(PlayerType *player_ptr);
+void print_state(PlayerType *player_ptr);
+void print_speed(PlayerType *player_ptr);
+void print_study(PlayerType *player_ptr);
+void print_imitation(PlayerType *player_ptr);
+void print_status(PlayerType *player_ptr);
+void print_frame_extra(PlayerType *player_ptr);
index 397a25f..dd019f0 100644 (file)
@@ -63,7 +63,7 @@ void print_field(concptr info, TERM_LEN row, TERM_LEN col)
  * of both "lite_spot()" and "print_rel()", and that we use the
  * "lite_spot()" function to display the player grid, if needed.
  */
-void print_map(player_type *player_ptr)
+void print_map(PlayerType *player_ptr)
 {
     TERM_LEN wid, hgt;
     term_get_size(&wid, &hgt);
@@ -114,7 +114,7 @@ void print_map(player_type *player_ptr)
     (void)term_set_cursor(v);
 }
 
-static void display_shortened_item_name(player_type *player_ptr, object_type *o_ptr, int y)
+static void display_shortened_item_name(PlayerType *player_ptr, object_type *o_ptr, int y)
 {
     char buf[MAX_NLEN];
     describe_flavor(player_ptr, buf, o_ptr, (OD_NO_FLAVOR | OD_OMIT_PREFIX | OD_NAME_ONLY));
@@ -184,7 +184,7 @@ static void display_shortened_item_name(player_type *player_ptr, object_type *o_
  * メインウィンドウ('M'コマンド)、サブウィンドウ兼(縮小図)用。
  * use_bigtile時に横の描画列数は1/2になる。
  */
-void display_map(player_type *player_ptr, int *cy, int *cx)
+void display_map(PlayerType *player_ptr, int *cy, int *cx)
 {
     int i, j, x, y;
 
@@ -323,7 +323,7 @@ void display_map(player_type *player_ptr, int *cy, int *cx)
     view_granite_lite = old_view_granite_lite;
 }
 
-void set_term_color(player_type *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, SYMBOL_CODE *cp)
+void set_term_color(PlayerType *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, SYMBOL_CODE *cp)
 {
     if (!player_bold(player_ptr, y, x))
         return;
index 44f9967..c2048f4 100644 (file)
@@ -16,9 +16,9 @@ extern POSITION panel_row_prt;
 extern int match_autopick;
 extern int feat_priority;
 
-struct player_type;
+class PlayerType;
 void print_field(concptr info, TERM_LEN row, TERM_LEN col);
-void print_map(player_type *player_ptr);
-void display_map(player_type *player_ptr, int *cy, int *cx);
-void set_term_color(player_type *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, SYMBOL_CODE *cp);
+void print_map(PlayerType *player_ptr);
+void display_map(PlayerType *player_ptr, int *cy, int *cx);
+void set_term_color(PlayerType *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, SYMBOL_CODE *cp);
 int panel_col_of(int col);
index d5dd650..cbabe1f 100644 (file)
@@ -48,7 +48,7 @@ static concptr *spoiler_flag_aux(const TrFlags &art_flags, const flag_desc *flag
  * @param o_ptr 記述を得たいオブジェクトの参照ポインタ
  * @param desc_ptr 記述内容を返すための文字列参照ポインタ
  */
-static void analyze_general(player_type *player_ptr, object_type *o_ptr, char *desc_ptr)
+static void analyze_general(PlayerType *player_ptr, object_type *o_ptr, char *desc_ptr)
 {
     describe_flavor(player_ptr, desc_ptr, o_ptr, OD_NAME_AND_ENCHANT | OD_STORE | OD_DEBUG);
 }
@@ -273,7 +273,7 @@ static void analyze_misc(object_type *o_ptr, char *misc_desc)
  * @param o_ptr オブジェクト構造体の参照ポインタ
  * @param desc_ptr 全アーティファクト情報を収める文字列参照ポインタ
  */
-void object_analyze(player_type *player_ptr, object_type *o_ptr, obj_desc_list *desc_ptr)
+void object_analyze(PlayerType *player_ptr, object_type *o_ptr, obj_desc_list *desc_ptr)
 {
     analyze_general(player_ptr, o_ptr, desc_ptr->description);
     analyze_pval(o_ptr, &desc_ptr->pval_info);
@@ -295,7 +295,7 @@ void object_analyze(player_type *player_ptr, object_type *o_ptr, obj_desc_list *
  * @param o_ptr ランダムアーティファクトのオブジェクト構造体参照ポインタ
  * @param desc_ptr 記述内容を収める構造体参照ポインタ
  */
-void random_artifact_analyze(player_type *player_ptr, object_type *o_ptr, obj_desc_list *desc_ptr)
+void random_artifact_analyze(PlayerType *player_ptr, object_type *o_ptr, obj_desc_list *desc_ptr)
 {
     analyze_general(player_ptr, o_ptr, desc_ptr->description);
     analyze_pval(o_ptr, &desc_ptr->pval_info);
index 1942b82..e6b822d 100644 (file)
@@ -2,6 +2,6 @@
 
 struct object_type;
 typedef struct obj_desc_list obj_desc_list;
-struct player_type;
-void object_analyze(player_type *player_ptr, object_type *o_ptr, obj_desc_list *desc_ptr);
-void random_artifact_analyze(player_type *player_ptr, object_type *o_ptr, obj_desc_list *desc_ptr);
+class PlayerType;
+void object_analyze(PlayerType *player_ptr, object_type *o_ptr, obj_desc_list *desc_ptr);
+void random_artifact_analyze(PlayerType *player_ptr, object_type *o_ptr, obj_desc_list *desc_ptr);
index 87b236b..35a4d31 100644 (file)
@@ -118,7 +118,7 @@ void display_debug_menu(int page, int max_page, int page_size, int max_line)
  * @param cmd コマンドキー
  * @return コマンド終了ならTRUE、ページ送りならFALSE
  */
-bool exe_cmd_debug(player_type *player_ptr, char cmd)
+bool exe_cmd_debug(PlayerType *player_ptr, char cmd)
 {
     switch (cmd) {
     case ' ':
@@ -280,7 +280,7 @@ bool exe_cmd_debug(player_type *player_ptr, char cmd)
  * @details
  * 番号を指定するには、それをN及びデバッグコマンドをXとしてとして「0N^aX」とする
  */
-void do_cmd_debug(player_type *player_ptr)
+void do_cmd_debug(PlayerType *player_ptr)
 {
     TERM_LEN hgt, wid;
     term_get_size(&wid, &hgt);
index 015e525..b6be59a 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void do_cmd_debug(player_type *player_ptr);
+class PlayerType;
+void do_cmd_debug(PlayerType *player_ptr);
index a586870..7f5562a 100644 (file)
@@ -166,7 +166,7 @@ SpoilerOutputResultType spoil_fixed_artifact(concptr fname)
                 if (!make_fake_artifact(&obj, a_ref.idx))
                     continue;
 
-                player_type dummy;
+                PlayerType dummy;
                 obj_desc_list artifact;
                 object_analyze(&dummy, &obj, &artifact);
                 spoiler_print_art(&artifact);
index 4f3e5dc..4e2d482 100644 (file)
@@ -27,7 +27,7 @@
  * @param val 価値を返すバッファ参照ポインタ
  * @param k ベースアイテムID
  */
-static void kind_info(player_type *player_ptr, char *buf, char *dam, char *wgt, char *chance, DEPTH *lev, PRICE *val, KIND_OBJECT_IDX k)
+static void kind_info(PlayerType *player_ptr, char *buf, char *dam, char *wgt, char *chance, DEPTH *lev, PRICE *val, KIND_OBJECT_IDX k)
 {
     object_type forge;
     object_type *q_ptr = &forge;
@@ -117,7 +117,7 @@ SpoilerOutputResultType spoil_obj_desc(concptr fname)
         }
 
         std::stable_sort(whats.begin(), whats.end(), [](auto k1_idx, auto k2_idx) {
-            player_type dummy;
+            PlayerType dummy;
             DEPTH d1, d2;
             PRICE p1, p2;
             kind_info(&dummy, nullptr, nullptr, nullptr, nullptr, &d1, &p1, k1_idx);
@@ -132,7 +132,7 @@ SpoilerOutputResultType spoil_obj_desc(concptr fname)
             char wgt[80];
             char chance[80];
             char dam[80];
-            player_type dummy;
+            PlayerType dummy;
             kind_info(&dummy, buf, dam, wgt, chance, &e, &v, k_idx);
             fprintf(spoiler_file, "  %-35s%8s%7s%5d %-40s%9ld\n", buf, dam, wgt, static_cast<int>(e), chance, static_cast<long>(v));
         }
index 64e8a84..6d2d324 100644 (file)
@@ -74,7 +74,7 @@ static concptr attr_to_text(monster_race *r_ptr)
 
 SpoilerOutputResultType spoil_mon_desc(concptr fname, std::function<bool(const monster_race *)> filter_monster)
 {
-    player_type dummy;
+    PlayerType dummy;
     uint16_t why = 2;
     char buf[1024];
     char nam[MAX_MONSTER_NAME + 10]; // ユニークには[U] が付くので少し伸ばす
@@ -182,7 +182,7 @@ static void roff_func(TERM_COLOR attr, concptr str)
  */
 SpoilerOutputResultType spoil_mon_info(concptr fname)
 {
-    player_type dummy;
+    PlayerType dummy;
     char buf[1024];
     path_build(buf, sizeof(buf), ANGBAND_DIR_USER, fname);
     spoiler_file = angband_fopen(buf, "w");
index 30a2e80..e6708c8 100644 (file)
@@ -28,8 +28,8 @@
 #include <tuple>
 #include <vector>
 
-void wiz_enter_quest(player_type *player_ptr);
-void wiz_complete_quest(player_type *player_ptr);
+void wiz_enter_quest(PlayerType *player_ptr);
+void wiz_complete_quest(PlayerType *player_ptr);
 void wiz_restore_monster_max_num();
 
 /*!
@@ -64,7 +64,7 @@ void display_wizard_game_modifier_menu()
  * @brief ゲーム設定コマンドの入力を受け付ける
  * @param player_ptr プレイヤーの情報へのポインタ
  */
-void wizard_game_modifier(player_type *player_ptr)
+void wizard_game_modifier(PlayerType *player_ptr)
 {
     screen_save();
     display_wizard_game_modifier_menu();
@@ -101,7 +101,7 @@ void wizard_game_modifier(player_type *player_ptr)
  * @brief 指定したクエストに突入する
  * @param プレイヤーの情報へのポインタ
  */
-void wiz_enter_quest(player_type* player_ptr)
+void wiz_enter_quest(PlayerType* player_ptr)
 {
     char ppp[30];
     char tmp_val[5];
@@ -128,7 +128,7 @@ void wiz_enter_quest(player_type* player_ptr)
  * @brief 指定したクエストを完了させる
  * @param プレイヤーの情報へのポインタ
  */
-void wiz_complete_quest(player_type *player_ptr)
+void wiz_complete_quest(PlayerType *player_ptr)
 {
     if (!player_ptr->current_floor_ptr->inside_quest) {
         msg_print("No current quest");
index da217ed..4fa26f0 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void wizard_game_modifier(player_type *player_ptr);
+class PlayerType;
+void wizard_game_modifier(PlayerType *player_ptr);
index aca0020..fbb8405 100644 (file)
@@ -99,14 +99,14 @@ T clamp_cast(int val)
 }
 
 void wiz_restore_aware_flag_of_fixed_arfifact(ARTIFACT_IDX a_idx, bool aware = false);
-void wiz_modify_item_activation(player_type *player_ptr);
-void wiz_identify_full_inventory(player_type *player_ptr);
+void wiz_modify_item_activation(PlayerType *player_ptr);
+void wiz_identify_full_inventory(PlayerType *player_ptr);
 
 /*!
     * @brief ゲーム設定コマンドの入力を受け付ける
     * @param player_ptr プレイヤーの情報へのポインタ
        */
-void wizard_item_modifier(player_type *player_ptr)
+void wizard_item_modifier(PlayerType *player_ptr)
 {
     screen_save();
     display_wizard_sub_menu();
@@ -196,7 +196,7 @@ void wiz_restore_aware_flag_of_fixed_arfifact(ARTIFACT_IDX a_idx, bool aware)
  * @brief オブジェクトに発動を追加する/変更する
  * @param catser_ptr プレイヤー情報への参照ポインタ
  */
-void wiz_modify_item_activation(player_type *player_ptr)
+void wiz_modify_item_activation(PlayerType *player_ptr)
 {
     auto q = _("どのアイテムの発動を変更しますか? ", "Which object? ");
     auto s = _("発動を変更するアイテムがない。", "Nothing to do with.");
@@ -220,7 +220,7 @@ void wiz_modify_item_activation(player_type *player_ptr)
  * @brief インベントリ内のアイテムを全て*鑑定*済みにする
  * @param catser_ptr プレイヤー情報への参照ポインタ
  */
-void wiz_identify_full_inventory(player_type *player_ptr)
+void wiz_identify_full_inventory(PlayerType *player_ptr)
 {
     for (int i = 0; i < INVEN_TOTAL; i++) {
         object_type *o_ptr = &player_ptr->inventory_list[i];
@@ -320,7 +320,7 @@ static void prt_binary(BIT_FLAGS flags, const int row, int col)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param o_ptr 詳細を表示するアイテム情報の参照ポインタ
  */
-static void wiz_display_item(player_type *player_ptr, object_type *o_ptr)
+static void wiz_display_item(PlayerType *player_ptr, object_type *o_ptr)
 {
     auto flgs = object_flags(o_ptr);
     auto get_seq_32bits = [](const TrFlags &flgs, uint start) {
@@ -391,7 +391,7 @@ static void wiz_display_item(player_type *player_ptr, object_type *o_ptr)
  * counter flags to prevent weirdness.  We use the items to collect
  * statistics on item creation relative to the initial item.
  */
-static void wiz_statistics(player_type *player_ptr, object_type *o_ptr)
+static void wiz_statistics(PlayerType *player_ptr, object_type *o_ptr)
 {
     concptr q = "Rolls: %ld  Correct: %ld  Matches: %ld  Better: %ld  Worse: %ld  Other: %ld";
     concptr p = "Enter number of items to roll: ";
@@ -480,7 +480,7 @@ static void wiz_statistics(player_type *player_ptr, object_type *o_ptr)
  * Apply magic to an item or turn it into an artifact. -Bernd-
  * @param o_ptr 再生成の対象となるアイテム情報の参照ポインタ
  */
-static void wiz_reroll_item(player_type *player_ptr, object_type *o_ptr)
+static void wiz_reroll_item(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (o_ptr->is_artifact())
         return;
@@ -570,7 +570,7 @@ static void wiz_reroll_item(player_type *player_ptr, object_type *o_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param o_ptr 調整するアイテムの参照ポインタ
  */
-static void wiz_tweak_item(player_type *player_ptr, object_type *o_ptr)
+static void wiz_tweak_item(PlayerType *player_ptr, object_type *o_ptr)
 {
     if (o_ptr->is_artifact())
         return;
@@ -644,7 +644,7 @@ static void wiz_quantity_item(object_type *o_ptr)
  *   - Change properties (via wiz_tweak_item)<br>
  *   - Change the number of items (via wiz_quantity_item)<br>
  */
-void wiz_modify_item(player_type *player_ptr)
+void wiz_modify_item(PlayerType *player_ptr)
 {
     concptr q = "Play with which object? ";
     concptr s = "You have nothing to play with.";
@@ -706,7 +706,7 @@ void wiz_modify_item(player_type *player_ptr)
 /*!
  * @brief オブジェクトの装備スロットがエゴが有効なスロットかどうか判定
  */
-static int is_slot_able_to_be_ego(player_type *player_ptr, object_type *o_ptr)
+static int is_slot_able_to_be_ego(PlayerType *player_ptr, object_type *o_ptr)
 {
     int slot = wield_slot(player_ptr, o_ptr);
 
@@ -737,7 +737,7 @@ static void wishing_puff_of_smoke(void)
  * @param confirm 願わない場合に確認するかどうか
  * @return 願った結果
  */
-WishResultType do_cmd_wishing(player_type *player_ptr, int prob, bool allow_art, bool allow_ego, bool confirm)
+WishResultType do_cmd_wishing(PlayerType *player_ptr, int prob, bool allow_art, bool allow_ego, bool confirm)
 {
     concptr fixed_str[] = {
 #ifdef JP
index b67cfd7..29f7a44 100644 (file)
@@ -4,8 +4,8 @@
 
 enum class WishResultType { FAIL = -1, NOTHING = 0, NORMAL = 1, EGO = 2, ARTIFACT = 3, MAX };
 
-struct player_type;
-void wizard_item_modifier(player_type *player_ptr);
-void wiz_modify_item(player_type *player_ptr);
-WishResultType do_cmd_wishing(player_type *player_ptr, int prob, bool art_ok, bool ego_ok, bool confirm);
-void wiz_identify_full_inventory(player_type *player_ptr);
+class PlayerType;
+void wizard_item_modifier(PlayerType *player_ptr);
+void wiz_modify_item(PlayerType *player_ptr);
+WishResultType do_cmd_wishing(PlayerType *player_ptr, int prob, bool art_ok, bool ego_ok, bool confirm);
+void wiz_identify_full_inventory(PlayerType *player_ptr);
index ee4993c..56a67e0 100644 (file)
@@ -4,7 +4,7 @@
 #include "io/write-diary.h"
 #include "view/display-messages.h"
 
-void msg_print_wizard(player_type *player_ptr, int cheat_type, concptr msg)
+void msg_print_wizard(PlayerType *player_ptr, int cheat_type, concptr msg)
 {
     if (!cheat_room && cheat_type == CHEAT_DUNGEON)
         return;
@@ -28,7 +28,7 @@ void msg_print_wizard(player_type *player_ptr, int cheat_type, concptr msg)
 /*
  * Display a formatted message, using "vstrnfmt()" and "msg_print()".
  */
-void msg_format_wizard(player_type *player_ptr, int cheat_type, concptr fmt, ...)
+void msg_format_wizard(PlayerType *player_ptr, int cheat_type, concptr fmt, ...)
 {
     if (!cheat_room && cheat_type == CHEAT_DUNGEON)
         return;
index 1d6a0fe..7aa54b5 100644 (file)
@@ -2,6 +2,6 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void msg_print_wizard(player_type *player_ptr, int cheat_type, concptr msg);
-void msg_format_wizard(player_type *player_ptr, int cheat_type, concptr fmt, ...);
+class PlayerType;
+void msg_print_wizard(PlayerType *player_ptr, int cheat_type, concptr msg);
+void msg_format_wizard(PlayerType *player_ptr, int cheat_type, concptr fmt, ...);
index 39cfce7..51375a7 100644 (file)
@@ -55,7 +55,7 @@ void display_wizard_player_modifier_menu()
  * @brief プレイヤー設定コマンドの入力を受け付ける
  * @param player_ptr プレイヤーの情報へのポインタ
  */
-void wizard_player_modifier(player_type *player_ptr)
+void wizard_player_modifier(PlayerType *player_ptr)
 {
     screen_save();
     display_wizard_player_modifier_menu();
index fc22d62..5f0b764 100644 (file)
@@ -1,4 +1,4 @@
 #pragma once
 
-struct player_type;
-void wizard_player_modifier(player_type *player_ptr);
+class PlayerType;
+void wizard_player_modifier(PlayerType *player_ptr);
index 90a9ead..a72d32a 100644 (file)
  * @brief プレイヤーを完全回復する /
  * Cure everything instantly
  */
-void wiz_cure_all(player_type *player_ptr)
+void wiz_cure_all(PlayerType *player_ptr)
 {
     (void)life_stream(player_ptr, false, false);
     (void)restore_mana(player_ptr, true);
@@ -224,7 +224,7 @@ static KIND_OBJECT_IDX wiz_create_itemtype()
  * Hack -- this routine always makes a "dungeon object", and applies
  * magic to it, and attempts to decline cursed items.
  */
-void wiz_create_item(player_type *player_ptr)
+void wiz_create_item(PlayerType *player_ptr)
 {
     screen_save();
     OBJECT_IDX k_idx = wiz_create_itemtype();
@@ -258,7 +258,7 @@ void wiz_create_item(player_type *player_ptr)
  * @param a_idx 固定アーティファクトのID
  * @return 固定アーティファクトの名称(Ex. ★ロング・ソード『リンギル』)を保持する std::string オブジェクト
  */
-static std::string wiz_make_named_artifact_desc(player_type *player_ptr, ARTIFACT_IDX a_idx)
+static std::string wiz_make_named_artifact_desc(PlayerType *player_ptr, ARTIFACT_IDX a_idx)
 {
     const auto &a_ref = a_info[a_idx];
     object_type obj;
@@ -277,7 +277,7 @@ static std::string wiz_make_named_artifact_desc(player_type *player_ptr, ARTIFAC
  * @param a_idx_list 選択する候補となる固定アーティファクトのIDのリスト
  * @return 選択した固定アーティファクトのIDを返す。但しキャンセルした場合は std::nullopt を返す。
  */
-static std::optional<ARTIFACT_IDX> wiz_select_named_artifact(player_type *player_ptr, const std::vector<ARTIFACT_IDX> &a_idx_list)
+static std::optional<ARTIFACT_IDX> wiz_select_named_artifact(PlayerType *player_ptr, const std::vector<ARTIFACT_IDX> &a_idx_list)
 {
     constexpr auto MAX_PER_PAGE = 20UL;
     const auto page_max = (a_idx_list.size() - 1) / MAX_PER_PAGE + 1;
@@ -351,7 +351,7 @@ static std::vector<ARTIFACT_IDX> wiz_collect_group_a_idx(const grouper &group_ar
 /*!
  * @brief 固定アーティファクトを生成する / Create the artifact
  */
-void wiz_create_named_art(player_type *player_ptr)
+void wiz_create_named_art(PlayerType *player_ptr)
 {
     screen_save();
 
@@ -390,7 +390,7 @@ void wiz_create_named_art(player_type *player_ptr)
  * @brief プレイヤーの現能力値を調整する / Change various "permanent" player variables.
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void wiz_change_status(player_type *player_ptr)
+void wiz_change_status(PlayerType *player_ptr)
 {
     int tmp_int;
     char tmp_val[160];
@@ -469,7 +469,7 @@ void wiz_change_status(player_type *player_ptr)
  * Create desired feature
  * @param creaturer_ptr プレイヤーへの参照ポインタ
  */
-void wiz_create_feature(player_type *player_ptr)
+void wiz_create_feature(PlayerType *player_ptr)
 {
     POSITION y, x;
     if (!tgt_pt(player_ptr, &x, &y))
@@ -527,7 +527,7 @@ void wiz_create_feature(player_type *player_ptr)
  * @details 0を指定すると地上に飛ぶが、元いた場所にしか飛ばない
  * @todo 可能ならダンジョンの入口 (例:ルルイエなら大洋の真ん中)へ飛べるようにしたい
  */
-static bool select_debugging_floor(player_type *player_ptr, int dungeon_type)
+static bool select_debugging_floor(PlayerType *player_ptr, int dungeon_type)
 {
     auto max_depth = d_info[dungeon_type].maxdepth;
     if ((max_depth == 0) || (dungeon_type > static_cast<int>(d_info.size()))) {
@@ -570,7 +570,7 @@ static bool select_debugging_floor(player_type *player_ptr, int dungeon_type)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @details 範囲外の値が選択されたら再入力を促す
  */
-static bool select_debugging_dungeon(player_type *player_ptr, DUNGEON_IDX *dungeon_type)
+static bool select_debugging_dungeon(PlayerType *player_ptr, DUNGEON_IDX *dungeon_type)
 {
     if (command_arg > 0) {
         return true;
@@ -599,7 +599,7 @@ static bool select_debugging_dungeon(player_type *player_ptr, DUNGEON_IDX *dunge
  * @brief 任意のダンジョン及び階層に飛ぶtための選択処理
  * Go to any level
  */
-void wiz_jump_to_dungeon(player_type *player_ptr)
+void wiz_jump_to_dungeon(PlayerType *player_ptr)
 {
     DUNGEON_IDX dungeon_type = 1;
     if (!select_debugging_dungeon(player_ptr, &dungeon_type)) {
@@ -628,7 +628,7 @@ void wiz_jump_to_dungeon(player_type *player_ptr)
  * Become aware of a lot of objects
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void wiz_learn_items_all(player_type *player_ptr)
+void wiz_learn_items_all(PlayerType *player_ptr)
 {
     object_type forge;
     object_type *q_ptr;
@@ -644,7 +644,7 @@ void wiz_learn_items_all(player_type *player_ptr)
 /*!
  * @brief プレイヤーの種族を変更する
  */
-void wiz_reset_race(player_type *player_ptr)
+void wiz_reset_race(PlayerType *player_ptr)
 {
     char ppp[80];
     sprintf(ppp, "Race (0-%d): ", MAX_RACES - 1);
@@ -672,7 +672,7 @@ void wiz_reset_race(player_type *player_ptr)
  * @brief プレイヤーの職業を変更する
  * @todo 魔法領域の再選択などがまだ不完全、要実装。
  */
-void wiz_reset_class(player_type *player_ptr)
+void wiz_reset_class(PlayerType *player_ptr)
 {
     char ppp[80];
     sprintf(ppp, "Class (0-%d): ", PLAYER_CLASS_TYPE_MAX - 1);
@@ -702,7 +702,7 @@ void wiz_reset_class(player_type *player_ptr)
  * @brief プレイヤーの領域を変更する
  * @todo 存在有無などは未判定。そのうちすべき。
  */
-void wiz_reset_realms(player_type *player_ptr)
+void wiz_reset_realms(PlayerType *player_ptr)
 {
     char ppp[80];
     char tmp_val[160];
@@ -800,7 +800,7 @@ void set_gametime(void)
 /*!
  * @brief プレイヤー近辺の全モンスターを消去する / Delete all nearby monsters
  */
-void wiz_zap_surrounding_monsters(player_type *player_ptr)
+void wiz_zap_surrounding_monsters(PlayerType *player_ptr)
 {
     for (MONSTER_IDX i = 1; i < player_ptr->current_floor_ptr->m_max; i++) {
         monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[i];
@@ -822,7 +822,7 @@ void wiz_zap_surrounding_monsters(player_type *player_ptr)
  * @brief フロアに存在する全モンスターを消去する / Delete all monsters
  * @param player_ptr 術者の参照ポインタ
  */
-void wiz_zap_floor_monsters(player_type *player_ptr)
+void wiz_zap_floor_monsters(PlayerType *player_ptr)
 {
     for (MONSTER_IDX i = 1; i < player_ptr->current_floor_ptr->m_max; i++) {
         monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[i];
@@ -839,7 +839,7 @@ void wiz_zap_floor_monsters(player_type *player_ptr)
     }
 }
 
-void cheat_death(player_type *player_ptr)
+void cheat_death(PlayerType *player_ptr)
 {
     if (player_ptr->sc)
         player_ptr->sc = player_ptr->age = 0;
index 89e4546..41d2ae3 100644 (file)
@@ -2,19 +2,19 @@
 
 #include "system/angband.h"
 
-struct player_type;
-void wiz_cure_all(player_type *player_ptr);
-void wiz_create_item(player_type *player_ptr);
-void wiz_create_named_art(player_type *player_ptr);
-void wiz_change_status(player_type *player_ptr);
-void wiz_create_feature(player_type *player_ptr);
-void wiz_jump_to_dungeon(player_type *player_ptr);
-void wiz_learn_items_all(player_type *player_ptr);
-void wiz_reset_race(player_type *player_ptr);
-void wiz_reset_class(player_type *player_ptr);
-void wiz_reset_realms(player_type *player_ptr);
+class PlayerType;
+void wiz_cure_all(PlayerType *player_ptr);
+void wiz_create_item(PlayerType *player_ptr);
+void wiz_create_named_art(PlayerType *player_ptr);
+void wiz_change_status(PlayerType *player_ptr);
+void wiz_create_feature(PlayerType *player_ptr);
+void wiz_jump_to_dungeon(PlayerType *player_ptr);
+void wiz_learn_items_all(PlayerType *player_ptr);
+void wiz_reset_race(PlayerType *player_ptr);
+void wiz_reset_class(PlayerType *player_ptr);
+void wiz_reset_realms(PlayerType *player_ptr);
 void wiz_dump_options(void);
 void set_gametime(void);
-void wiz_zap_surrounding_monsters(player_type *player_ptr);
-void wiz_zap_floor_monsters(player_type *player_ptr);
-extern void cheat_death(player_type *player_ptr);
+void wiz_zap_surrounding_monsters(PlayerType *player_ptr);
+void wiz_zap_floor_monsters(PlayerType *player_ptr);
+extern void cheat_death(PlayerType *player_ptr);
index 6dc89bf..70fa3ce 100644 (file)
@@ -53,7 +53,7 @@ debug_spell_command debug_spell_commands_list[SPELL_MAX] = {
  * @brief コマンド入力により任意にスペル効果を起こす / Wizard spells
  * @return 実際にテレポートを行ったらTRUEを返す
  */
-bool wiz_debug_spell(player_type *player_ptr)
+bool wiz_debug_spell(PlayerType *player_ptr)
 {
     char tmp_val[50] = "\0";
     int tmp_int;
@@ -99,7 +99,7 @@ bool wiz_debug_spell(player_type *player_ptr)
  * @brief 必ず成功するウィザードモード用次元の扉処理 / Wizard Dimension Door
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void wiz_dimension_door(player_type *player_ptr)
+void wiz_dimension_door(PlayerType *player_ptr)
 {
     POSITION x = 0, y = 0;
     if (!tgt_pt(player_ptr, &x, &y))
@@ -112,7 +112,7 @@ void wiz_dimension_door(player_type *player_ptr)
  * @brief ウィザードモード用モンスターの群れ生成 / Summon a horde of monsters
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void wiz_summon_horde(player_type *player_ptr)
+void wiz_summon_horde(PlayerType *player_ptr)
 {
     POSITION wy = player_ptr->y, wx = player_ptr->x;
     int attempts = 1000;
@@ -129,7 +129,7 @@ void wiz_summon_horde(player_type *player_ptr)
 /*!
  * @brief ウィザードモード用処理としてターゲット中の相手をテレポートバックする / Hack -- Teleport to the target
  */
-void wiz_teleport_back(player_type *player_ptr)
+void wiz_teleport_back(PlayerType *player_ptr)
 {
     if (!target_who)
         return;
@@ -141,7 +141,7 @@ void wiz_teleport_back(player_type *player_ptr)
  * @brief 青魔導師の魔法を全て習得済みにする /
  * debug command for blue mage
  */
-void wiz_learn_blue_magic_all(player_type *player_ptr)
+void wiz_learn_blue_magic_all(PlayerType *player_ptr)
 {
     auto bluemage_data = PlayerClass(player_ptr).get_specific_data<bluemage_data_type>();
     if (!bluemage_data) {
@@ -158,7 +158,7 @@ void wiz_learn_blue_magic_all(player_type *player_ptr)
 /*!
  * @brief 鍛冶師の全てのエッセンスを最大所持量にする
  */
-void wiz_fillup_all_smith_essences(player_type *player_ptr)
+void wiz_fillup_all_smith_essences(PlayerType *player_ptr)
 {
     auto smith_data = PlayerClass(player_ptr).get_specific_data<smith_data_type>();
     if (!smith_data) {
@@ -176,7 +176,7 @@ void wiz_fillup_all_smith_essences(player_type *player_ptr)
  * @param player_ptr プレイヤーへの参照ポインタ
  * @param num 生成処理回数
  */
-void wiz_summon_random_enemy(player_type *player_ptr, int num)
+void wiz_summon_random_enemy(PlayerType *player_ptr, int num)
 {
     for (int i = 0; i < num; i++)
         (void)summon_specific(player_ptr, 0, player_ptr->y, player_ptr->x, player_ptr->current_floor_ptr->dun_level, SUMMON_NONE, PM_ALLOW_GROUP | PM_ALLOW_UNIQUE);
@@ -189,7 +189,7 @@ void wiz_summon_random_enemy(player_type *player_ptr, int num)
  * @details
  * This function is rather dangerous
  */
-void wiz_summon_specific_enemy(player_type *player_ptr, MONRACE_IDX r_idx)
+void wiz_summon_specific_enemy(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     if (r_idx <= 0) {
         int val = 1;
@@ -208,7 +208,7 @@ void wiz_summon_specific_enemy(player_type *player_ptr, MONRACE_IDX r_idx)
  * @details
  * This function is rather dangerous
  */
-void wiz_summon_pet(player_type *player_ptr, MONRACE_IDX r_idx)
+void wiz_summon_pet(PlayerType *player_ptr, MONRACE_IDX r_idx)
 {
     if (r_idx <= 0) {
         int val = 1;
@@ -226,7 +226,7 @@ void wiz_summon_pet(player_type *player_ptr, MONRACE_IDX r_idx)
  * @param effect_idx 属性ID
  * @details デフォルトは100万・GF_ARROW(射撃)。RES_ALL持ちも一撃で殺せる。
  */
-void wiz_kill_enemy(player_type *player_ptr, HIT_POINT dam, AttributeType effect_idx)
+void wiz_kill_enemy(PlayerType *player_ptr, HIT_POINT dam, AttributeType effect_idx)
 {
     if (dam <= 0) {
         char tmp[80] = "";
@@ -268,7 +268,7 @@ void wiz_kill_enemy(player_type *player_ptr, HIT_POINT dam, AttributeType effect
  * @param dam ダメージ量
  * @param effect_idx 属性ID
  */
-void wiz_kill_me(player_type *player_ptr, HIT_POINT dam, AttributeType effect_idx)
+void wiz_kill_me(PlayerType *player_ptr, HIT_POINT dam, AttributeType effect_idx)
 {
     if (dam <= 0) {
         char tmp[80] = "";
index 903e275..44b9e7f 100644 (file)
@@ -6,26 +6,26 @@
 #define SPELL_MAX 5
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 typedef union spell_functions {
     struct debug_spell_type1 {
-        bool (*spell_function)(player_type *, floor_type *);
+        bool (*spell_function)(PlayerType *, floor_type *);
     } spell1;
 
     struct debug_spell_type2 {
-        bool (*spell_function)(player_type *);
+        bool (*spell_function)(PlayerType *);
     } spell2;
 
     struct debug_spell_type3 {
-        bool (*spell_function)(player_type *, HIT_POINT);
+        bool (*spell_function)(PlayerType *, HIT_POINT);
     } spell3;
 
     struct debug_spell_type4 { // 実質 ty curse
-        bool (*spell_function)(player_type *, bool, int*);
+        bool (*spell_function)(PlayerType *, bool, int*);
     } spell4;
 
     struct debug_spell_type5 {
-        void (*spell_function)(player_type *);
+        void (*spell_function)(PlayerType *);
     } spell5;
 
 } spell_functions;
@@ -38,14 +38,14 @@ typedef struct debug_spell_command {
 
 extern debug_spell_command debug_spell_commands_list[SPELL_MAX];
 
-bool wiz_debug_spell(player_type *player_ptr);
-void wiz_dimension_door(player_type *player_ptr);
-void wiz_summon_horde(player_type *player_ptr);
-void wiz_teleport_back(player_type *player_ptr);
-void wiz_learn_blue_magic_all(player_type *player_ptr);
-void wiz_fillup_all_smith_essences(player_type *player_ptr);
-void wiz_summon_random_enemy(player_type *player_ptr, int num);
-void wiz_summon_specific_enemy(player_type *player_ptr, MONRACE_IDX r_idx);
-void wiz_summon_pet(player_type *player_ptr, MONRACE_IDX r_idx);
-void wiz_kill_enemy(player_type *player_ptr, HIT_POINT dam = 1000000, AttributeType effect_idx = AttributeType::ARROW);
-void wiz_kill_me(player_type *player_ptr, HIT_POINT dam, AttributeType effect_idx);
+bool wiz_debug_spell(PlayerType *player_ptr);
+void wiz_dimension_door(PlayerType *player_ptr);
+void wiz_summon_horde(PlayerType *player_ptr);
+void wiz_teleport_back(PlayerType *player_ptr);
+void wiz_learn_blue_magic_all(PlayerType *player_ptr);
+void wiz_fillup_all_smith_essences(PlayerType *player_ptr);
+void wiz_summon_random_enemy(PlayerType *player_ptr, int num);
+void wiz_summon_specific_enemy(PlayerType *player_ptr, MONRACE_IDX r_idx);
+void wiz_summon_pet(PlayerType *player_ptr, MONRACE_IDX r_idx);
+void wiz_kill_enemy(PlayerType *player_ptr, HIT_POINT dam = 1000000, AttributeType effect_idx = AttributeType::ARROW);
+void wiz_kill_me(PlayerType *player_ptr, HIT_POINT dam, AttributeType effect_idx);
index 57d5012..1057c8d 100644 (file)
@@ -192,7 +192,7 @@ static SpoilerOutputResultType spoil_player_spell(concptr fname)
     spoil_out(buf);
     spoil_out("------------------------------------------\n\n");
 
-    player_type dummy_p;
+    PlayerType dummy_p;
     dummy_p.lev = 1;
 
     for (int c = 0; c < PLAYER_CLASS_TYPE_MAX; c++) {
index 56d3399..dadf4c2 100644 (file)
@@ -24,7 +24,7 @@
  * @brief プレイヤーの現在ダンジョンIDと階層に応じて、ダンジョン内ランクエの自動放棄を行う
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void check_random_quest_auto_failure(player_type *player_ptr)
+void check_random_quest_auto_failure(PlayerType *player_ptr)
 {
     if (player_ptr->dungeon_idx != DUNGEON_ANGBAND) {
         return;
@@ -49,7 +49,7 @@ void check_random_quest_auto_failure(player_type *player_ptr)
  * Autosave BEFORE resetting the recall counter (rr9)
  * The player is yanked up/down as soon as he loads the autosaved game.
  */
-void execute_recall(player_type *player_ptr)
+void execute_recall(PlayerType *player_ptr)
 {
     if (player_ptr->word_recall == 0)
         return;
@@ -125,7 +125,7 @@ void execute_recall(player_type *player_ptr)
  * / Handle involuntary movement once every 10 game turns
  * @param player_ptr プレイヤーへの参照ポインタ
  */
-void execute_floor_reset(player_type *player_ptr)
+void execute_floor_reset(PlayerType *player_ptr)
 {
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     if (player_ptr->alter_reality == 0)
index 645a38f..9a91d41 100644 (file)
@@ -1,6 +1,6 @@
 #pragma once
 
-struct player_type;
-void check_random_quest_auto_failure(player_type *player_ptr);
-void execute_recall(player_type *player_ptr);
-void execute_floor_reset(player_type* player_ptr);
+class PlayerType;
+void check_random_quest_auto_failure(PlayerType *player_ptr);
+void execute_recall(PlayerType *player_ptr);
+void execute_floor_reset(PlayerType* player_ptr);
index 30c7b7e..30f3342 100644 (file)
@@ -66,7 +66,7 @@ OBJECT_IDX o_pop(floor_type *floor_ptr)
  * Note that if no objects are "appropriate", then this function will\n
  * fail, and return zero, but this should *almost* never happen.\n
  */
-OBJECT_IDX get_obj_num(player_type *player_ptr, DEPTH level, BIT_FLAGS mode)
+OBJECT_IDX get_obj_num(PlayerType *player_ptr, DEPTH level, BIT_FLAGS mode)
 {
     if (level > MAX_DEPTH - 1)
         level = MAX_DEPTH - 1;
index d20761b..94ee3c5 100644 (file)
@@ -3,6 +3,6 @@
 #include "system/angband.h"
 
 struct floor_type;
-struct player_type;
+class PlayerType;
 OBJECT_IDX o_pop(floor_type *floor_ptr);
-OBJECT_IDX get_obj_num(player_type *player_ptr, DEPTH level, BIT_FLAGS mode);
+OBJECT_IDX get_obj_num(PlayerType *player_ptr, DEPTH level, BIT_FLAGS mode);
index b8d7e1a..7285ffb 100644 (file)
@@ -43,7 +43,7 @@
 #include "world/world-movement-processor.h"
 #include "world/world.h"
 
-WorldTurnProcessor::WorldTurnProcessor(player_type *player_ptr)
+WorldTurnProcessor::WorldTurnProcessor(PlayerType *player_ptr)
     : player_ptr(player_ptr)
 {
 }
index c1ec18a..9e6cda9 100644 (file)
@@ -1,15 +1,15 @@
 #pragma once
 
-struct player_type;
+class PlayerType;
 class WorldTurnProcessor {
 public:
-    WorldTurnProcessor(player_type *player_ptr);
+    WorldTurnProcessor(PlayerType *player_ptr);
     virtual ~WorldTurnProcessor() = default;
     void process_world();
     void print_time();
 
 private:
-    player_type *player_ptr;
+    PlayerType *player_ptr;
     int hour = 0;
     int min = 0;
 
index fcce349..fe3fc1b 100644 (file)
@@ -28,7 +28,7 @@ bool is_daytime(void)
  * @param hour 時数を返すための参照ポインタ
  * @param min 分数を返すための参照ポインタ
  */
-void extract_day_hour_min(player_type *player_ptr, int *day, int *hour, int *min)
+void extract_day_hour_min(PlayerType *player_ptr, int *day, int *hour, int *min)
 {
     const int32_t A_DAY = TURNS_PER_TICK * TOWN_DAWN;
     int32_t turn_in_today = (w_ptr->game_turn + A_DAY / 4) % A_DAY;
index 030330c..391377a 100644 (file)
@@ -68,9 +68,9 @@ struct world_type {
 
 extern world_type *w_ptr;
 
-struct player_type;
+class PlayerType;
 bool is_daytime(void);
-void extract_day_hour_min(player_type *player_ptr, int *day, int *hour, int *min);
+void extract_day_hour_min(PlayerType *player_ptr, int *day, int *hour, int *min);
 void update_playtime(void);
 void add_winner_class(PlayerClassType c);
 void add_retired_class(PlayerClassType c);