Hi there! You are currently browsing as a guest. Why not create an account? Then you get less ads, can thank creators, post feedback, keep a list of your favourites, and more!
Quick Reply
Search this Thread
Mad Poster
Original Poster
#1 Old 3rd Aug 2014 at 2:46 AM Last edited by murfee : 3rd Aug 2014 at 7:25 PM.
Help making Script mod, please - confused on steps for making No Alien Eyes code
I am freaking desperate; I've looked all over and I can't find a single mod for aliens, to get rid of their stupid eyes and stupid voices. Apparently it would require a script mod, and that it's something custom for visual overrides, like the the one Virtual Artisan made for vampires to remove the eye/skin glow.

I have never made a script mod before, and all the stuff here (http://modthesims.info/wiki.php?tit..._GeneralModding) is in ancient Sumerian to me--what the eff.

Closest I've got is the thread here (http://modthesims.info/showthread.p...highlight=alien) where apparently it IS possible to remove the eyes:

Quote: Originally posted by Sims MX
The following code removes the alien eyes!
Code: World.ObjectRemoveVisualOverride(target.ObjectId, eVisualOverrideTypes.Alien)


But I don't know what the heck to do with this thing! And I don't see anything about how to remove the voices, either.

How would I do all this, please:
- making a script mod to put that code thingy in, in order to remove those ghastly alien eyes
- making a similar code to remove alien voices
- Where would I find a code pertaining to the voices, or even know what to fiddle with and what to leave alone?

Also, I would like to add flavors to it, just like Virtual Artisan did, where I could have one mod just for eyes, one mod just for voices, and one mod for both (which I would use for the rest of my simming experience, I SWTG! )
Advertisement
Mad Poster
Original Poster
#2 Old 3rd Aug 2014 at 6:31 PM Last edited by murfee : 3rd Aug 2014 at 7:12 PM.
Putting all my asinine questions I'll probably solve on my own here:

- In Step 4 here (http://modthesims.info/wiki.php?tit..._Studio_project) it says to add the References you extracted from S3PE, and it says you want ScriptCore, SimIFace, Sims3GameplayObjects, Sims3GameplaySystems, Sims3StoreObjects, Sims3Metadata, System, System.Xml, and UI. But in the pictures it shows another one called Automation -- what's that from? *scratches head* (I just forged on ahead without trying to add any Automation thingy like was shown in the tut pictures.)

- In this step: The Actual Script / The First Steps from the tut here (http://modthesims.info/wiki.php?tit...ripting_Modding) I am actually STUCK. What do I do next, to incorporate Code: World.ObjectRemoveVisualOverride(target.ObjectId, eVisualOverrideTypes.Alien) as the Alien Eye script I want to create; where would it go--or do I have to do something else first?

- What is that NET Reflector thing for; when should I start using it; I don't understand what the tutorial's referring to -- "Start Reflector and load the core libraries with it". I just opened the thing and it started loading crap on it's own.

GAWD so confusion much!
Screenshots
Mad Poster
Original Poster
#3 Old 6th Aug 2014 at 8:50 PM
I did some more digging, and the only other thread I found is this one: http://www.den.simlogical.com/denfo...g13669#msg13669

*SIGH* This doesn't bode well.
Ms. Byte (Deceased)
#4 Old 7th Aug 2014 at 9:31 AM
I have no idea what Automation.dll is either.

To incorporate your code, try using the first part of this tutorial: http://www.modthesims.info/showthread.php?t=491875

You'll need the instantiation stuff and the OnWorldLoadFinished handler. Instead of adding interactions you'd put your code in the loop that iterates through all the sims.

foreach (Sim sim in Sims3.Gameplay.Queries.GetObjects<Sim>())
{
if (sim != null)
{
<your code>
}
}

You won't need the AddInteractions class or the interaction definition (ShowNotification).

Reflector starts with a set of default dlls. Just remove them and add the Sims ones. Also, if you don't want to pay for Reflector you can consider ILSpy. What it does is disassemble the game dlls so you can see a close approximation of the game source code and figure out how things are done, copy code into your script, etc.

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Mad Poster
Original Poster
#5 Old 7th Aug 2014 at 5:45 PM
Omg omg, thank you!

Okay, look at the before and after pictures and feel free to laugh at my pitiful attempt at coding.

Did I totally mess up all the way around? :P

I was confused about the brackets and spaces -- I was copy/pasting off the tutorial text and it kept adding extra lines in, so I took the liberty of removing them. I've never messed with this stuff before, so please pardon my excessive incompetency. My brain hurts. Need Pepsi.
Screenshots
Ms. Byte (Deceased)
#6 Old 7th Aug 2014 at 11:54 PM
Spacing doesn't matter. Brackets have to be in pairs. They mark the beginning and end of something - the begin and end of a class definition, a method definition, the code to execute in an if statement or loop, or whatever.

You've mixed some code together and included stuff that doesn't belong, at least right now. For now you can remove everything after your visual override removal line of code, and just close all your brackets. (I think five close brackets after that line will do it.)

To fix the errors in your line of code:

All lines of code must end with a semicolon - add one at the end.

"target" is not defined. Try replacing it with "sim" - which is the current sim you're processing in your 'foreach' loop, which iterates over each sim returned by the query.

Don't forget the instantiation XML.

That should give you a very basic mod. Later you should add testing whether the sim is alien before you remove the effect, and a handler for sim instantiation so you remove the effect from new created aliens, and some error handling. But let's start with the bare bones.

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Mad Poster
Original Poster
#7 Old 8th Aug 2014 at 3:11 AM
I was cringing the entire time I read that, going "Murf, you idiot!"

I really appreciate the help! Going back into my evil lair! Wish me luck!
Back to top