WIP - Rotate Character Sprites {XP} - Now Beta Testing Pendulums! (Updated)

Started by Heretic86, November 20, 2014, 05:39:29 pm

Previous topic - Next topic

Heretic86

After I read this thread and a few more, it got me thinking and I came up with a script.
http://forum.chaos-project.com/index.php?action=post;topic=14659.0;num_replies=4

This request for something similar to Rotating Events is one of several I've seen in a couple of days over several sites.  Work in Progress.  What I came up with will allow all Characters (Events and Player) to Rotate.  

There are a couple of TYPES of Rotations.  One where an event just "spins" repeatedly.  Next will Rotate to a Target Angle over a certain number of Frames.  And last but not least is to point at a Target, like the Player, another Event, or Map Location.  The Target is similar to a Compass, but not intended for use as such.  It might be useful for a Character that always points at the Player, or maybe a Helper where it points out a secret on a Map, or could even be used as a Camera!  I put in some stuff to allow limiting the Rotations, like a Camera that is mounted on a wall can only rotate within a limited range of degrees.  If an Event is targetting another Event that moves around, this is partially limited to require that the Event not be erased and has an Active Page.

Script will be released regardless if there is any current interest in it, because there is already interest in it, and its functionality is already mostly complete, short of any Feature Requests prior to release.  I just need to do Documentation and make stuff easier for users by adding a couple of Script Calls.  Then I need to do a Demo, which shouldnt take that long as this script isnt that complex.

I have questions for everyone.

Ive really only come up with one Option that I am debating NOT including as a Feature.  This script I am working on, although relatively simple, might need some Options while I work on it.  Currently, I have it set up so ALL Character (Event and Player) Sprites will Rotate from the CENTER of the Character's Sprite.  It also will Rotate any Events with Tile Graphics also.

- Would anyone want me to allow changing the Center of Rotation?

- Are there any other Features that might be put in that I have not considered?
Current Scripts:
Heretic's Moving Platforms

Current Demos:
Collection of Art and 100% Compatible Scripts

(Script Demos are all still available in the Collection link above.  I lost some individual demos due to a server crash.)

Zexion

- I don't see why not, it wouldn't hurt anyone to have an extra feature that is optional.
- Nah I don't think rotating a sprite can really get any more complicated or intricate than what you've already described.

Also, I think the main point that he was trying to make in that request, is simply fixing a picture's (from the picture command) onto an actual event's x/y coordinates. As in, if you have a 32x32 event, and a 64x64 picture, and you move in a way that the event is only 1 tile off screen, you would still see the picture, perfectly centered on the event. It's fixed to screen coordinates at the moment.

Heretic86

Agree.  I am a fan of doing things right the first time, even if they do result in an Overkill Solution.

Okay I added in changing the Vertical Rotation Center (0, 1, 2) where 0 is Top, 1 is Center (Default), and 2 is Bottom.

Also adding in which part of the Sprite to point.  Can either point the Top of a Character or Tile by default, or the Bottom, which is useful for things that "hang and swing" like a Rope.  Got that idea when I saw a character sheet with some morbid hanging chans to have those "point" at a Target.  It wont be very useful for using as a "Swinging" solution as it does not take into consideration gravitation acceleration or deceleration.  Mostly because I dont remember the math for gravitational angular velocities.  So the only thing this probably wont be useful for is a Pendulum type of effect.  Unless someone else REALLY wants a Pendulum?

Any other suggestions?  Im plum out of ideas at this point and it works quite well so far...

---

Edit:

Okay, the script is comlete unless anyone has any other requests for features.  It might take me a day or so to do the Demo...

---

Edit 2:

I thought of something to add, a Maximum Distance!  It allows pointing only while a Target Event is In Range of that Distance.  Then I went all nutso and combined this script with Super Event Sensor, and guess what, Metal Gear RMXP!  Since the Comment Configurations are used Per Page, when Super Event Sensor detects its own Target, it changes Pages, thus, when a Camera (Rotating Event) is a Sensor, it can change pages so when it is "Triggered", then the Camera points at the Player, and thanks to the Page Changes, when a Sensor does not detect its Pages, it can be set to just oscillate back and forth!

True Metal Gear RMXP!

How do you all like that?  :p
Current Scripts:
Heretic's Moving Platforms

Current Demos:
Collection of Art and 100% Compatible Scripts

(Script Demos are all still available in the Collection link above.  I lost some individual demos due to a server crash.)

Heretic86

NVM, I got Pendulums working!   :naughty:
---

Edit:  Okay, this is the Script I've come up with so far.  I feel confident this is release quality.  Havent finished the Demo for it yet.

Edit: Redacted.  Full script available here:
http://forum.chaos-project.com/index.php/topic,14987.0.html

Stick it in and check for bugs!  (okay, that sounded less "dirty" in my head)

Official post will be made when demo is finished later.
Current Scripts:
Heretic's Moving Platforms

Current Demos:
Collection of Art and 100% Compatible Scripts

(Script Demos are all still available in the Collection link above.  I lost some individual demos due to a server crash.)

Wingard

Im making a project with my own battle system based on events and characters graphics and this thingy looks amazing yet complicated at the same time  :wacko: i wish you'll make a demo for it eventually :D

Heretic86

Pendulums werent really intended for the Battle Scene, but arent that difficult to use.

Just add a couple comments:
comment: \pendulum
comment: \rotate_angle[45]

Other options:
comment: \pendulum_length[64]

After some needed time off froms scripting, I am back to working on stuff for XP again.  Vehicles is mostly done, working out some bugs between a couple scripts (downhill ice and looping maps for XP), but need to fix a number of other things, so Sensors will also need an update to work with looping maps as well.  It may be some time before I release, but rest assured, I am still working.

Script has not been officially posted yet because this is a beta release.  The version I have sitting on my computer has a couple other features, such as sprite scaling that arent included in the version in this thread.
Current Scripts:
Heretic's Moving Platforms

Current Demos:
Collection of Art and 100% Compatible Scripts

(Script Demos are all still available in the Collection link above.  I lost some individual demos due to a server crash.)