Forums WoW Modding Support Archives Azerothcore Discord Archives [DiscordArchive] So I'm looking at this page:

[DiscordArchive] So I'm looking at this page:

[DiscordArchive] So I'm looking at this page:

Pages (2): 1 2 Next
rektbyfaith
Administrator
0
06-09-2023, 08:50 PM
#1
Archived author: ritzmenardi • Posted: 2023-06-09T20:50:45.907000+00:00
Original source

So I'm looking at this page:
https://www.azerothcore.org/wiki/create-a-module
and it shows you how to create a new script module. But in this case I'm trying to *edit* a script - how would I do that? Should I just copy the script I want to edit from the core, change it, and then... will it update the base script with my changes? Or should I only include the functions I want to change?
rektbyfaith
06-09-2023, 08:50 PM #1

Archived author: ritzmenardi • Posted: 2023-06-09T20:50:45.907000+00:00
Original source

So I'm looking at this page:
https://www.azerothcore.org/wiki/create-a-module
and it shows you how to create a new script module. But in this case I'm trying to *edit* a script - how would I do that? Should I just copy the script I want to edit from the core, change it, and then... will it update the base script with my changes? Or should I only include the functions I want to change?

rektbyfaith
Administrator
0
06-09-2023, 08:51 PM
#2
Archived author: Honey • Posted: 2023-06-09T20:51:51.644000+00:00
Original source

To change a script, you need to use a hook inside the script.
Hooks pass the execution to a module and once the module is done the core takes back control.
rektbyfaith
06-09-2023, 08:51 PM #2

Archived author: Honey • Posted: 2023-06-09T20:51:51.644000+00:00
Original source

To change a script, you need to use a hook inside the script.
Hooks pass the execution to a module and once the module is done the core takes back control.

rektbyfaith
Administrator
0
06-09-2023, 08:52 PM
#3
Archived author: Honey • Posted: 2023-06-09T20:52:06.293000+00:00
Original source

If there's no hook in the spot you need, you can add one.
rektbyfaith
06-09-2023, 08:52 PM #3

Archived author: Honey • Posted: 2023-06-09T20:52:06.293000+00:00
Original source

If there's no hook in the spot you need, you can add one.

rektbyfaith
Administrator
0
06-09-2023, 08:53 PM
#4
Archived author: ritzmenardi • Posted: 2023-06-09T20:53:15.501000+00:00
Original source

Hmmmm, I see. My understanding was that we shouldn't edit files in the core because they'll be overwritten when updates are released. I'll look into creating hooks, maybe they answer that (implicit) question.
rektbyfaith
06-09-2023, 08:53 PM #4

Archived author: ritzmenardi • Posted: 2023-06-09T20:53:15.501000+00:00
Original source

Hmmmm, I see. My understanding was that we shouldn't edit files in the core because they'll be overwritten when updates are released. I'll look into creating hooks, maybe they answer that (implicit) question.

rektbyfaith
Administrator
0
06-09-2023, 08:53 PM
#5
Archived author: Honey • Posted: 2023-06-09T20:53:58.498000+00:00
Original source

That's exactly what modules are for
rektbyfaith
06-09-2023, 08:53 PM #5

Archived author: Honey • Posted: 2023-06-09T20:53:58.498000+00:00
Original source

That's exactly what modules are for

rektbyfaith
Administrator
0
06-09-2023, 08:54 PM
#6
Archived author: ritzmenardi • Posted: 2023-06-09T20:54:40.613000+00:00
Original source

That makes sense to me! Also this page is much more informative than the one I was looking at before:
https://www.azerothcore.org/wiki/hooks-script
rektbyfaith
06-09-2023, 08:54 PM #6

Archived author: ritzmenardi • Posted: 2023-06-09T20:54:40.613000+00:00
Original source

That makes sense to me! Also this page is much more informative than the one I was looking at before:
https://www.azerothcore.org/wiki/hooks-script

rektbyfaith
Administrator
0
06-09-2023, 09:06 PM
#7
Archived author: Revision • Posted: 2023-06-09T21:06:49.179000+00:00
Original source

Hooks are just code added to the core to allow modules to perform actions without actually modifying the core. Frankly there's nothing wrong with modifying the core. There may be conflicts later down the road but those can be resolved. Your code wouldn't be overwritten though.
rektbyfaith
06-09-2023, 09:06 PM #7

Archived author: Revision • Posted: 2023-06-09T21:06:49.179000+00:00
Original source

Hooks are just code added to the core to allow modules to perform actions without actually modifying the core. Frankly there's nothing wrong with modifying the core. There may be conflicts later down the road but those can be resolved. Your code wouldn't be overwritten though.

rektbyfaith
Administrator
0
06-09-2023, 09:07 PM
#8
Archived author: Revision • Posted: 2023-06-09T21:07:13.430000+00:00
Original source

Obviously hooks added to the core tends to be the better option, most of the time at least.
rektbyfaith
06-09-2023, 09:07 PM #8

Archived author: Revision • Posted: 2023-06-09T21:07:13.430000+00:00
Original source

Obviously hooks added to the core tends to be the better option, most of the time at least.

rektbyfaith
Administrator
0
06-09-2023, 09:14 PM
#9
Archived author: ritzmenardi • Posted: 2023-06-09T21:14:34.286000+00:00
Original source

This looks too complicated for me right now. I'm going to try and accomplish as much as I can with Eluna before I dive into the C++
rektbyfaith
06-09-2023, 09:14 PM #9

Archived author: ritzmenardi • Posted: 2023-06-09T21:14:34.286000+00:00
Original source

This looks too complicated for me right now. I'm going to try and accomplish as much as I can with Eluna before I dive into the C++

rektbyfaith
Administrator
0
06-09-2023, 09:16 PM
#10
Archived author: Honey • Posted: 2023-06-09T21:16:50.480000+00:00
Original source

You'll try C++ when you bump your head into something Eluna can't do. Then add it to Eluna.
Trust me, i've been there.
rektbyfaith
06-09-2023, 09:16 PM #10

Archived author: Honey • Posted: 2023-06-09T21:16:50.480000+00:00
Original source

You'll try C++ when you bump your head into something Eluna can't do. Then add it to Eluna.
Trust me, i've been there.

Pages (2): 1 2 Next
Recently Browsing
 1 Guest(s)
Recently Browsing
 1 Guest(s)