📄 handleball.h
字号:
/*
Copyright (C) 2001 Tsinghuaeolus
Authors : ChenJiang, YaoJinyi, CaiYunpeng, Lishi
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
If you make any changes or have any comments we would appreciate a
message to yjy01@mails.tsinghua.edu.cn.
*/
#ifndef _handleball
#define _handleball
#include "command.h"
#include "geometry.h"
#include "shoot.h"
#include "interception.h"
#include "objects.h"
#include "pass.h"
class Handleball{
private:
Time startime, action_times;
ActionType lastaction;
bool handleable;
/* inner-module competition
the result is saved in log*** */
bool DoShootDecision();
bool DoDribbleDecision();
bool DoPassDecision();
/* inter-module competition */
void Evaluate();
//sensitivity grad info
bool passable;
bool dribblable;
bool shootable;
float pass_priority;
float dribble_priority;
float shoot_priority;
Command shootcommand;
public:
bool Handlable();
bool Tryhandle();
void B_evaluate();
bool DoHandleballDecision();
PassInfo logpass;
float logdribble;
ShootInfo logshoot;
float GetShootPriority(ShootInfo& shoot);
float GetDribblePriority(AngleDeg angle);
float GetPassPriority(PassInfo& passinfo);
float GetMinShootSpeed(){ return logshoot.MinShootSpeed();}
AngleDeg GetShootAngle(){ return logshoot.ShootAngle();}
UNum GetReceiver(){ return logpass.Receiver();}
float GetPassSpeed(){ return logpass.PassSpeed();}
AngleDeg GetPassAngle(){ return logpass.PassAngle();}
AngleDeg GetDribbleAngle(){ return logdribble;}
bool WaitPassLook();
};
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -