Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Tales of MajEyal
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Assen Kanev
Tales of MajEyal
Commits
71cd9443
Commit
71cd9443
authored
6 years ago
by
DarkGod
Browse files
Options
Downloads
Patches
Plain Diff
forbid itotic mindstars from rerolling
parent
c38885c2
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
game/modules/tome/data/general/objects/egos/mindstars.lua
+27
-7
27 additions, 7 deletions
game/modules/tome/data/general/objects/egos/mindstars.lua
with
27 additions
and
7 deletions
game/modules/tome/data/general/objects/egos/mindstars.lua
+
27
−
7
View file @
71cd9443
...
...
@@ -1178,8 +1178,14 @@ newEntity{
melee_project
=
{
[
DamageType
.
ITEM_ACID_CORRODE
]
=
resolvers
.
mbonus_material
(
15
,
5
),
[
DamageType
.
ITEM_NATURE_SLOW
]
=
resolvers
.
mbonus_material
(
15
,
5
),},
},
no_auto_hotkey
=
true
,
exclude_selective_list
=
true
,
resolvers
.
charm
(
"divide the mindstar in two"
,
1
,
function
(
self
,
who
)
if
self
.
mitoticed
then
game
.
logPlayer
(
who
,
"Your %s has already been divided."
,
self
:
getName
({
no_add_name
=
true
,
do_color
=
true
}))
return
end
-- Check for free slot first
if
who
:
getFreeHands
()
==
0
then
game
.
logPlayer
(
who
,
"You must have a free hand to divide the %s."
,
self
:
getName
({
no_add_name
=
true
,
do_color
=
true
}))
...
...
@@ -1207,22 +1213,36 @@ newEntity{
who
:
takeoffObject
(
inven_id
,
pos
)
-- Remove some properties before cloning
o
.
cost
=
self
.
cost
/
2
-- more don't split for extra gold discouragement
o
.
cost
=
0
-- more don't split for extra gold discouragement
o
.
max_power
=
nil
o
.
power_regen
=
nil
o
.
use_power
=
nil
o
.
use_talent
=
nil
local
o2
=
o
:
clone
()
o
.
mitoticed
=
true
local
o2
=
o
:
cloneFull
()
-- Remove mitotic function forever
for
i
,
ego
in
ripairs
(
o
.
ego_list
)
do
if
ego
[
1
]
and
ego
[
1
].
keywords
and
ego
[
1
].
keywords
.
mitotic
then
for
i
=
#
ego
[
1
],
1
,
-
1
do
if
type
(
ego
[
1
][
i
])
==
"table"
and
ego
[
1
][
i
].
__resolver
==
"charm"
then
table.remove
(
ego
[
1
],
i
)
end
end
end
end
for
i
,
ego
in
ripairs
(
o2
.
ego_list
)
do
if
ego
[
1
]
and
ego
[
1
].
keywords
and
ego
[
1
].
keywords
.
mitotic
then
for
i
=
#
ego
[
1
],
1
,
-
1
do
if
type
(
ego
[
1
][
i
])
==
"table"
and
ego
[
1
][
i
].
__resolver
==
"charm"
then
table.remove
(
ego
[
1
],
i
)
end
end
end
end
-- Build the item set
o
.
define_as
=
"MS_EGO_SET_MITOTIC_ACID"
o2
.
define_as
=
"MS_EGO_SET_MITOTIC_SLIME"
o
.
set_list
=
{
{
"define_as"
,
"MS_EGO_SET_MITOTIC_SLIME"
}
}
o2
.
set_list
=
{
{
"define_as"
,
"MS_EGO_SET_MITOTIC_ACID"
}
}
local
uid
=
"_"
..
game
.
turn
..
"_"
..
rng
.
range
(
1
,
99999
)
o
.
define_as
=
"MS_EGO_SET_MITOTIC_ACID"
..
uid
o2
.
define_as
=
"MS_EGO_SET_MITOTIC_SLIME"
..
uid
o
.
set_list
=
{
{
"define_as"
,
"MS_EGO_SET_MITOTIC_SLIME"
..
uid
}
}
o2
.
set_list
=
{
{
"define_as"
,
"MS_EGO_SET_MITOTIC_ACID"
..
uid
}
}
o
.
on_set_complete
=
function
(
self
,
who
)
self
:
specialWearAdd
({
"combat"
,
"burst_on_crit"
},
{
[
engine
.
DamageType
.
ACID_BLIND
]
=
10
*
self
.
material_level
}
)
game
.
logPlayer
(
who
,
"#GREEN#The mindstars pulse with life."
)
game
.
logPlayer
(
who
,
"#GREEN#The mindstars pulse with life
as it synergises with its twin
."
)
end
o
.
on_set_broken
=
function
(
self
,
who
)
game
.
logPlayer
(
who
,
"#SLATE#The link between the mindstars is broken."
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment