Author | Message | ||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ![]() EDIT: During the fact of people being not able to call there work. I figured I should remove my snippets of code. Though if you want the harvest system. Go look somewhere else on this forum or contact me. I got my harvest system cracked up a bit. Lets get started!
###### We go to src\world.hpp. Scroll down a bit and you will see the Config files as in; Config admin_config; Place under formulas the followed line; Config harvs_config; Done with world.hpp! ###### We go to src\world.cpp. We search for; this->formulas_config.Read(static_cast<std::string>(this->config["FormulasFile"])); And place under that line; <Code removed> Make it yourself ^^
this->formulas_config.Read(this->config["FormulasFile"]); Place under that line; <Code removed> Make it yourself ^^ Done with world.cpp! ###### We go to src\handlers\attack.cpp. We search for; this->player->character->Attack(direction); Place under that line; <Code removed> Make it yourself ^^ Which is harvesting. Done with attack.cpp! ###### Go to you config.ini (Which is located inside your trunk) Search for; FormulasFile = ./data/formulas.ini Place under that line (Do space it up a bit); <Code removed> Make it yourself ^^ Then save the config file. Done with the config.ini! ###### Go to the data folder (located in your trunk). Now you can do a few things of adding a new .ini file. 1. Copy and paste lets say arena.ini and rename it to harvs.ini then clear the file. Now when you got this file delete (if you copied arena.ini) the lines and add; (File explains what things do) Done with the harvs.ini! Now once we all done this, Compile the source and test it out! --- "Pineapples and shit."
|
| ![]() yo i added it but do you need to have a special weapon or something to harvest? --- Live and let live. Hurt but do not kill. Finish what you start. NEVER GIVE UP!!!
|
| ![]()
--- "Pineapples and shit."
|
| ![]() OK i compiled it, but then when i go into the game, Nothing happens i think i sat there and hit it like 500 times and it still didnt give me anything :/ P.S. It compiled fine, but i got 3 warnings from Attack.cpp --- Create your own destiny, don't let someone else do it for you.
|
| ![]()
--- "Pineapples and shit."
|
| ![]() ok here are the warnings -------------- Build: MYSQL+SQLITE in eoserv --------------- Compiling: ..\src\guild.cpp Compiling: ..\src\handlers\Account.cpp Compiling: ..\src\handlers\AdminInteract.cpp Compiling: ..\src\handlers\Bank.cpp Compiling: ..\src\handlers\Barber.cpp Compiling: ..\src\handlers\Board.cpp Compiling: ..\src\handlers\Book.cpp Compiling: ..\src\handlers\Chair.cpp Compiling: ..\src\handlers\Character.cpp Compiling: ..\src\handlers\Chest.cpp Compiling: ..\src\handlers\Citizen.cpp Compiling: ..\src\handlers\Connection.cpp Compiling: ..\src\arena.cpp Compiling: ..\src\handlers\Emote.cpp Compiling: ..\src\handlers\Face.cpp Compiling: ..\src\handlers\Global.cpp Compiling: ..\src\handlers\Guild.cpp Compiling: ..\src\handlers\Init.cpp Compiling: ..\src\handlers\Internal.cpp Compiling: ..\src\handlers\Item.cpp Compiling: ..\src\handlers\Jukebox.cpp Compiling: ..\src\handlers\Locker.cpp Compiling: ..\src\handlers\Login.cpp Compiling: ..\src\handlers\Paperdoll.cpp Compiling: ..\src\handlers\Party.cpp Compiling: ..\src\handlers\Ping.cpp Compiling: ..\src\handlers\Players.cpp Compiling: ..\src\handlers\Refresh.cpp Compiling: ..\src\handlers\Shop.cpp Compiling: ..\src\handlers\Sit.cpp Compiling: ..\src\handlers\StatSkill.cpp Compiling: ..\src\handlers\Talk.cpp Compiling: ..\src\handlers\Trade.cpp Compiling: ..\src\handlers\Walk.cpp Compiling: ..\src\handlers\Warp.cpp Compiling: ..\src\handlers\Welcome.cpp Compiling: ..\src\handlers\Door.cpp Compiling: ..\src\main.cpp C:\Users\Austin\Desktop\Flash drive\trunk\src\main.cpp: In function 'int main(int, char**)': C:\Users\Austin\Desktop\Flash drive\trunk\src\main.cpp:548: warning: 'active_clients' may be used uninitialized in this function Compiling: ..\src\map.cpp C:\Users\Austin\Desktop\Flash drive\trunk\src\map.cpp: In member function 'void Map::LoadArena()': C:\Users\Austin\Desktop\Flash drive\trunk\src\map.cpp:278: warning: 's' may be used uninitialized in this function Compiling: ..\src\npc.cpp Compiling: ..\src\party.cpp Compiling: ..\src\player.cpp Compiling: ..\src\scriptreg.cpp C:\Users\Austin\Desktop\Flash drive\trunk\src\scriptreg.cpp:43: warning: 'script_DEBUG' defined but not used Compiling: ..\src\sln.cpp Linking console executable: ..\eoserv.exe Output size is 2.12 MB Process terminated with status 0 (1 minutes, 38 seconds) 0 errors, 3 warnings
--- Create your own destiny, don't let someone else do it for you.
|
| ![]()
--- "Pineapples and shit."
|
| ![]() Yea i added it, and heres my Harvs.ini ### Ananas Harvest System ### # Version 1.0 # # Location syntax; # (int).map = (mapid) # (int).x = (xloc) # (int).y = (yloc) # The Harvested Item ID ItemID = 11 # Amount of items being gained. ItemAmount = 1 # Amount of locations LocationAmount = 2 # First location 1.map = 9 1.x = 29 1.y = 29 # Second Location 2.map = 5 2.x = 40 2.y = 47 # (etc) On my server item 11 is a egg so i want harvesting to be able to give them pets. and btw could i use this for fishing also? --- Create your own destiny, don't let someone else do it for you.
|
| ![]()
--- "Pineapples and shit."
|
| ![]() oh your supposed to stand on it? lol i was attacking it yea ok when i stand on it it works now, but how do you make it so the item doesnt come up right away? like so everytime you attack it doesnt come up --- Create your own destiny, don't let someone else do it for you.
|
| ![]()
--- "Pineapples and shit."
|
| ![]() yea i yea i want the relay so ill just mess around and try to get it, :] --edit-- Ok, I can't seem to figure it out Lmao, Help me a little? --- Create your own destiny, don't let someone else do it for you.
|
| ![]() I like it nice job.! --- CN:BH 4 lyfe
|
| ![]() hey i got these 2 errors:
does maybe someone know what these 2 errors could be? --- opensource isometric game engine ~ www.avac-engine.blogspot.com
|
| ![]()
###### We go to src\world.hpp. Scroll down a bit and you will see the Config files as in; Config admin_config; Place under formulas the followed line; Config harvs_config; Done with world.hpp! ###### We go to src\world.cpp. We search for; this->formulas_config.Read(static_cast<std::string>(this->config["FormulasFile"])); And place under that line; this->harvs_config.Read(static_cast<std::string>(this->config["HarvsFile"]));
this->formulas_config.Read(this->config["FormulasFile"]); Place under that line; this->harvs_config.Read(this->config["HarvsFile"]); Done with world.cpp! ###### We go to src\handlers\attack.cpp. We search for; this->player->character->Attack(direction); Place under that line; int ItemID, ItemA, Map, X, Y; Which is harvesting. Done with attack.cpp! ###### Go to you config.ini (Which is located inside your trunk) Search for; FormulasFile = ./data/formulas.ini Place under that line (Do space it up a bit); ## HarvsFile (string) Then save the config file. Done with the config.ini! ###### Go to the data folder (located in your trunk). Now you can do a few things of adding a new .ini file. 1. Copy and paste lets say arena.ini and rename it to harvs.ini then clear the file. Now when you got this file delete (if you copied arena.ini) the lines and add; https://tehsausage.com/paste/Ananas%20Harvsini (File explains what things do) Done with the harvs.ini! Now once we all done this, Compile the source and test it out! --------------------------------------------------------------------------------------------- Bold: Examples of what I like when I look at a tutorial :] I love it very well done. |