[Mod] Achievements [3.2.0] [awards] – group support

User avatar
hoodedice
Member
 
Posts: 1372
Joined: Sat Jul 06, 2013 06:33
Location: world
GitHub: hoodedice
IRC: hoodedice
In-game: hoodedice

by hoodedice » Wed Nov 20, 2013 10:04

I am in need of a system that can give an achievement on_player_location. Can you do that, rubenwardy?
7:42 PM - Bauglio: I think if you go to staples you could steal firmware from a fax machine that would run better than win10 does on any platform
7:42 PM - Bauglio: so fudge the stable build
7:43 PM - Bauglio: get the staple build
 

User avatar
rubenwardy
Moderator
 
Posts: 5827
Joined: Tue Jun 12, 2012 18:11
Location: United Kingdom
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

by rubenwardy » Wed Nov 20, 2013 18:30

The easy way would be to implement support in privareas for this mod.

The longer way would to be to write a new trigger for on_player_location.
 

User avatar
hoodedice
Member
 
Posts: 1372
Joined: Sat Jul 06, 2013 06:33
Location: world
GitHub: hoodedice
IRC: hoodedice
In-game: hoodedice

by hoodedice » Wed Nov 20, 2013 19:43

rubenwardy wrote:The easy way would be to implement support in privareas for this mod.

The longer way would to be to write a new trigger for on_player_location.


If only I knew how exactly to implement that...
7:42 PM - Bauglio: I think if you go to staples you could steal firmware from a fax machine that would run better than win10 does on any platform
7:42 PM - Bauglio: so fudge the stable build
7:43 PM - Bauglio: get the staple build
 

User avatar
BrunoMine
Member
 
Posts: 1048
Joined: Thu Apr 25, 2013 17:29
Location: SP-Brasil
GitHub: BrunoMine

by BrunoMine » Sat Dec 07, 2013 15:29

I believe that you should create a prettier interface. Something like a book of adventure, in which the player can see a description of their duties. Only acro would be a good idea.
My small square universe under construction ... Minemacro
Comunidade Minetest Brasil
www.minetestbrasil.com
 

1704626
Member
 
Posts: 87
Joined: Thu Jan 02, 2014 22:52
Location: mushroom biome

by 1704626 » Wed Feb 05, 2014 01:11

U SHOULD ADD CUTCENES TO THIS MOD
PS DID U HEAR ABOUT THE RE ADDED DUNGEON MASTER U SHOULD MAKE A ACHIEVEMENT FOR SLAYING IT
Just Call Me Numbers
 

4aiman
Member
 
Posts: 1208
Joined: Mon Jul 30, 2012 05:47

by 4aiman » Fri Mar 07, 2014 15:57

I made this while being absent.
 

User avatar
rubenwardy
Moderator
 
Posts: 5827
Joined: Tue Jun 12, 2012 18:11
Location: United Kingdom
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

Re: [Mod] Achievements [0.3] [awards]

by rubenwardy » Fri May 02, 2014 19:20

0.4 Released



Image

This is the first half of my coding sprint. Tomorrow I will release more changes.

New Features
  • Awards menu listing all awards.

New Awards
  • Join a server.
  • First Word - use the chat to talk to other players.

API Changes
  • Added on chat trigger.
  • Added on join trigger.
  • Added support for secret mods (hidden in awards list until unlocked).
  • Added support for creating triggers outside the mod.
 

robotest
Member
 
Posts: 11
Joined: Tue Jul 23, 2013 00:12

Re: [Mod] Achievements [0.4] [awards] - awards menu

by robotest » Sat May 03, 2014 01:17

I get this error when i try to click on another achievement in the list:
Code: Select all
21:10:03: ERROR[main]: ServerError: ...minetest-0.4.9\bin\..\games\robotest\mods\awards/api.lua:415: attempt to call field 'explode_textlist_event' (a nil value)
21:10:03: ERROR[main]: stack traceback:
21:10:03: ERROR[main]:    ...minetest-0.4.9\bin\..\games\robotest\mods\awards/api.lua:415: in function <...minetest-0.4.9\bin\..\games\robotest\mods\awards/api.lua:406>
21:10:03: ERROR[main]:    ...st-0.4.7\minetest-0.4.9\bin\..\builtin/misc_register.lua:330: in function <...st-0.4.7\minetest-0.4.9\bin\..\builtin/misc_register.lua:318>
 

