Page 225 of 395

Re: Ask a simple question, get a simple answer

Posted: Sun Mar 18, 2018 10:21 am
by akroma222
Ok, yup Ive located the definition in minmays pack (sorry - forgot where exactly it was)
There are a still a few diff things it could be - my best guess atm is that you havent changed or updated Texture or Model locations / Material definitions etc
Those things will crash the game as soon as you click to place the monster in your dungeon (again, best guess)

I would strongly suggest double checking file locations and spelling typos just to be sure firstly
Also - have you added this line to your init.lua :

Code: Select all

import "assets/scripts/monsters/tentacles.lua"
(OR imported g1.lua at all? - you mention you just cut pasted the above def into your monster.lua ..?)
You definitely need to make sure that you have the base games 'tentacles' definition already imported before minmays version in your monsters.lua

Code: Select all

defineObject{
   name = "tentacles",
   baseObject = "tentacles",
Obviously its nothing wrong w minmays definition - just double check those few things and see if you can find the issue there
If not then it may be easier to upload the files and I can run through and check it out myself

Re: Ask a simple question, get a simple answer

Posted: Mon Mar 19, 2018 6:29 am
by Mysterious
Hi Akroam.

I pasted this into my init.lua file: import "assets/scripts/monsters/tentacles.lua"
and it still does not work. If I try to put the monster on the floor it crashes with:

string {"Animation.lua"];10 file not found
assets/animations/monsters/drainage_tentcles/drainage_tentcles_attack_from_back_animation
stack traceback:

I have no idea whats going on lol.

EDIT I have the latest version of Grimrock, it just cant find the animation files.
EDIT 2:
Ok I got it to works wow man. I had to copy this into my monster.lua

Code: Select all

--- Original Monster
defineObject{
	name = "tentacles",
	baseObject = "base_monster",
	components = {
		{
			class = "Model",
			model = "assets/models/monsters/drainage_tentacles.fbx",
			storeSourceData = true,
		},
		{
			class = "Animation",
			animations = {
				idle = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_idle.fbx",
				turnLeft = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_turn_left.fbx",
				turnRight = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_turn_right.fbx",
				hide = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_hide.fbx",
				reveal = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_raise.fbx",
				attack = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_from_back.fbx",
				attackBack = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_back.fbx",
				attackLeft = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_left.fbx",
				attackRight = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_right.fbx",
				getHitFrontLeft = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_left.fbx",
				getHitFrontRight = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_right.fbx",
				getHitBack = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_left.fbx",
				getHitLeft = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_right.fbx",
				getHitRight = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_left.fbx",
				fall = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_left.fbx",
			},
			currentLevelOnly = true,
		},
		{
			class = "Monster",
			meshName = "drainage_tentacles_mesh",
			hitSound = "tentacles_hit",
			dieSound = "tentacles_die",
			hitEffect = "hit_goo",
			capsuleHeight = 1,
			capsuleRadius = 0.1,
			health = 420,
			immunities = { "assassination", "backstab", "sleep", "blinded", "knockback" },
			resistances = {
				["cold"] = "resist",
				["shock"] = "weak",
			},
			exp = 320,
			headRotation = vec(90, 0, 0),
		},
		{
			class = "TentacleBrain",
			name = "brain",
			sight = 2.5,
			allAroundSight = true,
		},
		{
			class = "MonsterTurn",
			name = "turn",
			sound = "tentacles_walk",
		},
		{
			class = "TentacleHide",
			name = "hide",
		},
		{
			class = "MonsterAttack",
			name = "basicAttack",
			attackPower = 25,
			accuracy = 15,
			cooldown = 4,
			sound = "tentacles_attack",
			causeCondition = "paralyzed",
			conditionChance = 20,
		},
	},
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack.fbx",
	event = "attack",
	frame = 15,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack.fbx",
	event = "attack",
	frame = 20,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack.fbx",
	event = "attack",
	frame = 25,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_left.fbx",
	event = "attack",
	frame = 12,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_left.fbx",
	event = "attack",
	frame = 18,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_left.fbx",
	event = "attack",
	frame = 24,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_right.fbx",
	event = "attack",
	frame = 11,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_right.fbx",
	event = "attack",
	frame = 18,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_right.fbx",
	event = "attack",
	frame = 25,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_back.fbx",
	event = "attack",
	frame = 12,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_back.fbx",
	event = "attack",
	frame = 18,
}

defineAnimationEvent{
	animation = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_back.fbx",
	event = "attack",
	frame = 26,
}

defineSound{
	name = "tentacles_attack",
	filename = "assets/samples/monsters/tentacles_attack_01.wav",
	loop = false,
	volume = 1,
	minDistance = 1,
	maxDistance = 10,
}

defineSound{
	name = "tentacles_walk",
	filename = "assets/samples/monsters/tentacles_walk_01.wav",
	loop = false,
	volume = 1,
	minDistance = 1,
	maxDistance = 10,
}

defineSound{
	name = "tentacles_rise",
	filename = "assets/samples/monsters/tentacles_rise_01.wav",
	loop = false,
	volume = 1,
	minDistance = 1,
	maxDistance = 10,
}

defineSound{
	name = "tentacles_retreat",
	filename = "assets/samples/monsters/tentacles_retreat_01.wav",
	loop = false,
	volume = 1,
	minDistance = 1,
	maxDistance = 10,
}

defineSound{
	name = "tentacles_hit",
	filename = { 
		"assets/samples/weapons/hit_bone_01.wav",
		"assets/samples/weapons/hit_bone_02.wav",
		"assets/samples/weapons/hit_flesh_01.wav",
	},
	loop = false,
	volume = 1,
	minDistance = 1,
	maxDistance = 10,
}

defineSound{
	name = "tentacles_die",
	filename = "assets/samples/monsters/tentacles_die_01.wav",
	loop = false,
	volume = 1,
	minDistance = 1,
	maxDistance = 10,
}
If I use the (above) monster in my mod it crashes. If I use the below monster, which I just named ie (tentcles_min) It works perfectly.

Code: Select all

defineObject{
	name = "tentacles_min",
	baseObject = "tentacles",
	components = {
		{
			class = "Animation",
			animations = {
				idle = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_idle.fbx",
				turnLeft = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_turn_left.fbx",
				turnRight = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_turn_right.fbx",
				hide = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_hide.fbx",
				reveal = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_raise.fbx",
				attack = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack.fbx",
				attackBack = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_back.fbx",
				attackLeft = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_left.fbx",
				attackRight = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_right.fbx",
				getHitFrontLeft = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_left.fbx",
				getHitFrontRight = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_right.fbx",
				getHitBack = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_left.fbx",
				getHitLeft = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_right.fbx",
				getHitRight = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_left.fbx",
				fall = "assets/animations/monsters/drainage_tentacles/drainage_tentacles_get_hit_front_left.fbx",
			},
			currentLevelOnly = true,
		},
		{
			class = "TentacleBrain",
			name = "brain",
			sight = 2.5,
			allAroundSight = true,
			onThink = function(self)
				-- fix bug with builtin brain
				if not self.partyOnLevel then
					return self:performAction("hide") or self:wait()
				else
					return false
				end
			end,
		},
		{ -- fix another bug with builtin brain
			class = "MonsterAction",
			name = "move",
			onBeginAction = function(self) return false end,
		},
		{ -- fix another bug with builtin brain
			class = "MonsterAction",
			name = "turn",
			onBeginAction = function(self) return false end,
		},
	}
}

Re: Ask a simple question, get a simple answer

Posted: Mon Mar 19, 2018 11:01 am
by Mysterious
Hi all.

Ok I use this on Potions: champion:playHealingIndicator()

I have noticed there are more of the indicators but I cannot find the names. Can anyone tell me what the rest of the indicator names are or is there just one?

Thxs :)

