Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CPP Ecosystem Project
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RIVOAL Samuel
CPP Ecosystem Project
Merge requests
!23
Aymeric
Code
Review changes
Check out branch
Download
Patches
Plain diff
Expand sidebar
Merged
Aymeric
Aymeric
into
master
Overview
0
Commits
4
Pipelines
0
Changes
17
Merged
BERTHOUMIEU Aymeric
requested to merge
Aymeric
into
master
4 years ago
Overview
0
Commits
4
Pipelines
0
Changes
17
0
0
Merge request reports
Viewing commit
6c8df384
Prev
Next
Show latest version
17 files
+
297
−
42
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
17
6c8df384
test
· 6c8df384
Aymeric berthoumieu
authored
4 years ago
src/Animal.cpp
+
8
−
2
View file @ 6c8df384
Edit in single-file editor
Open in Web IDE
Show full file
@@ -163,6 +163,9 @@ void Animal::onCollision(){
}
}
double
Animal
::
getSpeed
(){
return
speed
;
}
int
Animal
::
getLife
()
const
{
return
life
;
@@ -200,14 +203,17 @@ void Animal::setCumul(double new_cumul_x,double new_cumul_y){
std
::
tuple
<
double
,
double
>
Animal
::
getOrientationSpeed
(){
return
std
::
make_tuple
(
this
->
orientation
,
this
->
s
peed
);
return
std
::
make_tuple
(
this
->
orientation
,
this
->
getS
peed
()
);
}
void
Animal
::
setOrientationSpeed
(
double
new_orientation
,
double
new_speed
){
this
->
orientation
=
new_orientation
;
this
->
speed
=
new_speed
;
}
vector
<
string
>
Animal
::
getAccessoriesAndCaptors
(){
vector
<
string
>
names
;
return
names
;
}
BehaviourStrategy
*
choose_behaviour
()
{
BehaviourStrategy
*
behaviour
;
Loading