Main Menu
  • Welcome to The RPG Maker Resource Kit.

[REQUEST] Torch/lamp/Flash light

Started by Ultimaodin, April 23, 2008, 01:01:52 PM

0 Members and 1 Guest are viewing this topic.

Ultimaodin

Alright this should be a rather simple request. Now before I start I would like to say I searched the database and didn't find this so...:


Alright I'm asking for this script for two reasons. One is for my own use, the other is because there's close to a post a day requesting this at a couple of the forums I hang out in.

Anyway What I am looking for is a script that turns the entire screen black except for a 3-tile (if alterable that would be prefered) diameter circle around the player. I have tried using a combination show picture and move picture commands but that just turns out buggy. I then tried through the use of an animation and a parallel process event except that caused a lot of lag. So I deem it nescessary to have it in a script format.

So anyway if anybody is willing to make this script or maybe link me to a similar script I may have missed that would be greatly appreciated!

ultimaodin

Falcon

There are so many ways to do this, some don't need a script.

Strike 1 for not reading rules.

modern algebra

Mmn, doing it by events might be a little tricky for a beginning eventer, but it's the best way to do it.

Just make a picture in Paint.NET or another image editing program that is 1280 x 960 and make it completely black. Then use a gradient tool or whatever is appropriate in your image editor. and make a circle with origin in the centre of the picture (640, 480). For a three tile radius, you're looking at a circle with radius 96.

Once you have that picture, then the eventing is easy. Just make a parallel process common event that acts on a switch. You can choose the switch, and whenever you want to turn on the lamp or whatever, then just turn that switch on.

In any case, inside the event, just make it look like this:

@>Control Variables: [XXX: Screen X] = Player's Screen X
@>Control Variables: [YYY: Screen Y] = Player's Screen Y
@>Show Picture: 1, 'Picture', Center (Variable[XXX][YYY]), (100%, 100%), 255, Normal
@>Wait: 1 frame(s)

I've attached a sample picture.

ahref

you could even do a coned image

\ /

^crap acii art but meh. This would look more realistic for electric torches but the circles would be better for flame torches.


Ultimaodin

That's how I have been doing it, it just has a few minor issues. A major one is if you require a second parrallel process running and it becomes excessively laggy!
Another is the fact That sometimes the parrelel process by itself lags and it leaves the image trailing behind the player.

Another more insignificant issue is that yes, a vast array of new time eventers find the evented system difficult. I did read the rules I am simply inquiring about a scripted version that isn't so... bugged.

ps I apologise about my bad spelling. I may be 18 but spelling just sucks for me!


ultimaodin

modern algebra

It's not so laggy if you put in extra wait frames. 1 or 2 frames shouldn't make a major difference to the functionality of the event.

Maybe there is a script out there, I'm not sure, but when the eventing is that easy I would have no motivation to write a script. In any case, best of luck finding someone to write this script for you.

Esmeralda

I know I've seen a script like this, it does exist somewhere.

Don't ask where, don't even ask the name, I have no idea. Sorry.
:taco: :taco: :taco:

modern algebra

I remember Levent said something about one too. I took a look and found this:

http://comunidad.rpgmaker.es/viewtopic.php?f=18&t=9225&start=0&st=0&sk=t&sd=a

It'ss an English script, but this is the site I found it on. Anyway, maybe it will do what you want it too.