Re: Ask a simple question, get a simple answer

Posted: Mon Mar 19, 2018 3:09 pm
by bongobeat
minmay wrote:
bongobeat wrote:
minmay wrote:You should never have multiple WaterSurfaceComponents on the same level. Remove all the WaterSurfaceComponents except one. You can still use multiple models for the ocean, but there should only be one WaterSurfaceComponent on the level.
I was afraid you say that! :shock:

Is there no way to keep the different watersurfaces? E.g: By keeping the ocean and destroying the water_surface and recreating it when needed.


It's gonna be difficult to completely remove the water_surface here. This level is some kind of harbor, and there are things to do underwater. I can't possibly remove those things without changing access to 2 levels.
Why do you think you need multiple WaterSurfaceComponents on the level? What advantage do you think you are getting by using more than one?
Well I didn't know that you can have (and should) only one. But what is the matter when using 5 water_surface_component on the same map? Except for the issue of reflection.

By the way, first I used a water_surface (who has the waterSurfaceComponent) and 4 custom beach_ocean without waterSurfaceComponent. There was still the reflection issue, when you enter an ocean tile.

So, I finally use the custom ocean without the WaterSurfaceComponent 3 times on the map, an ocean with waterSurfaceComponent and fog parameters (used one time on the map), and one water_surface without the waterSurfaceComponent. The reflection is ok everywhere.

