I've seen no way to specify the hotspot for now, so the hotspot is always at the center of the cursor.
A workaround for off-center hotspot is to add transparent pixels:
[MOD] Discrete Crosshair
- pango
- Posts: 3359
- Joined: Wed Jul 18, 2018 6:14 pm
- Location: France
- Contact:
Re: [MOD] Discrete Crosshair
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart
- King of Worms
- Posts: 4756
- Joined: Mon Oct 17, 2016 11:18 pm
- Location: Scourg Barrow (CZ)
- Contact:
Re: [MOD] Discrete Crosshair
Hmm, looks good Id say, I think we must see it ingame to know how well it fits/works. Its usually about some compromises of our ideals and restricted reality, no worries VMBlast, this is great start! Thank you & Pango
DREAM Nexus https://www.nexusmods.com/users/73250038?tab=user+files
DREAM Forums viewtopic.php?f=27&t=1168
DISCORD: king_of_worms_cz
DREAM Forums viewtopic.php?f=27&t=1168
DISCORD: king_of_worms_cz
- VMblast
- Posts: 535
- Joined: Wed Mar 29, 2017 12:22 pm
- Contact:
Re: [MOD] Discrete Crosshair
@pango
Cheers. Cant wait to see it ingame.
Cheers. Cant wait to see it ingame.
- Alyndiar
- Posts: 69
- Joined: Thu Dec 13, 2018 1:22 am
- Location: Québec
Re: [MOD] Discrete Crosshair
In my tests, the hotspot for the cursor was the top left corner. Are you sure we need an offset?
- pango
- Posts: 3359
- Joined: Wed Jul 18, 2018 6:14 pm
- Location: France
- Contact:
Re: [MOD] Discrete Crosshair
Hi Alyndiar,
And if I read the code correctly, the crosshair is centered on screen, and I don't think the hotspot ever moves from the center of the screen, which makes it always centered vs the crosshair:
https://github.com/Interkarma/daggerfal ... air.cs#L31
Tested it with doors, seems to be in the center to me.
And if I read the code correctly, the crosshair is centered on screen, and I don't think the hotspot ever moves from the center of the screen, which makes it always centered vs the crosshair:
https://github.com/Interkarma/daggerfal ... air.cs#L31
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart
- Alyndiar
- Posts: 69
- Joined: Thu Dec 13, 2018 1:22 am
- Location: Québec
Re: [MOD] Discrete Crosshair
Hmm... I don't think we're talking about the same thing... You're talking about the crosshair... I'm talking about the pointer, previously the fugly blue arrow you see in the config menu when you start DFU or in the in-game menus like spellmaker or inventory... you know, this :
I believe that was what King of Worms and Hazelnut were talking about before. Sorry for any confusion I caused if that was not the case.
I tried replacing that with VMblast's cursor my local copy of the repository and rebuilding, cursor is replaced and hotspot is top-left. In fact, when you go to Build Settings... and Player Settings, you can replace the cursor with any image and define the hot-spot. When you rebuild, you get the selected cursor in-game.I believe that was what King of Worms and Hazelnut were talking about before. Sorry for any confusion I caused if that was not the case.
- Alyndiar
- Posts: 69
- Joined: Thu Dec 13, 2018 1:22 am
- Location: Québec
Re: [MOD] Discrete Crosshair
VMblast wrote: ↑Sun Jan 13, 2019 10:48 am I did this test of suggested dagger. It would be fitting to have dagger cursor for the Daggerfall game, however Im not too sure, I had to do quite a bit of balancing since daggers are long, with prominent handle. If I squish it too much it'll just become a mess and not look like what suppose to look like....
- pango
- Posts: 3359
- Joined: Wed Jul 18, 2018 6:14 pm
- Location: France
- Contact:
Re: [MOD] Discrete Crosshair
Oh, I totally missed the point then!Alyndiar wrote: ↑Mon Jan 14, 2019 7:45 am Hmm... I don't think we're talking about the same thing... You're talking about the crosshair... I'm talking about the pointer, previously the fugly blue arrow you see in the config menu when you start DFU or in the in-game menus like spellmaker or inventory... you know, this : Cursor2.png
Yes, I assume this one will have the same hotspot alignment as the default blue arrow.
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart
- VMblast
- Posts: 535
- Joined: Wed Mar 29, 2017 12:22 pm
- Contact:
Re: [MOD] Discrete Crosshair
@Alyndiar
Oh Jesus, this is too small. What kind of resolution you've got there?
Bigger HDUltra versions:
PS - Concerning spell icons -thats what I was afraid off and gave away three different icon sizes. Unity have bad rescaling algorithm obviously, as the icons get choppy and more "pixelized". Im looking at that feather and its really bad looking.
Oh Jesus, this is too small. What kind of resolution you've got there?
Bigger HDUltra versions:
PS - Concerning spell icons -thats what I was afraid off and gave away three different icon sizes. Unity have bad rescaling algorithm obviously, as the icons get choppy and more "pixelized". Im looking at that feather and its really bad looking.
- Interkarma
- Posts: 7253
- Joined: Sun Mar 22, 2015 1:51 am
Re: [MOD] Discrete Crosshair
I noted that Alyndiar posted those screenshots as JPGs, so this is probably more JPG artifacts than Unity's scaling (which is all GPU-based anyway). Here's the same feather snipped at 1080p (left) and 4k (right) in PNG format.
The 4k one is definitely sharper, but I think they both hold up fairly well against the 128x128 version supplied in the test atlas. When making the icon pack "for real", you'll be able to use whatever sizes look best for you as well.