
Time is good
Fork of Robot2016_2-0 by
Map/Objectif/objectif.cpp@76:a862cb10559c, 2016-05-05 (annotated)
- Committer:
- sype
- Date:
- Thu May 05 06:34:13 2016 +0000
- Revision:
- 76:a862cb10559c
- Parent:
- 75:195dd2bb13a3
debuggage
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
IceTeam | 57:86f491f5b25d | 1 | #include "objectif.h" |
IceTeam | 57:86f491f5b25d | 2 | |
sype | 76:a862cb10559c | 3 | /* Dernier Changement : Romain 20h20 */ |
IceTeam | 57:86f491f5b25d | 4 | |
sype | 76:a862cb10559c | 5 | objectif::objectif (int ntype, float nx_obj, float ny_obj, float nthet_obj, AX12 * np, ControlleurPince * npince) { |
IceTeam | 60:8d2320a54a32 | 6 | Parasol = np; |
IceTeam | 60:8d2320a54a32 | 7 | pince = npince; |
IceTeam | 60:8d2320a54a32 | 8 | type = ntype; |
IceTeam | 60:8d2320a54a32 | 9 | x_objectif = nx_obj; |
IceTeam | 60:8d2320a54a32 | 10 | y_objectif = ny_obj; |
IceTeam | 60:8d2320a54a32 | 11 | thet_objectif = nthet_obj; |
IceTeam | 60:8d2320a54a32 | 12 | } |
IceTeam | 62:80a81e4ad9f8 | 13 | |
IceTeam | 62:80a81e4ad9f8 | 14 | bool objectif::Action () { |
IceTeam | 57:86f491f5b25d | 15 | switch(type) { |
sype | 76:a862cb10559c | 16 | case OBJ_BLOC: |
IceTeam | 60:8d2320a54a32 | 17 | return obj_bloc_action(); |
sype | 76:a862cb10559c | 18 | break; |
IceTeam | 60:8d2320a54a32 | 19 | case OBJ_PARA: |
IceTeam | 60:8d2320a54a32 | 20 | return obj_para_action(); |
sype | 76:a862cb10559c | 21 | break; |
IceTeam | 57:86f491f5b25d | 22 | default: |
sype | 76:a862cb10559c | 23 | break; |
IceTeam | 64:24e1057a97f7 | 24 | } |
IceTeam | 60:8d2320a54a32 | 25 | } |
IceTeam | 60:8d2320a54a32 | 26 | |
IceTeam | 62:80a81e4ad9f8 | 27 | bool objectif::obj_bloc_action () { |
IceTeam | 75:195dd2bb13a3 | 28 | return true; |
IceTeam | 60:8d2320a54a32 | 29 | } |
IceTeam | 60:8d2320a54a32 | 30 | |
IceTeam | 63:176d04975f06 | 31 | bool objectif::obj_para_action() { |
IceTeam | 57:86f491f5b25d | 32 | return true; |
IceTeam | 57:86f491f5b25d | 33 | } |