Skip to content

Commit

Permalink
Run environment: remove console spam
Browse files Browse the repository at this point in the history
  • Loading branch information
FilipChalupa committed Feb 6, 2025
1 parent e107f70 commit 79ce9ba
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/utilities/runEnvironment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,6 @@ function* run(

for (const instruction of instructions) {
const isConditionFulfilled = getFulfilledConditions()
console.log('')
console.log(instruction)
if (instruction.type === 'go_forward') {
if (elementsAt(playerState.x + 1, playerState.y).includes('hole')) {
playerState.x++
Expand Down Expand Up @@ -179,9 +177,6 @@ function* run(
yield step('invalidMove')
}
} else if (instruction.type === 'pick') {
console.log(isConditionFulfilled)
console.log(elements)
console.log(elementsAt(playerState.x, playerState.y))
if (isConditionFulfilled.sword) {
playerState.hasSword = true
yield step('pickSword')
Expand Down Expand Up @@ -329,7 +324,6 @@ export function* runEnvironment(
while (true) {
const { value, done } = runtime.next()
if (done) {
console.log('done', value)
if (value.type === 'final') {
if (value.success) {
return {
Expand All @@ -345,7 +339,6 @@ export function* runEnvironment(
}
return value satisfies never
}
console.log({ value })
yield value
}
}
Expand Down

0 comments on commit 79ce9ba

Please sign in to comment.