More Awesome Than You!
Welcome, Guest. Please login or register.
2024 November 01, 05:35:37

Login with username, password and session length
Search:     Advanced search
540282 Posts in 18067 Topics by 6544 Members
Latest Member: Butternut
* Home Help Search Login Register
+  More Awesome Than You!
|-+  TS2: Burnination
| |-+  The Podium
| | |-+  Miscellaneous Moddling Questions
0 Members and 3 Chinese Bots are viewing this topic. « previous next »
Pages: [1] THANKS THIS IS GREAT Print
Author Topic: Miscellaneous Moddling Questions  (Read 3468 times)
rufio
Non-Standard
Uncouth Undesirable
****
Posts: 3030


More Nonstandard Than You


View Profile WWW
Miscellaneous Moddling Questions
« on: 2009 December 06, 23:18:56 »
THANKS THIS IS GREAT

1.  How would one go about creating an invisible, omnipresent object that does not need to be bought and cannot be sold, which would sit around for the purpose of storing a set of global, hood-wide settings?  Alternatively, is there a way to do this without creating an object?
2.  To what extent is it possible to have an object on a community lot maintain a persistent state between visits from sims who do not own the lot, without resetting every time someone new shows up?  Would the state have to be saved to an above-mentioned global object, or is there a neater way to do it?
3.  Business info: where is it stored?  How does one get to it?  I notice that BRY calls Lua scripts to find out whether a lot has a business - does all business info have to be accessed through Lua scripts?  Are there major differences for home businesses?  Is it possible to get a list of all the businesses in the current hood without going through every single lot and testing to see if it is a business?  Are there ways to attach additional info fields to a business and be reasonably certain that it won't be overwritten with garbage later?
Logged

I was thinking about these things and I am a feminist.

J. M. Pescado
Fat Obstreperous Jerk
El Presidente
*****
Posts: 26286



View Profile
Re: Miscellaneous Moddling Questions
« Reply #1 on: 2009 December 07, 01:13:09 »
THANKS THIS IS GREAT

1.  How would one go about creating an invisible, omnipresent object that does not need to be bought and cannot be sold, which would sit around for the purpose of storing a set of global, hood-wide settings?  Alternatively, is there a way to do this without creating an object?
Invisible omnipresent objects are common, as "controllers", and can be created by setting the "Global Object" bit in the OBJD, but they do not retain hood-wide settings, and each instance of an object is seperate and independent of those on other lots. If you wish to retain a global setting, you will need to utilize global neighborhood tokens, which don't necessarily need an invisible object. An example of global settings is seen in the Autonomy Controller, which retains the list of global proscriptions across all lots.

2.  To what extent is it possible to have an object on a community lot maintain a persistent state between visits from sims who do not own the lot, without resetting every time someone new shows up?  Would the state have to be saved to an above-mentioned global object, or is there a neater way to do it?
There isn't. This is neither feasible nor advisable.

3.  Business info: where is it stored?  How does one get to it?  I notice that BRY calls Lua scripts to find out whether a lot has a business - does all business info have to be accessed through Lua scripts?
Yes.

Are there major differences for home businesses?  Is it possible to get a list of all the businesses in the current hood without going through every single lot and testing to see if it is a business?  Are there ways to attach additional info fields to a business and be reasonably certain that it won't be overwritten with garbage later?
No.
Logged

Grant me the serenity to accept the things I cannot change, the courage to change the things I cannot accept, and the wisdom to hide the bodies of those I had to kill because they pissed me off.
rufio
Non-Standard
Uncouth Undesirable
****
Posts: 3030


More Nonstandard Than You


View Profile WWW
Re: Miscellaneous Moddling Questions
« Reply #2 on: 2009 December 07, 01:22:44 »
THANKS THIS IS GREAT

Thanks.

If you wish to retain a global setting, you will need to utilize global neighborhood tokens, which don't necessarily need an invisible object. An example of global settings is seen in the Autonomy Controller, which retains the list of global proscriptions across all lots.

Ah, ok.  I looked at autonomycontrol briefly, but I was looking for global objects, not tokens.  How do neighborhood tokens work?  Do they carry across play sessions?  Are there problems if a mod that creates and manages such tokens is installed and then later deleted?

As for the global objects, I take it they can still be used to store persistent lot-wide settings, provided the lot isn't a community lot?
Logged

I was thinking about these things and I am a feminist.

J. M. Pescado
Fat Obstreperous Jerk
El Presidente
*****
Posts: 26286



View Profile
Re: Miscellaneous Moddling Questions
« Reply #3 on: 2009 December 07, 01:38:26 »
THANKS THIS IS GREAT

Ah, ok.  I looked at autonomycontrol briefly, but I was looking for global objects, not tokens.  How do neighborhood tokens work?  Do they carry across play sessions?  Are there problems if a mod that creates and manages such tokens is installed and then later deleted?
Yes, and no, deleting them will just cause the loss of all tokens. You can store instance-specific data on lot-controllers, but don't expect them to stick around. For that, you will want lot-tokens, similar to AC's "proscribe for lot".
Logged

Grant me the serenity to accept the things I cannot change, the courage to change the things I cannot accept, and the wisdom to hide the bodies of those I had to kill because they pissed me off.
rufio
Non-Standard
Uncouth Undesirable
****
Posts: 3030


More Nonstandard Than You


View Profile WWW
Re: Miscellaneous Moddling Questions
« Reply #4 on: 2009 December 07, 02:05:45 »
THANKS THIS IS GREAT

Ok - I'll go look at AC some more and see if I can figure out how it works.

ETA:  Ok, I understand how the tokens work.  Are there any special flags that need to be set to define an object as a token, or can any object be used as a token?  In AC specifically, what's the function of the Helper objects - are they needed for token manipulation in general, or just for your implementation of AC?  Why are they defined as "SimType"s (type value of 0x7)?
« Last Edit: 2009 December 09, 20:43:34 by rufio » Logged

I was thinking about these things and I am a feminist.

Pages: [1] Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.115 seconds with 20 queries.