[Mod] vacuum cleaner robot 1.6 [aclean]

Post Reply
User avatar
AiTechEye
Member
Posts: 1002
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

[Mod] vacuum cleaner robot 1.6 [aclean]

by AiTechEye » Post



Auto clean (vacuum cleaner)

This is a vacuum cleaner robot, that cleaning by it self.

Left click to open the dumpster (when its not active)
It will clone it self if its much to clean.
And its locked by owner :-)

You can choose how it will clean:
Mobs / other entitys
Monsters (have the type="monster" setting)
Drops

It will always restore its position, so its not risk it disappear in some way (node > entity > node)


V1.6: fixed a forgotten textstring, from another mod :-)
Last edited by AiTechEye on Sun Nov 13, 2016 20:23, edited 14 times in total.

User avatar
Desour
Member
Posts: 1546
Joined: Thu Jun 19, 2014 19:49
GitHub: Desour
IRC: Desour
In-game: DS
Location: I'm scared that if this is too exact, I will be unable to use my keyboard.

Re: [Mod] aclean (vacuum cleaner robot)

by Desour » Post

nice
i would like to have the clean function in simple_robot mod
he/him; Codeberg; GitHub; ContentDB; public personal TODO list; "DS" is preferred (but often too short)

User avatar
Hybrid Dog
Member
Posts: 2856
Joined: Thu Nov 01, 2012 12:46
GitHub: HybridDog

Re: [Mod] aclean (vacuum cleaner robot)

by Hybrid Dog » Post

Could you loop a vacuum cleaner sound?
http://freesound.org/search/?q=vacuum+cleaner

‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪

User avatar
AiTechEye
Member
Posts: 1002
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] aclean 2 (vacuum cleaner robot)

by AiTechEye » Post

Added :-)

I making all my sounds / effects by myself, that's less problems with licenses

Sokomine
Member
Posts: 4317
Joined: Sun Sep 09, 2012 17:31
GitHub: Sokomine
IRC: Sokomine
In-game: Sokomine

Re: [Mod] aclean 2.1 (vacuum cleaner robot)

by Sokomine » Post

Funny :-) Where does the oerkki come from? Does it act as a dust mote? :-) Anyway: I'd like to see some of those roam around on servers. Finally no more tedious manual dusting of your carpets and storage areas!
A list of my mods can be found here.

User avatar
TailsTheFoxDoes MT
Member
Posts: 415
Joined: Mon Jan 18, 2016 20:50
In-game: TailsTheFox
Location: Mobius

Re: [Mod] aclean 2.1 (vacuum cleaner robot)

by TailsTheFoxDoes MT » Post

Did you know this thing saved my life? So basically, i spawned a crocodile and flew above it and i tried to spawn a NPC to fight it but then the crocodile started attacking me, then out of nowhere one of those robots came in with that mouth and he killed the crocodile!! It's like a gaurd!!!
I'm the TailsTMM of minetest, in other words, i rock.
BRAAAAAZZZZAAAA!!!!!!!!!!!!!!!!!!!!!!!!!!!
BTW it means TailsTheMeseMinecart, but that isn't my name, it's just a way of saying that i basically do the same thing Dantdm does but i do it with minetest And you problably can't see the invisible ink.
My mods:
My first mod:tails_boss

Mob_pack now has voice acting! Do you want YOUR VOICE included? Look in my posts for the thread!

lincy
Member
Posts: 46
Joined: Tue Dec 29, 2015 19:37
Location: Taipei, Taiwan, R.O.C.

Re: [Mod] aclean 2.1 (vacuum cleaner robot)

by lincy » Post

