Author | Message | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ![]() Hello, everybody. I am re-releasing this code because it now reads from pub files. First Go to character.hpp find short karma; add under it short boost, tick; Done with that. Go to world.cpp find event = new TimeEvent(world_recover, this, 90.0, Timer::FOREVER); this->timer.Register(event); event->Release(); add under it event = new TimeEvent(world_boost, this, 10.0, Timer::FOREVER); this->timer.Register(event); event->Release(); find void world_act_npcs(void *world_void) { World *world(static_cast<World *>(world_void)); double current_time = Timer::GetTime(); UTIL_PTR_VECTOR_FOREACH(world->maps, Map, map) { UTIL_PTR_VECTOR_FOREACH(map->npcs, NPC, npc) { if (npc->alive && npc->last_act + npc->act_speed < current_time) { npc->Act(); } } } } add under it
Done with world.cpp
Go to item.cpp
find
case EIF::Heal
{
done with item.cpp
Goto character.cpp
and follow these instructions
Then add database values
short and tick of the INTEGER type
done with this stuff
How to use:
Open your item file with Pub Edit
Make the items type 3
Change the str, con, agi, etc values to the numbers you want the potion to boost by
Change the acc to the amount of time you want the potion to last (1 = 10 seconds)
If I forgot anything or something is not working post here. Thanks again.
--- Love you too.
|
| ![]() Pretty awesome job!
|
| ![]() Thank you! First reply :P --- Love you too.
|
| ![]() I'm sorry, i also tested it out yesterday, works fine ^^ just forgot to reply D: --- Skype: izumibluuh I sincerely apologize for my posts from when I was 12.
|
| ![]() Right.. The item type is 3 (Potion) but that doesnt allow you to edit str,con ect..
|
| ![]() Use pub edit instead of edit pub. Don't be so negative jesus :/ --- Love you too.
|
| ![]() Im using that bro. And im not negative :o
|
| ![]() If your program isnt letting you edit it you are using the wrong one. Using Pub Edit. It should look like this:http://tinypic.com/r/28b4syd/7 --- Love you too.
|
| ![]() Sorry for blaming ur code, My serv was just fucked up but uhh... You didnt say in your release to add: this->boost, this->tick, this->karma, this->boost, this->tick, this->karma, this->boost, this->tick, this->sitting,
|
| ![]()
|
| ![]() hello i am a noob but where can i find these "character.cpp" files and "world.cpp" hpp and all that?
Now that I think, is it in the Data? But how do i open the Data files?
|
| ![]() LegendaryG posted: (2nd Nov 2012, 01:49 am) You'd better use this one: Click Me. It's made by Ryouken, I suppose it's more advanced than this one. |