Ask a simple question, get a simple answer
Re: Ask a simple question, get a simple answer
Quick Question -
Is there any way to get/find the Width & Height (x, y dimensions) of the base game's GuiItems??
Reason - trying to re-implement: champion:showAttackResult(string, guiItem)
(Need the guiItem's width/height to center the guiItem correctly... I think?)
Any help appreciated
Akroma
Is there any way to get/find the Width & Height (x, y dimensions) of the base game's GuiItems??
Reason - trying to re-implement: champion:showAttackResult(string, guiItem)
(Need the guiItem's width/height to center the guiItem correctly... I think?)
Any help appreciated
Akroma
Labyrinth of Lies (viewtopic.php?f=14&t=4400)
Legacy of Lies (viewtopic.php?f=22&t=12983&hilit=+legacy)
Legacy of Lies (viewtopic.php?f=22&t=12983&hilit=+legacy)
Re: Ask a simple question, get a simple answer
Your correction still has a problem: it tries to pass the ItemComponent directly through the delayedCall.
Here's a quick dump of gui item data:
Here's a quick dump of gui item data:
Code: Select all
AbilityMinusDown
width 35
y 2394
x 2162
height 20
AbilityMinusHover
width 35
y 2278
x 1107
height 20
AbilityMinusUp
width 35
y 2124
x 1918
height 20
AbilityPlusDown
width 35
y 1953
x 2444
height 20
AbilityPlusHover
width 35
y 2002
x 2444
height 20
AbilityPlusUp
width 35
y 1893
x 2444
height 20
AccuracySymbol
width 18
y 2384
x 1132
height 18
AttackFrame
x 2128
offsetY -7
y 1224
offsetX -7
width 208
height 205
AttackFrameBarBackground
width 117
y 1865
x 2365
height 14
AttackFrameBarBackgroundShort
width 97
y 2180
x 2346
height 14
AttackFrameConditionRect
width 76
y 1443
x 1981
height 75
AttackFrameDisabled
x 2159
offsetY -7
y 1562
offsetX -7
width 200
height 193
AttackFrameEnergy
width 113
y 2514
x 3
height 10
AttackFrameEnergyShort
width 93
y 2200
x 2346
height 10
AttackFrameHealthGreen
width 113
y 2514
x 122
height 10
AttackFrameHealthGreenShort
width 93
y 2070
x 1442
height 10
AttackFrameHealthRed
width 113
y 2514
x 360
height 10
AttackFrameHealthRedShort
width 93
y 2226
x 2204
height 10
AttackFrameHealthYellow
width 113
y 2514
x 241
height 10
AttackFrameHealthYellowShort
width 93
y 2226
x 2303
height 10
AttackFrameItemSlot
width 75
y 71
height 75
x 28
AttackFramePortraitRect
width 62
y 1
height 62
x 0
AttackFrameSelected1
width 200
y 1562
x 1747
height 193
AttackFrameSelected2
width 200
y 1562
x 1953
height 193
AttackFrameShield
width 220
y 1224
x 1902
height 213
AttackFrameSlotSpacing
y 0
x 8
AttackFrameSpacing
y -5
x -2
AttackPowerSymbol
width 18
y 2360
x 1132
height 18
Background
offsetX -6
offsetY -6
ButtonAccept
width 108
y 2218
x 1970
height 32
ButtonAcceptDisabled
width 108
y 2066
x 1970
height 32
ButtonAcceptHover
width 108
y 2028
x 2345
height 32
ButtonApply
width 95
y 2104
x 2312
height 32
ButtonApplyHover
width 95
y 2142
x 2162
height 32
ButtonCancel
width 108
y 2370
x 1970
height 32
ButtonCancelHover
width 108
y 2256
x 1970
height 32
ButtonChoose
width 108
y 2408
x 1970
height 32
ButtonChooseDisabled
width 108
y 2332
x 1970
height 32
ButtonChooseHover
width 108
y 2066
x 2084
height 32
ButtonClear
width 108
y 2066
x 2312
height 32
ButtonClearDisabled
width 108
y 2446
x 1970
height 32
ButtonClearHover
width 108
y 2104
x 2084
height 32
ButtonClose
width 108
y 2484
x 1970
height 32
ButtonCloseHover
width 108
y 2104
x 2198
height 32
ButtonDefaults
width 128
y 1827
x 2365
height 32
ButtonDefaultsHover
width 128
y 1761
x 2365
height 32
ButtonImport
width 108
y 2180
x 1970
height 32
ButtonImportDisabled
width 108
y 2142
x 1970
height 32
ButtonImportHover
width 108
y 2294
x 1970
height 32
ButtonKeyConfig
width 144
y 2334
x 1747
height 32
ButtonKeyConfigHover
width 144
y 2296
x 1747
height 32
ButtonNo
width 73
y 1524
x 1981
height 32
ButtonNoHover
width 73
y 2142
x 2263
height 32
ButtonSave
width 108
y 2066
x 2198
height 32
ButtonSaveHover
width 108
y 2104
x 1970
height 32
ButtonYes
width 73
y 2142
x 2342
height 32
ButtonYesHover
width 73
y 2104
x 2413
height 32
ChampionConditionOverlay
width 128
y 1224
x 2342
height 128
CharGenBackToMenu
width 139
y 2218
x 1825
height 32
CharGenBackToMenuHover
width 139
y 2256
x 1825
height 32
CharGenNameBox
width 274
y 1172
x 2042
height 22
CharGenPortraitSel128
width 128
y 1054
x 2346
height 128
CharGenPortraitSelBig
width 96
y 2426
x 1027
height 96
CharGenPortraitSelSmall
width 64
y 2445
x 1747
height 64
CharGenSkillMinusHover
width 36
y 2352
x 2162
height 36
CharGenSkillMinusImage
width 36
y 2268
x 2162
height 36
CharGenSkillPlusHover
width 36
y 2310
x 2162
height 36
CharGenSkillPlusImage
width 36
y 2226
x 2162
height 36
CharGenSkillSlot
width 314
y 2426
x 707
height 36
CharGenSkillSlotHover
width 314
y 732
x 2037
height 36
CharGenStartGame
width 119
y 2028
x 2220
height 32
CharGenStartGameDisabled
width 119
y 2028
x 1970
height 32
CharGenStartGameHover
width 119
y 2028
x 2095
height 32
CharSheet
width 617
y 776
x 1765
height 272
CheckBox
width 20
y 408
x 2469
height 20
CheckBoxChecked
width 20
y 619
x 2466
height 20
CheckBoxCheckedHover
width 20
y 2308
x 1132
height 20
CheckBoxHover
width 20
y 2334
x 1132
height 20
ChooseDungeonBackground
width 810
y 3
x 3
height 767
ChooseDungeonDownload
width 96
y 1020
x 2388
height 18
ChooseDungeonDownloadHvr
width 96
y 2002
x 2342
height 18
ChooseDungeonUnsubscribe
width 110
y 1799
x 2365
height 18
ChooseDungeonUnsubscribeHvr
width 110
y 2500
x 1442
height 18
ChooseDungeonWorkshop
width 181
y 2048
x 1747
height 32
ChooseDungeonWorkshopHvr
width 181
y 2086
x 1747
height 32
ChoosePortraitDialog
x 1158
offsetY -10
y 1224
offsetX -10
width 462
height 523
CloseButtonHover
width 58
y 2334
x 1897
height 28
ComboBox
width 180
y 2002
x 1970
height 20
ComboBoxHover
width 180
y 2002
x 2156
height 20
ConfirmDialog
x 2037
offsetY -10
y 3
offsetX -10
width 433
height 304
ContainerChest
x 1158
offsetY -5
y 1753
offsetX -5
width 278
height 328
ContainerSack
x 1158
offsetY -5
y 2087
offsetX -5
width 278
height 328
CraftPotionPanel
width 173
y 2337
x 1442
height 119
DamageSplash
width 112
y 1492
x 2342
height 45
DialogFrameCornerBottomLeft
width 5
y 282
x 2487
height 5
DialogFrameCornerBottomRight
width 5
y 293
x 2476
height 5
DialogFrameCornerTopLeft
width 5
y 293
x 2487
height 5
DialogFrameCornerTopRight
width 5
y 282
x 2476
height 5
DialogFrameSideBottom
width 90
y 1212
x 2346
height 5
DialogFrameSideLeft
width 5
y 3
x 2476
height 90
DialogFrameSideRight
width 5
y 3
x 2487
height 90
DialogFrameSideTop
width 90
y 2226
x 2402
height 5
DialogShadowCornerBottomLeft
width 40
y 2439
x 2084
height 40
DialogShadowCornerBottomRight
width 40
y 2180
x 2254
height 40
DialogShadowCornerTopLeft
width 40
y 2393
x 2084
height 40
DialogShadowCornerTopRight
width 40
y 2180
x 2208
height 40
DialogShadowSideBottom
width 40
y 2180
x 2300
height 40
DialogShadowSideLeft
width 40
y 2485
x 2084
height 40
DialogShadowSideRight
width 40
y 2180
x 2162
height 40
DialogShadowSideTop
width 40
y 2347
x 2084
height 40
EnterTextDialog
x 551
offsetY -10
y 2120
offsetX -10
width 550
height 182
EquipmentSlots
width 270
y 1224
x 1626
height 332
ExpBar
x 2042
offsetY 3
y 1200
offsetX 3
width 246
height 15
ExpBarFrame
width 252
y 1926
x 1970
height 21
FoodBarFrame
width 252
y 2501
x 707
height 21
FoodBarGreen
x 2222
offsetY 3
y 1981
offsetX 3
width 246
height 15
FoodBarRed
x 2228
offsetY 3
y 1926
offsetX 3
width 246
height 15
FoodBarYellow
x 1970
offsetY 3
y 1981
offsetX 3
width 246
height 15
GameOver
width 389
y 649
x 2037
height 77
HandSlot1
width 84
y 435
x 2379
height 116
HandSlot2
width 84
y 313
x 2379
height 116
HandSlotHighlight1
width 82
y 898
x 2388
height 116
HandSlotHighlight2
width 82
y 1435
x 2216
height 116
HitSplash
width 117
y 2005
x 1442
height 59
HitSplashLarge
width 150
y 2426
x 551
height 85
HitSplashSmall
width 72
y 2142
x 2084
height 48
Injury
width 81
y 557
x 2379
height 80
InjuryHand1
width 82
y 776
x 2388
height 116
InjuryHand2
width 82
y 1435
x 2128
height 116
InjurySmall
width 63
y 2442
x 1820
height 63
InstructionsAttackPanel
width 336
y 313
x 2037
height 330
InventoryTab
width 601
y 776
x 1158
height 442
IslandMasterSymbol
width 47
y 2005
x 1565
height 65
KeyBindings
width 542
y 1438
x 3
height 545
MapArrowLeft
width 73
y 1443
x 1902
height 92
MapArrowRight
width 73
y 2421
x 1330
height 92
MapButtonHover
width 58
y 2296
x 1897
height 28
MapClose
width 62
y 2442
x 1889
height 62
MapToolsBackground
width 115
y 1562
x 1626
height 603
MapToolsCenter
width 80
y 2421
x 1244
height 87
MapToolsCenterHover
width 80
y 2421
x 1158
height 87
MapToolsClose
width 45
y 2247
x 2084
height 44
MapToolsCloseHover
width 45
y 2297
x 2084
height 44
MapToolsCross
width 32
y 2210
x 1707
height 33
MapToolsCrossHover
width 32
y 2171
x 1707
height 33
MapToolsExclamation
width 15
y 137
x 2476
height 32
MapToolsExclamationHover
width 15
y 99
x 2476
height 32
MapToolsLevelDivider
width 68
y 2514
x 1158
height 6
MapToolsLevelDown
width 47
y 713
x 2432
height 56
MapToolsLevelDownHover
width 47
y 1562
x 2446
height 56
MapToolsLevelUp
width 47
y 1643
x 2446
height 56
MapToolsLevelUpHover
width 47
y 1443
x 2063
height 56
MapToolsQuestion
width 22
y 473
x 2469
height 32
MapToolsQuestionHover
width 22
y 435
x 2469
height 32
MapToolsQuil
width 29
y 2252
x 1707
height 32
MapToolsQuilHover
width 29
y 2290
x 1707
height 32
MenuButtonHover
width 58
y 1724
x 2365
height 28
Moon
width 64
y 2372
x 1890
height 64
MovementArrowDown
width 67
y 2372
x 1747
height 67
MovementArrows
x 1747
offsetY -7
y 1893
offsetX -7
width 217
height 149
NewGame
width 542
y 1989
x 3
height 519
NextChampionHover
width 25
y 2183
x 1107
height 89
PackSlotBgImage
x 2432
offsetY 5
y 649
offsetX 3
width 58
height 58
PreviousChampionHover
width 24
y 313
x 2469
height 89
QuickSwapButtonDown1
width 29
y 1498
x 2304
height 57
QuickSwapButtonDown2
width 29
y 1492
x 2460
height 57
QuickSwapButtonUp1
width 29
y 2468
x 984
height 57
QuickSwapButtonUp2
width 29
y 1435
x 2304
height 57
RandomizeButton
width 24
y 511
x 2469
height 25
RandomizeButtonHover
width 24
y 588
x 2466
height 25
SaveGameBackground
x 819
offsetY -10
y 3
offsetX -10
width 664
height 761
SaveGameDeleteButton
width 64
y 2066
x 2426
height 18
SaveGameDeleteHover
width 64
y 2142
x 2421
height 18
SaveGamePortraitFrame
x 1747
offsetY -2
y 2218
offsetX -2
width 72
height 72
SaveGameSlot
width 575
y 2308
x 551
height 112
SaveGameSlotHover
width 575
y 1054
x 1765
height 112
SaveGameTitleLoad
width 171
y 2462
x 1442
height 32
SaveGameTitleSave
width 165
y 2124
x 1747
height 32
Settings
width 542
y 3
x 1489
height 760
SkillMinusImage
width 45
y 1705
x 2446
height 45
SkillPlusHover
width 45
y 2196
x 2084
height 45
SkillPlusImage
width 45
y 1505
x 2063
height 45
SkillSlots
width 60
y 2500
x 1558
height 21
SkillSlotsHighlight
x 2357
offsetY -3
y 732
offsetX -3
width 66
height 27
SkillTick
width 10
y 219
x 2476
height 15
SkillTickUpgrade
width 10
y 261
x 2476
height 15
SkillTickUpgradeSelected
width 10
y 240
x 2476
height 15
SkillsTab
width 601
y 1224
x 551
height 442
SkillsTabHighlight
width 42
y 2120
x 1107
height 57
SkillsTabHighlightSel
width 39
y 2180
x 2449
height 39
SleepButtonHover
width 58
y 2495
x 1626
height 28
Slider
width 150
y 2517
x 551
height 5
SliderKnob
width 16
y 197
x 2476
height 16
SliderKnobHover
width 16
y 175
x 2476
height 16
SmallFoodBarFrame
width 112
y 1188
x 2346
height 18
SmallFoodBarGreen
x 2342
offsetY 3
y 1543
offsetX 3
width 106
height 12
SmallFoodBarRed
x 1877
offsetY 3
y 1205
offsetX 3
width 106
height 12
SmallFoodBarYellow
x 1765
offsetY 3
y 1205
offsetX 3
width 106
height 12
SpellFizzle
width 173
y 1753
x 1442
height 120
SpellNoEnergy
width 173
y 1879
x 1442
height 120
SpellPanel
width 173
y 2087
x 1442
height 119
SpellPanelNoButtons
width 173
y 2212
x 1442
height 119
SpellRuneGlow
width 128
y 1358
x 2342
height 128
SpellRunes
width 612
y 1761
x 1747
height 60
SpellRunesGlow
width 612
y 1827
x 1747
height 60
Star
width 25
y 557
x 2466
height 25
StatisticsDialog
width 542
y 776
x 3
height 656
StatsTab
width 601
y 1672
x 551
height 442
Sun
width 64
y 2372
x 1820
height 64
TextButton
width 217
y 2162
x 1747
height 22
TextButtonHover
width 217
y 2190
x 1747
height 22
TextButtonLong
width 231
y 1953
x 1970
height 22
TextButtonLongHover
width 231
y 1953
x 2207
height 22
TraitSlot
width 231
y 1893
x 2207
height 27
TraitSlotHover
width 231
y 1893
x 1970
height 27
TraitSlotLong
width 271
y 1172
x 1765
height 27
TraitSlotLongHover
width 271
y 2468
x 707
height 27
TraitsTab
width 601
y 776
x 551
height 442
UnarmedAttackBearLeft
width 75
y 2252
x 1626
height 75
UnarmedAttackBearRight
width 75
y 1562
x 2365
height 75
UnarmedAttackLeft
width 75
y 2171
x 1626
height 75
UnarmedAttackMageLeft
width 75
y 2414
x 1626
height 75
UnarmedAttackMageRight
width 75
y 2333
x 1626
height 75
UnarmedAttackRight
width 75
y 1643
x 2365
height 75
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
Re: Ask a simple question, get a simple answer
YES! ... And also... HOW??minmay wrote:Here's a quick dump of gui item data:
(Its Ok, the answer to HOW is most probably not simple at all ... keen to know though )
Thanks again good sir
Labyrinth of Lies (viewtopic.php?f=14&t=4400)
Legacy of Lies (viewtopic.php?f=22&t=12983&hilit=+legacy)
Legacy of Lies (viewtopic.php?f=22&t=12983&hilit=+legacy)
Re: Ask a simple question, get a simple answer
Well thank you for your answer.akroma222 wrote:Try adding:bongobeat wrote:but there is not the secreDoor = true in the definition
I don't understand, sorry.to the definition, see if that helps at all....Code: Select all
secretDoor = false
ok, that means the secretdoor = true is activatd by defaut but absent of the definition?
Anyway, I have done something else instead. I use a (true) secret door, that is opened and closed very fast.
I remember that I use such system to activate and deactivate a particles, shown after equipping or not the item, but this is an independant object.
Re: Ask a simple question, get a simple answer
I was afraid you say that!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.
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.
- zimberzimber
- Posts: 432
- Joined: Fri Feb 08, 2013 8:06 pm
Re: Ask a simple question, get a simple answer
Can't you just tick off the component in the oceans object?
That doesn't disable the water on the object.
That doesn't disable the water on the object.
My asset pack [v1.10]
Features a bit of everything!
Features a bit of everything!
Re: Ask a simple question, get a simple answer
Why do you think you need multiple WaterSurfaceComponents on the level? What advantage do you think you are getting by using more than one?bongobeat wrote:I was afraid you say that!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.
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.
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
- Mysterious
- Posts: 226
- Joined: Wed Nov 06, 2013 8:31 am
Re: Ask a simple question, get a simple answer
Hi again.
Ok I would like to use the tentacles monster from LOG 1.
I have tried to take the Object monster out of Min's G1MP_Alpha_1 script but for some reason it does not work. I copied the code from his lua file and added it to my monster lua file code in my mod and it crashes when I try to put the Monster in the level editor.
I just want to get a working version of it for LOG 2 thanks for the help
Ok I would like to use the tentacles monster from LOG 1.
I have tried to take the Object monster out of Min's G1MP_Alpha_1 script but for some reason it does not work. I copied the code from his lua file and added it to my monster lua file code in my mod and it crashes when I try to put the Monster in the level editor.
I just want to get a working version of it for LOG 2 thanks for the help
Re: Ask a simple question, get a simple answer
Hey Mysterious,Mysterious wrote: I have tried to take the Object monster out of Min's G1MP_Alpha_1 script but for some reason it does not work. I copied the code from his lua file and added it to my monster lua file code in my mod and it crashes when I try to put the Monster in the level editor.
can you pls cut and paste the definition you have in your files so we can fix it up?
Its probably just a minor typo or a missing file or something
(just tested the tentacle monster with no problems.. but I cant find where the definition is hiding )
Labyrinth of Lies (viewtopic.php?f=14&t=4400)
Legacy of Lies (viewtopic.php?f=22&t=12983&hilit=+legacy)
Legacy of Lies (viewtopic.php?f=22&t=12983&hilit=+legacy)
- Mysterious
- Posts: 226
- Joined: Wed Nov 06, 2013 8:31 am
Re: Ask a simple question, get a simple answer
Hi Aka
This is from MIns g1.lua file:
It crashes I don't know whats wrong?
This is from MIns g1.lua file:
Code: Select all
defineObject{
name = "tentacles",
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,
},
}
}
defineMaterial{
name = "drainage_tentacles",
diffuseMap = "assets/textures/monsters/drain_tentacles_dif.tga",
specularMap = "assets/textures/monsters/drain_tentacles_spec.tga",
normalMap = "assets/textures/monsters/drain_tentacles_normal.tga",
doubleSided = false,
lighting = true,
alphaTest = false,
blendMode = "Opaque",
textureAddressMode = "Wrap",
glossiness = 35,
depthBias = 0,
}