bajanhgk
Member
 
Posts: 75
Joined: Sun Apr 06, 2014 16:31
Location: The World Of Darkness
In-game: bajanhgk

Re: [Mod] Achievements [0.4] [awards] - awards menu

by bajanhgk » Sat May 03, 2014 11:39

rubenwardy wrote:First mese find - dig 1 mese
Just a Loner In the Winds which Blow Endlessly towards Death
 

4aiman
Member
 
Posts: 1208
Joined: Mon Jul 30, 2012 05:47
 

User avatar
Krock
Developer
 
Posts: 4365
Joined: Thu Oct 03, 2013 07:48
Location: Switzerland
GitHub: SmallJoker

Re: [Mod] Achievements [0.4] [awards] - awards menu

by Krock » Sat May 03, 2014 16:04

robotest wrote:I get this error when i try to click on another achievement in the list:
Code: Select all
21:10:03: ERROR[main]: ServerError: ...minetest-0.4.9\bin\..\games\robotest\mods\awards/api.lua:415: attempt to call field 'explode_textlist_event' (a nil value)
21:10:03: ERROR[main]: stack traceback:
21:10:03: ERROR[main]:    ...minetest-0.4.9\bin\..\games\robotest\mods\awards/api.lua:415: in function <...minetest-0.4.9\bin\..\games\robotest\mods\awards/api.lua:406>
21:10:03: ERROR[main]:    ...st-0.4.7\minetest-0.4.9\bin\..\builtin/misc_register.lua:330: in function <...st-0.4.7\minetest-0.4.9\bin\..\builtin/misc_register.lua:318>

viewtopic.php?p=140109#p140109

EDIT: I invested my 1000th post for you!
Last edited by Krock on Sat May 03, 2014 17:46, edited 1 time in total.
>> Mod Search Engine << - Mods by Krock - DuckDuckGo mod search bang: !mtmod <keyword here>
 

User avatar
rubenwardy
Moderator
 
Posts: 5827
Joined: Tue Jun 12, 2012 18:11
Location: United Kingdom
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

Re: [Mod] Achievements [0.4] [awards] - awards menu

by rubenwardy » Sat May 03, 2014 17:12

4aiman wrote:Neat :)
Any chance prerequisites would be shown?


A progress bar will be added in the next version, but the description should explain what to do.
 

User avatar
kaeza
Moderator
 
Posts: 2162
Joined: Thu Oct 18, 2012 05:00
Location: Montevideo, Uruguay
GitHub: kaeza
IRC: kaeza diemartin blaaaaargh
In-game: kaeza

Re: [Mod] Achievements [0.4] [awards] - awards menu

by kaeza » Sat May 03, 2014 19:53

Request: Use HUD instead of Formspecs.
Suppose you are struggling with a vombie, or worse, a DM, and you place your 100th torch...
Your signature is not the place for a blog post. Please keep it as concise as possible. Thank you!

Check out my stuff! | Donations greatly appreciated! PayPal
 

User avatar
webdesigner97
Member
 
Posts: 1325
Joined: Mon Jul 30, 2012 19:16
Location: Bergisch Gladbach, Germany
GitHub: webD97
IRC: webdesigner97
In-game: webdesigner97

Re: [Mod] Achievements [0.4] [awards] - awards menu

by webdesigner97 » Sat May 03, 2014 20:40

kaeza wrote:Request: Use HUD instead of Formspecs.
Suppose you are struggling with a vombie, or worse, a DM, and you place your 100th torch...

Achievement unlocked: "But I was reading this form!" - Die while reading a formspec :D
 

User avatar
rubenwardy
Moderator
 