when try to test some drop items.
server was crash ...
2016-02-21 16:50:36: ERROR[main]: UNRECOVERABLE error occurred. Stopping server. Please fix the following error:
2016-02-21 16:50:36: ERROR[main]: Lua: Runtime error from mod '*builtin*' in callback luaentity_Step(): Double fault error from mod '*builtin*' in callback luaentity_Punch(): error in error handling
2016-02-21 16:50:36: ERROR[main]: stack traceback:
2016-02-21 16:50:36: ERROR[main]: [C]: in function 'punch'
2016-02-21 16:50:36: ERROR[main]: /usr/share/games/minetest/mods/aclean/init.lua:374: in function </usr/share/games/minetest/mods/aclean/init.lua:346>

In thread 7f401059f780:
/build/minetest-_pkXwf/minetest-0.4.13+repack/src/server.cpp:511: void Server::step(float): A fatal error occurred: Lua: Runtime error from mod '*builtin*' in callback luaentity_Step(): Double fault error from mod '*builtin*' in callback luaentity_Punch(): error in error handling
stack traceback:
[C]: in function 'punch'
/usr/share/games/minetest/mods/aclean/init.lua:374: in function </usr/share/games/minetest/mods/aclean/init.lua:346>
Debug stacks:
DEBUG STACK FOR THREAD 7f4001acc700:
#0 virtual void* EmergeThread::Thread()
(Leftover data: #1 MapBlock* ServerMap::loadBlock(v3s16))
(Leftover data: #2 void ServerMap::loadBlock(std::__cxx11::string*, v3s16, MapSector*, bool))
(Leftover data: #3 void ItemStack::deSerialize(std::istream&, IItemDefManager*))
DEBUG STACK FOR THREAD 7f4003fff700:
#0 virtual void* ServerThread::Thread()
#1 void Server::Receive()
(Leftover data: #2 void Server::SendBlocks(float))
(Leftover data: #3 void RemoteClient::GetNextBlocks(ServerEnvironment*, EmergeManager*, float, std::vector<PrioritySortedBlockTransfer>&))
(Leftover data: #4 void ItemStack::serialize(std::ostream&) const)
(Leftover data: #5 bool getCraftingResult(Inventory*, ItemStack&, std::vector<ItemStack>&, bool, IGameDef*))
(Leftover data: #6 void ItemStack::deSerialize(std::istream&, IItemDefManager*))
DEBUG STACK FOR THREAD 7f401059f780:
#0 int main(int, char**)
#1 Dedicated server branch
#2 void dedicated_server_loop(Server&, bool&)
#3 void Server::step(float)
any idea ?

User avatar
AiTechEye
Member
Posts: 1002
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] aclean 2.1Rfix (vacuum cleaner robot)

by AiTechEye » Post

Looks like it tried to change the health on a void object ... fixed!

lincy
Member
Posts: 46
Joined: Tue Dec 29, 2015 19:37
Location: Taipei, Taiwan, R.O.C.

Re: [Mod] aclean 2.1Rfix (vacuum cleaner robot)

by lincy » Post

UjEdwin wrote:Looks like it tried to change the health on a void object ... fixed!
Thanks your help.
After apply the FIX version. I get this log when restart server
2016-02-22 01:41:54: ERROR[main]: ========== ERROR FROM LUA ===========
2016-02-22 01:41:54: ERROR[main]: Failed to load and run script from
2016-02-22 01:41:54: ERROR[main]: /usr/share/games/minetest/mods/aclean/init.lua:
2016-02-22 01:41:54: ERROR[main]: /usr/share/games/minetest/mods/aclean/init.lua:372: 'then' expected near ')'
2016-02-22 01:41:54: ERROR[main]: ======= END OF ERROR FROM LUA ========
2016-02-22 01:41:54: ERROR[main]: Server: Failed to load and run /usr/share/games/minetest/mods/aclean/init.lua
So, I try to change the code of line 372 from

Code: Select all

                 if math.sqrt((pos.x-o.x)*(pos.x-o.x) + (pos.y-o.y)*(pos.y-o.y)+(pos.z-o.z)*(pos.z-o.z)) <=0.4
                        and (self.target:is_player() or self.target:get_luaentity())) then
to

Code: Select all

                 if math.sqrt((pos.x-o.x)*(pos.x-o.x) + (pos.y-o.y)*(pos.y-o.y)+(pos.z-o.z)*(pos.z-o.z)) <=0.4
                        and (self.target:is_player() or self.target:get_luaentity()) then
after restart server an test it. still same result ..
2016-02-22 01:51:53: ERROR[main]: UNRECOVERABLE error occurred. Stopping server. Please fix the following error:
2016-02-22 01:51:53: ERROR[main]: Lua: Runtime error from mod '*builtin*' in callback luaentity_Step(): Double fault error from mod '*builtin*' in callback luaentity_Punch(): error in error handling
2016-02-22 01:51:53: ERROR[main]: stack traceback:
2016-02-22 01:51:53: ERROR[main]: [C]: in function 'punch'
2016-02-22 01:51:53: ERROR[main]: /usr/share/games/minetest/mods/aclean/init.lua:375: in function </usr/share/games/minetest/mods/aclean/init.lua:346>

In thread 7f8cfd58e780:
/build/minetest-_pkXwf/minetest-0.4.13+repack/src/server.cpp:511: void Server::step(float): A fatal error occurred: Lua: Runtime error from mod '*builtin*' in callback luaentity_Step(): Double fault error from mod '*builtin*' in callback luaentity_Punch(): error in error handling
stack traceback:
[C]: in function 'punch'
/usr/share/games/minetest/mods/aclean/init.lua:375: in function </usr/share/games/minetest/mods/aclean/init.lua:346>
Debug stacks:
DEBUG STACK FOR THREAD 7f8cf4fe7700:
#0 virtual void* EmergeThread::Thread()
(Leftover data: #1 MapBlock* ServerMap::loadBlock(v3s16))
(Leftover data: #2 void ServerMap::loadBlock(std::__cxx11::string*, v3s16, MapSector*, bool))
(Leftover data: #3 void ItemStack::deSerialize(std::istream&, IItemDefManager*))
DEBUG STACK FOR THREAD 7f8cf57e8700:
#0 virtual void* ServerThread::Thread()
#1 void Server::Receive()
(Leftover data: #2 void Server::SendBlocks(float))
(Leftover data: #3 void RemoteClient::GetNextBlocks(ServerEnvironment*, EmergeManager*, float, std::vector<PrioritySortedBlockTransfer>&))
(Leftover data: #4 void ItemStack::serialize(std::ostream&) const)
(Leftover data: #5 bool getCraftingResult(Inventory*, ItemStack&, std::vector<ItemStack>&, bool, IGameDef*))
DEBUG STACK FOR THREAD 7f8cfd58e780:
#0 int main(int, char**)
#1 Dedicated server branch
#2 void dedicated_server_loop(Server&, bool&)
#3 void Server::step(float)

User avatar
AiTechEye
Member
Posts: 1002
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] aclean 2.1 Refix2 (vacuum cleaner robot)

by AiTechEye » Post

it was a ) too much in the if-block, fixed

lincy
Member
Posts: 46
Joined: Tue Dec 29, 2015 19:37
Location: Taipei, Taiwan, R.O.C.

Re: [Mod] aclean 2.1 Refix2 (vacuum cleaner robot)

by lincy » Post

UjEdwin wrote:it was a ) too much in the if-block, fixed
already download the new refix2 version. same error message. Sorry ....

Code: Select all

2016-02-23 04:30:17: ERROR[main]: ========== ERROR FROM LUA ===========
2016-02-23 04:30:17: ERROR[main]: Failed to load and run script from 
2016-02-23 04:30:17: ERROR[main]: /usr/share/games/minetest/mods/aclean/init.lua:
2016-02-23 04:30:17: ERROR[main]: /usr/share/games/minetest/mods/aclean/init.lua:372: 'then' expected near ')'
2016-02-23 04:30:17: ERROR[main]: ======= END OF ERROR FROM LUA ========
2016-02-23 04:30:17: ERROR[main]: Server: Failed to load and run /usr/share/games/minetest/mods/aclean/init.lua
I have remove the last ")" from line 372 and restart server. server work. But crash when I try to drop an cobblestone to test it ......

User avatar
AiTechEye
Member
Posts: 1002
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] aclean 2.1 Refix3 (vacuum cleaner robot)

by AiTechEye » Post

If it keep crashing, it's nothing i can do right now (it works fine in windows)

This is a unstable mod, and the only way to clear all problems is to start from beginning... something I didn't do voluntarily :-)

User avatar
mahmutelmas06
Member
Posts: 367
Joined: Mon Mar 02, 2015 13:10
GitHub: mahmutelmas06
IRC: mahmutelmas06
In-game: masum

Re: [Mod] aclean 2.1 Refix3 (vacuum cleaner robot)

by mahmutelmas06 » Post

maybe it could clean unknown objects :)
My Mods:

Beverage

lincy
Member
Posts: 46
Joined: Tue Dec 29, 2015 19:37
Location: Taipei, Taiwan, R.O.C.

Re: [Mod] aclean 2.1 Refix3 (vacuum cleaner robot)

by lincy » Post

UjEdwin wrote:If it keep crashing, it's nothing i can do right now (it works fine in windows)

This is a unstable mod, and the only way to clear all problems is to start from beginning... something I didn't do voluntarily :-)
It's ok... :Q

User avatar
AiTechEye
Member
Posts: 1002
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] aclean 2.1 Refix3 (vacuum cleaner robot)

by AiTechEye » Post

mahmutelmas06 wrote:maybe it could clean unknown objects :)
It can eat all objects (entities) even the most powerful mobs have no chance to beat it, the only way to kill it is to remove its base (the node) then it cant respawn.

It can also clone it self when it detect many objects at same time (on spawn)

ok, i will examine the code (soon) to try to fix all the problems, I have ideas about what it could be.

User avatar
Hybrid Dog
Member
Posts: 2856
Joined: Thu Nov 01, 2012 12:46
GitHub: HybridDog

by Hybrid Dog » Post

After it cloned itself, does it eat its clone?

‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪

User avatar
AiTechEye
Member
Posts: 1002
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] vacuum cleaner robot 1.5 [aclean]

by AiTechEye » Post

They returning to the base and disappear, then when the base not finding some of the bots it replacing the node (to that white one), so it can respawn :-)

I checked the code and added a few extra checks in the "for loops", replaced all the ":remove()" with ":set_hp(0)" and ":punch()" because attached objects have a tendency to crash with it.

If you still have problems with crashs, this maybe will be better

User avatar
azekill_DIABLO
Member
Posts: 7507
Joined: Wed Oct 29, 2014 20:05
GitHub: azekillDIABLO
In-game: azekill_DIABLO
Location: OMICRON
Contact:

Re: [Mod] vacuum cleaner robot 1.5 [aclean]

by azekill_DIABLO » Post

Nice mod!

you should do more of them!(robots)
Gone, but not dead. Contact me on discord: azekill_DIABLO#6565
DMs are always open if you want to get in touch!

User avatar
AiTechEye
Member
Posts: 1002
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] vacuum cleaner robot 1.6 [aclean]

by AiTechEye » Post

if i had more time, i would make a subgame, that would be pretty technical. but it seems to be a really big job. like the default mod need at least 80 textures to generally work with other mods.

blackmart12
New member
Posts: 1
Joined: Thu Dec 13, 2018 13:14

Re: [Mod] vacuum cleaner robot 1.6 [aclean]

by blackmart12 » Post

Well! this is the best idea project to work on! I am also thinking to work on the same concept any further leads are available here to proceed further or anyone is here to join me to replicate or have any suggestion for me. Would like to hear from you people
Deebot M80 Review
high-end room cleaner

Post Reply

Who is online

Users browsing this forum: No registered users and 8 guests