Bonkers

I haven't seen you since the plague.
Restaff
Joined
May 26, 2013
Messages
2,942
Reaction score
2,908
First Language
English
Primarily Uses
RMMV
I made sure to search the thread itself before posting this, and hope someone can take Amaranth's Super Simple Mouse System for Ace, and make it not use a 20 x 20 icon on the 'icon set' but use a 

png file of some 40x40 or 60x60 size as the cursor "arrow" for it's default.  Eventually I'd like to replace it going to the icon set at all in system, and instead look for pngs labeled "Arrow.png", "Talk.png", "Look.png", etc instead of the small 20 x 20 icons referenced by number.

Here is the script I am using:

http://forums.rpgmakerweb.com/index.php?/topic/17829-amaranths-super-simple-mouse-system-for-ace/?hl=%2Bsimple+%2Bmouse+%2Bscript

An example for what I'd like to use instead for a cursor is a 40x40 png 
9gA7JW1.png


I do have the LUNA engine, and am willing to edit the appropriate menu if it is necessary.  I can also create a new folder labeled "Icons" if you do not wish to use System for the amended script snippet.

Thank you for any and all help.
 

Venka

Veteran
Veteran
Joined
Jun 20, 2012
Messages
945
Reaction score
367
First Language
English
Primarily Uses
I haven't looked but you could make a new icon sheet and change the cell sizes to 60x60 or 40x40 size and make the script point to that icon sheet instead. That would probably be the easiest fix.

edit: I forgot, will probably need a snippet written for that. I'll try to take a look tonight if someone hasn't gotten back to you by then :)
 
Last edited by a moderator:

Bonkers

I haven't seen you since the plague.
Restaff
Joined
May 26, 2013
Messages
2,942
Reaction score
2,908
First Language
English
Primarily Uses
RMMV
Much appreciated and please take your time. I am in absolutely no rush.  Thank you for the quick response =3
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
44,789
Reaction score
15,916
First Language
English
Primarily Uses
RMMV
It would require less modification if you still use an "iconset" (with a different name) but just enlarge the images as you need.


Then when it pulls from the icon, just make it pull from your own large-icon image instead.


I'm at work, otherwise I'd do a quick mod for you straight away. If Venka hasn't provided a solution before I get home (and if I remember), I'll give you a mod tonight.
 
Last edited by a moderator:

Bonkers

I haven't seen you since the plague.
Restaff
Joined
May 26, 2013
Messages
2,942
Reaction score
2,908
First Language
English
Primarily Uses
RMMV
Thanks Shaz, much appreciated.  Again no rush, and I am happy this was attended too so quickly.  I'll keep trying on my end with what you just suggested.
 

Venka

Veteran
Veteran
Joined
Jun 20, 2012
Messages
945
Reaction score
367
First Language
English
Primarily Uses
here's what I got:

simple mouse altered.txt

And here's the mock up icons I used to test with if you want to have a base (but I'm pretty sure you know you're doing on images) :)

MouseIcons.png

They're just icons scaled up to double their size. I put the script so it'll adjust to any size icons you decide to go with. The icons sheets just need to be 16 columns across for the calculations to work.

If you have an edited version of the script already.. the only changes I made were to add a spot you can set the icon sheet's name in the settings:

ICON_SHEET = 'MouseIcons'and one method around line 150

#-------------------------------------------------------------------------- # * Set Bitmap #-------------------------------------------------------------------------- def set_bitmap(cursor = DEFAULT_ICON, text = nil) if @ignored cursor = DEFAULT_ICON text = nil end if @cursor != cursor || @text != text @cursor = cursor @text = text item_cursor = ICON[cursor] is = Cache.system(ICON_SHEET).width / 16 rect = Rect.new(item_cursor % 16 * is, item_cursor / 16 * is, is, is) if @text.nil? self.bitmap = Bitmap.new(is, [is, 32].max) self.bitmap.blt(0, 0, Cache.system(ICON_SHEET), rect) else w = @dummy.text_size(@text).width h = @dummy.font.size bitmap = Bitmap.new(is + 2 + w, [32, h+2].max) bitmap.font.size = @dummy.font.size bitmap.font.shadow = true if self.x + is + 2 + w > Graphics.width bitmap.draw_text(0, 0, w, h, @text) bitmap.blt(w, 0, Cache.system(ICON_SHEET), rect) else bitmap.blt(0, 0, Cache.system(ICON_SHEET), rect) bitmap.draw_text(is + 2, 0, w, h, @text) end self.bitmap = bitmap end end end
I did notice for icons bigger then 32x32.. when the mouse is outside of the game's window, that part of the image will still show in the top corner. I couldn't track that part down.

edit:

found the spot to hide the cursor when the mouse is outside of the game window:

#-------------------------------------------------------------------------- # * Mouse Position #-------------------------------------------------------------------------- def self.pos gx, gy = global_pos x, y = screen_to_client(gx, gy) # Test boundaries begin if (x >= 0 && y >= 0 && x <= Graphics.width && y <= Graphics.height) return x, y else is = Cache.system(ICON_SHEET).width / 16 return -is, -is end rescue return 0, 0 end endI added in line 317 and changed line 318.
 

Attachments

  • simple mouse altered.txt
    310 bytes · Views: 13
Last edited by a moderator:

Bonkers

I haven't seen you since the plague.
Restaff
Joined
May 26, 2013
Messages
2,942
Reaction score
2,908
First Language
English
Primarily Uses
RMMV
It worked, until I started a new game or loaded a save.  Got this error:

TQg17x0.jpg


Not sure what I did wrong, loaded a png 16 and 16 columns high at 62 pixels for a 992x992 sheet.  I'll try again with the ones you provided and see if it helps any.  

Edit:

Hmm when I copied your uploaded version of the script it makes the icon vanish altogether.  Lemme brew on this a bit and see what I am doing wrong here.

Thank you for the help.  I just need to work out what I did wrong.

Ah I see!  The first icon is actually icon 0 ><  Whoops.  I feel foolish.

I'm also seeing what you mean when the icon gets close to the window.  I can design the maps so that isn't a issue though by adding a few extra tiles to force the icon on or expand the boarder through another script that won't break the mouse controls.

This solves my issue, and helps me immensely.  Thank you for your work again Venka.
 
Last edited by a moderator:

Venka

Veteran
Veteran
Joined
Jun 20, 2012
Messages
945
Reaction score
367
First Language
English
Primarily Uses
Oh ok :) yeah I left it 0 cause I've messed with the script some, but I haven't really dissected all of it so I didn't know if shaz ever used the 0 icon slot to blank out the image. I also edited the above post to fix the issue of the image hiding in the corner :)
 

Latest Threads

Latest Profile Posts

More words of wisdom: Trying to make everyone happy will just make you miserable.
Ads: "Up to 90% off"
Reality: 9 items at 10% Off, one item at 90% off
if you were working on a rhythm-based retro fighting game, would you rather have the jumps take up two beats (one for jumping, one for landing) or just one?
Only 3 more days to get your copy of Move That Box! with -15% discount!

Forum statistics

Threads
124,381
Messages
1,163,234
Members
163,180
Latest member
Viking
Top