PenUltima Online

It is currently Thu Aug 28, 2008 9:57 pm

All times are UTC - 8 hours




Post new topic Reply to topic  [ 26 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Integrated Static Tool
PostPosted: Mon Apr 03, 2006 3:44 am 
Offline

Joined: Thu Feb 02, 2006 8:33 am
Posts: 271
I'm just working on a custom map2 getting a little insane while doing so :wink: I think most of us know that building maps and statics need a lot of patience and a lot of knowledge of several tools (UO Landscaper, World Forge, UOSIR, UOSP .........). Imho there is no tool to create or edit statics2.mul and staidx2.mul except for random creation with UO Landscaper or install RunUO and use the freeze function there (just read that). This is way to complicated i think.

Cause 96 has ListStatics* commands i thought about an easy to use a feature at least for statics to build, edit or delete staticsN.mul and staidxN.mul files. The file formats for these files are well known and i thought about writing a pearl script but if pol can do that for all map statics it would be a lot easier and we all can easily do that just using pol.

I think about commands like:

AddItemsToStaticsInBox(( x1,y1,z1, x2,y2,z2, flags := 0, realm := _DEFAULT_REALM );

AddItemsToStaticsOfTypeInBox(( x1,y1,z1, x2,y2,z2, objtype, flags := 0, realm := _DEFAULT_REALM );

DeleteStaticItemsInBox(( x1,y1,z1, x2,y2,z2, realm := _DEFAULT_REALM );

DeleteStaticItemsOfTypeInBox(( x1,y1,z1, x2,y2,z2, objtype, realm := _DEFAULT_REALM );

Flags could be:
const IGNORE_Z := ??;
const IGNORE_DOORS := ??;
const IGNORE_INVIS_ITEMS := ??;

Just to mention the most important operations.
Pol could rebuild the staidxN.mul and staticsN.mul then and save it e.g. as newstaidxN.mul and newstaticsN.mul into the mul directory.

If that is possible, it could save a lot of time in world building. You only need to uoconvert the new files and restart the server to check your work.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 03, 2006 7:01 am 
Offline

Joined: Tue Mar 07, 2006 7:28 am
Posts: 39
Location: Poland
IMO good idea, it'll help a lot in world building.

_________________
Sorry for my English... I don't know it well.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 03, 2006 7:49 am 
Offline
Distro Developer
User avatar

Joined: Fri Feb 10, 2006 8:08 am
Posts: 313
Location: Myrtle Beach, South Carolina
Some way of burning items into statics VIA pol would be absolutely wonderful.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 03, 2006 9:50 am 
Offline

Joined: Tue Mar 07, 2006 7:28 am
Posts: 39
Location: Poland
Hmm what about automated uoconvert (but not all file, only edited part, so core will edit both mul and POL map .dat files)? I think it'll be possible.
And what about "unloading" them without restarting server? Is it possible? I know that client restart is required (mul files), but what about server?

_________________
Sorry for my English... I don't know it well.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 04, 2006 9:34 am 
Offline
User avatar

Joined: Sat Feb 04, 2006 8:17 am
Posts: 136
Location: Illinois, USA
With Windows, if the file is in use changes can not be saved to them. That is why the restart would be required. At least that is what I have heard in the past.

_________________
2nd place is the 1st loser.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 04, 2006 10:35 am 
Offline

Joined: Tue Mar 07, 2006 7:28 am
Posts: 39
Location: Poland
Uh, you're right, I forgot this :D

_________________
Sorry for my English... I don't know it well.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Apr 05, 2006 7:14 am 
Tritan wrote:
With Windows, if the file is in use changes can not be saved to them. That is why the restart would be required. At least that is what I have heard in the past.


That's actually not technically true - a program can choose what sort of lock to request on a file, and the operating system can grant or not grant that type of lock.

With that said, it is typical when a program must have constant access to a file which it expects never to change, that it requests a lock that prevents writing to the file. This is usually because changes in some part of the file could cause program errors due to the program making assumptions about what else it read from the file before - which may have changed in the interim.

I haven't tested it myself, but my understanding is that POL096 doesn't lock -ANY- of the mul files at all, since it's actually not reading them at all.

But the configs that it produces, which it has to read from time to time - POL typically does not lock them at all ever, except for the momentary locks when it actually is writing to them. This demonstrates what I said above: It's up to the program to lock or not lock, depending on how it uses the file in question. (of course, it's also likely POL doesn't keep those files open, but just opens them right when it needs them - but I still don't believe it locks the files at all while reading, as you would expect errors if you were editing a config file at the same time POL read from it, but I've never seen such an error)


ALL of that said... I think I would have to vote against including such features into POL, for two reasons:

One: The tools to do this are already out there, so why waste POL dev time (which is already so extremely limited) working on reinventing the wheel?

Two: I really don't want my production server clogged up with code for this sort of thing. Even if the above objection were made moot by a sudden influx of more dev team time than needed to accomplish the more important things that need to be done for POL, I would still object to this unless it were possible to configure POL not even to load the code which does this... as a dynamically loaded module, for example.


Top
  
 
 Post subject:
PostPosted: Wed Apr 05, 2006 3:14 pm 
Offline

Joined: Fri Feb 03, 2006 9:13 am
Posts: 32
Location: Canada, Quebec
Stafflicker...

_________________
Image


Top
 Profile  
 
 Post subject:
PostPosted: Wed Apr 05, 2006 5:57 pm 
Offline
Distro Developer
User avatar

Joined: Fri Feb 10, 2006 8:08 am
Posts: 313
Location: Myrtle Beach, South Carolina
Marilla I totally understand you'd rather have the devs bust out all the bugs. But this is a Feature suggestion. It doesn't really help pol, but it helps the users. That's what Features do. Atleast from my point of view, which to you is apperently very wrong. :D

What you're basically saying is that you'd rather; cmd<coords/target> the item(s) you want static into a cfg, copy/paste the cfg, load up a program, burn the statics, etc.

Sphere/RunUO(One of the two) has it(I think) and no this isn't Sphere/RunUO. But you have to admit, it's a nice Feature for an emulator. And knowing you, you probably will still object to it/never agree to it even if we had the developers.

That's all I'm going to say, Anti-Feature. :) Rawr.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Apr 06, 2006 4:22 am 
Unreal wrote:
Marilla I totally understand you'd rather have the devs bust out all the bugs. But this is a Feature suggestion. It doesn't really help pol


Thank you for making my point for me.


Top
  
 
 Post subject:
PostPosted: Fri Apr 07, 2006 9:56 am 
Offline

Joined: Fri Feb 03, 2006 9:13 am
Posts: 32
Location: Canada, Quebec
I know a song... In it, you can hear... Marilla Marillaaaaa.... (the song continu but I don't know the words...lol..) Anyway, this post is absolutely useless...

_________________
Image


Top
 Profile  
 
 Post subject:
PostPosted: Sat Apr 08, 2006 3:50 pm 
Offline

Joined: Thu Feb 02, 2006 8:33 am
Posts: 271
I thought i made a feature suggestion. I don't wanted to start a personal war. It seems some of you want?. I suggest this, cause it seems only RunUO has a solution for that. I had to install this server now to solve that. I have to run through new commands for me. Nevertheless i think it will be a good idea for Pol, cause People should choose Pol for such a reason(feature). Maybe i am wrong.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Apr 09, 2006 1:00 pm 
Offline

Joined: Thu Feb 02, 2006 1:41 pm
Posts: 1118
Location: Southern Central USA
I agree Pierce. POL needs tools like the ones being developed for RunUO. It seems to be defeating the purpose if we need to install a RunUO server just to be able to do map creation and editing in a userfriendly environment.

Now understand I have yet to even try one of those utilities developed for RunUO so they may not be as user friendly as I assume them to be. But to hear the propoganda from those developing them they sure sound like they are. Regardless of what is being done for/with other emulators, it would be nice to have tools like that for us.

I would even be willing to pay for such a program as long as the price was reasonable, say $20.00 to $30.00 US for a decent map editing and static editing program.

_________________
Sincerely,
Yukiko

I know you think you understand what you thought I said but what you heard is not exactly what I meant.

Titus 2:13


Top
 Profile  
 
 Post subject:
PostPosted: Sun Apr 09, 2006 4:37 pm 
Offline

Joined: Sat Jan 28, 2006 12:39 pm
Posts: 38
Location: Greece
Indeed it would be nice to have such a feature. Though I'd prefer it to be a simple tool that does just that, and not integrate that kind of code into POL's core base.

Maybe a small just-do-this tool would be more handy/appropriate.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Apr 09, 2006 9:38 pm 
Offline

Joined: Thu Feb 02, 2006 1:41 pm
Posts: 1118
Location: Southern Central USA
Oh yes Melanius. I am sorry. I didn't mean to suggest that it should be integrated into the POL core at all.

I guess I should have stated it more clearly.

I meant to say that it would be nice to have an outside tool that would do what we need and be able to work in the same way Dundee's Other Hand does. It would be nice to be able to be logged into POL and while standing in a certain area be able to either add or remove areas from the map or statics simply by having the program "see" where we are in game. I am pretty sure that any map/statics mods would have to be done on copies of the map rather than the one being used. I am not sure if what I am thinking of is even possible for map editing. Any program that would allow creation of the map in realtime would be nice and that wouldn't have to be attached to POL in any way.

I wish I knew more about the grapjics end of programming. I never got into that much.

_________________
Sincerely,
Yukiko

I know you think you understand what you thought I said but what you heard is not exactly what I meant.

Titus 2:13


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 13, 2006 11:55 am 
Offline

Joined: Thu Feb 02, 2006 8:33 am
Posts: 271
melanius wrote:
Indeed it would be nice to have such a feature. Though I'd prefer it to be a simple tool that does just that, and not integrate that kind of code into POL's core base.

Maybe a small just-do-this tool would be more handy/appropriate.


A simple tool like uoconvert would also be great. I suggest that as pol commands cause you could ask the gamemasters building around. And if they are ready you use these commands to build the new statics and pol will delete the found items to build a new static file from the items.txt.
The possibility of coordination in world building on pol would be better.
I surely don't now if this is much code to swell the core. But these functions won't be called often (i think) to cause lag on a live shard.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jun 16, 2006 11:36 am 
Offline
User avatar

Joined: Thu Feb 09, 2006 11:48 pm
Posts: 35
Location: Finland
If we could have only one new feature for 97, I would definately give my voice for this one. The new core is very stable (not a single crash after RC3 was released, absolutely great job!), so it would be good timing to try something new.

Currently updating statics with pol and external tools contains too much simplistic work that should be handled automaticly. Desroying one or two items in statics is plainly said painful operation. Only the server can give the best support for statics editing, especially when there are multiple builders.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 22, 2006 12:57 pm 
Offline

Joined: Thu Feb 02, 2006 8:33 am
Posts: 271
Is there perhaps someone who played around with the RunUO type of files? I installed that server and played around with statics on the ilshenar map. It's very easy to change the statics on RunUO on every map. I can realtime delete or add statics there. The .mul is changed immediatly.
The only function i like on RunUO. So i tried to take a look if i can write a converter from item.txt to the RunUO type of handling of items. But that are 3 files, that are not purely text: items.bin, items.idx,items.tbd.
So it's not the easy way to convert. Does anyone else also take a look into this already?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 22, 2006 2:03 pm 
Offline

Joined: Sun Feb 05, 2006 2:00 am
Posts: 91
Location: Denmark
This is very high on my wish list, for the next POL release.

_________________
When was the last time, you did something for the first time?


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 26, 2006 12:46 pm 
Offline

Joined: Thu Feb 02, 2006 8:33 am
Posts: 271
Shame on me, i forget the language POL is written. Was it C++?
If so, it could be a simple thing if one takes a look into the statics.cs command of runuo.

The last three days i played around with runuo a little bit, without any knowledge of c++. The only thing that was interesting for me was the extremly fast method to change the static files cause it tooks too much time to use uosir, uosp or anything else ... And they don't work on maps like ilshenar, malas ...

So i tried too make a runuo 1.0 command that reads the 96/97 items.txt of Pol. After biting 2 days in my keyboard cause of no real idea how C++ works i managed the command on day 3. So far a test command.
I coded it so we could read in the items.txt this way:

command x1 y1 x2 y2 mapid

The command will read every item within these ranges on the choosen map to runuo. I did a test with a 23 MB items.txt without creating items. It took about 2-3 min. to go through that file size on runuo. Perhaps it can be faster, i am new to c++ as i said :D

The creating also works. I test it with a small range with 10 test items.
I will do some further test with some structures i like to place on the ilshenar map and therefor i tried this in first place.

If these tests are successful, i will post this command here.

Nevertheless i hope this will be a feature of POL, cause i hate to use 20 different programs and copy around data to reach my goal :wink:


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 29, 2006 6:15 am 
Offline

Joined: Sun Mar 05, 2006 7:25 am
Posts: 118
Location: Italy
My vote goes for a "simple" single function

ItemToStatics(itemref);

which copies the item to the right statics file according to the map it belongs to.
No need to delete the dynamic item, it can be done with another instruction
No need to add another command to delete in an area, it can be done in scripts
Any other login can be added in script, one single command which just copies 1 item to statics would be easy and powerful
there also is no need to autorun uoconvert and update the at runtime the server data about statics movement validation and such, it can be done turning the server off and doing it manually running uoconvert by command line
Having the ability to code a script which converts to statics the buildings but leaves the doors in dynamic would be great, and you can think of a lot of other examples where this could be very usefull.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 29, 2006 5:10 pm 
Offline

Joined: Thu Feb 02, 2006 8:33 am
Posts: 271
Quote:
there also is no need to autorun uoconvert and update the at runtime the server data about statics movement validation


Are you sure?
If the statics on whatever Map is changed, you need to run uoconvert again.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 30, 2006 1:25 am 
Offline

Joined: Sun Mar 05, 2006 7:25 am
Posts: 118
Location: Italy
Of course, you have to
- shutdown the server
- run uoconvert
- give new statics to clients
- restart the server

What I meant is that, imho, there's no need for a complex modification to the server in order to add a StaticsConvert() function which lets us runuoconvert by scripts without having to shutdown and restart the server, because I think it would be a complex modification for the devs and not as useful as the ItemToStatics(itemref) itself. Do you agree?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Aug 31, 2006 3:17 pm 
Offline

Joined: Thu Feb 02, 2006 8:33 am
Posts: 271
Lagoon wrote:
Do you agree?

Hard to say if i agree to that. I convert my items to RunUo and freeze it there to the .mul files. My wish stays as i stated in my first post in this topic to save this in my opinion useless export to runuo. And therefor force their only advantage over Pol.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Sep 01, 2006 1:58 am 
Offline

Joined: Sun Mar 05, 2006 7:25 am
Posts: 118
Location: Italy
I use a RunUO server to build my towns for the same reason
And also because noone ever coded (it's a cat who bites its tail) a tool like UO Architect for POL


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 26 posts ]  Go to page 1, 2  Next

All times are UTC - 8 hours


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Style based on FI Subice by phpBBservice.nl