Animated Inventory Items

Started by Freydall, Sun 05/03/2006 11:14:31

Previous topic - Next topic

Freydall

A short simple question... it's easy to animate cursors but what if you want an animated item cursor, like a creature that blinks or an electronic device with flashing lights? Quite sure there's nothing about this in the manual, and if there is then my apologies.
AEscplega is the best epic ever. Chapter I is finally finished and Chapter II is on it's way.

Ashen

Unless it's been added in the new betas, there's no way to animate Inventory items without scripting it. However, strazer wrote this handy module a while back, which should take care of that for you.
I know what you're thinking ... Don't think that.

Freydall

I put " InvItemAnimation.Start(iMGLVE, 7, 0, 10, eRepeat); " in the global script under repeatedly execute, and it says "unexpexted: InvItemAnimation"... What else do I need to put?
AEscplega is the best epic ever. Chapter I is finally finished and Chapter II is on it's way.

Ashen

When you say "under repeatedly execute", you haven't placed it outside of the function, have you? Off hand, that's the only thing I can think of that would give that error. "Unexpected (commandname)" errors are usually when a function is called from a part of the script it shouldn't be.

Also, you should only need to call that command once (unless you want to change the animation, of course), so game_start might be a better place than rep_ex.
I know what you're thinking ... Don't think that.

Freydall

#4
I've now put... :

#sectionstart game_start  // DO NOT EDIT OR REMOVE THIS LINE
function game_start() {
  // called when the game starts, before the first room is loaded
}

InvItemAnimation.Start(iMGLVE, 7, 0, 10, eRepeat);

#sectionend game_start  // DO NOT EDIT OR REMOVE THIS LINE

...but it still comes up with the unexpected error.


Oops, that was clumsy. Yep, just noticed that I put it outside the {}. Cheers! Thanks for the help...
AEscplega is the best epic ever. Chapter I is finally finished and Chapter II is on it's way.

SMF spam blocked by CleanTalk