Luis C.M
0aa9303f61
IPlayer:
...
-Removed 4 sendMessage functions that can already be done with Minecraft formatted codes.
2022-06-28 01:23:42 -05:00
Luis C.M
37e12b81d0
IPlayer:
...
-Implemented removeItem, removeAllItems, and inventoryItemCount functions with "ignoreNBT" and "ignoreDamage" parameters.
2022-06-28 01:10:38 -05:00
Luis C.M
dd207757ea
IPlayer:
...
-Added disableMouseInput(long time, int... buttonIds) function.
2022-06-13 17:21:02 -05:00
Luis C.M
fd1ac6dce4
Merge KAMKEEL-dev into dev.
2022-06-12 04:23:05 -05:00
Luis C.M
63a1525ee2
API Changes:
...
-Implemented interfaces for all jobs & roles.
ScriptPlayer:
-Added getData() function, which returns player data objects.
IPlayerData: New class that holds all player data for modification.
-Holds dialog, bank, quest, transport, faction, item giver, and mail data.
-Also holds companion data, with functions has/set/getCompanion, and a getCompanionID function to differentiate companions.
2022-06-12 01:26:23 -05:00
1whohears
b18d0965f2
script player.sendMessage uses String as color parameter
2022-05-28 22:53:57 -05:00
Luis C.M
8d4a7ea0b6
More merge fixes
2022-05-27 15:54:12 -05:00
Luis C.M
ec5fc71413
Merge branch 'master' into dev
...
# Conflicts:
# src/main/java/noppes/npcs/scripted/ScriptFaction.java
# src/main/java/noppes/npcs/scripted/ScriptWorld.java
# src/main/java/noppes/npcs/scripted/entity/ScriptNpc.java
# src/main/java/noppes/npcs/scripted/entity/ScriptPlayer.java
# src/main/java/noppes/npcs/scripted/interfaces/IEntity.java
# src/main/java/noppes/npcs/scripted/interfaces/IWorld.java
# src/main/java/noppes/npcs/scripted/interfaces/entity/ICustomNpc.java
# src/main/java/noppes/npcs/scripted/interfaces/entity/IPlayer.java
2022-05-27 15:31:02 -05:00
Luis C.M
301e113be2
Added quest tracking, need to add objectives list and turn in info too.
2022-05-27 14:32:24 -05:00
1whohears
3d02ce3ce0
world.rayCastBlock uses double[] for parameters
2022-05-26 03:04:13 -05:00
1whohears
bc85756476
player.getLookingAtBlock returns IBlock
2022-05-26 01:51:05 -05:00
Luis C.M
2895f7a76a
Removed overridden getDimension() function, and an unused HashMap for skin overlays from ScriptPlayer.
2022-05-26 01:46:38 -05:00
1whohears
a4361b8420
Added various things to the API and other small changes
...
This adds some useful functions to the api and a few other changes.
I had been creating a custom build of this mod while working on stuff because I couldn't figure out how to do certain things without changing the mod. So this is a collection api features that I think everyone would find useful.
Api additions:
-purchase counting, and disabling trades for the trader role. (if a trade is disabled the gui still says insufficient funds, maybe allow a custom message to appear) added get the traders currency items and sell items.
-if an npc's projectile does explosive damage, you can disable it destroying blocks even if mob griefing is on
-int arrays as stored data for entities
-entity.playSound(...)
-get set if npcs can drown
-player read and unread dialog
-player set faction points
-extra player.sendMessage functions to add custom colors/bold/underline
-player clear inventory
-get set if a follower npc is following a player or waiting
-a bunch of stuff to script faction
-is an item food and how many food points?
-get scoreboard team by it's name
-get and create factions from the script world
-world.rayCastBlockPos is used for getting what block a player is looking at.
-world.getNearestAir is meant to get the block of air above or around the result of world.rayCastBlockPos, or at least that's how I've been using it.
Changes:
-in NoppesUtilServer I feel like if an npc is cloned it's ticksExisted or age should bee zero
-follower npcs should have the canDespawn field automatically set to false...? maybe make it an option
2022-05-24 03:06:16 -05:00
Luis C.M
33bb0307e9
Separated data objects and data controller objects in the noppes.npcs.controllers package.
2022-05-24 01:07:50 -05:00
Luis C.M
6220a8ce14
-Overlays for players and NPCs are now grouped in an "overlay handler" object, similar to how you retrieve timers.
...
-Fixed client NPC overlay updates.
2022-05-23 20:41:32 -05:00
Luis C.M
b9266c3cc5
Added plenty more documentation for the javadoc.
2022-05-17 18:02:09 -05:00
Luis C.M
8bc3190295
Implemented multiple overlay layers for CNPCs, replaces powered textures.
2022-05-17 04:34:46 -05:00
Luis C.M
e8a3eb8344
Implemented offsets for player skin overlays
2022-05-17 00:01:31 -05:00
Luis C.M
f9fcd6b9f8
Added alpha, size, scale, and speed attributes to player skin overlays.
2022-05-16 23:27:11 -05:00
Luis C.M
83fbccdf55
Added setAlpha to skin overlays
2022-05-16 22:14:11 -05:00
Luis C.M
6f9358c1ca
Glow can be disabled/enabled on skin overlays
2022-05-16 22:04:54 -05:00
Luis C.M
dbfbab7be2
Players can now have multiple skin overlays, just like GUI overlays.
2022-05-16 18:47:16 -05:00
Luis C.M
9a0aae50e0
Implemented custom player overlays.
2022-05-16 05:45:00 -05:00
Luis C.M
cf33b90b26
Used interfaces in implementations instead of the real classes for most scripted classes.
2022-05-11 22:08:31 -05:00
Luis C.M
6896cec417
Every function in API classes that calls the main API class now calls the loaded API wrapper, renamed to NpcAPI, instead of the abstract class, renamed to AbstractNpcAPI.
2022-05-11 17:12:48 -05:00
Luis C.M
6dea5a1cbc
Interfaces have a file strucutre resembling the file structure of their implementing classes.
2022-05-11 16:43:14 -05:00
Luis C.M
c2546c3f82
Updated interfaces to have the proper functions. Documentation will focus around them, so they'll be better organized from now on.
2022-05-11 16:31:14 -05:00
Luis C.M
26f5f86dca
Implemented Scripted Custom Items.
2022-05-11 01:10:31 -05:00
Luis C.M
d41b3b7a7e
ScriptEntity:
...
-Added setInvisible, setSneaking, setSprinting, and getUniqueID() functions.
ScriptLivingBase:
-Added getLookVec() function
ScriptPlayer:
-Added stopUsingItem(), clearItemInUse(), playSound(name,volume,pitch), mountEntity(entity), dropOneItem(shouldDropStack), canHarvestBlock(block), interactWith(entity) functions
2022-05-03 11:26:04 -05:00
Luis C.M
b309738c0b
Fixed swingHand() function for ScriptPlayer
2022-05-02 01:41:43 -05:00
Luis C.M
65bb3b5939
Important fix to some NPC hook scripts crashing, added option and dialog object fields to local NPC dialog and NPC dialog closed scripts
2022-04-09 00:17:16 -05:00
Luis C.M
769a574210
Fixed setHunger/Saturation using client-side functions from FoodStats
2022-03-19 22:51:39 -05:00
luisc
70536de655
Removed checkQuestCompleted from ScriptPlayer, now redundant with new quest checks that happen periodically.
2022-02-02 07:21:45 -06:00
luisc
1ebf747302
Optimized NBT access of player data when checking quest completion, player data variable is passed down to lower functions.
...
Player's quests are checked for completion every couple seconds now.
2022-02-02 07:18:33 -06:00
luisc
7de585843d
Added get/setHunger, and get/setSaturation functions for ScriptPlayer.
...
The player KeyPressed event now sends a list of keys that are currently pressed by the player.
2022-01-31 20:16:00 -06:00
luisc
534f716991
Implemented Scripted Overlays which stay on the player's screen. Overlays persist in the client, and can be removed from the screen as well.
2022-01-30 04:05:01 -06:00
luisc
04def38b63
Added dialog events to scripted player events
2022-01-12 22:59:03 -06:00
luisc
6b9cfb9d25
Implemented custom GUIs.
2022-01-12 04:44:08 -06:00
luisc
d50f51e208
Added handler support to NPC API.
2022-01-10 15:21:48 -06:00
luisc
12cb6a2937
Added blocking() function to ScriptPlayer to check whether the player is blocking.
2021-12-15 00:02:27 -06:00
luisc
cf91d8638f
Fixed getDBCPlayer not returning a DBC Player instance.
2021-12-13 18:33:20 -06:00
luisc
3cd1410c19
Added new ScriptDBCPlayer class for manipulating Dragon Block C attributes.
...
Flying NPCs no longer chase you down if you're dead, or if they're dead.
2021-12-05 15:04:03 -06:00
luisc
0d807b36d9
Added isGUIOpen() function, and setPosition function with a dimensionId parameter to ScriptPlayer.
2021-11-16 10:41:04 -06:00
luisc
6fcf566ef7
Made setRotation work for players, with yaw and pitch parameters.
2021-10-24 23:33:22 -05:00
luisc
18aa2d099f
Added updatePlayerInventory to ScriptPlayer
2021-10-24 01:53:20 -05:00
luisc
a29058d696
Fixed timers on the server-side.
2021-10-22 02:22:45 -05:00
luisc
4de969f6c9
Implemented scripted timers for players and NPCs.
2021-10-20 23:04:52 -05:00
luisc
15bfbcdbd1
Added storeAsClone function. Made some fields in Script Entity, NPC, and Player public because of the refactoring.
2021-10-18 07:02:19 -05:00
luisc
72f2c3c60a
Implemented global Forge events. Reorganized NPC API files.
2021-10-18 06:33:39 -05:00