Search found 11 matches

by Leoncio
Sat Apr 29, 2023 2:46 pm
Forum: Modding help
Topic: Can you make an entity despawn after a while?
Replies: 9
Views: 1762

Re: Can you make an entity despawn after a while?


Then add this mod , reload the game, and type "/gvv" in the chat window to open the GUI of gvv. You can then inspect the contents of your global table. Also, you should add "log()" commands to your code so you can follow what happens and see whether the part that should destroy the entities is ...
by Leoncio
Sat Apr 29, 2023 11:53 am
Forum: Modding help
Topic: Can you make an entity despawn after a while?
Replies: 9
Views: 1762

Re: Can you make an entity despawn after a while?

Thank you!

I will load now, however, the entity wont despawn. Should the entire code be in control.lua? Should I do something else to the entity to make it interact with the event script?
by Leoncio
Sat Apr 29, 2023 10:07 am
Forum: Modding help
Topic: Can you make an entity despawn after a while?
Replies: 9
Views: 1762

Re: Can you make an entity despawn after a while?

Thanks for the reply!

I've been trying to implement the script as good as I can, but I still getting error messages that I don't understand what it means.

the code that I have been running in the control.lua is

local function register_entity(event)
local tick = event.tick
local entity = event ...
by Leoncio
Tue Apr 25, 2023 11:48 pm
Forum: Modding help
Topic: Can you make an entity despawn after a while?
Replies: 9
Views: 1762

Re: Can you make an entity despawn after a while?

Thanks for the reply and help! :D
I am so lost in what the piece of code that you posted means, which makes me unable to implement my entity to it, this is my entity that I want to give a despawn timer, how would the script code look like with this in mind?


data:extend({
{
type = "simple-entity ...
by Leoncio
Mon Apr 24, 2023 5:34 pm
Forum: Modding help
Topic: Can you make an entity despawn after a while?
Replies: 9
Views: 1762

Can you make an entity despawn after a while?

Hello,

I was wondering if there is way to make a "simple-entity" have a duration/despawn -timer? So far I haven't been able to find a way to make them disappear after a couple of seconds. The only things that I have been able to find, are ghosts, character-corpse, smoke-with-trigger, but none of ...
by Leoncio
Thu Apr 06, 2023 4:27 pm
Forum: Modding help
Topic: My settings gets overwritten by another mods
Replies: 6
Views: 1314

Re: My settings gets overwritten by another mods

That did the trick! Tried so many different ways to get the "if settings.startup["vanilla-flashlight"].value" to work, thank you again for the help I would have never come up with the solution by myself! :D <3
by Leoncio
Thu Apr 06, 2023 1:36 pm
Forum: Modding help
Topic: My settings gets overwritten by another mods
Replies: 6
Views: 1314

Re: My settings gets overwritten by another mods

Just tested the code again, without the Gear Girl Character mod, and it the game crashed saying that it couldn't find ["GearGirl-skin"].
Guess I still need some help figuring out how I can implement the settings...
by Leoncio
Thu Apr 06, 2023 11:30 am
Forum: Modding help
Topic: My settings gets overwritten by another mods
Replies: 6
Views: 1314

Re: My settings gets overwritten by another mods

It worked when I put GearGirl as a dependency and then I added the code to the data.lua:
if settings.startup["vanilla-flashlight"].value then
data.raw["character"]["character"]["light"] = off
else
data.raw.character["GearGirl-skin"].light = off
end

Edit:
Thank you for the help! :D
by Leoncio
Thu Apr 06, 2023 12:36 am
Forum: Modding help
Topic: My settings gets overwritten by another mods
Replies: 6
Views: 1314

My settings gets overwritten by another mods

Hello,

I was wondering if someone could help me with trying to find out if its possible for me, to not have one of my settings get overwritten by another mod?

The script that I want to "overwrite" ( don't know the proper terminology) another mods settings is:

My settings.lua code:
data:extend ...
by Leoncio
Tue Apr 04, 2023 5:08 pm
Forum: Modding help
Topic: Make stickers not to have any effect on Player character?
Replies: 0
Views: 466

Make stickers not to have any effect on Player character?

Hello,

I was wondering if the sticker prototype can be made to not affect the player, but other objects in the game world?

Such as, making a poison sticker that only affects the enemies and not the player? Have I understood the sticker prototype right? Or are they dependent on the the way that ...
by Leoncio
Sun Mar 12, 2023 10:43 pm
Forum: Modding discussion
Topic: New to Modding, what is allowed?
Replies: 3
Views: 1611

New to Modding, what is allowed?

Hello,

I've just started to look at just making some small changes in other peoples mods, going into their .lua scripts and changing the colors, recipe resources, etc.
As I was doing it, I started to look into more complex mods that I've enjoyed and wanted to see "how-it-works", while doing so I ...

Go to advanced search