Lighting effect without script

Im having trouble with the lighting of a lantern key item. For example, at the entrance of a dark dungeon, when u use the item and move forward, this happens:
PYGvEFu.png

And when reaching the edge of a map this here happens;
YwOTDYw.png


Im trying to get it where the image follows the player constantly without being offset like in these 2 photos. Any help would be appreciated
Any reason why you prefer without script?
Any reason why you prefer without script?
Im not that advanced on using scripts and this would be a good start for me to until i can backtrack and change up what i need to with scripts
Here's a workaround I use in my project (for different reasons):
Don't have the "edge" of your map be the actual edge. Put a perimeter of 8 black tiles from what was the edge of your map, and as long as the camera has that outside space to move, your character should always be in the center of the frame or around the center.

Edit:
See the attached image as an example of what I mean.
A solution without script is to use parallel process to move the picture based on variables.
- Set variables > game data > character > player > screen x & screen y (this need to be in parallel process)
- Use show picture > Display origin = center (I assume the transparent one is exactly in center of the pic)
- Use variable as position
- Then use move picture on parallel process > uncheck wait for completion > use one frame in Time > Set position based on those variables

I never create it on eventing though, so it was just guess. But if you want to resort a script, there is Galv Visibility Range
So I guess the parallel process event is the only way that works. Being that I had it set up as a common event linked to the key item to be able to use it from the inventory.
YeDVcdA.png
Here's a workaround I use in my project (for different reasons):
Don't have the "edge" of your map be the actual edge. Put a perimeter of 8 black tiles from what was the edge of your map, and as long as the camera has that outside space to move, your character should always be in the center of the frame or around the center.

Edit:
See the attached image as an example of what I mean.

Seems thats the only way i can get it to work in a map like that and with a key item lantern. I tried using an event but i cant seem to get it to link up with the lantern. I've been stuck on this for about 3 days trying to find a possible way to get it to work without a basic event or script
Well, first of all I would set a switch to your Lantern On common event. That way you can use that said switch to check if lantern is actually on. You can even use it to automatically toggle the lantern without using choices.

The switch should then trigger a parallel process common event (your event is NOT a parallel process) that only contains the part checking your player x and y coordinates and then moves the image there. The problem is when you have to move your image.

As it has been said if you want to use a picture then you need to have your map a bit bigger than usual to achieve that. However the main reason why you cannot link your event to your lantern key item is because you need two events, not just one.

  1. Two different effects:
    - if your switch is off checks player X and Y on screen, sets a new image using those coordinates and turns the switch on (if your switch is on then the lantern is on as well);
    - if your switch is on (it means the lantern has already been activated once) it turns the switch off and erases the image.
  2. Parallel process triggered by the switch you activated in the previous event. Checks player X and Y and moves your image to those coordinates every frame (aka the lighted zone follows the player).
No need to erase your image in the second event: turning off the lantern will do the trick. However you should remember to turn off the lantern (if it is on) when leaving the place and remove the image. Otherwise the image will be carried to other maps too.
Well Heirukichi, I have it set where leaving the dungeon or mine will erase the picture. The one problem I see though is that the lantern needs to be activated from the inventory...I can't have random things turning the lantern on (if that's what you mean). But for now I will leave things as it is and go into a seperate tutorial game and experiment with that idea.
I can't have random things turning the lantern on
Having the lantern trigger the switch is exactly the way to achieve this.

Original thread: https://forums.rpgmakerweb.com/threads/lighting-effect-without-script.97652/