Cunning fox Posted January 16, 2017 Share Posted January 16, 2017 Heya! I need somehow to make mod, that'll be able to read gow many days each player survived, and then give him some tag. It should be like that: if days_survived == 10 then inst.AddTag("SomeTag") end But I realy don't know how to do it. Any ideas? I can give you elegant skin, if you'll help me! 1 Link to comment https://forums.kleientertainment.com/forums/topic/73413-need-some-help-with-survived_days/ Share on other sites More sharing options...
returnofblank Posted January 16, 2017 Share Posted January 16, 2017 (edited) Just press tab in a server and it will tell you how many days each player survived in total. I don't know about the tag though. Edited January 16, 2017 by Ryan9004 Link to comment https://forums.kleientertainment.com/forums/topic/73413-need-some-help-with-survived_days/#findComment-858754 Share on other sites More sharing options...
Cunning fox Posted January 16, 2017 Author Share Posted January 16, 2017 30 minutes ago, Ryan9004 said: Just press tab in a server and it will tell you how many days each player survived in total. I don't know about the tag though. I'm making mod -_- 1 Link to comment https://forums.kleientertainment.com/forums/topic/73413-need-some-help-with-survived_days/#findComment-858759 Share on other sites More sharing options...
Aquaterion Posted January 16, 2017 Share Posted January 16, 2017 try looking in data/scripts/components/age.lua it has functions that return the age of the player Link to comment https://forums.kleientertainment.com/forums/topic/73413-need-some-help-with-survived_days/#findComment-858768 Share on other sites More sharing options...
zUsername Posted January 16, 2017 Share Posted January 16, 2017 ThePlayer.components.age.GetDisplayAgeInDays() Link to comment https://forums.kleientertainment.com/forums/topic/73413-need-some-help-with-survived_days/#findComment-858769 Share on other sites More sharing options...
Cunning fox Posted January 16, 2017 Author Share Posted January 16, 2017 (edited) 19 minutes ago, zUsername said: ThePlayer.components.age.GetDisplayAgeInDays() So it should look like that? local days_survived = ThePlayer.components.age.GetDisplayAgeInDays() right? Edited January 16, 2017 by makar5000 1 Link to comment https://forums.kleientertainment.com/forums/topic/73413-need-some-help-with-survived_days/#findComment-858774 Share on other sites More sharing options...
Aquaterion Posted January 16, 2017 Share Posted January 16, 2017 it would be: local days_survived = inst.components.age:GetDisplayAgeInDays() Link to comment https://forums.kleientertainment.com/forums/topic/73413-need-some-help-with-survived_days/#findComment-858775 Share on other sites More sharing options...
Cunning fox Posted January 17, 2017 Author Share Posted January 17, 2017 14 hours ago, Aquaterion said: it would be: local days_survived = inst.components.age:GetDisplayAgeInDays() Thanks! Give me your trade link, and i'll give you reward! 1 Link to comment https://forums.kleientertainment.com/forums/topic/73413-need-some-help-with-survived_days/#findComment-858952 Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now