~opencog-dev/embodiment-mv1.5-proxy/trunk

« back to all changes in this revision

Viewing changes to server/src/com/vettalabs/petaverse/plugins/WorldSimulator.java

  • Committer: Zhenhua Cai
  • Date: 2011-05-16 06:39:16 UTC
  • Revision ID: czhedu@gmail.com-20110516063916-bb7g0n32gn7qj680
clean up PhysiologicalModel and make it more interesting

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
 * Free Software Foundation, Inc.,
21
21
 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
22
22
 */
23
 
package com.vettalabs.petaverse.plugins;
24
 
 
25
 
import java.util.Map;
26
 
 
27
 
import com.vettalabs.petaverse.actions.PetAction;
28
 
 
29
 
public interface WorldSimulator {
30
 
 
31
 
        /**
32
 
         * 
33
 
         * @param petName
34
 
         * @param petAction
35
 
         * @param actionTicket
36
 
         */
37
 
        public void executeAction(String petName, PetAction petAction, long actionTicket);
38
 
 
39
 
        /**
40
 
         * Send messages containing Petaverse feedback.
41
 
         * 
42
 
         * @param ownerOid
43
 
         * @param message
44
 
         */
45
 
        public void sendFeedBackMessage(Long ownerOid, String message);
46
 
        
47
 
        /**
48
 
         * Spawn the pet 3D model into Multiverse world.
49
 
         * 
50
 
         * @param petId The id of the pet to be spawned
51
 
         */
52
 
        public void spawnPet(String petOid);
53
 
        
54
 
        /**
55
 
         * Despawn the pet 3D model into Multiverse world.
56
 
         * 
57
 
         * @param petId The id of the pet to be despawned
58
 
         */
59
 
        public void despawnPet(String petOid);
60
 
        
61
 
        /**
62
 
         * Update the values of physiologicalModel recored in mob properties
63
 
         * 
64
 
         * @param physiologicalModel
65
 
         */
66
 
        public void updatePhysiologicalModel(PetaversePhysiologicalModel physiologicalModel, Long petId);
67
 
        
68
 
        /**
69
 
         * Update the emotional feelings properties 
70
 
         * 
71
 
         * @param feelingsValueMap
72
 
         * @param petId
73
 
         */
74
 
        public void updateEmotionalFeelings(Map<String, Float> feelingsValueMap, Long petId);
75
 
 
76
 
        /**
77
 
         * Cancel all scheduled actions for agent with the given ID
78
 
         * @param agentId
79
 
         */
80
 
        public void cancelAgentActions(String agentId);
81
 
 
82
 
        /**
83
 
         * Get the current orientation angle of the agent with the given ID 
84
 
         * @param agentId
85
 
         * @return
86
 
         */
87
 
        public double getAgentOrientationAngle(String petId);
88
 
 
89
 
        /**
 
23
package com.vettalabs.petaverse.plugins;
 
24
 
 
25
import java.util.Map;
 
26
 
 
27
import com.vettalabs.petaverse.actions.PetAction;
 
28
 
 
29
public interface WorldSimulator {
 
30
 
 
31
        /**
 
32
         * 
 
33
         * @param petName
 
34
         * @param petAction
 
35
         * @param actionTicket
 
36
         */
 
37
        public void executeAction(String petName, PetAction petAction, long actionTicket);
 
38
 
 
39
        /**
 
40
         * Send messages containing Petaverse feedback.
 
41
         * 
 
42
         * @param ownerOid
 
43
         * @param message
 
44
         */
 
45
        public void sendFeedBackMessage(Long ownerOid, String message);
 
46
        
 
47
        /**
 
48
         * Spawn the pet 3D model into Multiverse world.
 
49
         * 
 
50
         * @param petId The id of the pet to be spawned
 
51
         */
 
52
        public void spawnPet(String petOid);
 
53
        
 
54
        /**
 
55
         * Despawn the pet 3D model into Multiverse world.
 
56
         * 
 
57
         * @param petId The id of the pet to be despawned
 
58
         */
 
59
        public void despawnPet(String petOid);
 
60
        
 
61
        /**
 
62
         * Update the values of physiologicalModel recored in mob properties
 
63
         * 
 
64
         * @param physiologicalModel
 
65
         */
 
66
        public void updatePhysiologicalModel(PetaversePhysiologicalModel physiologicalModel, Long petId);
 
67
        
 
68
        /**
 
69
         * Update the emotional feelings properties 
 
70
         * 
 
71
         * @param feelingsValueMap
 
72
         * @param petId
 
73
         */
 
74
        public void updateEmotionalFeelings(Map<String, Float> feelingsValueMap, Long petId);
 
75
 
 
76
        /**
 
77
         * Cancel all scheduled actions for agent with the given ID
 
78
         * @param agentId
 
79
         */
 
80
        public void cancelAgentActions(String agentId);
 
81
 
 
82
        /**
 
83
         * Get the current orientation angle of the agent with the given ID 
 
84
         * @param agentId
 
85
         * @return
 
86
         */
 
87
        public double getAgentOrientationAngle(String petId);
 
88
 
 
89
        /**
90
90
         * Get the agent vision radius (how long it can perceive objects) in this world
91
 
         * @param petId 
92
 
         */
93
 
        public int getAgentVisionRadius(String petId);
94
 
 
95
 
        /**
96
 
         * Get the global X position (the lower X coordinate) for this world
97
 
         */
98
 
        public int getGlobalPositionX(String petId);
99
 
 
100
 
        /**
101
 
         * Get the global Y position (the lower Y coordinate) for this world
102
 
         */
103
 
        public int getGlobalPositionY(String petId);
104
 
        
105
 
}
 
91
         * @param petId 
 
92
         */
 
93
        public int getAgentVisionRadius(String petId);
 
94
 
 
95
        /**
 
96
         * Get the global X position (the lower X coordinate) for this world
 
97
         */
 
98
        public int getGlobalPositionX(String petId);
 
99
 
 
100
        /**
 
101
         * Get the global Y position (the lower Y coordinate) for this world
 
102
         */
 
103
        public int getGlobalPositionY(String petId);
 
104
        
 
105
}