- Site Map >
- Modding and Creation >
- Sims 3 Creation >
- Modding Discussion >
- Tuning mod with if/else statements??
- Site Map >
- Modding and Creation >
- Sims 3 Creation >
- Modding Discussion >
- Tuning mod with if/else statements??
Replies: 1 (Who?), Viewed: 1724 times.
#1
9th Apr 2019 at 12:34 AM
Posts: 13
Thanks: 101 in 2 Posts
Tuning mod with if/else statements??
Basically, I'm new to this. I want to make a mod that changes an objects "CanMoveUpDownWalls" flag to true, but only if it has the "OnWall" flag set to true already. i want to make any item placed on walls shiftable. I don't want to change the flag for every single wall object in s3pe, I simply want to change the flag for any object passing the test. I know a little about C#, and have followed the tutorial about setting up my visual studio/creating a basic scripting mod. Here's some pseudo-code showing what I want to do. Thank you for anyone that can help, I'm a coding newb.
Code:
if (this.object.flags.WallPlacementFlags(OnWall) == true){ this.object.WallPlacementFlags(CanMoveUpDownWalls) = true; };
Advertisement
#2
13th Apr 2019 at 1:33 PM
Posts: 3,860
Thanks: 8536 in 67 Posts
I think I'm a tad confused because it's good to know what the difference is between a "tuning mod" and a "Script mod"
So anything C# related basically counts as a script mod. Whereas an edit in an XML/DMTR/ITUN file is considered a "Tuning mod". It's good to know the difference before starting your modding journey since that can help a lot when searching the issues on google or what not
I think indeed making this a script mad might be a good idea, and you've got a good start too! Because indeed, if 'onWall' inside our OBJK file (This is a resource you can find with every object package with S3PE). one thing, unless you created a variable for that, might be that 'object ' doesn't do anything and thus might not recognise it the way you thought it would recognise it.
If you need any more help i'm here!
So anything C# related basically counts as a script mod. Whereas an edit in an XML/DMTR/ITUN file is considered a "Tuning mod". It's good to know the difference before starting your modding journey since that can help a lot when searching the issues on google or what not
I think indeed making this a script mad might be a good idea, and you've got a good start too! Because indeed, if 'onWall' inside our OBJK file (This is a resource you can find with every object package with S3PE). one thing, unless you created a variable for that, might be that 'object ' doesn't do anything and thus might not recognise it the way you thought it would recognise it.
If you need any more help i'm here!
Who Posted
|