Jump to content

Custom Block: Bicycle - Advice?


zztong

Recommended Posts

I'm making a Bike Shop custom POI. I'd like to have harvestable bicycles in the shop. That is, blocks that can be scrapped, rather than ridden away. (See screenshot, below.)

 

I can make a custom block, place it, collide with it, all groovy... except I cannot hit it with a pick, nor harvest it with a wrench, nor interact with its inventory. I assume this is a problem with my XML, but so far have been unable to isolate it. Perhaps you can pick apart my attempt and identify the issue?

 

        <block name="zztongBicycleFloat">
            <property name="CreativeMode" value="Dev"/>
            <property name="CustomIcon" value="vehicleBicyclePlaceable"/>
            <property name="CustomIconTint" value="6BB6E8"/>
            <property name="Material" value="Mmetal"/>
            <property name="Class" value="Loot"/>
            <property name="LootList" value="playerStorage"/>
            <property name="Shape" value="ModelEntity"/>
            <property name="Path" value="solid"/>
            <property name="Model" value="#Entities/Vehicles?bicycle_Prefab.prefab"/>
            <!-- <property name="Collide" value="movement,melee,rocket"/> -->
            <property name="MaxDamage" value="250"/>
            <property name="DisplayType" value="blockMulti"/>
            <property name="MultiBlockDim" value="1,2,2"/>
            <property name="IsTerrainDecoration" value="true"/>
            <drop event="Harvest" name="terrStone" count="0" tool_category="Disassemble"/>
            <drop event="Harvest" name="resourceForgedIron" count="1" prob="0.1" tag="salvageHarvest"/>
            <drop event="Harvest" name="resourceMechanicalParts" count="1" prob="0.2" tag="salvageHarvest"/>
            <drop event="Harvest" name="resourceLeather" count="1" prob="0.2" tag="salvageHarvest"/>
            <drop event="Harvest" name="resourceSpring" count="1" prob="0.5" tag="salvageHarvest"/>
            <drop event="Harvest" name="resourceScrapIron" count="10,20" tag="allHarvest"/>
            <drop event="Destroy" count="0"/>
            <drop event="Fall" name="scrapMetalPile" count="1" prob="0.75" stick_chance="1"/>
            <property name="FilterTags" value="MC_outdoor,SC_decor"/>
            <property name="Group" value="Decor/Miscellaneous"/>
            <property name="DescriptionKey" value="furnitureGroupDesc"/>
            <property name="SortOrder1" value="fh38"/>
        </block>

        <block name="zztongBicycleGround">
            <property name="Extends" value="zztongBicycleFloat"/>
            <property name="MultiBlockDim" value="1,1,2"/>
            <property name="GndAlign" value="1"/>
            <property name="ModelOffset" value="0,0,0.5"/>
        </block>

 

Screenshot:

20220903140706_1.thumb.jpg.87764b3aef3971a432c91ce911b66d8c.jpg

Link to comment
Share on other sites

For a block to be interacted with in anyway besides collision, you need a specific tag in unity T_Mesh_B... A vehicle however uses other tags E_vehicle or something. So simply using the vanilla one will not work. You'll have to import into unity and change the tag (on the child objects with the hitboxes) in order to be used as a block.

Link to comment
Share on other sites

39 minutes ago, Telric said:

For a block to be interacted with in anyway besides collision, you need a specific tag in unity T_Mesh_B... A vehicle however uses other tags E_vehicle or something. So simply using the vanilla one will not work. You'll have to import into unity and change the tag (on the child objects with the hitboxes) in order to be used as a block.

 

Oh, thanks so much for the reply. I was hoping for just an XML change as I'm not ready to cross the threshold into making meshes and objects.

 

I guess I won't have any bikes in my bikeshop. Darn looters.

Link to comment
Share on other sites

13 hours ago, zztong said:

 

Oh, thanks so much for the reply. I was hoping for just an XML change as I'm not ready to cross the threshold into making meshes and objects.

 

I guess I won't have any bikes in my bikeshop. Darn looters.

It can be a big jump and very daunting, but absolutely worth it. More creativity, more flexibility. Definitely worth the hassle of learning. :)

Link to comment
Share on other sites

10 hours ago, Telric said:

It can be a big jump and very daunting, but absolutely worth it. More creativity, more flexibility. Definitely worth the hassle of learning. :)

 

Heh. I keep editing this post. It is a mishmash of thoughts.

 

Yes, but I'm not sure of the audience. I feel like there's a gulf between XML mods that seem to largely work server-side only, and mods that must have client-side deployment because they have I guess what I'll call "advanced assets" like sounds, meshes, etc. I'm watching to see how the game evolves with modlets, Steam integration, and so forth. I don't have a feel for how well modlets integrate with each other, how we find out about collisions in XML and code, and if modlet features will learn to detect dependencies between modlets.


I'd be tempted to implement a modlet full of new assets - a library of assets - separate from a POI modlet and then have a dependency. I'm also not a graphic artist, 2D or 3D. I don't care for the quality of my work in that area. I suspect I'd not follow through.

 

