Antonio Jose de Vasconcelos Costa - ajvc
Breno Batista Machado - bbm
Cleyton Mario de Oliveira Rodrigues - cmor
Marcos Aurelio Almeida da Silva - maas
Pablo Santana Barbosa – psb
Renata Teles Moreira - rtm
Weslei Alvim de Tarso Marinho - watm






O que é Rollerslam?
Características
Estratégias
Logging
Dificuldades
Estatísticas
Gaelic
Football
Australian
Football
Soccer
Handball
Rollerslam!
Basketball
Ice
Hockey
Slamball
Roller
Derby
Rugby
American
Football
Rollerslam Simulation GUI
Game
Visualization
GUI
referee
Agent Reasoning
Visualization GUI
playerAgent1(teamA)
playerAgent1(teamB)
playerAgent20(teamA)
Coach(teamB)
gamePhysicsRulesSimulatorAgent
...
...
Coach(teamA)
playerAgent20(teamB)






O que é Rollerslam?
Características
Estratégias
Logging
Dificuldades
Estatísticas
Effector
Sensor
effector
<<interface>>
Effector
+ doAction(ac:Message)
<<component>>
Agent
Message
+ sender : Agent
sensor
<<interface>>
Sensor
+ getActions() : Message[0..*]
SimulationStateProvider
DisplayRegistry
Logging
logging
server
SimulationAdmin
simulation
AgentRegistry
client
<<component>>
Server
AgentRegistryExt
ClientInitialization
environment[1]
agent[*]
ServerInitialization
Effector
Sensor
Display Effector
Service
effector
sensor
effector
<<component>>
Rollerslam
Agent
initialization
registration
Sensor
sensor
simulation
<<component>>
Rollerslam
Environment
logging
logging
display
registration
<<component>>
Rollerslam
Display
simulation
initialization

Agente GoalBased:
◦ Jogadores;
◦ Técnicos.
effector
sensor
<<component>>
AutomataAgent
simulation
worldModel
+ state : SimulationState
<<component>>
GoalBasedAgent
GoalInitialization
<<interface>>
GoalInitialization
+ initialize(m:GoalBasedEnvironmentStateModel)
worldModel
Environment
State
Model
GoalBased
Environment
State
Model
GoalUpdate
<<interface>>
GoalUpdate
+ updateGoal(m:GoalBasedEnvironmentStateModel)
Agente Autômato – O Ambiente
SimulationStateProvider
Effector
effector
Sensor
sensor
simulation
<<interface>>
ModelBasedBehaviorStrategy
+ computeAction(w:EnvironmentStateModel):Message
<<component>>
AutomataAgent
<<interface>>
ModelInitialization
+ state : SimulationState
# initialize()
# think()
+ initialize(m:EnvironmentStateModel)
worldModel
ModelInitialization
Environment
State
Model
<<interface>>
ActionInterpretation
+processAction(w:EnvironmentStateModel, m:Message)
ActionInterpretation
RamificationComponent
ModelBasedBehaviorStrategy
<<interface>>
RamificationComponent
+processRamifications(world : EnvironmentStateMode)
Comportamento do Ambiente
ramificationsComponent^
processRamifications(worldModel)
self^initialize()
sensor
.getActions()
s : Set of
Message
s->forAll(x | actionInterpretation
^processAction(worldModel,x))
[not state = RUNNING]
self^think()
modelBasedBehaviorStrategy
^computeAction(worldModel)
effector^
doAction(action)
action :
Message
Simulation
RMI
Rollerslam
Mobile
Display
Socket
Socket
Mobile
Client 1
Mobile
Client 2
Socket
Mobile
Client 3






O que é?
Características
Estratégias
Logging
Dificuldades
Estatísticas


As percepções que os agentes (player, coach e
refeer) recebem é o modelo completo do ambiente,
já que o ambiente é totalmente observável para
todos os agentes.
As percepções que o agente environment recebe
são as ações dos outros agentes.

As ações do agente player são:

A ação dos agentes refeer e coach é:

A ação do agente environment é enviar o modelo do ambiente
para os outros agentes.
◦
◦
◦
◦
◦
◦
◦
◦
◦
◦
Catch – Pegar a bola com as mãos;
Release – Soltar a bola;
Tackle – Derrubar outro jogador;
Countertackle – Defender de um Tackle de outro jogador;
Throw – Jogar a bola com as mãos;
Kick – Chutar a bola com os pés;
Hit – Chutar a bola de primeira;
Dash – Mover-se;
StandUp – Levantar-se;
SendMsg – Envia uma mensagem para outros agentes.
◦ SendMsg – Envia uma mensagem para outros agentes.


O agente player considera:
◦
◦
◦
◦
◦
◦
Seu objetivo inicial;
A posição da bola;
A posição dos jogadores;
Quem esta com a bola (time);
A função do jogador (papel que ele esta desempenhando no momento);
Ações de outros agentes.
◦
◦
◦
◦
◦
Seu objetivo inicial;
A posição da bola;
A posição dos jogadores;
Quem esta com a bola (time);
Placar do jogo (mudar a estratégia).
O agente coach considera:

