বসানো প্রকার
সেভ করা পৃষ্ঠা গুছিয়ে রাখতে 'সংগ্রহ' ব্যবহার করুন
আপনার পছন্দ অনুযায়ী কন্টেন্ট সেভ করুন ও সঠিক বিভাগে রাখুন।
adBreak()
সমস্ত কলে একটি প্লেসমেন্টের ধরন নির্দিষ্ট করতে হবে। এটি একটি স্ট্রিং যা আপনার গেমের অবস্থা বর্ণনা করে যখন বিজ্ঞাপনটি দেখানো হবে৷ আপনার খেলা কি শুধু লোড হচ্ছে? প্লেয়ার খেলা খেলা বিরতি দিয়েছেন? অথবা তারা আপনার গেমের এমন একটি পয়েন্টে পৌঁছেছে যেখানে তাদের একটি পুরষ্কার দেওয়া যেতে পারে?
আপনি যে সুনির্দিষ্ট প্রকার ব্যবহার করেন তা গুরুত্বপূর্ণ। যেহেতু এটি দেখানো হবে এমন বিজ্ঞাপনের অভিজ্ঞতাকে সরাসরি প্রভাবিত করতে পারে (একটি ইন্টারস্টিশিয়াল বনাম একটি পুরস্কৃত বিজ্ঞাপন)। কিন্তু এটি API-এর আচরণে অন্যান্য কম দৃশ্যমান প্রভাবও থাকতে পারে। এটি গুরুত্বপূর্ণ যে আপনি প্লেসমেন্টের ধরনটি সঠিকভাবে নির্দিষ্ট করুন যাতে API সর্বোত্তমভাবে কাজ করতে পারে।
বসানোর ধরন | বর্ণনা |
---|
'preroll' | আপনার গেমটি এর UI লোড করেনি এবং সাউন্ড বাজছে না। প্রতিটি পৃষ্ঠা লোডের জন্য আপনার গেমে শুধুমাত্র একটি 'প্রিরোল' প্লেসমেন্ট থাকতে পারে।
উদাহরণ: একজন খেলোয়াড় একটি গেম ক্যাটালগের মধ্যে আপনার গেমটিতে ক্লিক করে। গেমের ক্যানভাস প্রদর্শিত হয় এবং আপনার গেমটি তার UI রেন্ডার করার আগে বা শব্দ সক্ষম করার আগে একটি বিজ্ঞাপন দেখানো হয়। প্লেয়ার বিজ্ঞাপনটিতে ক্লিক করতে পারে বা খেলাটি কোন সময়ে শুরু হবে তা বাতিল করতে পারে। |
'start' | আপনার গেমটি লোড হয়েছে, UI দৃশ্যমান এবং শব্দ সক্ষম করা হয়েছে, প্লেয়ার গেমটির সাথে ইন্টারঅ্যাক্ট করতে পারে, কিন্তু গেম প্লে এখনও শুরু হয়নি৷
উদাহরণ: আপনি একটি সংক্ষিপ্ত লোডিং স্ক্রীন "লোড হচ্ছে..." প্রদর্শন করেন এবং একটি ইন্টারস্টিশিয়াল বিজ্ঞাপন দেখানো হয়। প্লেয়ার খেলা চালিয়ে যেতে বিজ্ঞাপনটিতে ক্লিক করতে পারে বা বাতিল করতে পারে।
দ্রষ্টব্য: একটি preroll আপনার জন্য একটি start প্লেসমেন্টের চেয়ে বেশ কিছুটা বেশি কাজ করে। preroll এপিআই শুরু হওয়ার জন্য অপেক্ষা করে এবং স্বয়ংক্রিয়ভাবে বিজ্ঞাপনগুলি প্রিলোড করে। UI রেন্ডার হওয়ার আগে আপনার গেমটি লোড হওয়ার সময় দেখানো start বিজ্ঞাপনের জন্য স্টার্টের পরিবর্তে আপনার preroll ব্যবহার করা উচিত। আপনার UI রেন্ডার হয়ে গেলে এবং প্লেয়ার গেমের সাথে ইন্টারঅ্যাক্ট করতে সক্ষম হলে start একটি ভাল প্লেসমেন্ট। start ব্যবহার করা যেতে পারে যখন গেম রিস্টার্ট হয়- প্রতি পৃষ্ঠা লোডের জন্য একাধিক start প্লেসমেন্ট থাকতে পারে। যদি একটি start প্লেসমেন্ট আপনার গেমের প্রথম প্লেসমেন্ট হয় (যেমন আপনি preroll প্লেসমেন্ট ব্যবহার করেন না), তাহলে আপনাকে ম্যানুয়ালি অনুরোধ করতে হতে পারে যে বিজ্ঞাপনগুলি আগে থেকে লোড করা হয়েছে । |
'pause' | খেলোয়াড় খেলা থামিয়ে দেয়।
উদাহরণ: প্লেয়ার গেমটি বিরতি দেয় এবং একটি ইন্টারস্টিশিয়াল বিজ্ঞাপন দেখানো হয়। প্লেয়ার এটি বাতিল না করা পর্যন্ত বিজ্ঞাপনটি স্ক্রিনে থাকে। তারা যখন ফিরে আসে তখনও খেলা বন্ধ থাকে। প্লেয়ার তারপর গেমটি আবার শুরু করতে পারে এবং খেলা চালিয়ে যেতে পারে। |
'next' | প্লেয়ার পরবর্তী স্তরে নেভিগেট করে।
উদাহরণ: প্লেয়ার সবেমাত্র একটি স্তর সম্পন্ন করেছে। তারা একটি বোতামে ট্যাপ করে "পরবর্তী স্তর..." একটি ইন্টারস্টিশিয়াল বিজ্ঞাপন দেখানো হয়। তারা বিজ্ঞাপনটি দেখে, এটি খারিজ করে এবং পরবর্তী স্তরে এগিয়ে যায়। |
'browse' | প্লেয়ার গেমপ্লের বাইরে বিকল্পগুলি অন্বেষণ করে।
উদাহরণ: খেলোয়াড় তাদের চরিত্রের শৈলী পরিবর্তন করতে চায়। তারা "বিকল্প..." বোতামে ট্যাপ করে একটি ইন্টারস্টিশিয়াল বিজ্ঞাপন দেখানো হয়। তারা বিজ্ঞাপনটি দেখে, এটি খারিজ করে এবং চরিত্র সম্পাদকের কাছে যায়। |
'reward' | খেলোয়াড় গেমের এমন একটি পয়েন্টে পৌঁছায় যেখানে তাদের একটি পুরষ্কার দেওয়া যেতে পারে।
উদাহরণ: খেলোয়াড় সবেমাত্র মারা গেছে এবং জীবন শেষ হয়ে গেছে। এই সময়ে তারা একটি বোনাস জীবন অফার করে যদি তারা একটি বিজ্ঞাপন দেখে। প্লেয়ারকে পুরষ্কার দেওয়ার জন্য অ্যাড প্লেসমেন্ট API আপনার কোডকে কল করে। তারা পুরষ্কার বোতামটি আলতো চাপুন এবং একটি ভিডিও বিজ্ঞাপনের সমস্ত দেখুন৷ তারপরে তারা একটি নতুন জীবন পায় এবং খেলতে থাকে। |
দ্রষ্টব্য : বসানো ধরনের এই সেটটি সক্রিয় বিকাশের একটি ক্ষেত্র।
যদি আপনার গেমে এমন প্লেসমেন্ট থাকে যা স্বাভাবিকভাবেই এই শ্রেণীগুলির মধ্যে একটির সাথে খাপ খায় না, তাহলে আপনার Google অ্যাকাউন্ট ম্যানেজারকে জানান, এবং আমরা এই বিভাগগুলিকে পরিমার্জিত করতে সময়ের সাথে সাথে এই প্রতিক্রিয়াটি ব্যবহার করব৷
অন্য কিছু উল্লেখ না করা থাকলে, এই পৃষ্ঠার কন্টেন্ট Creative Commons Attribution 4.0 License-এর অধীনে এবং কোডের নমুনাগুলি Apache 2.0 License-এর অধীনে লাইসেন্স প্রাপ্ত। আরও জানতে, Google Developers সাইট নীতি দেখুন। Java হল Oracle এবং/অথবা তার অ্যাফিলিয়েট সংস্থার রেজিস্টার্ড ট্রেডমার্ক।
2025-07-24 UTC-তে শেষবার আপডেট করা হয়েছে।
[null,null,["2025-07-24 UTC-তে শেষবার আপডেট করা হয়েছে।"],[[["\u003cp\u003eAll calls to \u003ccode\u003eadBreak()\u003c/code\u003e require a placement type string describing the game's state when the ad is shown (e.g., loading, paused, reward offered).\u003c/p\u003e\n"],["\u003cp\u003eThe placement type impacts the ad experience (interstitial or rewarded) and the API's behavior, so accurate specification is crucial for optimal performance.\u003c/p\u003e\n"],["\u003cp\u003ePlacement types include \u003ccode\u003epreroll\u003c/code\u003e (before UI loads), \u003ccode\u003estart\u003c/code\u003e (after UI loads), \u003ccode\u003epause\u003c/code\u003e, \u003ccode\u003enext\u003c/code\u003e, \u003ccode\u003ebrowse\u003c/code\u003e, and \u003ccode\u003ereward\u003c/code\u003e, each with specific use cases.\u003c/p\u003e\n"],["\u003cp\u003eWhile the current placement types cover common scenarios, developers with unique placements should inform their Google Account Manager for potential refinements to the categories.\u003c/p\u003e\n"]]],["The `adBreak()` function requires a placement type string, which defines the game's state when an ad appears. Placement types include `'preroll'` (game loading, before UI), `'start'` (game loaded, UI visible), `'pause'` (game paused), `'next'` (level transition), `'browse'` (exploring non-gameplay options), and `'reward'` (player offered an in-game reward for watching an ad). The selected placement directly impacts ad type and API behavior. `'preroll'` preloads ads and is preferable for the first ad.\n"],null,["# Placement types\n\nAll calls to `adBreak()` must specify a placement type. This is a string that\ndescribes the state of your game when the ad will be shown. Is your game just\nloading? Has the player paused the game play? Or have they reached a point in\nyour game where they could be offered a reward?\n\nThe precise type that you use is important. As it can directly affect the kind\nof ad experience that will be shown (an interstitial versus a rewarded ad). But\nit can also have other less visible effects on behaviour of the API. It's\nimportant that you specify the placement type correctly so the API can work\noptimally.\n\n| Placement type | Description |\n|----------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `'preroll'` | Your game has not loaded its UI and is not playing sound. There can only be one 'preroll' placement in your game for each page load. **Example:** a player clicks on your game within a game catalogue. The game canvas is displayed, and before your game renders its UI or enables sound an ad is shown. The player can click on the ad or dismiss it at which point the game will start. |\n| `'start'` | Your game has loaded, the UI is visible and sound is enabled, the player can interact with the game, but the game play has not started yet. **Example:** You display a brief loading screen \"Loading...\" and an interstitial ad is shown. The player can click on the ad or dismiss it to continue to the game. **NOTE:** A `preroll` does quite a bit more work for you than a `start` placement. `preroll` waits for the API to initialise and automatically preloads ads. You should use `preroll` instead of `start` for the very first ad that's shown while your game is loading, before the UI has rendered. `start` is a better placement once your UI has rendered and the player is able to interact with the game. `start` can also be used when the game restarts---there can be multiple `start` placements per page load. If a `start` placement is the very first placement in your game (i.e. you don't use the `preroll` placement), you may need to [manually request that ads are preloaded](/ad-placement/docs/preload-ads). |\n| `'pause'` | The player pauses the game. **Example:** the player pauses the game and an interstitial ad is shown. The ad remains on the screen until the player dismisses it. When they return the game is still paused. The player can then resume the game and keep playing. |\n| `'next'` | The player navigates to the next level. **Example:** The player has just completed a level. They tap a button \"Next level...\" an interstitial ad is shown. They view the ad, dismiss it, and proceed to the next level. |\n| `'browse'` | The player explores options outside of the gameplay. **Example:** The player wants to alter the style of their character. They tap the button \"Options...\" an interstitial ad is shown. They view the ad, dismiss it, and proceed to the character editor. |\n| `'reward'` | The player reaches a point in the game where they can be offered a reward. **Example:** The player has just died and run out of lives. They are offered a bonus life at this point if they watch an ad. The Ad Placement API calls your code to offer the reward to the player. They tap the reward button and watch all of a video ad. They then receive a new life and keep playing. |\n\n**Note**: this set of placement types is an\narea of active development.\n\nIf you have placements in your game that don't naturally fit into one of\nthese categories, let your Google Account Manager know, and we will use this\nfeedback over time to refine these categories."]]