diff options
author | Robert Knop <prospero@lindenlab.com> | 2009-02-25 21:02:17 +0000 |
---|---|---|
committer | Robert Knop <prospero@lindenlab.com> | 2009-02-25 21:02:17 +0000 |
commit | c88b470a8a2cdae8e69e5570b46d4b21c43368bc (patch) | |
tree | 551d764767aa1d9c095a99b586f5bb38ae3f1e57 /indra/llinventory/llparcel.cpp | |
parent | 997d24b83221aa63ef8141a9ab94434d2ba2ddc6 (diff) |
svn merge -r108815:112761 svn+ssh://svn.lindenlab.com/svn/linden/branches/server/server-1.26
The biggest things in this are Scalable Space Servers and Maint-Server-6
QAR-1209 : SSS
QAR-1295 : maint-server-6
Conflicts resolved by prospero:
C scripts/farm_distribute
C scripts/automated_build_scripts/build-linux.sh : resolved by
prospero, mostly kept the merge-right version in
the conflict, but there was one block of repeated
code from earlier that I removed.
C scripts/automated_build_scripts/build-mac.sh : kept merge-right
C indra/llcommon/llversionserver.h : svn revert
C indra/newsim/llsimparcel.h : kept *both*... working had "setArea",
merge-right had exportStream and importStream
C indra/newsim/llsimparcel.cpp : see llsimparcel.h
C indra/newsim/lltask.h : working had LLTask derived also from
LLScriptResourceConsumer, merge-right had LLTask
dervied also from LLAgentPosition. To resolve
conflict, derive from both.
C indra/newsim/lllslmanager.h : kept merge-right (had an added comment)
C indra/llmessage/llhttpnode.h : kept working (added the definition
of method LLHTTPNode::extendedResult)
C indra/lscript/lscript_execute_mono/llscriptexecutemono.cpp
C indra/lscript/lscript_execute_mono/llscriptexecutemono.h
: These two were resolved by si, in consultation with daveh
I also had to add the following stubs to
indra/newsim/tests/llgodkickutils_test.cpp in order to get it to
compile:
// LLScriptResourceConsumer interface methods in LLTask
LLScriptResource::LLScriptResource() { }
LLScriptResourcePool::LLScriptResourcePool() { }
LLScriptResourcePool LLScriptResourcePool::null;
LLScriptResourceConsumer::LLScriptResourceConsumer() { }
LLScriptResourcePool& LLScriptResourceConsumer::getScriptResourcePool() { return LLScriptResourcePool::null; }
const LLScriptResourcePool& LLScriptResourceConsumer::getScriptResourcePool() const { return LLScriptResourcePool::null; }
bool LLScriptResourceConsumer::switchScriptResourcePools(LLScriptResourcePool& new_pool) { return false; }
bool LLScriptResourceConsumer::canUseScriptResourcePool(const LLScriptResourcePool& resource_pool) { return false; }
bool LLScriptResourceConsumer::isInPool(const LLScriptResourcePool& resource_pool) { return false; }
void LLScriptResourceConsumer::setScriptResourcePool(LLScriptResourcePool& pool) { }
S32 LLTask::getUsedPublicURLs() const { return 0; }
void LLTask::setScriptResourcePool(LLScriptResourcePool& pool) { }
Diffstat (limited to 'indra/llinventory/llparcel.cpp')
-rw-r--r-- | indra/llinventory/llparcel.cpp | 744 |
1 files changed, 0 insertions, 744 deletions
diff --git a/indra/llinventory/llparcel.cpp b/indra/llinventory/llparcel.cpp index 6fa5c9076e..2689ada80c 100644 --- a/indra/llinventory/llparcel.cpp +++ b/indra/llinventory/llparcel.cpp @@ -110,37 +110,11 @@ static const std::string PARCEL_ACTION_STRING[LLParcel::A_COUNT + 1] = "unknown" }; -// Timeouts for parcels -// default is 21 days * 24h/d * 60m/h * 60s/m *1000000 usec/s = 1814400000000 -const U64 DEFAULT_USEC_CONVERSION_TIMEOUT = U64L(1814400000000); -// ***** TESTING is 10 minutes -//const U64 DEFAULT_USEC_CONVERSION_TIMEOUT = U64L(600000000); -// group is 60 days * 24h/d * 60m/h * 60s/m *1000000 usec/s = 5184000000000 -const U64 GROUP_USEC_CONVERSION_TIMEOUT = U64L(5184000000000); -// ***** TESTING is 10 minutes -//const U64 GROUP_USEC_CONVERSION_TIMEOUT = U64L(600000000); -// default sale timeout is 2 days -> 172800000000 -const U64 DEFAULT_USEC_SALE_TIMEOUT = U64L(172800000000); -// ***** TESTING is 10 minutes -//const U64 DEFAULT_USEC_SALE_TIMEOUT = U64L(600000000); - -// more grace period extensions. -const U64 SEVEN_DAYS_IN_USEC = U64L(604800000000); - -// if more than 100,000s before sale revert, and no extra extension -// has been given, go ahead and extend it more. That's about 1.2 days. -const S32 EXTEND_GRACE_IF_MORE_THAN_SEC = 100000; - - -const std::string& ownership_status_to_string(LLParcel::EOwnershipStatus status); -LLParcel::EOwnershipStatus ownership_string_to_status(const std::string& s); //const char* revert_action_to_string(LLParcel::ESaleTimerExpireAction action); //LLParcel::ESaleTimerExpireAction revert_string_to_action(const char* s); -const std::string& category_to_string(LLParcel::ECategory category); const std::string& category_to_ui_string(LLParcel::ECategory category); -LLParcel::ECategory category_string_to_category(const std::string& s); LLParcel::ECategory category_ui_string_to_category(const std::string& s); LLParcel::LLParcel() @@ -548,500 +522,6 @@ void LLParcel::setDiscountRate(F32 rate) // File input and output //----------------------------------------------------------- - -// WARNING: Area will be wrong until you calculate it. -BOOL LLParcel::importStream(std::istream& input_stream) -{ - U32 setting; - S32 secs_until_revert = 0; - - skip_to_end_of_next_keyword("{", input_stream); - if (!input_stream.good()) - { - llwarns << "LLParcel::importStream() - bad input_stream" << llendl; - return FALSE; - } - - while (input_stream.good()) - { - skip_comments_and_emptyspace(input_stream); - std::string line, keyword, value; - get_line(line, input_stream, MAX_STRING); - get_keyword_and_value(keyword, value, line); - - if ("}" == keyword) - { - break; - } - else if ("parcel_id" == keyword) - { - mID.set(value); - } - else if ("status" == keyword) - { - mStatus = ownership_string_to_status(value); - } - else if ("category" == keyword) - { - mCategory = category_string_to_category(value); - } - else if ("local_id" == keyword) - { - LLStringUtil::convertToS32(value, mLocalID); - } - else if ("name" == keyword) - { - setName( value ); - } - else if ("desc" == keyword) - { - setDesc( value ); - } - else if ("music_url" == keyword) - { - setMusicURL( value ); - } - else if ("media_url" == keyword) - { - setMediaURL( value ); - } - else if ("media_desc" == keyword) - { - setMediaDesc( value ); - } - else if ("media_type" == keyword) - { - setMediaType( value ); - } - else if ("media_width" == keyword) - { - S32 width; - LLStringUtil::convertToS32(value, width); - setMediaWidth( width ); - } - else if ("media_height" == keyword) - { - S32 height; - LLStringUtil::convertToS32(value, height); - setMediaHeight( height ); - } - else if ("media_id" == keyword) - { - mMediaID.set( value ); - } - else if ("media_auto_scale" == keyword) - { - LLStringUtil::convertToU8(value, mMediaAutoScale); - } - else if ("media_loop" == keyword) - { - LLStringUtil::convertToU8(value, mMediaLoop); - } - else if ("obscure_media" == keyword) - { - LLStringUtil::convertToU8(value, mObscureMedia); - } - else if ("obscure_music" == keyword) - { - LLStringUtil::convertToU8(value, mObscureMusic); - } - else if ("owner_id" == keyword) - { - mOwnerID.set( value ); - } - else if ("group_owned" == keyword) - { - LLStringUtil::convertToBOOL(value, mGroupOwned); - } - else if ("clean_other_time" == keyword) - { - S32 time; - LLStringUtil::convertToS32(value, time); - setCleanOtherTime(time); - } - else if ("auth_buyer_id" == keyword) - { - mAuthBuyerID.set(value); - } - else if ("snapshot_id" == keyword) - { - mSnapshotID.set(value); - } - else if ("user_location" == keyword) - { - sscanf(value.c_str(), "%f %f %f", - &mUserLocation.mV[VX], - &mUserLocation.mV[VY], - &mUserLocation.mV[VZ]); - } - else if ("user_look_at" == keyword) - { - sscanf(value.c_str(), "%f %f %f", - &mUserLookAt.mV[VX], - &mUserLookAt.mV[VY], - &mUserLookAt.mV[VZ]); - } - else if ("landing_type" == keyword) - { - S32 landing_type = 0; - LLStringUtil::convertToS32(value, landing_type); - mLandingType = (ELandingType) landing_type; - } - else if ("join_neighbors" == keyword) - { - llinfos << "found deprecated keyword join_neighbors" << llendl; - } - else if ("revert_sale" == keyword) - { - LLStringUtil::convertToS32(value, secs_until_revert); - if (secs_until_revert > 0) - { - mSaleTimerExpires.start(); - mSaleTimerExpires.setTimerExpirySec((F32)secs_until_revert); - } - } - else if("extended_grace" == keyword) - { - LLStringUtil::convertToS32(value, mGraceExtension); - } - else if ("user_list_type" == keyword) - { - // deprecated - } - else if("auction_id" == keyword) - { - LLStringUtil::convertToU32(value, mAuctionID); - } - else if ("allow_modify" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_CREATE_OBJECTS, setting); - } - else if ("allow_group_modify" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_CREATE_GROUP_OBJECTS, setting); - } - else if ("allow_all_object_entry" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_ALL_OBJECT_ENTRY, setting); - } - else if ("allow_group_object_entry" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_GROUP_OBJECT_ENTRY, setting); - } - else if ("allow_deed_to_group" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_DEED_TO_GROUP, setting); - } - else if("contribute_with_deed" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_CONTRIBUTE_WITH_DEED, setting); - } - else if ("allow_terraform" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_TERRAFORM, setting); - } - else if ("allow_damage" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_DAMAGE, setting); - } - else if ("allow_fly" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_FLY, setting); - } - else if ("allow_landmark" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_LANDMARK, setting); - } - else if ("sound_local" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_SOUND_LOCAL, setting); - } - else if ("allow_group_scripts" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_GROUP_SCRIPTS, setting); - } - else if ("allow_voice_chat" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_VOICE_CHAT, setting); - } - else if ("use_estate_voice_chan" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_USE_ESTATE_VOICE_CHAN, setting); - } - else if ("allow_scripts" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_OTHER_SCRIPTS, setting); - } - else if ("for_sale" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_FOR_SALE, setting); - } - else if ("sell_w_objects" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_SELL_PARCEL_OBJECTS, setting); - } - else if ("use_pass_list" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_USE_PASS_LIST, setting); - } - else if ("show_directory" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_SHOW_DIRECTORY, setting); - } - else if ("allow_publish" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_ALLOW_PUBLISH, setting); - } - else if ("mature_publish" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_MATURE_PUBLISH, setting); - } - else if ("claim_date" == keyword) - { - // BUG: This will fail when time rolls over in 2038. - S32 time; - LLStringUtil::convertToS32(value, time); - mClaimDate = time; - } - else if ("claim_price" == keyword) - { - LLStringUtil::convertToS32(value, mClaimPricePerMeter); - } - else if ("rent_price" == keyword) - { - LLStringUtil::convertToS32(value, mRentPricePerMeter); - } - else if ("discount_rate" == keyword) - { - LLStringUtil::convertToF32(value, mDiscountRate); - } - else if ("draw_distance" == keyword) - { - LLStringUtil::convertToF32(value, mDrawDistance); - } - else if ("sale_price" == keyword) - { - LLStringUtil::convertToS32(value, mSalePrice); - } - else if ("pass_price" == keyword) - { - LLStringUtil::convertToS32(value, mPassPrice); - } - else if ("pass_hours" == keyword) - { - LLStringUtil::convertToF32(value, mPassHours); - } - else if ("box" == keyword) - { - // deprecated - } - else if ("aabb_min" == keyword) - { - sscanf(value.c_str(), "%f %f %f", - &mAABBMin.mV[VX], &mAABBMin.mV[VY], &mAABBMin.mV[VZ]); - } - else if ("use_access_group" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_USE_ACCESS_GROUP, setting); - } - else if ("use_access_list" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_USE_ACCESS_LIST, setting); - } - else if ("use_ban_list" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_USE_BAN_LIST, setting); - } - else if ("group_name" == keyword) - { - llinfos << "found deprecated keyword group_name" << llendl; - } - else if ("group_id" == keyword) - { - mGroupID.set( value ); - } - // TODO: DEPRECATED FLAG - // Flag removed from simstate files in 1.11.1 - // Remove at some point where we have guarenteed this flag - // no longer exists anywhere in simstate files. - else if ("require_identified" == keyword) - { - // LLStringUtil::convertToU32(value, setting); - // setParcelFlag(PF_DENY_ANONYMOUS, setting); - } - // TODO: DEPRECATED FLAG - // Flag removed from simstate files in 1.11.1 - // Remove at some point where we have guarenteed this flag - // no longer exists anywhere in simstate files. - else if ("require_transacted" == keyword) - { - // LLStringUtil::convertToU32(value, setting); - // setParcelFlag(PF_DENY_ANONYMOUS, setting); - // setParcelFlag(PF_DENY_IDENTIFIED, setting); - } - else if ("restrict_pushobject" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_RESTRICT_PUSHOBJECT, setting); - } - else if ("deny_anonymous" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_DENY_ANONYMOUS, setting); - } - else if ("deny_identified" == keyword) - { -// LLStringUtil::convertToU32(value, setting); -// setParcelFlag(PF_DENY_IDENTIFIED, setting); - } - else if ("deny_transacted" == keyword) - { -// LLStringUtil::convertToU32(value, setting); -// setParcelFlag(PF_DENY_TRANSACTED, setting); - } - else if ("deny_age_unverified" == keyword) - { - LLStringUtil::convertToU32(value, setting); - setParcelFlag(PF_DENY_AGEUNVERIFIED, setting); - } - else if ("access_list" == keyword) - { - S32 entry_count = 0; - LLStringUtil::convertToS32(value, entry_count); - for (S32 i = 0; i < entry_count; i++) - { - LLAccessEntry entry; - if (importAccessEntry(input_stream, &entry)) - { - mAccessList[entry.mID] = entry; - } - } - } - else if ("ban_list" == keyword) - { - S32 entry_count = 0; - LLStringUtil::convertToS32(value, entry_count); - for (S32 i = 0; i < entry_count; i++) - { - LLAccessEntry entry; - if (importAccessEntry(input_stream, &entry)) - { - mBanList[entry.mID] = entry; - } - } - } - else if ("renter_list" == keyword) - { - /* - S32 entry_count = 0; - LLStringUtil::convertToS32(value, entry_count); - for (S32 i = 0; i < entry_count; i++) - { - LLAccessEntry entry; - if (importAccessEntry(input_stream, &entry)) - { - mRenterList.put(entry); - } - }*/ - } - else if ("pass_list" == keyword) - { - // legacy - put into access list - S32 entry_count = 0; - LLStringUtil::convertToS32(value, entry_count); - for (S32 i = 0; i < entry_count; i++) - { - LLAccessEntry entry; - if (importAccessEntry(input_stream, &entry)) - { - mAccessList[entry.mID] = entry; - } - } - } - - else - { - llwarns << "Unknown keyword in parcel section: <" - << keyword << ">" << llendl; - } - } - - // this code block detects if we have loaded a 1.1 simstate file, - // and follows the conversion rules specified in - // design_docs/land/pay_for_parcel.txt. - F32 time_to_expire = 0.0f; - if(mID.isNull()) - { - mID.generate(); - mStatus = OS_LEASE_PENDING; - //mBuyerID = mOwnerID; - if(getIsGroupOwned()) - { - time_to_expire += GROUP_USEC_CONVERSION_TIMEOUT / SEC_TO_MICROSEC; - } - else - { - time_to_expire += DEFAULT_USEC_CONVERSION_TIMEOUT / SEC_TO_MICROSEC; - } - //mExpireAction = STEA_PUBLIC; - mRecordTransaction = TRUE; - } - - // this code block deals with giving an extension to pending - // parcels to the midday of 2004-01-19 if they were originally set - // for some time on 2004-01-12. - if((0 == mGraceExtension) - && (EXTEND_GRACE_IF_MORE_THAN_SEC < secs_until_revert)) - { - const S32 NEW_CONVERSION_DATE = 1074538800; // 2004-01-19T11:00:00 - time_t now = time(NULL); // now in epoch - secs_until_revert = (S32)(NEW_CONVERSION_DATE - now); - time_to_expire = (F32)secs_until_revert; - mGraceExtension = 1; - } - - // This code block adds yet another week to the deadline. :( - if(1 == mGraceExtension) - { - time_to_expire += SEVEN_DAYS_IN_USEC / SEC_TO_MICROSEC; - mGraceExtension = 2; - } - - if (time_to_expire > 0) - { - mSaleTimerExpires.setTimerExpirySec(time_to_expire); - mSaleTimerExpires.start(); - } - - // successful import - return TRUE; -} - - BOOL LLParcel::importAccessEntry(std::istream& input_stream, LLAccessEntry* entry) { skip_to_end_of_next_keyword("{", input_stream); @@ -1085,230 +565,6 @@ BOOL LLParcel::importAccessEntry(std::istream& input_stream, LLAccessEntry* entr return input_stream.good(); } -BOOL LLParcel::exportStream(std::ostream& output_stream) -{ - S32 setting; - std::string id_string; - - std::ios::fmtflags old_flags = output_stream.flags(); - output_stream.setf(std::ios::showpoint); - output_stream << "\t{\n"; - - mID.toString(id_string); - output_stream << "\t\t parcel_id " << id_string << "\n"; - output_stream << "\t\t status " << ownership_status_to_string(mStatus) << "\n"; - output_stream << "\t\t category " << category_to_string(mCategory) << "\n"; - - output_stream << "\t\t local_id " << mLocalID << "\n"; - - const char* name = (mName.empty() ? "" : mName.c_str() ); - output_stream << "\t\t name " << name << "\n"; - - const char* desc = (mDesc.empty() ? "" : mDesc.c_str() ); - output_stream << "\t\t desc " << desc << "\n"; - - const char* music_url = (mMusicURL.empty() ? "" : mMusicURL.c_str() ); - output_stream << "\t\t music_url " << music_url << "\n"; - - const char* media_url = (mMediaURL.empty() ? "" : mMediaURL.c_str() ); - output_stream << "\t\t media_url " << media_url << "\n"; - - const char* media_type = (mMediaType.empty() ? "" : mMediaType.c_str() ); - output_stream << "\t\t media_type " << media_type << "\n"; - - const char* media_desc = (mMediaDesc.empty() ? "" : mMediaDesc.c_str() ); - output_stream << "\t\t media_desc " << media_desc << "\n"; - - output_stream << "\t\t media_auto_scale " << (mMediaAutoScale ? 1 : 0) << "\n"; - output_stream << "\t\t media_loop " << (mMediaLoop ? 1 : 0) << "\n"; - output_stream << "\t\t obscure_media " << (mObscureMedia ? 1 : 0) << "\n"; - output_stream << "\t\t obscure_music " << (mObscureMusic ? 1 : 0) << "\n"; - - mMediaID.toString(id_string); - output_stream << "\t\t media_id " << id_string << "\n"; - - output_stream << "\t\t media_width " << mMediaWidth << "\n"; - output_stream << "\t\t media_height " << mMediaHeight << "\n"; - - mOwnerID.toString(id_string); - output_stream << "\t\t owner_id " << id_string << "\n"; - output_stream << "\t\t group_owned " << (mGroupOwned ? 1 : 0) << "\n"; - output_stream << "\t\t clean_other_time " << getCleanOtherTime() << "\n"; - - if(!mAuthBuyerID.isNull()) - { - mAuthBuyerID.toString(id_string); - output_stream << "\t\t auth_buyer_id " << id_string << "\n"; - } - if (!mSnapshotID.isNull()) - { - mSnapshotID.toString(id_string); - output_stream << "\t\t snapshot_id " << id_string << "\n"; - } - if (!mUserLocation.isExactlyZero()) - { - output_stream << "\t\t user_location " - << (F64)mUserLocation.mV[VX] - << " " << (F64)mUserLocation.mV[VY] - << " " << (F64)mUserLocation.mV[VZ] << "\n"; - output_stream << "\t\t user_look_at " - << (F64)mUserLookAt.mV[VX] - << " " << (F64)mUserLookAt.mV[VY] - << " " << (F64)mUserLookAt.mV[VZ] << "\n"; - } - output_stream << "\t\t landing_type " << mLandingType << "\n"; - //if(mJoinNeighbors) - //{ - // output_stream << "\t\t join_neighbors " << mJoinNeighbors << "\n"; - //} - if(mSaleTimerExpires.getStarted()) - { - S32 dt_sec = (S32) mSaleTimerExpires.getRemainingTimeF32()+60; // Add a minute to prevent race conditions - output_stream << "\t\t revert_sale " << dt_sec << "\n"; - //output_stream << "\t\t revert_action " << revert_action_to_string(mExpireAction) << "\n"; - output_stream << "\t\t extended_grace " << mGraceExtension << "\n"; - } - - if(0 != mAuctionID) - { - output_stream << "\t\t auction_id " << mAuctionID << "\n"; - } - - output_stream << "\t\t allow_modify " << getAllowModify() << "\n"; - output_stream << "\t\t allow_group_modify " << getAllowGroupModify() << "\n"; - output_stream << "\t\t allow_all_object_entry " << getAllowAllObjectEntry() << "\n"; - output_stream << "\t\t allow_group_object_entry " << getAllowGroupObjectEntry() << "\n"; - output_stream << "\t\t allow_terraform " << getAllowTerraform() << "\n"; - output_stream << "\t\t allow_deed_to_group " << getAllowDeedToGroup() << "\n"; - output_stream << "\t\t contribute_with_deed " << getContributeWithDeed() << "\n"; - output_stream << "\t\t allow_damage " << getAllowDamage() << "\n"; - output_stream << "\t\t claim_date " << (S32)mClaimDate << "\n"; - output_stream << "\t\t claim_price " << mClaimPricePerMeter << "\n"; - output_stream << "\t\t rent_price " << mRentPricePerMeter << "\n"; - output_stream << "\t\t discount_rate " << mDiscountRate << "\n"; - output_stream << "\t\t allow_fly " << (getAllowFly() ? 1 : 0) << "\n"; - output_stream << "\t\t allow_landmark " << (getAllowLandmark() ? 1 : 0) << "\n"; - output_stream << "\t\t sound_local " << (getSoundLocal() ? 1 : 0) << "\n"; - output_stream << "\t\t allow_scripts " << (getAllowOtherScripts() ? 1 : 0) << "\n"; - output_stream << "\t\t allow_group_scripts " << (getAllowGroupScripts() ? 1 : 0) << "\n"; - output_stream << "\t\t use_estate_voice_chan " << (getParcelFlagUseEstateVoiceChannel() ? 1 : 0) << "\n"; - - output_stream << "\t\t allow_voice_chat " << (getParcelFlagAllowVoice() ? 1 : 0) << "\n"; - output_stream << "\t\t use_estate_voice_chan " << (getParcelFlagUseEstateVoiceChannel() ? 1 : 0) << "\n"; - output_stream << "\t\t for_sale " << (getForSale() ? 1 : 0) << "\n"; - output_stream << "\t\t sell_w_objects " << (getSellWithObjects() ? 1 : 0) << "\n"; - output_stream << "\t\t draw_distance " << mDrawDistance << "\n"; - output_stream << "\t\t sale_price " << mSalePrice << "\n"; - - setting = (getParcelFlag(PF_USE_ACCESS_GROUP) ? 1 : 0); - output_stream << "\t\t use_access_group " << setting << "\n"; - - setting = (getParcelFlag(PF_USE_ACCESS_LIST) ? 1 : 0); - output_stream << "\t\t use_access_list " << setting << "\n"; - - setting = (getParcelFlag(PF_USE_BAN_LIST) ? 1 : 0); - output_stream << "\t\t use_ban_list " << setting << "\n"; - - mGroupID.toString(id_string); - output_stream << "\t\t group_id " << id_string << "\n"; - - //const char* group_name - // = (mGroupName.isEmpty() ? "" : mGroupName.c_str() ); - //output_stream << "\t\t group_name " << group_name << "\n"; - - setting = (getParcelFlag(PF_USE_PASS_LIST) ? 1 : 0); - output_stream << "\t\t use_pass_list " << setting << "\n"; - - output_stream << "\t\t pass_price " << mPassPrice << "\n"; - output_stream << "\t\t pass_hours " << mPassHours << "\n"; - - setting = (getParcelFlag(PF_SHOW_DIRECTORY) ? 1 : 0); - output_stream << "\t\t show_directory " << setting << "\n"; - - setting = (getParcelFlag(PF_ALLOW_PUBLISH) ? 1 : 0); - output_stream << "\t\t allow_publish " << setting << "\n"; - - setting = (getParcelFlag(PF_MATURE_PUBLISH) ? 1 : 0); - output_stream << "\t\t mature_publish " << setting << "\n"; - - setting = (getParcelFlag(PF_DENY_ANONYMOUS) ? 1 : 0); - output_stream << "\t\t deny_anonymous " << setting << "\n"; - -// setting = (getParcelFlag(PF_DENY_IDENTIFIED) ? 1 : 0); -// output_stream << "\t\t deny_identified " << setting << "\n"; - -// setting = (getParcelFlag(PF_DENY_TRANSACTED) ? 1 : 0); -// output_stream << "\t\t deny_transacted " << setting << "\n"; - - setting = (getParcelFlag(PF_DENY_AGEUNVERIFIED) ? 1 : 0); - output_stream << "\t\t deny_age_unverified " << setting << "\n"; - - setting = (getParcelFlag(PF_RESTRICT_PUSHOBJECT) ? 1 : 0); - output_stream << "\t\t restrict_pushobject " << setting << "\n"; - - output_stream << "\t\t aabb_min " - << mAABBMin.mV[VX] - << " " << mAABBMin.mV[VY] - << " " << mAABBMin.mV[VZ] << "\n"; - - if (!mAccessList.empty()) - { - output_stream << "\t\t access_list " << mAccessList.size() << "\n"; - access_map_const_iterator cit = mAccessList.begin(); - access_map_const_iterator end = mAccessList.end(); - - for ( ; cit != end; ++cit) - { - output_stream << "\t\t{\n"; - const LLAccessEntry& entry = (*cit).second; - entry.mID.toString(id_string); - output_stream << "\t\t\tid " << id_string << "\n"; - output_stream << "\t\t\ttime " << entry.mTime << "\n"; - output_stream << "\t\t\tflags " << entry.mFlags << "\n"; - output_stream << "\t\t}\n"; - } - } - - if (!mBanList.empty()) - { - output_stream << "\t\t ban_list " << mBanList.size() << "\n"; - access_map_const_iterator cit = mBanList.begin(); - access_map_const_iterator end = mBanList.end(); - - for ( ; cit != end; ++cit) - { - output_stream << "\t\t{\n"; - const LLAccessEntry& entry = (*cit).second; - entry.mID.toString(id_string); - output_stream << "\t\t\tid " << id_string << "\n"; - output_stream << "\t\t\ttime " << entry.mTime << "\n"; - output_stream << "\t\t\tflags " << entry.mFlags << "\n"; - output_stream << "\t\t}\n"; - } - } - - /*if (mRenterList.count() > 0) - { - output_stream << "\t\t renter_list " << mRenterList.count() << "\n"; - for (i = 0; i < mRenterList.count(); i++) - { - output_stream << "\t\t{\n"; - const LLAccessEntry& entry = mRenterList.get(i); - entry.mID.toString(id_string); - output_stream << "\t\t\tid " << id_string << "\n"; - output_stream << "\t\t\ttime " << entry.mTime << "\n"; - output_stream << "\t\t\tflags " << entry.mFlags << "\n"; - output_stream << "\t\t}\n"; - } - }*/ - - output_stream << "\t}\n"; - output_stream.flags(old_flags); - - return TRUE; -} - - // Assumes we are in a block "ParcelData" void LLParcel::packMessage(LLMessageSystem* msg) { |