Posts: 5827
Joined: Tue Jun 12, 2012 18:11
Location: United Kingdom
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

Re: [Mod] Achievements [0.4] [awards] - awards menu

by rubenwardy » Sun May 04, 2014 11:46

kaeza wrote:Request: Use HUD instead of Formspecs.
Suppose you are struggling with a vombie, or worse, a DM, and you place your 100th torch...


When I made this mod, there were no such things as HUD elements. But I will add them soon.
 

User avatar
minermoder27
Member
 
Posts: 138
Joined: Wed Nov 20, 2013 23:24
Location: Unfortunately, not in Baikonur
GitHub: ZNixian
In-game: minermoder27

Re: [Mod] Achievements [0.4] [awards] - awards menu

by minermoder27 » Mon May 05, 2014 20:42

I have some code that can display awards in a tree, and can find that code for you if you like
 

User avatar
Calinou
Moderator
 
Posts: 3156
Joined: Mon Aug 01, 2011 14:26
Location: Troyes, France
GitHub: Calinou
IRC: Calinou
In-game: Calinou

Re: [Mod] Achievements [0.4] [awards] - awards menu

by Calinou » Tue May 06, 2014 09:21

Carbone implemented this mod, with added achievements and fixes, feel free to take the changes.

https://github.com/Calinou/carbone/tree ... ods/awards
 

4aiman
Member
 
Posts: 1208
Joined: Mon Jul 30, 2012 05:47

Re: [Mod] Achievements [0.4] [awards] - awards menu

by 4aiman » Tue May 06, 2014 22:11

rubenwardy wrote:
4aiman wrote:Neat :)
Any chance prerequisites would be shown?


A progress bar will be added in the next version, but the description should explain what to do.


What I've meant is a way to show a map of achievements of some sort. Like in my version one have to have "Upgrade2" to be able to receive "Upgrade3".

rubenwardy wrote:
kaeza wrote:Request: Use HUD instead of Formspecs.
Suppose you are struggling with a vombie, or worse, a DM, and you place your 100th torch...


When I made this mod, there were no such things as HUD elements. But I will add them soon.

Noooo!!! That'll ruin my fork!!!....
Just kidding, I owe you big time.
I'll be glad to see this develop.

Does your custom triggers support timer-triggered events?
What I mean is the ability to create achievement that'll be unlocked ANYTIME a modder want. Say, I pick up an uranium lump. I't MY duty to start the timer. But is it possible to give an award for a player when MY timer hits some time I have chosen?
Can I use smth like give_award(player, 'Hulk SmAaAAaaaSh!!!')?
Like having some item in the inventory, say, uranium, would)
 

User avatar
rubenwardy
Moderator
 
Posts: 5827
Joined: Tue Jun 12, 2012 18:11
Location: United Kingdom
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

Re: [Mod] Achievements [0.4] [awards] - awards menu

by rubenwardy » Wed May 07, 2014 07:56

4aiman wrote:What I've meant is a way to show a map of achievements of some sort. Like in my version one have to have "Upgrade2" to be able to receive "Upgrade3".


Oh, I see. That is an interesting idea. Currently, you can unlock any achievement as long as you fullfil the requirements. I can functionality that only unlocks an award when a specified set of awards are all unlocked.

For example:
Code: Select all
awards.register_achievement("award_mine3",{
   title = S("Hardened Miner"),
   description = S("You have dug 1000 stone blocks"),
   icon = "miniminer.png",
   background = "bg_mining.png",
   requires = {"award_mine1", "award_mine2"},
   trigger = {
      type = "dig",
      node = "default:stone",
      target = 1000
   }
})


As for displaying this, the awards could be grouped together and only the newest/best awards shown. Or it could be in a tree view like the mod manager. Or it could be in a graphical tree, but that would be hard to do.

