Lokai

Moderator
Lokai submitted a new resource:

Flags of the World - Expands Voxpire's USA Flag idea, with a gump that lets you display the flag of each of 65 nations.

Allows you to display the flags of 65 nations of the world. This is an expansion of the idea from Voxpire's "USA Flag".

2 ways to use this right now.

1. [viewflags -- brings up the FlagPickerGump, which lets you browse all 65 nations. The gump is coded to allow you to add or remove countries as you wish without breaking the gump.
2. [viewflag <name of the country> -- this lets you view just the flag of that country. It is not case-sensitive and you don't have to use quotes to name a...

Read more about this resource...
 
I love this.
Not because I did it first or anything like that, but because I managed to inspire something this cool.
This is what this community is all about - pushing the limits, learning, and having fun while doing it!

You're right about it crashing the client, the gumps don't like a lot of data - you can fit 65kb of data into a single UO packet - so your gumps have to compress down to that size at maximum or you get compression buffer overflows and such.

There are techniques for reducing the amount of data - like a circle can be made of a single large square, with lines on each side that get shorter and shorter to make up a circle - rather than having every pixel in the circle generated individually.
Triangles can kinda be drawn the same way, but it's a lot tougher - you have to break them into a set of the largest possible rectangles, then fill in the rest with lines or pixels.
Another good way to save space is to use layers - if the flag has a dominant color, us that as the main background and fill that in, etc, so you're not repeating things for the stripes and such (looks like you did this for the most part already).
Flags that have 3 consecutive stripes of two alternating colors, can be represented by two html entries instead of three - one entry is 100% width/height of the full striped area, and the other rectangle is 33% and is laid-out along the center. This give the illusion of sequential stripes.

I may release my Geo-Location service at some point, and this system would be a neat one to embed with it to display each player's flag (since it can extrapolate their country, etc).

Anyway, great work!
 
Seria genial incorporar las banderas, al lado o encima del nombre del jugador.

> It looks like there aren't many great matches for your search.
 
Back