Webcg-adobe-animate-adapter

Hey there. I’m trying to use Webcg-adobe-animate-adapter and everything is perfect! But I’ve bumped into one problem. Is it possible somehow to send data to symbol? I’m trying to make table with few entries in line. And if I name texts field for example “No1”, “Player1” etc. everything is good. But I would like to make one symbol with text fields and name it for example “Line1”, “Line2” etc. And how I understand I should send data by typing “Line1.No” but nothing happens. Could you bring me guys back to right path? Thanks!

Ok guys, just in case if somebody else will bump into this problem, you have to write global code for template like:

webcg.on('data', function (data) {
	// data is a JavaScript object that contains the data that was passed via CG PLAY or CG UPDATE.
	console.log('on data, object: ' + JSON.stringify(data));
	console.log('data is an object: ' + (typeof data === 'object')); // true
	// If data is sent as template data XML format, f1 is an object with a property text.
	// If data is sent as JSON object, f1 is a string.
	var subtitle = data.f1 ? data.f1.text || data.f1 || '' : '';
	// You can use this data to update instances on your template:
	console.log('updating subtitle with: ' + subtitle);
	exportRoot.lowerThird.subtitle.text = subtitle;
});
2 Likes