Step 3 - Action-Response

This page provides details about actionresponse.json and its underlying validation rules along with a sample actionresponse.json file of a Bowling Alley VR Scene for your review

Here is the actionresponse.json template that is to be used for filling the scene requirement specifications.

{
	"ObjAction": [
	{
	"actresid":"",
	"sourceObj":"",
    "targetObj":"",	          
	"IsCollision":"",
    "response":"",
    "comment":"",
    "Syncronous":"",
	"repeatactionfor":""
    
  }
 ]
}

Here is the actionresponsevalidator.json with details about each specification along with its usage.

{

"ObjAction":{
    "req":"mandatory",
    "typeof":"object",
     "repeat":"notallow",
     "%comment%":"Collection of Objects that are set for action and corresponding response"
    },
	
"actresid":{
    "req":"mandatory",
     "root":"ObjAction",
    "typeof":"string",
     "repeat":"allow",
     "%comment%":"Unique Identifier for a given action and response"
    },	
	
"sourceObj":{
    "req":"mandatory",
	"root":"ObjAction",
    "typeof":"string",
     "repeat":"allow",
     "%comment%":"Source object where the action is applied or originated"
    },	

"targetObj":{
    "req":"mandatory",
	"root":"ObjAction",
    "typeof":"string",
     "repeat":"allow",
     "%comment%":"Target object where the action's response is made visible"
    },	


"IsCollision":{
    "req":"mandatory",
	"root":"ObjAction",
    "typeof":"boolean",
     "repeat":"allow",
     "%comment%":"Flag to determine if the action is based on collision"
    },	

"response":{
    "req":"mandatory",
	"root":"ObjAction",
    "typeof":"string",
     "repeat":"allow",
     "%comment%":"Defines the type of response, i,e, natural law based response or a customized response"
    },		
	
	"comment":{
    "req":"mandatory",
		"root":"ObjAction",
    "typeof":"string",
     "repeat":"allow",
     "%comment%":"Illustrate in words the course of response and its journey"
    },

"Syncronous":{
    "req":"mandatory",
	"root":"ObjAction",
    "typeof":"boolean",
     "repeat":"allow",
     "%comment%":"Defines if the response is Syncronous to action or has any delay or Asyncronous to other objects"
    },
	
	"repeatactionfor":{
    "req":"mandatory",
		"root":"ObjAction",
    "typeof":"string",
     "repeat":"allow",
     "%comment%":"Flag to use or repeat the same action for other objects. Metion the targetobjects ids or names"
    }
	
	


}	
	
	

Here is a sample actionresponse.json file for a Bowling Alley VR Scene.

{
	"ObjAction": [
	{
	"actresid":"ball_pinsetter1",
	"sourceObj":"_gameball",
    "targetObj":"_pinsetter1",	          
		"IsCollision":true,
    "response":"natural/custom",
    "comment":"<freetext>",
    "Syncronous":true,
	"repeatactionfor":""
	},
	
	{
	"actresid":"gameball_trackplane",
	"sourceObj":"_gameball",
    "targetObj":"_trackplane",	          
		"IsCollision":true,
    "response":"natural/custom",
    "comment":"<freetext>",
    "Syncronous":true,
	"repeatactionfor":"null"
	},
	
	{
	"actresid":"gameball_pinplane",
	"sourceObj":"_gameball",
    "targetObj":"_pinplane",	         
		"IsCollision":true,
    "response":"natural/custom",
    "comment":"<freetext>",
    "Syncronous":true,
    "repeatactionfor":"null"
	},
	
	{
	"actresid":"gameball_gamegutter",
	"sourceObj":"_gameball",
    "targetObj":"_gamegutter",	         
		"IsCollision":true,
    "response":"natural/custom",
    "comment":"<freetext>",
    "Syncronous":true,
    "repeatactionfor":"null"
	},
	
	{
	"actresid":"gameball_scoreboard",
	"sourceObj":"_gameball",
    "targetObj":"_scoreboard",	          
		"IsCollision":true,
    "response":"passthrough",
    "comment":"<freetext>",
    "Syncronous":true,
    "repeatactionfor":"null"
	},
	
	{
	"actresid":"gameball_scoreboard",
	"sourceObj":"_pinsetter1",
    "targetObj":"_pin2pin",	          
		"IsCollision":true,
    "response":"natural",
    "comment":"<freetext>",
    "Syncronous":true,
 "repeatactionfor":"_pinsetter3,_pinsetter4,_pinsetter5,_pinsetter6,_pinsetter7,_pinsetter8,_pinsetter9,_pinsetter10"
	}
	]
}	

Last updated