4aiman wrote:Does your custom triggers support timer-triggered events?
What I mean is the ability to create achievement that'll be unlocked ANYTIME a modder want. Say, I pick up an uranium lump. I't MY duty to start the timer. But is it possible to give an award for a player when MY timer hits some time I have chosen?
Can I use smth like give_award(player, 'Hulk SmAaAAaaaSh!!!')?
Like having some item in the inventory, say, uranium, would)


You can use:

Code: Select all
awards.give_achievement(name, award)


Where name is the player name, and award is the achievement name. This allows you to register your own triggers.

Also, in order to register table triggers, you can use this: https://github.com/rubenwardy/awards/bl ... pi.lua#L76
The code explains it in a comment.

A table trigger:

Code: Select all
trigger = {
   type = "place",
   node = "default:torch",
   target = 100
}
 

4aiman
Member
 
Posts: 1208
Joined: Mon Jul 30, 2012 05:47

Re: [Mod] Achievements [0.4] [awards] - awards menu

by 4aiman » Wed May 07, 2014 10:49

Aha.. Thanks!
Now I can throw my version away :)

Showing the last one achieved sounds good for me. This way achievements may be not just a list of, well, achievements, but some sort of help to distinguish different ranks:
killed 1 mob = awarded "Soldier"
killed 10 mobs = awarded "Lieutenant"
killed 100 mobs = you're a "General"
killed 1000 mobs = you're a "Commander-in-Chief"
Or smth like this.

Just one more little question: I've looked through the code and feel unsure about this:
Say, I want to add on_craft trigger...
There's no such type of triggers. So, table ones won't do. Am I to use awards.give_achievement() wrapped by my code in my mod?

Other than this, I have to try this new version to be able to ask the right questions for anything else I'm not sure about, I guess.
Great work, rubenwardy! Regards!
 

Amaz
Member
 
Posts: 348
Joined: Wed May 08, 2013 08:26
GitHub: Amaz1
IRC: Amaz
In-game: Amaz

Re: [Mod] Achievements [0.4] [awards] - awards menu

by Amaz » Sat May 17, 2014 21:42

Have you thought about adding support for groups in various awards? For group:wood for one maybe?
And also, what about a craft award? And is their a way to add a way for killing mobs?
I could try to implement the first myself... Sorry for all of the requests!
 

User avatar
rubenwardy
Moderator
 
Posts: 5827
Joined: Tue Jun 12, 2012 18:11
Location: United Kingdom
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

Re: [Mod] Achievements [0.4] [awards] - awards menu

by rubenwardy » Sun May 18, 2014 15:46

Amaz wrote:Have you thought about adding support for groups in various awards? For group:wood for one maybe?
And also, what about a craft award? And is their a way to add a way for killing mobs?
I could try to implement the first myself... Sorry for all of the requests!


I could do that. It would complicate the code. I might have to add a function like:

Code: Select all
awards.watch_node( group or itemname )


to save space in the recording tables. (Don't count if no awards use it).


About the mobs, you could add it. Not sure about the simple mobs or mobf side of it, though.
 

User avatar
Pitriss
Member
 
Posts: 253
Joined: Mon Aug 05, 2013 17:09
Location: Czech republic, Bohumin
GitHub: Pitriss
IRC: pitriss
In-game: pitriss

Re: [Mod] Achievements [0.4] [awards] - awards menu

by Pitriss » Tue May 20, 2014 06:06

Maybe you can add archivements based on time online?
 

4aiman
Member
 
Posts: 1208
Joined: Mon Jul 30, 2012 05:47

Re: [Mod] Achievements [0.4] [awards] - awards menu

by 4aiman » Tue May 20, 2014 07:46

Pitriss wrote:Maybe you can add archivements based on time online?

I think the best way is to depend on Rubenwardy's awards to do things like that.
How 'bout separating API from all achievements? I mean 2 separate mods in a single modpack.
Then the part with achievements only could use a few github pushes.
 

Thedarksoldier
New member
 
Posts: 8
Joined: Mon May 26, 2014 11:12
In-game: subham
 

PreviousNext

Return to Mod Releases



Who is online

Users browsing this forum: MSN [Bot] and 4 guests