I wish I had some stats about player preferences as well as things like how much server play there is and how much is solo.

 

My own behavior has been to avoid things that require me to turn EAC off. I'm not really sure why. Well, partly because I build to be vanilla compatible and I don't want to have to worry about juggling around configs to switch between play and building.

 

In short, I've been moving cautiously into new areas as my time permits.

Edited by zztong (see edit history)
Link to comment
Share on other sites

3 hours ago, zztong said:

 

Heh. I keep editing this post. It is a mishmash of thoughts.

 

Yes, but I'm not sure of the audience. I feel like there's a gulf between XML mods that seem to largely work server-side only, and mods that must have client-side deployment because they have I guess what I'll call "advanced assets" like sounds, meshes, etc. I'm watching to see how the game evolves with modlets, Steam integration, and so forth. I don't have a feel for how well modlets integrate with each other, how we find out about collisions in XML and code, and if modlet features will learn to detect dependencies between modlets.


I'd be tempted to implement a modlet full of new assets - a library of assets - separate from a POI modlet and then have a dependency. I'm also not a graphic artist, 2D or 3D. I don't care for the quality of my work in that area. I suspect I'd not follow through.

 

I wish I had some stats about player preferences as well as things like how much server play there is and how much is solo.

 

My own behavior has been to avoid things that require me to turn EAC off. I'm not really sure why. Well, partly because I build to be vanilla compatible and I don't want to have to worry about juggling around configs to switch between play and building.

 

In short, I've been moving cautiously into new areas as my time permits.

 

I absolutely feel ya'...   Been walking that line myself....    I still don't know which side of the rope I'm going to fall off of....   😜

 

Edited by MichaelL. (see edit history)
Link to comment
Share on other sites

9 hours ago, MichaelL. said:

 

I absolutely feel ya'...   Been walking that line myself....    I still don't know which side of the rope I'm going to fall off of....   😜

 

 

Part of what I said is laziness, well and a bit of a busy schedule at the moment. I could at least figure out how those things work and then I could make better decisions about what to use.

 

My note about my inability to make quality assets rings true, however. I'd be constantly tempted to grab stuff off of various websites and then end up in some kind of DMCA / Copyright situation. It would be easier for me to get into code changes.

 

My notes about the future of modlets and Steam I think are apropos. I think that has some potential to change the landscape of modding.

 

I don't know if I'm being a stick in the mud about EAC, or not.

 

I really would like stats about player habits and player preferences.

Edited by zztong (see edit history)
Link to comment
Share on other sites

I follow one rule when modding... Mod for myself. If others like it, great. If not, I enjoyed the experience and learned something new. Your mods aren't going to be liked by everyone, so don't go in expecting it. If you mod for yourself as a learning experience or even just something you personally want, you're going to be happier than trying to please people on a forum.

As for me, I don't want to work on mods that require code because I don't know code. So if something breaks, I'm at the mercy of someone else to fix it for me. lol

Servers are really only using server friendly mods right now for the ease of getting players in. Not everyone knows how or wants to install mods on their own computer, so to get more people in, server friendly mods will help greatly. But, the caveat is you're limited.. You can still do some good stuff, but it would require some imagination from the players. Look at valmar's old school mods. Chicken coops were just chicken nests that grew into lootable forms. It all worked fine, just needed the imagination from the player that a chicken was there laying an egg... lol.

Link to comment
Share on other sites

Kind of a dumb question, I suppose, but are POIs like the CP server-side only? I've been  forcing friends on our dedicated server to install them (and back when that involved the Data folder, it was an undertaking for some of them).

 

POI creators have shown incredible imagination in using the limited selection of items and blocks to realize a lot of other things, and with all the new shapes added in A20 I'm sure that'll be taken to even higher levels. But yeah, I really like the idea of going into a bike shop and seeing actual bikes instead of wooden crates. In fact, I added bikes of various colors and sizes (and states of disassembly) to the random car wreck generation on our map after growing tired of "Planet of the Sedans" and wanting a crack at some bike parts in early game. The nice thing about extracting the bike model and fooling around with it in Unity is you can scale it down for a child-sized ride or turn off parts like the seat, wheels, chain, etc.

 

I like the idea of having a set of additional "props" that could be added through the CP, as I imagine there would be a lot of overlap with the sort of things people would want to add, and there's no sense re-inventing the wheel (or the bicycle) for every POI-creator's buildings. I adapted a bunch of video game and pinball machines for use in game, and Deverezieaux made an awesome POI to showcase them, but I don't know how many people have bothered to try them. It doesn't help that it's a big, honking 150 Mb download, and I envision most finishing touch props would be way smaller than that.

 

Sorry if I'm rambling, but I see a little Justice League of Modders in here, and I just had to weigh in with my own experiences.

Link to comment
Share on other sites

1 hour ago, Cranberry Monster said:

Kind of a dumb question, I suppose, but are POIs like the CP server-side only? I've been  forcing friends on our dedicated server to install them (and back when that involved the Data folder, it was an undertaking for some of them).

 