Re: Ask a simple question, get a simple answer

Posted: Mon Mar 19, 2018 8:16 pm
by Zo Kath Ra
Mysterious wrote:Hi all.

Ok I use this on Potions: champion:playHealingIndicator()

I have noticed there are more of the indicators but I cannot find the names. Can anyone tell me what the rest of the indicator names are or is there just one?

Thxs :)
What other indicators are there?

Re: Ask a simple question, get a simple answer

Posted: Mon Mar 19, 2018 10:08 pm
by minmay
bongobeat wrote:Well I didn't know that you can have (and should) only one. But what is the matter when using 5 water_surface_component on the same map? Except for the issue of reflection.
The game only has one reflection buffer. The only things you accomplish by having multiple WaterSurfaceComponents on the same level are:
1. You make it difficult to know which WaterSurfaceComponent will be used to calculate the reflection buffer. This is bad.
2. You make performance slightly worse. This is also bad.

Note that WaterSurfaceComponent isn't really affected by disabling it. You should remove the components entirely, not just disable them.

Re: Ask a simple question, get a simple answer

Posted: Sun Mar 25, 2018 11:33 am
by Badgert
There is such an object

Code: Select all

defineObject{
	name = "mine_door_spear",
	baseObject = "base_door",
	components = {
		{
			class = "Model",
			model = "assets/models/env/mine_door_spear.fbx",
		},
		{
			class = "Door",
			openVelocity = 4,
			closeVelocity = -6,
			openingDirection = "down",
			maxHeight = 2,
			sparse = true,
			killPillars = false,
			openSound = "spear_door",
			closeSound = "spear_door",
			--lockSound = "wall_sliding_lock",
		},
	},
}
Can I make it NOT displayed on the auto-map?

Re: Ask a simple question, get a simple answer

Posted: Sun Mar 25, 2018 12:07 pm
by Isaac
Badgert wrote:There is such an object
...
Can I make it NOT displayed on the auto-map?
What effect—exactly , and specifically, are you trying to achieve? (Or what is it that you are intending to do with it?)

Re: Ask a simple question, get a simple answer

Posted: Sun Mar 25, 2018 5:33 pm
by Badgert
I want to make an invisible labyrinth of these elements. But as soon as I open the map - there are no secrets left ...

Re: Ask a simple question, get a simple answer

Posted: Sun Mar 25, 2018 7:12 pm
by Isaac
Badgert wrote:I want to make an invisible labyrinth of these elements. But as soon as I open the map - there are no secrets left ...
Can they ever be seen? Are these walls intended to become visible on the map when discovered?

The easiest way to make them permanently invisible on the automap, is to set the object's automap tile to the number for a blank one; like setting it to 24.

Code: Select all

defineObject{
   name = "mine_door_spear_hidden",
   baseObject = "base_door",
   automapIcon = 24, --blank
   components = {
      {
         class = "Model",
         model = "assets/models/env/mine_door_spear.fbx",
      },
      {
         class = "Door",
         openVelocity = 4,
         closeVelocity = -6,
         openingDirection = "down",
         maxHeight = 2,
         sparse = true,
         killPillars = false,
         openSound = "spear_door",
         closeSound = "spear_door",
         --lockSound = "wall_sliding_lock",
      },
   },
}