O agente refeer considera:

O agente environment considera:
◦ A posição da bola;
◦ Quem esta com a bola (time).
◦ O estado atual do ambiente;
◦ Ações recebidas dos agentes.


O agente player recebe as informações do agente
coach com o seu papel. A partir daí o agente player
toma as decisões de acordo com seu papel. O
agente player recebe o modelo do ambiente
(ambiente totalmente observável) como percepção,
e a partir daí ele toma as decisões de acordo com o
estado atual do modelo do ambiente, do objetivo
do seu papel e das mensagens recebidas de outros
agentes.
O agente refeer toma a decisão (gol ou não) de
acordo com a posição da bola e quem está com a
bola.


O agente coach recebe mensagens dos agentes
players (que ainda não possuem um papel) e
distribui um papel para estes de acordo com a
ordem de envio das mensagens. Para as decisões
de mudança de estratégia o agente coach
considera quem (time) está com a bola, a posição
dos jogadores e o placar do jogo.
O agente environment toma as decisões de
mudança de estado do ambiente de acordo com as
ações recebidas dos outros agentes.

As decisões são somente para a próxima ação, pois
ele toma a decisão de acordo com o modelo atual
do ambiente.


Todos os agentes estão totalmente cientes
da presença dos outros agentes no
ambiente, visto que o ambiente é
totalmente observável.
As trocas de informações podem ser:
◦ Mensagens de informações táticas e estratégicas entre
player e refeer;
◦ As percepções entre environment e os outros agentes;
◦ As ações entre os outros agentes e o environment.

Eles se coordenam por partilha de tarefas, ao
definir os papéis que cada jogador tem no jogo
(responsabilidade do técnico). Após seu papel
definido, irão agir independentes de acordo com
seu papel, e as comunicações dos outros agentes.
Não possui negociação, pois os jogadores são
cooperativos. Não possuem aprendizagem.

É hibrida, pois é centralizada na distribuição dos
papéis e na mudança de estratégia e emergente
nos outros momentos.


Todos os players são iguais, mais eles agem de
maneira diferente de acordo com os papéis
atribuídos a eles, logo os direitos e deveres são
diferenciados de acordo com o seu papel.
Os agentes player, coach e refeer são diferentes e
possuem direitos e deveres diferentes.

Os objetivos individuais do agente (do seu papel)
se complementam para atingir o objetivo geral do
grupo.
Máquina de Estados
JOIN_GAM
E
send JoinGameAction/
WAIT_JOIN
_GAME
[model->gameStarted]
INITIALIZATIO
N
send InitializationFact/
STAND_UP
send StandUpAction/
[me->inGround]
send DashAction/
[me->hasBall and
not me->inGround and
not nearBall()]
GO_TO_GO
AL
GO_TO_INI
T_COORD
[nearBall() and not
me->inGround]
STOP
recv DefineRoleFact/
SET_ROLES
[insideArea(0.10) and
not me->hasBall and
not me->inGround and
not nearBall()]
GO_TO_BALL
[not me->inGround]
send DashAction/
[nearBall()]
send DashAction/
send StandUpAction/
[me->inGround]
[nearBall() and
not me->inGround()]
[not nearBall()]
WAIT_MOVIME
NT
send StandUpAction/
[me->inGround]
GO_TO_INI
T_COORD
send DashAction/
[ball->withPlayer and
playerWithBall.team = me.team]
send DashAction/
[not me->inGround
and not nearBall()
and not veryNearBall()]
GO_TO_BAL
L
STAND_UP
send StandUpAction/
[me->inGround]
send TackleAction/
[not me->inGround
and veryNearBall()]
TACKLE_PLA
YER
[ball->withPlayer and
playerWithBall.team <> me.team]
send CatchAction/
[not ball->withPlayer]
CATCH_BAL
L
send CounterTackleAction/
[nearOpponent()]
send DashAction/
COUNTER_TAC
KLE
GO_TO_GOAL
[not nearOpponent()]
[me->hasBall]
CATCH_BAL
L
[not me->inGround]
send DashAction/
[not me->hasBall]
[nearBall()]
send StandUpAction/
[me->inGround]
[playerWithBall.team <> me.team]
STAND_UP
send DashAction/
[not nearBall()]
send DashAction/
[playerWithBall.team = me.team]
GO_TO_INIT_COO
R
GO_TO_BALL
TACKLE_PLA
YER
send DashAction/
[not me->inGround]
[playerWithBall.team = me.team]
[playerWithBall.team <> me.team]
send StandUpAction/
send DashAction/
[me->inGround]
[not nearBall()]
STAND_UP
send DashAction/
[nearBall()]
GO_TO_BALL
GO_TO_INIT_COOR
D
send DashAction/
STAND_UP
[not me->inGround]
[playerWithBall.team = me.team]
[playerWithBall.team <> me.team]
send StandUpAction/
send DashAction/
[me->inGround]
[not nearBall()]
STAND_UP
send DashAction/
[nearBall()]
GO_TO_BALL
GO_TO_INIT_COOR
D
STAND_UP
send StandUpAction/
[me->inGround]
GO_TO_GO
AL
send DashAction/
[nearBall()]
GO_TO_BALL
send DashAction/
GO_TO_INIT_COO
R
[not me->inGround
and not me->hasBall]
[not nearBall()]
[not me->inGround
and me->hasBall]
send ThrowAction/
[not manyOponentsNear()
and nearGoal(30000)]
send KickAction/
[manyOponentsNear()]
KICK_BALL
Near 30
meter
(30000
millimeter)
send KickAction/
[not manyOponentsNear()
and nearGoal(50000)]
Near 50
meter
(50000
millimeter)
THROW_BALL
STAND_UP
send StandUpAction/
send DashAction/
[hasBall()]
[me->inGround]
THROW_BAL
L
GO_TO_GOAL
[not me->inGround
and playerWithBall.team = me.team]
send DashAction/
[not me->inGround
and not playerWithBall.team = me.team]
[not hasBall()]
send DashAction/
[not nearBall()]
send DashAction/
[nearBall()]
GO_TO_BALL
GO_TO_INIT_COO
R
STAND_UP
send StandUpAction/
send DashAction/
[hasBall()]
[me->inGround]
THROW_BAL
L
GO_TO_GOAL
[not me->inGround
and playerWithBall.team = me.team]
send DashAction/
[not me->inGround
and not playerWithBall.team = me.team]
[not hasBall()]
send DashAction/
[not nearBall()]
send DashAction/
[nearBall()]
GO_TO_BALL
GO_TO_INIT_COO
R
STAND_UP
send StandUpAction/
[me->inGround]
COUNTER_TAC
KLE
[not me->inGround
and me.hasBall]
GO_TO_GOAL
[not me->inGround
and not me.hasBall]
send DashAction/
[not nearBall()]
send DashAction/
[nearBall()]
GO_TO_BALL
GO_TO_INIT_COO
R
Máquina de Estados
WAIT_JOIN_GAM
E
[model->gameStarted]
LISTENING
send SendMsgAction/
[not receiveAgentInitMsg()] [receiveAgentInitMsg()]
SET_POSITIO
N
[teamWinning() and
not teamLosing()]
send SendMsgAction/
CHANGE_DEFENSI
VE_POSITION
send SendMsgAction/
[teamLosing() and
not teamWinning()]
CHANGE_OFFENSI
VE_POSITION
[not teamLosing() and
not teamWinning() and
manyEnemyNearBall()]
GO_TO_BALL
send SendMsgAction






