Search found 289 matches

by PFQNiet
Sun Nov 12, 2023 3:34 am
Forum: Ideas and Requests For Mods
Topic: [Mod Request] GUI Theme Changer
Replies: 2
Views: 339

Re: [Mod Request] GUI Theme Changer

The person wanting to use a different theme might be able to replace the graphics files in their installation, assuming the new theme exactly matches the placements of everything in the sprite sheet. A bit drastic, perhaps, but GUI styles are prototypes just like most anything else defined in the ga...
by PFQNiet
Sun Nov 12, 2023 3:32 am
Forum: Modding help
Topic: Get hovered item in Inventory
Replies: 1
Views: 247

Re: Get hovered item in Inventory

The closest thing I can think of is to have the custom input provide the hovered prototype, and try to infer what to do from that. This would, however, not allow you to select a specific item stack, the best you could do with it is "take one item matching the prototype that was hovered", b...
by PFQNiet
Sun Nov 12, 2023 3:30 am
Forum: Modding help
Topic: Items crafted by an assembly machine
Replies: 1
Views: 278

Re: Items crafted by an assembly machine

There is no event for machines completing a craft. Such an event would happen thousands of times per second or even more in megabases. Player handcrafting, by contrast, is relatively rare.
by PFQNiet
Fri Nov 03, 2023 2:19 pm
Forum: News
Topic: Friday Facts #383 - Super force building
Replies: 172
Views: 27515

Re: Friday Facts #383 - Super force building

Awesome news! How flexible is the auto-landfill part of the super force build mode with regard to modding? Is "landfill" going to be hard-coded similar to the "copper-wire", "red-wire" and "green-wire" items, or is it using some property of the tile prototype ...
by PFQNiet
Thu Sep 14, 2023 6:52 pm
Forum: Modding interface requests
Topic: Third option for use_exact_mode: toggle
Replies: 0
Views: 240

Third option for use_exact_mode: toggle

I was halfway through writing a suggestion for the game itself when I remembered that half of the idea is already implemented for mods. I would like to suggest an option for chests to have a checkbox allowing the player to toggle exact mode on a given entity. I would especially love it if this could...
by PFQNiet
Fri May 12, 2023 2:08 am
Forum: Ideas and Requests For Mods
Topic: [Mod Idea] - Personal Auto Crafting mod
Replies: 5
Views: 1012

Re: [Mod Idea] - Personal Auto Crafting mod

I should note that IR3 intentionally makes handcrafting painful to strongly encourage automation. In my personal experience of it, you should focus on automating intermediates so that you're only hand crafting buildings, then work on automating the buildings. I feel that this is a very deliberate de...
by PFQNiet
Mon May 01, 2023 1:08 am
Forum: Implemented for 2.0
Topic: on_gui_element_destroyed
Replies: 7
Views: 1103

Re: on_gui_element_destroyed

Likely should require registration, similar to entities being destroyed, otherwise a lot of irrelevant events could happen.
by PFQNiet
Sat Apr 29, 2023 12:55 am
Forum: Modding help
Topic: Healing Over Time
Replies: 15
Views: 2106

Re: Healing Over Time

I don't remember it exactly myself, but the projectile creates a "poison-cloud" entity, which I believe is a "smoke with triggers" I think?
by PFQNiet
Fri Apr 28, 2023 11:00 pm
Forum: Modding help
Topic: Modify the "tutorial" player?
Replies: 2
Views: 481

Re: Modify the "tutorial" player?

You should be able to loop through tutorials in the prototype tree, and prefix their code with a line to set the character's reach there.
by PFQNiet
Fri Apr 28, 2023 10:57 pm
Forum: Modding help
Topic: Healing Over Time
Replies: 15
Views: 2106

Re: Healing Over Time

Look at how poison clouds do damage over time, and give that negative damage to make a heal-over-time area.
by PFQNiet
Fri Feb 10, 2023 3:07 pm
Forum: Modding help
Topic: How do I use request_path?
Replies: 4
Views: 930

Re: How do I use request_path?

I think character.prototype.bounding_box should work, right? But aside from that your code is prone to issues in a multiplayer setting, since you've hardcoded "player 1" in there. You should instead do game.players[event.player_index], and you should also be checking that objects exist and...
by PFQNiet
Wed Feb 08, 2023 3:31 am
Forum: Modding interface requests
Topic: Adding a way for "dynamic" camera
Replies: 2
Views: 632

Re: Adding a way for "dynamic" camera

This definitely feels like it would be better as a suggestion on the base game. As it involves the cursor position (which isn't part of the game state) and the rendered camera (which just renders the game state) it would be very difficult to get it in a mod since mods are all about working with the ...
by PFQNiet
Thu Jan 26, 2023 10:54 am
Forum: Modding discussion
Topic: spider-vehicle unselectable if it is too high
Replies: 5
Views: 1154

Re: spider-vehicle unselectable if it is too high

Forgive me if this is a daft question, but why is the search for selection boxes implemented using collision boxes? I'm guessing code reuse, since collision boxes are used in so many more places?
by PFQNiet
Mon Dec 05, 2022 8:02 am
Forum: Won't implement
Topic: [lua][feature] User defined data attached to lua entity
Replies: 6
Views: 1732

Re: [lua][feature] User defined data attached to lua entity

I'm fairly sure this would actually be worse for performance, since you'd be querying the game engine for the user data rather than using your local Lua environment for it. Interfacing between script and game are the biggest bottleneck for mod performance, and such round trips should be minimised. B...
by PFQNiet
Wed Nov 16, 2022 7:02 pm
Forum: Modding help
Topic: sprite-button with semi-transparent sprite
Replies: 0
Views: 425

sprite-button with semi-transparent sprite

I'm creating some custom GUI for a part of my mod, and I would like to be able to replicate the visual effect of a filtered inventory slot. To this end I created a `sprite-button` with `style="inventory_slot"`, but obviously just setting the `sprite` to the desired item results in the spri...
by PFQNiet
Thu Nov 10, 2022 11:57 pm
Forum: Modding help
Topic: Unremovable armour
Replies: 1
Views: 566

Unremovable armour

As part of my mod I want to create a piece of armour that cannot be removed - this is to allow having an equipment grid that you can place your actual equipment into. To that end, I can give the player this armour item when they spawn/respawn, and replace it with its equipped items in their corpse o...
by PFQNiet
Mon Nov 07, 2022 11:00 am
Forum: Modding interface requests
Topic: gun_inventory_size for characters
Replies: 0
Views: 417

gun_inventory_size for characters

Unless I'm missing it, the gun inventory size appears to be hard-coded to 3. I think it would be beneficial to have that moddable. Even better if it could be expanded via technology. This would allow my mod to have a progression where you start with only one slot for weapons, and can unlock more as ...
by PFQNiet
Mon Nov 07, 2022 10:57 am
Forum: Documentation Improvement Requests
Topic: API Docs Visual Refresh
Replies: 5
Views: 1407

Re: API Docs Visual Refresh

I'm going to second InappropriatePenguin's comment about link colours. It was the very first thing I noticed, and after checking I see it has a contrast ratio of 4.1 with the grey background. Given the relatively thin font weight, this makes it a big fail for accessibility/legibility. It doesn't jus...
by PFQNiet
Fri Oct 28, 2022 6:46 am
Forum: Modding help
Topic: Mining In a Line
Replies: 6
Views: 865

Re: Mining In a Line

Unfortunately not, the mining radius is always a square.

Go to advanced search