POI creators have shown incredible imagination in using the limited selection of items and blocks to realize a lot of other things, and with all the new shapes added in A20 I'm sure that'll be taken to even higher levels. But yeah, I really like the idea of going into a bike shop and seeing actual bikes instead of wooden crates. In fact, I added bikes of various colors and sizes (and states of disassembly) to the random car wreck generation on our map after growing tired of "Planet of the Sedans" and wanting a crack at some bike parts in early game. The nice thing about extracting the bike model and fooling around with it in Unity is you can scale it down for a child-sized ride or turn off parts like the seat, wheels, chain, etc.

 

I like the idea of having a set of additional "props" that could be added through the CP, as I imagine there would be a lot of overlap with the sort of things people would want to add, and there's no sense re-inventing the wheel (or the bicycle) for every POI-creator's buildings. I adapted a bunch of video game and pinball machines for use in game, and Deverezieaux made an awesome POI to showcase them, but I don't know how many people have bothered to try them. It doesn't help that it's a big, honking 150 Mb download, and I envision most finishing touch props would be way smaller than that.

 

Sorry if I'm rambling, but I see a little Justice League of Modders in here, and I just had to weigh in with my own experiences.

Unfort atm custom pois are server and client side. 

Tho atm I am assisting guppy in trying to track all bugs relating to having custom pois server side only and hoping to get custom pois server side only. 
if this can happen will be great for everyone, server owners and players alike. 

but as for the mods zz is talking bout xml stuff is fairly easy to adapt. The cp is pure vanilla atm as for many reasons every new alphs custom blocks have to be updated so we would have to wait. then the prefabber/s would have to update their pois and then eventually the cp would update so after gold modded pois will be allowed. 

Link to comment
Share on other sites

21 hours ago, Cranberry Monster said:

I like the idea of having a set of additional "props" that could be added through the CP, as I imagine there would be a lot of overlap with the sort of things people would want to add, and there's no sense re-inventing the wheel (or the bicycle) for every POI-creator's buildings. I adapted a bunch of video game and pinball machines for use in game, and Deverezieaux made an awesome POI to showcase them, but I don't know how many people have bothered to try them.

 

I looked at your video games and pinball machines and have longed for them. I'd love to mix them into POIs.

 

Mixing them in creates a dependency. I'd rather our modlets be loosely integrated, such that we could update our modlets independently. I'd like to see something like a nice in-game modlet feature could detect the dependency, download it if necessary, and make sure things load in the correct order. Otherwise, my only option is to add all those details to my installation instructions and then field all the support requests when folks don't read/understand/follow those instructions.

 

The CP will face the same issues being "downstream" of both your modlet and mine.

 

BTW, I hold up Rimworld as a game with an effective Mod distribution and installation system integrated with Steam.

Edited by zztong (see edit history)
Link to comment
Share on other sites

20 hours ago, stallionsden said:

Tho atm I am assisting guppy in trying to track all bugs relating to having custom pois server side only and hoping to get custom pois server side only. 

 

Hurray!

 

20 hours ago, stallionsden said:

but as for the mods zz is talking bout xml stuff is fairly easy to adapt. The cp is pure vanilla atm as for many reasons every new alphs custom blocks have to be updated so we would have to wait.

 

Yes. Well, there's a bit of a give and take going on. There was a bit when my modlet had decorations but the CP didn't. It was wise for the CP to watch how that panned out, think it over, etc. The same is kind of happening with XML-only custom blocks. When I try things that aren't currently in the CP I run some risk of the CP not accepting one of my POIs. I get that. It makes sense.

 

The CP has complexities related to accepting POIs from anyone and everyone. It makes it really hard for the CP to create some kind of standard package of extra stuff, like Pinball Machines. Every contribution could introduce a new dependency. If those dependencies collide, then what does the CP do? Excluding a dependency to resolve the issue basically means throwing POIs with that dependency out of the CP.

 

The future of the Infinity installer perhaps offers options in this realm. Unknown is how that might integrate with wherever TFP is going with modlets. I'm on the edge of my seat.

Link to comment
Share on other sites

3 hours ago, zztong said:

 

Hurray!

 

 

Yes. Well, there's a bit of a give and take going on. There was a bit when my modlet had decorations but the CP didn't. It was wise for the CP to watch how that panned out, think it over, etc. The same is kind of happening with XML-only custom blocks. When I try things that aren't currently in the CP I run some risk of the CP not accepting one of my POIs. I get that. It makes sense.

 

The CP has complexities related to accepting POIs from anyone and everyone. It makes it really hard for the CP to create some kind of standard package of extra stuff, like Pinball Machines. Every contribution could introduce a new dependency. If those dependencies collide, then what does the CP do? Excluding a dependency to resolve the issue basically means throwing POIs with that dependency out of the CP.

 

The future of the Infinity installer perhaps offers options in this realm. Unknown is how that might integrate with wherever TFP is going with modlets. I'm on the edge of my seat.

In the end we remove the modded stuff as have done in the past. 

 

But I got the modded xml stuff sorted and xml stuff is easier to maintain then custo blocks themselves til gold anyway

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...