source: cpp/frams/neuro/impl/neuroimpl-body-sdk.h @ 298

Last change on this file since 298 was 288, checked in by Maciej Komosinski, 10 years ago

GDK->SDK, gdk_test.cpp -> genomanipulation.cpp

  • Property svn:eol-style set to native
File size: 2.4 KB
Line 
1// This file is a part of Framsticks SDK.  http://www.framsticks.com/
2// Copyright (C) 1999-2015  Maciej Komosinski and Szymon Ulatowski.
3// See LICENSE.txt for details.
4
5#ifndef _NEUROIMPLBODY_H_
6#define _NEUROIMPLBODY_H_
7
8#include <frams/neuro/neuroimpl.h>
9
10class NI_Gyro: public NeuroImpl
11{
12public:
13NeuroImpl* makeNew(){return new NI_Gyro();} // for NeuroFactory
14int lateinit() {if (!neuro->joint) return 0; simorder=0; return 1;}
15void go() {setState(0);}
16};
17
18extern ParamEntry NI_Touch_tab[];
19class NI_Touch: public NeuroImpl
20{
21public:
22double range;
23NeuroImpl* makeNew(){return new NI_Touch();} // for NeuroFactory
24int lateinit() {if (!neuro->part) return 0; simorder=0; return 1;}
25void go() {setState(0);}
26NI_Touch():range(1) {paramentries=NI_Touch_tab;}
27};
28
29class NI_Smell: public NeuroImpl
30{
31public:
32NeuroImpl* makeNew(){return new NI_Smell();} // for NeuroFactory
33void go() {setState(0);}
34int lateinit() {if (!neuro->part) return 0; simorder=0; return 1;}
35};
36
37extern ParamEntry NI_BendMuscle_tab[];
38class NI_BendMuscle: public NeuroImpl
39{
40public:
41double power,bendrange;
42NeuroImpl* makeNew(){return new NI_BendMuscle();} // for NeuroFactory
43NI_BendMuscle() {paramentries=NI_BendMuscle_tab;}
44int lateinit() {if (!neuro->joint) return 0; simorder=2; return 1;}
45void go() {}
46};
47
48extern ParamEntry NI_RotMuscle_tab[];
49class NI_RotMuscle: public NeuroImpl
50{
51public:
52double power;
53NeuroImpl* makeNew(){return new NI_RotMuscle();} // for NeuroFactory
54NI_RotMuscle() {paramentries=NI_RotMuscle_tab;}
55int lateinit() {if (!neuro->joint) return 0; simorder=2; return 1;}
56void go() {}
57};
58
59extern ParamEntry NI_LinearMuscle_tab[];
60class NI_LinearMuscle: public NeuroImpl
61{
62public:
63double power;
64NeuroImpl* makeNew(){return new NI_RotMuscle();} // for NeuroFactory
65NI_LinearMuscle() {paramentries=NI_RotMuscle_tab;}
66int lateinit() {if (!neuro->joint) return 0; simorder=2; return 1;}
67void go() {}
68};
69
70class NI_Sticky: public NeuroImpl
71{
72public:
73double power;
74NeuroImpl* makeNew(){return new NI_Sticky();} // for NeuroFactory
75int lateinit() {if (!neuro->part) return 0; simorder=0; return 1;}
76void go() {}
77};
78
79class NI_WaterDetect: public NeuroImpl
80{
81public:
82NeuroImpl* makeNew(){return new NI_WaterDetect();} // for NeuroFactory
83int lateinit() {if (!neuro->part) return 0; simorder=0; return 1;}
84void go() {setState(0);}
85};
86
87class NI_Energy: public NeuroImpl
88{
89public:
90NeuroImpl* makeNew(){return new NI_Energy();} // for NeuroFactory
91void go() {setState(0);}
92};
93
94#endif
95
Note: See TracBrowser for help on using the repository browser.