Commit da9c334e authored by Daniel Graungaard's avatar Daniel Graungaard
Browse files

Noe with view color

parent c474580f
......@@ -3,11 +3,11 @@ breed[child-teens child-teen]
breed[young-adults young-adult]
breed[adults adult]
breed[seniors senior]
videos-own [vrede interessant realisme aww latter energi completed-segments viewers]
seniors-own [vrede-præference interessant-præference realisme-præference aww-præference latter-præference]
adults-own [vrede-præference interessant-præference realisme-præference aww-præference latter-præference]
young-adults-own [vrede-præference interessant-præference realisme-præference aww-præference latter-præference]
child-teens-own [vrede-præference interessant-præference realisme-præference aww-præference latter-præference]
videos-own [vrede interessant realisme aww latter energi completed-segments]
seniors-own [vrede-præference interessant-præference realisme-præference aww-præference latter-præference viewers-views]
adults-own [vrede-præference interessant-præference realisme-præference aww-præference latter-præference viewers-views]
young-adults-own [vrede-præference interessant-præference realisme-præference aww-præference latter-præference viewers-views]
child-teens-own [vrede-præference interessant-præference realisme-præference aww-præference latter-præference viewers-views]
globals [completed? views top-right-patches bottom-right-patches top-left-patches bottom-left-patches]
to setup
......@@ -36,7 +36,7 @@ to setup
ask turtles [
set color grey
set color gray
]
;top left - pre-teens
......@@ -92,15 +92,14 @@ ask turtles [
jump-to start
;husk at den samlede mængde point herunder ikke må overstige 30 point
set vrede 2
set interessant 2
set realisme 2
set aww 2
set latter 2
set vrede 7
set interessant 7
set realisme 7
set aww 7
set latter 7
set energi 10 ; Dette er den mængde energi videoen starter med
set completed-segments (list)
set viewers (list)
set label-color green
set size 2
]
......@@ -183,15 +182,9 @@ to go
set energi (energi - 1)
;set vrede-præference number-from-interval [1 5]
;set interessant-præference number-from-interval [4 7]
;set realisme-præference number-from-interval [2 5]
;set aww-præference number-from-interval [6 10]
;set latter-præference number-from-interval [7 10]
let viewer one-of other turtles-here
if viewer != nobody [ ; solves problem where video gets to close to the edges, would probably be better to change the behavior so it never steps out of bounds
if viewer != nobody [ ; check if we have a viewer, solves problem where video gets to close to the edges, would probably be better to change the behavior so it never steps out of bounds
let vrede-præference-her [vrede-præference] of viewer
let interessant-præference-her [interessant-præference] of viewer
......@@ -200,7 +193,7 @@ to go
let latter-præference-her [latter-præference] of viewer
let deltas (list (latter-præference-her - latter) (aww-præference-her - aww) (realisme-præference-her - realisme) (interessant-præference-her - interessant) (vrede-præference-her - vrede))
;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
......@@ -217,12 +210,20 @@ to go
move-to-next-segment
]
if(not member? patch-here viewers)
[
set views views + 1
set viewers lput patch-here viewers
set views views + 1
ask viewer [
set viewers-views viewers-views + 1
let red-value viewers-views * 10
if red-value < 255 [
set color (list red-value 0 0)
]
]
set label round energi
]
......
Markdown is supported
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