Commit 4799ec10 authored by Daniel Graungaard's avatar Daniel Graungaard
Browse files

Added intyerface elements and debugging

parent 582e0243
......@@ -69,6 +69,7 @@ to setup
set emotionelt 10
set humor 10
set nuttethed 10
set energi 10 ; Dette er den mængde energi videoen starter med
set completed-segments (list)
set viewers (list)
......@@ -100,23 +101,25 @@ end
to go
if any? videos with [energi < 0 ] [user-message "Din video er løbet tør for energi. Øv" stop]
if any? videos with [energi <= 0 ] [user-message "Din video er løbet tør for energi. Øv" stop]
if completed? [user-message "Din video har været i alle fire segmenter" stop]
ask videos [
move
set energi energi - 1
; This is the core of the ssubject matter. The algorithm below !SHOULD! be finalized with teachers!
set energi (energi - 1)
; This is the core of the subject matter. The algorithm below !SHOULD! be finalized with teachers!
let deltas (list (utrolige-evner-præference - utrolige-evner) (empati-præference - emotionelt) (nuttethed-præference - nuttethed) (humor-præference - humor))
let average sum deltas / length deltas
(ifelse average <= 1 [
set energi energi + 5
] average <= 2 [
set energi energi + 3
] average <= 3 [
set energi energi + 1
show average
(ifelse abs average <= 1 [
set energi (energi + 1)
] abs average <= 2 [
set energi (energi + 0.5)
] abs average <= 3 [
set energi (energi + 0.2)
])
if energi > 1000 [
......@@ -138,8 +141,8 @@ end
to move ;turtle method
ifelse wall? [
forward -1
right 180
forward 1
] [
right random 360
forward random 2
......@@ -208,18 +211,15 @@ to-report find-current-segment
])
end
@#$#@#$#@
GRAPHICS-WINDOW
210
10
647
448
402
108
1368
1075
-1
-1
13.0
9.49
1
10
1
......@@ -229,10 +229,10 @@ GRAPHICS-WINDOW
0
0
1
-16
16
-16
16
-50
50
-50
50
0
0
1
......@@ -264,7 +264,7 @@ CHOOSER
start
start
"TOP RIGHT" "TOP LEFT" "BOTTOM RIGHT" "BOTTOM LEFT"
3
0
BUTTON
117
......@@ -301,16 +301,56 @@ NIL
1
MONITOR
1179
201
1236
246
29
248
86
293
NIL
views
17
1
11
TEXTBOX
414
116
564
152
Pre-teens
30
46.0
1
TEXTBOX
418
1026
568
1062
Teens
30
0.0
1
TEXTBOX
1275
115
1425
151
Ældre
30
0.0
1
TEXTBOX
1248
1028
1398
1064
Voksne
30
0.0
1
@#$#@#$#@
## WHAT IS IT?
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment