These are chat archives for ZaneDubya/UltimaXNA

14th
Aug 2015
Zane Wagner
@ZaneDubya
Aug 14 2015 01:17
@jeffboulanger Sounds exceptional. Had some spaghetti / mb this afternoon - pretty exceptional, but I'm sure yours would be better.
lol, exceptional this, exceptional that.
Everything is exceptional!
Except for me, I'm bone tired.
;)
@paezao Any updates? :)
I have the new html renderer working - but only barely. The output looks completely wrong. But it's working!
And the code is so much cleaner than before!
Marcelo Paez
@paezao
Aug 14 2015 02:40
hey man
got home late today :|
Jeff Boulanger
@jeffboulanger
Aug 14 2015 02:40
@ZaneDubya Sweet
Marcelo Paez
@paezao
Aug 14 2015 02:41
didnt have time to test the stackables
Zane Wagner
@ZaneDubya
Aug 14 2015 13:04
@paezao No worries. Again, if you have questions, please ask. :)
Zane Wagner
@ZaneDubya
Aug 14 2015 13:30
Ok, the rendering looks almost perfect. I just need to add block collapsing.
And href link regions...
Marcelo Paez
@paezao
Aug 14 2015 14:12
Hey :D
Cool
Zane Wagner
@ZaneDubya
Aug 14 2015 15:32
@robertdeclaux Curious, what are the cpu/gpu stats on your laptop?
Your screenshots on #223 show DrawMS = 2%; on my computer it takes 4%. My computer is a virtualized 4ghz windows; I wonder how much performance I'm losing to virtualization...
Zane Wagner
@ZaneDubya
Aug 14 2015 17:31
I have completed and am merging the new html layout engine. It may well cause graphical errors and crashes. Let me know if you find any. I will close this issue with M0.7; I assume that if there are any problems, they will have been discovered by then.
See #257.
Marcelo Paez
@paezao
Aug 14 2015 17:32
Cool
Ill check that out later
Jeff Boulanger
@jeffboulanger
Aug 14 2015 17:32
congrats man
Marcelo Paez
@paezao
Aug 14 2015 17:32
:D
Zane Wagner
@ZaneDubya
Aug 14 2015 17:34
Took long enough!
:shipit:
Marcelo Paez
@paezao
Aug 14 2015 17:35
Hope I have more time to help out next week
been crazy here at work
Zane Wagner
@ZaneDubya
Aug 14 2015 17:35
Color me unsurprised.
Startup and all.
:)
Marcelo Paez
@paezao
Aug 14 2015 17:35
Yea
Im fighting to have the weekend off
My wife is starting to complain
And shes very patient
Zane Wagner
@ZaneDubya
Aug 14 2015 17:42
You know your priorities ;)
Zane Wagner
@ZaneDubya
Aug 14 2015 17:56
MonoGame includes input handling functionality that would effectively replace all of the windows-specific input code.
However, they don't include localization.
So that would still be platform specific. :(
This resource seems like a good start for localization:
Jeff Boulanger
@jeffboulanger
Aug 14 2015 17:57
isnt their input handling the same as xna's?
Zane Wagner
@ZaneDubya
Aug 14 2015 17:57
(start, end, and finish)
Jeff Boulanger
@jeffboulanger
Aug 14 2015 17:58
Keyboard.GetState() Mouse.GetState()
Zane Wagner
@ZaneDubya
Aug 14 2015 17:58
Yes, but they also include GameWindow.TextEntered or somesuch.
Which allows for event-based keyboard input; which is really all that we need beyond xna's input routines.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 17:59
the only reason the event input is used is cause per-frame state checking doesnt mimic the UO client
classic client
a perfect example would be
pressing and holding a key, there is a .25-.35 period where you dont get constant input
an example of this is just pressing the a key in notpad
initial A is typed, then about .5 seconds later, multiple aaaaaaaa's are output
Zane Wagner
@ZaneDubya
Aug 14 2015 18:00
That's not the reason we're using windows msg based input - your input code handles the issue of xna's input routines not being event-based.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:00
ya but its crap
Zane Wagner
@ZaneDubya
Aug 14 2015 18:01
Your input code?
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:01
that was the reason I write that input code
to mimic windows input
reason is
macros
spamming macros would be bad
and doing 60 fps checks on whats down, can spam macros
unless you write all the logic to wait
which i didnt wanna do
Plus input can be handled on a seperate thread with the event based approach
Zane Wagner
@ZaneDubya
Aug 14 2015 18:03
So MonoGame's GameWindow.TextInput event does handle both the pause and key repeating.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:03
events are triggered on the windows message loop, where as DX is run in its own thread.
nice
Zane Wagner
@ZaneDubya
Aug 14 2015 18:04
It doesn't work on MAC Os X, but does work on Windows and Linux...
Wonder why not Mac.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:04
dunno
Ill be honest, ive not heard good things of monogame
Zane Wagner
@ZaneDubya
Aug 14 2015 18:04
Non-character keys aren't handled either.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:04
we have a developer here that ported his game, he has nothing but complaints
Zane Wagner
@ZaneDubya
Aug 14 2015 18:04
So tab, backspace, etc.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:04
and never finished the port
from XNA too
Marcelo Paez
@paezao
Aug 14 2015 18:04
did he try FNA?
Zane Wagner
@ZaneDubya
Aug 14 2015 18:05
Jeff, that may be the case, but: http://www.monogame.net/showcase/
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:06
Sure, im not saying its not doable
i just dont believe in monogame
;)
its stale, old, and behind in the race to create amazing cross framework/platforms
Zane Wagner
@ZaneDubya
Aug 14 2015 18:08
Interestingly, the 'platform difference' page on MG's website doesn't mention the lack of that keyboard input functionality. Excellent keyboard input is essential for an MMO...
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:10
http://sharpdx.org/news/ this is why i dont like monogame
the guy that wrote this (Which is what monogame uses)
now works and extends paradox3d
and isnt updating sharpdx anymore
Marcelo Paez
@paezao
Aug 14 2015 18:10
UE4 is the good thing
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:11
monogame is a plethera of community input and not an actual game engine written by 1 specific company from scratch. its more of a mesh of a ton of different libs that got thrown together to get things to work
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:20
ue4 would just be an entire rewrite
;)
Marcelo Paez
@paezao
Aug 14 2015 18:22
yea thats for sure
lol
Zane Wagner
@ZaneDubya
Aug 14 2015 18:49
Sometimes I think that the xna client needs an entire rewrite just to work on xna ;)
Jeff Boulanger
@jeffboulanger
Aug 14 2015 18:49
lol
Marcelo Paez
@paezao
Aug 14 2015 18:52
haha
Zane Wagner
@ZaneDubya
Aug 14 2015 22:48
@jeffboulanger Let's brainstorm.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 22:48
do i have to ? ;)
Zane Wagner
@ZaneDubya
Aug 14 2015 22:48
RunUO only keeps the client updated with entities within 24 tiles.
;)
Should we just delete any entities outside of 24+x tiles?
Because they're never updated.
And they're always resent.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 22:49
do you always get a new packet for an entity that goes 25 then to 24?
Zane Wagner
@ZaneDubya
Aug 14 2015 22:49
Can't say.
What if we simply made them invisible at 24?
Jeff Boulanger
@jeffboulanger
Aug 14 2015 22:50
I mean, i wouldnt draw them if they arent within view
but maybe have them fade out
not just disappear
Zane Wagner
@ZaneDubya
Aug 14 2015 22:50
And then if the server let us know they were moving (instead of letting us know they existed), we could just move thme.
Haha, well, can't do alpha transparency yet.
If you want to take on that job, be my guest ;)
Jeff Boulanger
@jeffboulanger
Aug 14 2015 22:50
;)
i would say ya, if they are 24> tiles away, just drop them from the world
Zane Wagner
@ZaneDubya
Aug 14 2015 22:58
Now that I look at it again, it looks like 16 tiles.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 22:59
yikes
allowing fullscreen world rendering seems pretty pointless now ;)
Zane Wagner
@ZaneDubya
Aug 14 2015 22:59
Yeah...
We could grey out tiles beyond 16?
Or draw a line or some such.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 23:07
ya maybe
what'd be really cool is like a fog of war type of effect
Zane Wagner
@ZaneDubya
Aug 14 2015 23:07
Very cool!
And potentially doable without alpha transparency...
I mean, certainly doable; if brood war could do it, so can we ;)
Jeff Boulanger
@jeffboulanger
Aug 14 2015 23:08
you could just render fog of war over top of everything
wouldnt need to worry about transparency, it'd be a post process
however
the better way to do it would be how fog is done in the shader via distance
so the shader would receive the center pixel
and a distance
and you calculate the drawing vector distance
from center
sec ill find code
This message was deleted
stupid gitter
//Needed Variables
uniform const float     FogEnabled      : register(c0);
uniform const float     FogStart        : register(c1);
uniform const float     FogEnd          : register(c2);
uniform const float3    FogColor        : register(c3);

//Vertex Shader Bits
float ComputeFogFactor(float d) 
{
    //d is the distance to the geometry sampling from the camera
    //this simply returns a value that interpolates from 0 to 1 
    //with 0 starting at FogStart and 1 at FogEnd 
    return clamp((d - FogStart) / (FogEnd - FogStart), 0, 1) * FogEnabled;
}

CommonVSOutput ComputeCommonVSOutput(float4 position)
{
    CommonVSOutput vout;

    float4 pos_ws = mul(position, World);
    float4 pos_vs = mul(pos_ws, View);
    float4 pos_ps = mul(pos_vs, Projection);

    vout.Pos_ws = pos_ws;
    vout.Pos_ps = pos_ps;

    vout.Diffuse    = float4(DiffuseColor.rgb + EmissiveColor, Alpha);
    vout.Specular   = 0;
    vout.FogFactor  = ComputeFogFactor(length(EyePosition - pos_ws ));

    return vout;
}

VertexLightingVSOutputTx VSBasicTx(VSInputTx vin)
{
    VertexLightingVSOutputTx vout;

    CommonVSOutput cout = ComputeCommonVSOutput(vin.Position);

    vout.PositionPS = cout.Pos_ps;
    vout.Diffuse    = cout.Diffuse;
    vout.Specular   = float4(cout.Specular, cout.FogFactor);
    vout.TexCoord   = vin.TexCoord;

    return vout;
}

float4 PSBasicTx(VertexLightingPSInputTx pin) : COLOR
{
    float4 color = tex2D(TextureSampler, pin.TexCoord) * pin.Diffuse + float4(pin.Specular.rgb, 0);
    color.rgb = lerp(color.rgb, FogColor, pin.Specular.w);
    return color;
}
Zane Wagner
@ZaneDubya
Aug 14 2015 23:11
Do you think the different heights; etc would make the effect look screwy?
btw I can just barely see items pop in at 1280x1280.
make that 1024x1024.
Jeff Boulanger
@jeffboulanger
Aug 14 2015 23:23
1024 is the biggest they allow
in settings
Zane Wagner
@ZaneDubya
Aug 14 2015 23:35
800x600
1024 fullscreen, I think.
But that's including the black area.
Zane Wagner
@ZaneDubya
Aug 14 2015 23:58
Ok, that's enough programming for a friday.
Night all!