O que é Rollerslam?
Características
Estratégias
Logging
Dificuldades
Estatísticas
Logging – Trace Driver
Minimal Trace Event
Simulation
Simulation Level
Reasoning Trace
Team
1..*
Additional Data
Agent Level
Reasoning Trace
Agent
1..*
Component
1..*
Algorithmic Workflow
1..*
Imperative Object
Trace
Query
1..*
Service Level
Reasoning Trace
Service
Non-Reasoning Service
User
Reasoning Service
1..*
Tracer
Driver
Trace Query
OO Rule
Firing Level
Reasoning Trace
Object-Oriented Rule
1..*
Logical Object
Inheritance Level
Reasoning Trace
Logical Object Molecule
1..*
Logical Constraint Atom
Justification-Based
Logical Constraint
Matching/Entailment Level
Reasoning Trace
Integrated
MultiGranularity
Reasoning
Trace Query
&
Visualization
GUI
<<component>>
LogRecorder
LogRecording
Service
<<delegate>>
LogRecording
ServiceImpl
Simulation
Description
<<component>>
LogPlayer
Log Playing
Service
<<delegate>>
LogPlayer
Impl
-------------------------------+ currentCycle : Integer
Simulation
Description
<<window>>
LogPlayerDisplay
<<frame>>
GameCanvas
<<ComboBox>>
AgentFilter
<<Text>>
CurrentCycle
<<Slider>>
CurrentCycleSlider
<<ComboBox>>
MessageTypeFilter
<<Button>>
Show
<<Text>>
Messages
<<Text>>
Speed
<<Slider>>
SpeedSlider
<<Button>>
Run
<<Button>>
LoadSimulation
<<FileChooser>>
SelectSimulation





O que é Rollerslam?
Características
Estratégias
Dificuldades
Estatísticas



Laboratórios cheios
Problemas relativos a distribuição
Máquinas diferentes nos laboratórios
◦ IP fora do padrão
◦ DNS não funciona
◦ Muito lenta

Uso de:
◦ CHR
◦ FLUX

Trace Driver





O que é Rollerslam?
Características
Estratégias
Dificuldades
Estatísticas

Arquivos: ~650 arquivos
Linhas de código: ~6000
Commits: ~600
Slides (documentação): ~300
Reuniões: ~60

Por que aproximadamente?




◦ Está sempre sendo atualizado,
quando você ler isto,
os números já estarão diferentes
http://rollerslam.googlecode.com
Download

Logging - rollerslam