Aerisetta
Active member
Hi,
I have a feature I want to add to CRxTRDude's Story System. I want to make the image load 10 pixels to the left (or right, doesn't matter) to create a screen shake effect.
This might be very complex, but I'm hoping it may be easier than I thought:
_back is the command that makes it load an image.
I created this _back1 to load the image to the side, it successfully loads the image when I enter the _back1 command. However, I don't know how to write the code to tell the image to move 10 pixels to the side. ^_^;;;
Any help would be greatly appreciated.
I have a feature I want to add to CRxTRDude's Story System. I want to make the image load 10 pixels to the left (or right, doesn't matter) to create a screen shake effect.
This might be very complex, but I'm hoping it may be easier than I thought:
_back is the command that makes it load an image.
Code:
else if(name=="_back"){
if (dir){
if(message != NULL()){
setindexedvar(story_back, loadsprite("data/story/bgs/"+message));
setindexedvar(story_backfile, back);
}else shutdown(1,"STORY: _back 1 is empty. Check your dialog file.\n\n");
}else{
setindexedvar(story_back, "_");
setindexedvar(story_backfile, "_");
}
filestreamnextline(filenumber);
updateframe(self,0);
}
I created this _back1 to load the image to the side, it successfully loads the image when I enter the _back1 command. However, I don't know how to write the code to tell the image to move 10 pixels to the side. ^_^;;;
Any help would be greatly appreciated.
Code:
else if(name=="_back1"){
if (dir){
if(message != NULL()){
setindexedvar(story_back, loadsprite("data/story/bgs/"+message));
setindexedvar(story_backfile, back);
}else shutdown(1,"STORY: _back 1 is empty. Check your dialog file.\n\n");
}else{
setindexedvar(story_back, "_");
setindexedvar(story_backfile, "_");
}
filestreamnextline(filenumber);
updateframe(self,0);
}
Last edited: