Ambiera ForumDiscussions, Help and Support. |
|
|
|||||
|
Is it possible to make behavior like standart "Animate a texture" But on key pressed, or every second. For example: I press "W" -> Play texture animation for 0.8 sec. After this, it go on default texture. I press "S" -> Play texture animation until i release "S". |
||||
|
This can be achieved using an alternate method that uses a combination of 'change a texture' and 'if a variable has a value do something' and 'every few seconds do something'. It's pain staking yes, but once you set it up you can clone it for use in other objects, and simply modify it. Might be easier if someone created a javascript plugin that does this, but I think then you would have to store your textures in a folder and it would manually load them?? i don't like that. Other than that you'd have to wait for niko to add this to the program. (as far as I am aware) But I do what you have described in essence quite a bit using the first method. maybe someone else has a better idea. |
||||
|
rolevix, I created an example for you that might achieve your goal. Before you try my demo, you must download this first: http://ambiera.com/coppercube/ex... Inside of that Zip file, you will see a file named "action_DoLater.js". You must extract it and place it at this location on your hard drive: Documents\CopperCube\extensions After you put the file at that location, you must close CopperCube and restart it. Now, you should download my example here: https://drive.google.com/file/d/... When you open the CCB file with CopperCube, press the tab that says "Publish" near the top, and then press the arrow shaped like a "Play" button to start the game. When the game opens, you can do this: 1. When you press the W button, the textures that appear on the character will change. After 0.8 seconds, the textures will switch to the normal textures. 2. When you hold the S button, the textures will change, and they will only switch to the normal textures when you stop pressing the button. Study the file to learn how I did that. |
||||
|
Umm, im working with CCB about 4 years, i know how to do all of this, im just looking for plugin to make process of animation 2D characters more easy. But thanks for answers... |
||||
|
oops...just discovered that you can change the textures via javascript without having to store textures in a folder. you just have to call them into the cache first. cool! so this could be done with a javascript plugin. one of these days i gotta look into how to make one of those plugins. doesn't look too difficult, i'll have to study javascipt in more detail now. |
|