Help - Search - Members - Calendar
Full Version: MapRadar
RPG RPG Revolution Forums > Scripting > Script Submissions > RGSS2-Submissions
Pages: 1, 2, 3
SojaBird
MapRadar

Version v2.2.2
Author SojaBird
Release Date
v1.0 > 12-05-08
v1.1 > 12-05-08
v1.5 > 13-05-08
v1.7 > 17-05-08
v1.7.2 > 17-05-08
v1.8 > 20-05-08
v2.0 > 10-06-08
v2.2 > 17-06-08
v2.2.1 > 23-06-08
v2.2.2 > 24-06-08


Introduction
Oke so this is a realy nice script I transfered and improved from a xp script from DeM0nFiRe.
So actualy I'm realy happy that I could do this and that it also works smile.gif
So thats a realy nice thing.



Features
v1.0
- Display a small hud with the map and your location.
- Using pictures for:
> Border
> Bg when there is no map
> Players locationmark
> Maps
- Choose to display mapname or not.
- Easy script on/off fucntion for creating map pictures.
v1.1
- Change location of the hud to preset locations or your own custom placements.
v1.5
- Changes size of the hud.
- Changes opacity of the hud.
- Enable 'automatic hide hud' when player is behind it.
- Set amount of opacitydecrease when 'automatic hide hud' is on.
v1.7
- Use a switch to hide and show the radar.
- Change wether the map or the playerindicator moves (moveing indicator doesnt scroll jet when out of the frame).
v1.7.2
- Some bugs fixed with the switch (still doesn't work totaly).
v1.8
- Totaly working switch now.
v2.0
- Automatic picture scaling, so no more map calculations.
- More easy to use script setup.
v2.2
- Choose how to open the radar (switch, key, switch and key, switch or key).
v2.2.1
- Less options so it's more easy to use.
- Fixed some bugs with the "how-to-open" function.
- Removed the locationname option.
v2.2.2
- Fixed scalingproblem with the frame and background.

To come features
- Change location of hud.
- Change size of hud and pictures.
- Change opacity of hud.
- Autogenerate mappicture (using Andreas21 and Cybersam "Screenshot Script").
- Fix the 'automatic hide hud' for bigger maps than 17*13.
- Turn hud on/off with switch.
- Call script funtions.
- Ability to changes the pictures when staying on the same map (eg an other playerindicator when on boat etc).
- Ability to scroll the map automaticly when the player get's out of frame when using move-player-over-map function.

Script
Click to view attachment



Customization
The whole setup is in the script self.
All you have to do is change it to your own style.

the setup in the script starts from
CODE
#############
# Start SETUP
#############


and ends with
CODE
############
# End SETUP
############


For the pictures you need to make some yourself.


Compatibility
VX only.


Screenshot



DEMO v1.8



Installation
Put the script above main.
Set the script up by changing it to your project.
Make your pictures and put them in the Picturefolder of your project.
Credit me pls.


FAQ
Non jet...

Terms and Conditions
Credit me pls with site, and the script is yours.
If anyone want some changes, pls pm me or post it here, I'll track the topic.
gend0
Thanks laugh.gif
My dream is come true bunny.gif
Azuaya
Impressive, it's good that there's scriptors helping out around here... well once I learn RGSS2 I hope I will be able to help around too !
SojaBird
Update to v1.1
drebenk
@pim321 mate make a demo or some screenshots. Some people (like me) need to see the script in action before downloading it. ^^
SojaBird
yes I'm working on it smile.gif
COMMING SOON biggrin.gif
SojaBird
UPDATE TO V1.5
SojaBird
Update, demo now!
gend0
Can't download sad.gif

recommended to use
http://www.mediafire.com/
SojaBird
QUOTE (gend0 @ May 13 2008, 03:25 PM) *
Can't download sad.gif

recommended to use
http://www.mediafire.com/


try again now smile.gif

AmIMeYet
QUOTE (pim321 @ May 12 2008, 03:07 PM) *
- Autogenerate mappicture (using Andreas21 and Cybersam "Screenshot Script")


You might want to know that this script is bugged for vista users who use the 'Aero' skin.
They get a black screen.... (well, atleast with Woratana's neo save system, with wich I've seen it, but I don't know if the screenshot script is updated to fix this, though... )
Or have you already found a fix for this?
SojaBird
well I only want to do this if I have realy much time...so I think it'll never happen tongue.gif
hehe

anyway...what do you thing of my scripting dear Nederlander biggrin.gif
Namio
I'm having a problem. This script somehow conflicts with the Main Script when it has default_font = ............. . How do I fix this?
jarhead31
Is there a way to turn the radar on or off through a switch or script call?
drebenk
@pim321 this script is nice, but you had to use pictures which are taken from greater hight, for the images in the radar. Right now the same thing that I see on my screen is the thing I see in the radar so there is no point at looking at this radar.
BTW I wish that somebody make a good map script. So when the player presses M (for example) it shows the world map and a indicator (a dot or something) that shows the players position on the world map.
SojaBird
@namio
I've fixed that now, it's because you don't have the font Arial...you could use a other font instead. In the next version you can changes the Font input to "" so that it draws the default font.

@jarhead31
I'll try to put that in the next version (probably wich swich).

@drebenk
In the next version I'll implent the function to choose wether to move the map to the players position or just to move the player icon over the map. I'm still working on that but have some problems with the size.


General note:
Next version will be up soon, so just keep your eyes on the topic for updates wink.gif
AmIMeYet
QUOTE (pim321 @ May 13 2008, 10:21 PM) *
well I only want to do this if I have realy much time...so I think it'll never happen tongue.gif
hehe

anyway...what do you thing of my scripting dear Nederlander biggrin.gif


Well I've just downloaded it and it's pretty great...
How much of it did you do yourself? (I mean, what parts are from DeM0nFiRe and what parts are yours?)

Anyway, I really like the features that you've added wink.gif

Though I don't really get what the map size should be...
"# You need a picture of every map you want to display in the Hud, where the width=PlayerSize*[number of X-tiles] and where is the height=PlayerSize*[number of Y-tiles]"
What's PlayerSize?

Heh, we should do a project called 'über-map' wich uses my map system and your, well..., map system! heheh tongue.gif
SojaBird
PlayerSize is what you put above, actualy it's just the size of your player_icon width or height

Let's do that project tongue.gif hehe
Should be cool ^^

Most part is mine, only checked on some things like how to move the map to player location.
Though mostly it's mine yea smile.gif
Namio
That's wierd. I do have Arial font. When I don't have the MapRadar script and Arial is set as default font, it works fine. But when I put the MapRadar in it comes up an error
SojaBird
mmm stranges thing :S
what error do you have exactely?
well actualy when you put a "" at THE NEW VERSION (comes soon), you'll just get the "UmePlus Gothic" font...
however, I just don't get why this problem is occuring

the next must stand at line 41
CODE
Font = "Arial"


Do not forget the "" brackets!


pls post the error so I can take a look at it
Ilikepie123
QUOTE (AmIMeYet @ May 13 2008, 08:25 AM) *
QUOTE (pim321 @ May 12 2008, 03:07 PM) *
- Autogenerate mappicture (using Andreas21 and Cybersam "Screenshot Script")


You might want to know that this script is bugged for vista users who use the 'Aero' skin.
They get a black screen.... (well, atleast with Woratana's neo save system, with wich I've seen it, but I don't know if the screenshot script is updated to fix this, though... )
Or have you already found a fix for this?

Not really, I use the Aero skin, and I have implemented the Neo Save System into my project. Works fine. o.O
Daredeamon
Het kompas ding heeft een probleem... je hebt een screenshot genomen van Map1 maar daar staat een boot op.
Die blijft daar natuurlijk gewoon!!
Namio
I already have it in brackets. The error is

Script 'Main*' line 8: NoMethodError occurred
undefined method 'default_name=' for "Arial": String

I have put Arial in brackets for both scripts but this keeps appearing.


SojaBird
@daredeamon
thats true, there still is a boat on the picture, it's just what you like to have on the picture...you could also make a picture that isn't for that map...you can create very funny and cool things with that concept

@namio
well I think it has something to do with your other scripts or the use of arial as normal font...try to solve that, it has nothing to do with MapRadar
tehpwnerer
liek OMG dis skript Ownz n00bs hard rite i wuz in teh prossis of finding a good skript and i kame akros tihs 1 rite n i almost had a hartattck n stuf..

basically what i am saying is THANK YOU for this genious piece of code writer architecture its really a cool and fun feature to have in my game.. although i really need that *((Autogenerate mappicture (using Andreas21 and Cybersam "Screenshot Script"))* because if this means what i think it does it will save me alot of trial and error in drawing my maps (screenshots and ms paint lol) i cant seem to figure out what size my map needs to be for the radar to pick it up but ill keep at it until you incorporate this new thing.. i really need to learn RGSS2 myself lol i like coding and i actually understood ruby but i cant find a good tut on it... nonethe less THANKS again ill be looking forward to future installments of this =Þ
SojaBird
Update picture edit and some to come things
drebenk
@pim321 I'm waiting to see the next version of your script. All I need is a world map which can be turned on and off using one key (M or what so ever) and that displays in realm time the position of the player. So if I'm in a town A and press M a picture/window appears and shows me the world map and a dot (the player) in town A. If I go out of the town and press M the same picture/window appears and shows me the world map and the dot which is outside of the town and so on. Like in GTA VC, SA (and many, many other games) where when you call the world map it shows you where you are.
SojaBird
Update to v1.7!!

EDIT

Sorry but it still has an error when using switch...fixing asap
SojaBird
update v1.7.2
not working totaly yet...
tehpwnerer
lol i copied over the old script with the new one and (im not sure) but i think the switch idea is whats now stopping the map from showing up entirely it could be an unforseen problem that i unforsaw but none the less the game works like always yet lo and behold... no map.. what do you think it could be? in the general configuration in the script the switch that controls wiether the map is used or not is default set to 1.. but theres no indication whitch one is true and which on is false..
i know im gonna feel like an idiot for this one because its probably the easiest solution but iv tried many things so far...
SojaBird
He pwner, thanks for comment and useing my script.
I'm not sure what causes your problem but I'll just explain what you should check to help me out helping you.

At first, do you have "MapRadar v1.7.2"? Just go to the script and see in the first textline (line2) wich version it is.
Next, see if at line62
CODE
UseRadar = true
is set, if it's
CODE
UseRadar = false
, set it to True, else the script won't load.
Then, get to line13 and look what is set after
CODE
Radar_Switch =
. If it is as you say default 1, than when you go in the game, turn switch 1 on.
You can also go to the OpacitySetup beneath line40 to see if the opacities of each picture isn't nil.
Also what you need to look for is if your pictures have come in properly. To do so, get to the project and open the "Resource Manager" (fourth button from the right on the top bar). Get to the picturefolder and do a preview on every picture (at least the maps).
See if under the PictureSetup (line18) the width- and heigthvalues aren't set to nil.
The problem can also be that you have set the custom placement to a negative number, not realy obvious but just to be sure. When you have this, the pictures are drawn outside the screen wich causes the Radar also not to showup (at least not visable for you).

More I can't think off...
If you still have the problem, pls post wich scripts you have other than "MapRadar v.1.7.2".


Update me pls what your conclusions are when you've solved to problem.
tehpwnerer
lol like i said was going to be an easy solution...
it was the fact that i had to turn (in my case) switch 12 on which i set to mapradar but i got a new problem
after that lol now when i use an event to turn on the switch the event freezes the whole game lol...
dont worry though i should be able to solve this one momentarily (im not a complete noob lol)
thanks for your help though woratana your still the shit man

on another note im actually picking up a bit on this code language =) i slowly began scripting what i like to call (project complete failure)
im just starting simple i need to learn more things like modules aliases and all that but for the time being im starting from nothing at all and trying to get it so at the input of a button (j) my charactor jumps forward once lol (not the most brilliant idea but i still wanna try to start somewhere lol) im beginning to account for the fact that means you could jump over impassable walls and say into water .. ill need to make an instant death scenario for when you jump directly onto an impassable tile.. lol

like i said its a work in progress but its fun as hell..

thanks again woratana your the shit man =) happy trails
SojaBird
Well you could thank me as well dude tongue.gif

I know I still got some problem with that eventing stuff...I can get it to turn the map on and off but when I try to open it again, it printing a error...Still need to fix that...However laugh.gif

About learning to script, it's just Trial-And-Error, well actualy...that's how I got into this (I'm still a bit n00by on this but he, I posted some scripts allready tongue.gif)


Have fun using MY scripts
SojaBird
Update to v1.8 where switch is working totaly
tehpwnerer
Unbelievable... not only does this new code work.. but i ACTUALLY figured out EXACTLY how big to make my map... it WORKS BEAUTIFULLY

just for referance for anyone else who might have the same problem with largescale maps where the radar dont line up properly..
in the database my main map is 250 by 250 (database terms)
in MS paint i had to make the bitmap an astounding 2000 pixel by 2000 pixel...
i dont know the exact math behind this but using this as a referance maybe anyone with the same problem can sort it out?

thanks a million for this beautiful script pim you really rule dont think of yourself as nooby my man because i couldnt code half this myself IM nooby lol your pro..

thanks again
~Teh~
drebenk
@pim321 mate can you make a demo with the new script version?
I saw the screenshot from the 1st page of this topic and I want this thing to happen when I'm on a map a image showing wider area to appear on the radar map. So can you make a demo with the new 1.8 ver. that wil look like the screenshot on the first page?
SojaBird
@pwner
the math behind it is that you take your amount of tiles wich is 250 and multipy that with the playerindicator size (yours is 8*8)
in script at line 28 you'll find this
CODE
# You need a picture of every map you want to display in the Hud, where the width=PlayerSize*[number of X-tiles] and where is the height=PlayerSize*[number of Y-tiles]


@drenbenk
allright I'll make that, im not as good with demo's, im also working on my AutoLight demo atm but i'll just post that projectfile from the screen wink.gif
SojaBird
Update v1.8 demo online!!
drebenk
@pim321 good script mate and a good demo too. One problem when I put image of one of my maps (size 192x192) instead of the one you've put it works fine. BUt if I copy paste one of my maps in your demo and put the two guys on my map and start the game it doesn't even start. It just shows me black screen for a sec and turns the game off. So what do I need to do in order to aplly your script to my game? Will copy/paste (above Main) work? I'll also copy/paste the images for the player indikator and the map frame.
SojaBird
well what error do you get?
the picture u're using for your map need to have the correct name, els it won't work
check the map id and changes your picture name so that it corresponds with that map

works now?


o and yes, just copy paste will work, though to set it up, you do have to create these map pictures and all...so be sure that all is set correct
drebenk
@pim321 yep it works fine now. ^^ It didn't gave me any error it just closed the game. The problem was in the map name. Thank you for your support.
Now I have another question how can I make an image for a map? So I open the editor and take a picture of my map (the map I'm talking is W40xH30 size) at a view 1/2. After that I make that picture to a 192x192 and with png extention. The problem is that it doesn't show my player at the right possition on the radar. It shows it to the left from the current position on the map. So can you give me some tips on how to make my map screens so that they can be shown on the radar correctly.
SojaBird
just go to the mode where you can see the whole map (in your case 1/2).
then check the amount of squars and multiply that with 32 (so (40*PZ)x(30*PZ)).
PZ is the same as your playersize actualy...so if you have a playericon of 4x4 then you should do (40*4)x(30*4)...and so on.
make sure you set the playerwidth and playerheight at lines 19 and 20...
im not sure if i can pull the pictureinformation of the pictures self but, if it can, ill put it in the next version

however, just make a screen of your editor and go to photoshop and create a new file with the right sizes.
then just past it and if ya did it right, the total map will fit perfectly...though perhaps you have to increase the size twince since ya took it at 1/2 size but that's something you have to figure out yarself...it isnt that hard...


well actualy ive a vid.tutorial on AutoLight where i also put a map picture in photoshop, perhaps check that out
just check my sig for AutoLight and find in the post the VideoTutorial link or visit my blog (also in sig but link is NestCast...hope it helped ya out...if not ill make an other vid.tut on this script but only if nessesary
drebenk
@pim321 umm I still can't understand how to capture the pic with the right size. My player sheet contains only 1 player and it is 4 squares in height and 3 squares in lenght (4x3). My map is 40x30. If I multiply 40x32 that is 1280 and 30x32 it is 960. So when I make a image in Photoshop with w1280 and h960 and paste the screen from my map (screen taken in the 1/2 view of the editor) the map shows in the screen but there is a lot of empty space around it. What I'm trying to say is that I can't understand how to calculate the picture size in Photoshop. Can you please make a video tutorial for this script with a map 40x30 and a char sheet 4x3?
SojaBird
allright i'll do in some time wink.gif
drebenk
@pim321 thank you mate I'll be waiting for it. ^^
SojaBird
QUOTE (drebenk @ May 23 2008, 11:15 PM) *
@pim321 thank you mate I'll be waiting for it. ^^


cool I'll hope to have it up soon tomorrow (well actualy today teehee.gif ) keep an sharp eye... wink.gif
Shut48
it doesnt work for me, It doesnt open on paint or anything else. what do i have to do
SojaBird
pls explain what u've done...
what are u want to open in paint?
drebenk
@pim321 how is the tutorial going mate?
SojaBird
@drenbenk
yea sorry m8 but im very bussy with my exams and all
i though i could do it beside it realy quick but it seems that it doesnt
though i hope that ill have it up soon
ill pm u personaly if its done wink.gif
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2013 Invision Power Services, Inc.