V1N1C1U5 Posted December 23, 2022 Share Posted December 23, 2022 I ask to chat gpt to make an npc to heal and give buff to near players, this is the result: #include <stdio.h> #include <unistd.h> // Função para obter jogadores próximos Player* get_nearby_players(int* num_players) { // Código para obter jogadores próximos return players; } // Função para curar jogadores void heal_players(Player* players, int num_players) { for (int i = 0; i < num_players; i++) { // Código para curar o jogador players[i].health = players[i].max_health; } } // Função para dar buff nos jogadores void buff_players(Player* players, int num_players) { for (int i = 0; i < num_players; i++) { // Código para adicionar um buff ao jogador players[i].buffs |= BUFF_ID; } } int main() { while (1) { int num_players; // Obter jogadores próximos Player* players = get_nearby_players(&num_players); // Curar jogadores heal_players(players, num_players); // Dar buff nos jogadores buff_players(players, num_players); // Pausar por alguns segundos antes de executar novamente sleep(5); } return 0; } Now my question to u guys, this gonna work in emulator? Quote Link to comment Share on other sites More sharing options...
peterl Posted December 25, 2022 Share Posted December 25, 2022 If you mean an "rAthena NPC script" I guess this won't work. The code you've shown above only seems like some C style code rather than rAthena script. 1 Quote Link to comment Share on other sites More sharing options...