Catchable tiny_rats
Re: Catchable tiny_rats
I like it crom, fun to see the interactivity develop.
- cromcrom
- Posts: 549
- Joined: Tue Sep 11, 2012 7:16 am
- Location: Chateauroux in a socialist s#!$*&% formerly known as "France"
Re: Catchable tiny_rats
Glad you like it. It is not very elegant, but aww well... I LOVE interactivity, and to link it to skills. Everythings were interactive and linked to skills in The Lost Continent, and will be (bigger and better ^^) in the Lost Continent 2
A trip of a thousand leagues starts with a step.
Re: Catchable tiny_rats
I like it too! i actually will use this in my mod if you dont mind..oh and i changed the script a littebit for my needs
Code: Select all
defineObject{
name = "tiny_rat",
baseObject = "tiny_rat",
components = {
{
class="Clickable",
onClick=function(self)
local item = getMouseItem()
if item then
hudPrint("You can't catch a rat with an item in your hand!")
return
end
self.go:destroy()
setMouseItem(spawn('rat_swarm_shank').item)
hudPrint("Not tasty but it serves it's purpose")
end
}
}
}
Re: Catchable tiny_rats
Of course anybody can use anything posted on these forums, and you can modify it as much as you like. I'm just glad you guys found this useful.
- LoG Framework 2http://sites.google.com/site/jkoslog2 Define hooks in runtime by entity.name or entity.id + multiple hooks support.
- cloneObject viewtopic.php?f=22&t=8450
- cloneObject viewtopic.php?f=22&t=8450
Re: Catchable tiny_rats
Well, if you know your way around a hex editor you can always dump the dat file there and type in an educated guess trying to find what you are looking for.
It can be quite tricky since what you will get won't be in plain text.
Anyways, i dropped the file in Frhed and made some queries and this seems to work.
So, pretend base is 13, and character has Agile trait (+2 dex) and a pair of Rogue Boots on (+1 dex) then the current stat will say 16.
Edit: Wops, corrected some punctuation misstakes in the code block
It can be quite tricky since what you will get won't be in plain text.
Anyways, i dropped the file in Frhed and made some queries and this seems to work.
Code: Select all
-- will return the 'base' stat without bonuses
party.party:getChampion(1):getBaseStat("dexterity")
-- will return and print the stat with all bonuses applied
party.party:getChampion(1):getCurrentStat("dexterity")
Edit: Wops, corrected some punctuation misstakes in the code block
Re: Catchable tiny_rats
bitcpy wrote:Well, if you know your way around a hex editor you can always dump the dat file there and type in an educated guess trying to find what you are looking for.
It can be quite tricky since what you will get won't be in plain text.
Anyways, i dropped the file in Frhed and made some queries and this seems to work.
So, pretend base is 13, and character has Agile trait (+2 dex) and a pair of Rogue Boots on (+1 dex) then the current stat will say 16.Code: Select all
-- will return the 'base' stat without bonuses party.party:getChampion(1):getBaseStat("dexterity") -- will return and print the stat with all bonuses applied party.party:getChampion(1):getCurrentStat("dexterity")
Edit: Wops, corrected some punctuation misstakes in the code block
Thank you! Exactly what I needed [for days]! =)
Re: Catchable tiny_rats
I think you should be able to do this in a more "correct" manner by adding an item component on the monster. Or at least some point during development we did this to an ogre
Steven Seagal of gaming industry
- cromcrom
- Posts: 549
- Joined: Tue Sep 11, 2012 7:16 am
- Location: Chateauroux in a socialist s#!$*&% formerly known as "France"
Re: Catchable tiny_rats
Thanks Antti. I wish we could try that by ourselves, if you see what I mean . This has been a very loooong WE....
A trip of a thousand leagues starts with a step.
Re: Catchable tiny_rats
i'm using this script but i noticed that if i spawn these tiny rats on elevation 0 they recognize walls , but if i spawn them at an higher elevation than they falls to the ground but they walk through walls. i wonder why.
[...]
All those moments will be lost in time, like tears in rain.
Time to die.
All those moments will be lost in time, like tears in rain.
Time to die.